/* HEADER STYLES - NEW DESIGN */

/* ВАЖНО: Обеспечиваем прозрачность ВСЕХ родительских элементов */
body,
html,
#page,
.site,
.site-header,
.site-header *:not(.header-container):not(.header-container *) {
    background: transparent !important;
}

/* УБИРАЕМ ОТСТУП - контент должен начинаться с самого верха! */
.site-content {
    position: relative;
    z-index: 1;
}

.site-header {
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999;
    padding: 0 !important;
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
    border: none !important;
    pointer-events: none;
}

.site-header::before,
.site-header::after {
    content: none !important;
    display: none !important;
    background: none !important;
}

.header-container {
    max-width: 1400px;
    margin: 15px 30px 0;
    background: transparent !important;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 2px solid rgba(255, 255, 255, 0.9);
    border-radius: 50px;
    padding: 12px 30px;
    box-shadow: none;
    transition: all 0.3s ease;
    pointer-events: auto;
}

@media (min-width: 1460px) {
    .header-container {
        margin-left: auto;
        margin-right: auto;
    }
}

.site-header.scrolled .header-container {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 10px 30px;
}

.site-header.scrolled .header-logo {
    min-width: 180px;
}

.site-header.scrolled .logo-placeholder svg {
    width: 38px;
    height: 38px;
}

.site-header.scrolled .logo-title {
    font-size: 16px;
}

.site-header.scrolled .logo-subtitle {
    font-size: 9px;
}

.site-header.scrolled .menu a {
    padding: 10px 18px;
    font-size: 14px;
}

.site-header.scrolled .cta-btn {
    padding: 10px 22px;
    font-size: 14px;
}

.wrapper {
    display: flex;
    align-items: center;
    gap: 50px;
}

/* LOGO */
.header-logo {
    flex-shrink: 0;
    min-width: 200px;
    transition: all 0.3s ease;
}

.header-logo a {
    display: block;
    text-decoration: none;
}

.header-logo .custom-logo {
    height: 50px;
    width: auto;
    display: block;
    transition: all 0.3s ease;
}

.logo-placeholder {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-placeholder svg {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.logo-title {
    font-family: var(--font-heading, 'Montserrat', sans-serif);
    font-size: 17px;
    font-weight: 800;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1;
    transition: all 0.3s ease;
}

.logo-subtitle {
    font-size: 10px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
    transition: all 0.3s ease;
}

/* MENU */
.header-menu {
    display: flex;
    justify-content: center;
}

.menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 5px;
}

.menu li {
    margin: 0;
}

.menu a {
    display: block;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    border-radius: 25px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.menu a:hover,
.menu .current-menu-item a {
    background: rgba(255, 255, 255, 0.12);
}

/* LANGUAGE SWITCHER */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 22px;
    padding: 5px;
}

.lang-switcher a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 18px;
    transition: all 0.3s ease;
}

.lang-switcher a:hover,
.lang-switcher a.active {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

/* HEADER RIGHT */
.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
    margin-left: auto;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 26px;
    background: transparent;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-radius: 25px;
    transition: all 0.3s ease;
    white-space: nowrap;
    cursor: pointer;
    flex-shrink: 0;
}

.cta-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
}

/* MOBILE BUTTON */
.mob-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    width: 28px;
    height: 24px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

