:root {
    --beige: #EFF0EA;
    --sidebar-color: #EFF0EA;
    --gray-blue: #4A5568;
    --dark-gray: #333333;
}

body {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    color: var(--dark-gray);
    background-color: var(--beige);
    line-height: 1.6;
    scroll-behavior: smooth;
}

header {
    background: var(--sidebar-color);
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 250px;
    z-index: 1000;
    border-right: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    padding: 2rem 1.5rem;
    box-sizing: border-box;
}

nav {
    display: flex;
    flex-direction: column;
    width: 100%;
    align-items: center;
}

.logo {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
    width: 100%;
}

.logo-text {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--gray-blue);
    letter-spacing: -1px;
    text-decoration: none;
    line-height: 1;
}

.logo a {
    text-decoration: none;
}

.logo img {
    max-width: 100%;
    height: auto;
}

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    width: 100%;
    text-align: center;
}

.nav-links li {
    margin-left: 0;
    margin-bottom: 1.5rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-gray);
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #999;
}

.login-link, .admin-link {
    font-weight: bold;
    color: var(--gray-blue) !important;
}

.login-link:hover, .admin-link:hover {
    color: var(--dark-gray) !important;
}

main {
    padding-top: 0;
    margin-left: 250px;
}

section {
    padding: 100px 5%;
    max-width: 1000px;
    margin: 0 auto;
}

.container {
    text-align: center;
}

h1, h2 {
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 2rem;
    color: var(--gray-blue);
}

#hero {
    height: 100vh;
    background: url('/images/front.webp?w=1920') center 60% / cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    max-width: 100%;
    padding: 0;
    position: relative;
}

#hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    margin-top: -10vh; /* Поднимаем текст чуть выше центра */
}

#about, #portfolio, #price, #contact {
    background-color: var(--beige);
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: white;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: white;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: transparent;
    border: 2px solid white;
    color: white;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s;
}

.cta-button:hover {
    background: white;
    color: black;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-images {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    justify-content: center;
}

.about-images img {
    width: calc(50% - 0.5rem);
    height: auto;
    object-fit: cover;
    border-radius: 12px;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.gallery-item {
    aspect-ratio: 1 / 1;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border-radius: 12px;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
}

.modal-content {
    position: relative;
    margin: auto;
    padding: 0;
    width: 90%;
    max-width: 1200px;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 600px) {
    .modal {
        padding-top: 30px;
    }
    
    .modal-content {
        width: 100%;
    }
    
    .prev, .next {
        padding: 10px;
        font-size: 20px;
    }
    
    .close {
        right: 20px;
        top: 10px;
    }
}

.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    z-index: 2100;
}

.close:hover,
.close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

.prev, .next {
    cursor: pointer;
    position: fixed;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white;
    font-weight: bold;
    font-size: 30px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
    background-color: rgba(0,0,0,0.3);
    z-index: 2200;
}

.next {
    right: 20px;
    border-radius: 3px 0 0 3px;
}

.prev {
    left: 20px;
}

.prev:hover, .next:hover {
    background-color: rgba(0,0,0,0.8);
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    padding: 20px;
    text-align: center;
    box-sizing: border-box;
}

.overlay span {
    width: 100%;
    display: block;
}

.gallery-item:hover .overlay {
    opacity: 1;
}

.portfolio-more {
    margin-top: 4rem;
    text-align: center;
}

.portfolio-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: transparent;
    border: 2px solid var(--gray-blue);
    color: var(--gray-blue);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s;
    font-weight: 400;
    border-radius: 4px;
}

.portfolio-button:hover {
    background: var(--gray-blue);
    color: white;
}

.price-sections {
    max-width: 900px;
    margin: 3rem auto 0;
    text-align: left;
}

