/* ==========================================
   CONTAINER & LAYOUT
   ========================================== */

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.section {
    padding: var(--spacing-xl) 0;
    position: relative;
}

.section + .section {
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.section__header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.section__title {
    font-family: var(--font-heading);
    font-size: 48px;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.02em;
    position: relative;
    display: inline-block;
    transition: transform 0.3s ease;
}

.section__title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.6;
}

.section__subtitle {
    font-size: 18px;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.section__cta {
    text-align: center;
    margin-top: var(--spacing-lg);
}

/* ==========================================
   HEADER & NAVIGATION
   ========================================== */

.header {
    position: sticky;
    top: 0;
    background-color: rgba(245, 240, 233, 0.85);
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 20px 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Backdrop-filter только для десктопа */
@media (min-width: 768px) {
    .header {
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
    }
}

.header.scrolled {
    background-color: rgba(245, 240, 233, 0.95);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 15px 0;
}

.header__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    overflow: visible;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
    position: relative;
}

.logo:hover {
    transform: translateY(-2px);
}

/* Instagram Link Styles */
.instagram-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.instagram-icon {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}

.instagram-handle {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #6a1523 0%, #ffc987 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.instagram-link .instagram-icon {
    color: #6a1523;
}

.instagram-link:hover .instagram-icon {
    transform: scale(1.1) rotate(5deg);
    color: #ffc987;
}

.instagram-link:hover {
    transform: translateY(-2px);
}

.instagram-link:hover .instagram-handle {
    background: linear-gradient(135deg, #ffc987 0%, #6a1523 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo__image {
    height: 45px;
    width: auto;
    transition: transform 0.3s ease;
}

/* Дмитренко - тонкий элегантный sans-serif с градиентом */
.logo__surname {
    font-family: 'Lato', sans-serif;
    font-size: 22px;
    font-weight: 100;
    font-style: italic;
    background: linear-gradient(
        90deg,
        #C79A6B 0%,
        #D0A272 30%,
        #D8AD7F 50%,
        #D0A272 70%,
        #C79A6B 100%
    );
    background-size: 300% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: logoGradient 6s ease-in-out infinite;
    letter-spacing: 0.05em;
    line-height: 1;
    white-space: nowrap;
    overflow: visible;
    display: inline-block;
    padding: 0;
}

/* Полина - легкий sans-serif */
.logo__name {
    font-family: 'Lato', sans-serif;
    font-size: 20px;
    font-weight: 300;
    color: #6B2C2C;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
    line-height: 1;
    white-space: nowrap;
    display: inline-block;
    padding: 0;
}

@keyframes logoGradient {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Hover эффект */
.logo:hover .logo__surname {
    animation-duration: 3s;
}

.logo:hover .logo__name {
    color: #812020;
}

/* Адаптивные размеры для SVG логотипа */
@media (min-width: 768px) {
    .logo__image {
        height: 50px;
    }
    
    .instagram-icon {
        width: 26px;
        height: 26px;
    }
    
    .instagram-handle {
        font-size: 17px;
    }
    
    /* На десктопе показываем SVG, скрываем PNG */
    .hero__logo-desktop {
        display: block !important;
    }
    
    .hero__logo-mobile {
        display: none !important;
    }
}

@media (max-width: 767px) {
    .logo__image {
        height: 36px;
    }
    
    .instagram-link {
        gap: 6px;
    }
    
    .instagram-icon {
        width: 20px;
        height: 20px;
    }
    
    .instagram-handle {
        font-size: 14px;
    }
}

.nav__list {
    display: flex;
    gap: var(--spacing-md);
}

.nav__link {
    font-size: 14px;
    font-weight: 400;
    color: var(--text-muted);
    position: relative;
    padding: 8px 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav__link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(199, 154, 107, 0.05), transparent);
    border-radius: 4px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.nav__link:hover::before {
    opacity: 1;
}

.nav__link:hover,
.nav__link.nav-link--active {
    color: var(--text-main);
}

.nav__link::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
    transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav__link:hover::after,
.nav__link.nav-link--active::after {
    width: 100%;
}

/* Burger Menu */
.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    z-index: 1001;
}

.burger span {
    width: 24px;
    height: 2px;
    background-color: var(--text-main);
    transition: var(--transition);
}

.burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.burger.active span:nth-child(2) {
    opacity: 0;
}

.burger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background-color: var(--bg-main);
    z-index: 999;
    padding: 100px var(--spacing-md);
    transition: right 0.4s ease;
}

.mobile-menu.active {
    right: 0;
}

.mobile-nav__list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.mobile-nav__link {
    font-size: 24px;
    font-weight: 400;
    color: var(--text-main);
}

/* SCROLL TO TOP BUTTON */

.scroll-to-top {
    position: fixed;
    bottom: 40px;
    right: 40px;
    width: 50px;
    height: 50px;
    background-color: var(--accent);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 999;
    box-shadow: 0 4px 15px rgba(199, 154, 107, 0.3);
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 25px rgba(199, 154, 107, 0.4);
}

.scroll-to-top::before {
    content: '↑';
    animation: bounceArrow 2s ease-in-out infinite;
}

@keyframes bounceArrow {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-3px);
    }
}