.mob-btn span {
    display: block;
    width: 100%;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* MOBILE MENU */
.mob-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mob-menu.active {
    opacity: 1;
    visibility: visible;
    background: rgba(0, 0, 0, 0.7);
}

.mob-inner {
    position: absolute;
    top: 0;
    right: 0;
    width: 320px;
    max-width: 90%;
    height: 100%;
    background: #dd9933;
    padding: 60px 30px 30px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.mob-menu.active .mob-inner {
    transform: translateX(0);
}

.mob-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 35px;
    line-height: 1;
    cursor: pointer;
    color: #fff;
}

.mob-nav {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mob-nav li {
    margin: 0 0 5px;
}

.mob-nav a {
    display: block;
    padding: 12px 15px;
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.mob-nav a:hover,
.mob-nav .current-menu-item a {
    background: rgba(255, 255, 255, 0.1);
}

.mob-contact {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.mob-contact a {
    display: block;
    padding: 10px 0;
    color: #fff;
    text-decoration: none;
}

/* CONTACT POPUP */
.contact-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.contact-popup.active {
    opacity: 1;
    visibility: visible;
    background: rgba(0, 0, 0, 0.8);
}

.popup-content {
    background: #fff;
    border-radius: 12px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    position: relative;
}

.contact-popup.active .popup-content {
    transform: scale(1);
}

.popup-header {
    padding: 30px 30px 20px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.popup-header h3 {
    margin: 0;
    font-size: 24px;
    color: #1a1a1a;
}

.popup-header p {
    margin: 5px 0 0;
    color: #666;
    font-size: 14px;
}

.popup-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
    color: #999;
    transition: all 0.2s ease;
}

.popup-close:hover {
    color: #333;
    transform: rotate(90deg);
}

.popup-body {
    padding: 30px;
}

.contact-form .form-group {
    margin-bottom: 20px;
}

.contact-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.contact-form label .required {
    color: #DC143C;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
    outline: none;
    border-color: #dd9933;
    box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
}

.contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

.contact-form button[type="submit"] {
    width: 100%;
    padding: 14px 24px;
    background: #dd9933;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.contact-form button[type="submit"]:hover {
    background: #c88829;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(221, 153, 51, 0.3);
}

.contact-form button[type="submit"]:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.contact-form button[type="submit"].loading::after {
    content: "...";
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: "."; }
    40% { content: ".."; }
    60%, 100% { content: "..."; }
}

.form-message {
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.form-message.success {
    display: block;
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    display: block;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* RESPONSIVE */

/* 1200px - уменьшаем отступы */
@media (max-width: 1200px) {
    .header-container {
        margin: 15px 25px 0;
        padding: 10px 25px;
    }
    
    .wrapper {
        gap: 40px;
    }
    
    .menu a {
        padding: 11px 18px;
        font-size: 14px;
    }
}

/* 1100px - компактнее */
@media (max-width: 1100px) {
    .header-container {
        margin: 12px 20px 0;
        padding: 10px 22px;
    }
    
    .wrapper {
        gap: 30px;
    }
    
    .menu a {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .cta-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* 1000px - минимальный gap */
@media (max-width: 1000px) {
    .header-container {
        margin: 12px 15px 0;
    }
    
    .wrapper {
        gap: 20px;
    }
    
    .menu a {
        padding: 9px 14px;
        font-size: 13px;
    }
    
    .header-logo {
        min-width: 180px;
    }
    
    .logo-title {
        font-size: 16px;
    }
    
    .logo-subtitle {
        font-size: 9px;
    }
    
    .logo-placeholder svg {
        width: 38px;
        height: 38px;
    }
}

/* 900px - переход на мобильный */
@media (max-width: 900px) {
    .header-container {
        margin: 12px 15px 0;
        border-radius: 35px;
        padding: 8px 16px;
    }
    
    .header-menu,
    .lang-switcher {
        display: none;
    }
    
    .mob-btn {
        display: flex;
    }
    
    .cta-btn {
        padding: 8px 14px;
        font-size: 12px;
    }
}

/* 768px - мобильный */
@media (max-width: 768px) {
    .header-container {
        margin: 10px 12px 0;
        border-radius: 30px;
        padding: 8px 14px;
    }
    
    .wrapper {
        gap: 10px;
    }
    
    .header-logo {
        min-width: 135px;
    }
    
    .logo-title {
        font-size: 13px;
    }
    
    .logo-subtitle {
        font-size: 7px;
    }
    
    .logo-placeholder svg {
        width: 28px;
        height: 28px;
    }
    
    .popup-header,
    .popup-body {
        padding: 20px;
    }
    
    .popup-header h3 {
        font-size: 20px;
    }
}

/* 480px - маленькие экраны */
@media (max-width: 480px) {
    .header-container {
        margin: 10px 10px 0;
        border-radius: 25px;
        padding: 7px 12px;
    }
    
    .header-logo {
        min-width: 120px;
    }
    
    .logo-title {
        font-size: 12px;
    }
    
    .logo-subtitle {
        font-size: 7px;
    }
    
    .logo-placeholder svg {
        width: 26px;
        height: 26px;
    }
    
    .cta-btn {
        font-size: 0;
        padding: 7px 10px;
    }
    
    .cta-btn::after {
        content: "✉";
        font-size: 14px;
    }
    
    .popup-content {
        max-width: 100%;
        border-radius: 0;
    }
}