.price-group {
    background: white;
    padding: 2.5rem;
    margin-bottom: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.price-group h3 {
    color: var(--gray-blue);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    padding-bottom: 1rem;
}

.price-cards {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.price-card {
    flex: 1;
    min-width: 250px;
    padding: 1.5rem;
    background: #fdfbf8;
    border-radius: 8px;
    border-left: 4px solid var(--gray-blue);
}

.price-card-header {
    font-size: 0.9rem;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 0.5rem;
}

.price-card-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-gray);
}

.price-note-inline {
    font-size: 0.9rem;
    font-style: italic;
    color: #888;
    margin-top: 0.5rem;
}

.price-list {
    list-style: none;
    padding: 0;
}

.price-list li {
    margin-bottom: 1rem;
    position: relative;
    padding-left: 1.8rem;
    line-height: 1.5;
}

.price-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--gray-blue);
    font-weight: bold;
}

.work-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.step {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    line-height: 1.4;
}

.step-num {
    background: var(--gray-blue);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.8rem;
    font-weight: bold;
}

.price-note {
    margin-top: 2rem;
    font-size: 0.9rem;
    font-style: italic;
    color: #888;
}

.contact-info {
    font-size: 1.1rem;
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-info a {
    color: var(--gray-blue);
    text-decoration: none;
    transition: opacity 0.3s;
    font-weight: 400;
}

.contact-info a:hover {
    opacity: 0.7;
    text-decoration: underline;
}

footer {
    text-align: center;
    padding: 2rem;
    background: var(--beige);
    border-top: 1px solid rgba(0,0,0,0.05);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-left: 250px;
}

/* Mobile Navigation Toggle (Burger) */
.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--gray-blue);
    cursor: pointer;
    z-index: 2100; /* Higher than header and sidebar */
    position: fixed;
    top: 5px;
    right: 1.5rem;
}

@media (max-width: 992px) {
    .mobile-nav-toggle {
        display: block;
    }

    header {
        position: fixed;
        width: 100%;
        height: 60px;
        top: 0;
        left: 0;
        padding: 0;
        flex-direction: row;
        align-items: center;
        border-right: none;
        border-bottom: 1px solid rgba(0,0,0,0.05);
        background: var(--sidebar-color);
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
        z-index: 2000;
    }

    nav {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0 1.5rem;
        height: 100%;
        width: 100%;
    }

    .logo {
        margin-bottom: 0;
        justify-content: flex-start;
        width: auto;
    }

    .logo-text {
        font-size: 1.5rem;
    }

    .nav-links {
        position: fixed;
        top: 60px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 60px);
        background: var(--sidebar-color);
        flex-direction: column;
        justify-content: center;
        transition: left 0.3s ease;
        padding: 2rem;
        box-sizing: border-box;
        display: flex; /* Overriding previous display: none */
        z-index: 1999;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        margin-bottom: 2rem;
    }

    .nav-links a {
        font-size: 1.2rem;
    }

    main {
        margin-left: 0;
        padding-top: 60px; /* Space for fixed header */
    }

    section {
        padding: 60px 5%;
    }

    footer {
        margin-left: 0;
    }

    .hero-content h1 {
        font-size: 2rem;
        letter-spacing: 2px;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .about-images {
        flex-direction: column;
    }

    .about-images img {
        width: 100%;
    }

    .gallery {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .price-group {
        padding: 1.5rem;
    }

    .price-card {
        min-width: 100%;
    }
}

.sidebar {
    width: 250px;
    background-color: var(--sidebar-color);
    border-right: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    padding: 2rem 1.5rem;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
    box-sizing: border-box;
    transition: left 0.3s ease;
}

.main-content {
    margin-left: 250px;
    flex-grow: 1;
    padding: 2rem;
    width: calc(100% - 250px);
    transition: margin-left 0.3s ease, width 0.3s ease;
}

@media (max-width: 992px) {
    .sidebar {
        left: -250px;
        top: 60px;
        height: calc(100vh - 60px);
    }
    
    .sidebar.active {
        left: 0;
    }
    
    .main-content {
        margin-left: 0;
        width: 100%;
        padding: 1rem;
        padding-top: 80px;
    }
}
