/* ========================================
   Template07 Header Styles - New Class Names
   ======================================== */

/* Main Header Container */
.t07-header {
    background-color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 0;
    z-index: 99;
}

.t07-header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Top Section: Logo, Search, Language */
.t07-header-main {
    display: flex;
    justify-content: space-between;
    padding: 18px 0 0;
}

/* Brand Logo */
.t07-header-brand {
    flex-shrink: 0;
}

.t07-brand-logo {
    height: 45px;
    width: auto;
    display: block;
}

/* Search Area: Catalog Button + Search Box */
.t07-header-searcharea {
    display: flex;
    flex: 1;
    max-width: 750px;
    margin: 0 40px;
    flex-direction: column;
}

.search-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Catalog Button */
.t07-catalog-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    background-color: #2196F3;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.t07-catalog-button:hover {
    background-color: #1976D2;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.t07-catalog-button:active {
    transform: translateY(0);
}

.t07-catalog-button span {
    font-weight: 500;
}

/* Search Wrapper */
.t07-search-wrapper {
    flex: 1;
}

.t07-search-form {
    display: flex;
    gap: 12px;
    align-items: center;
    width: 100%;
    position: relative;
}


/* Search Submit Button */
.t07-search-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    background-color: #2196F3;
    color: #fff;
    text-decoration: none;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    flex-shrink: 0;
}

.t07-search-submit:hover {
    background-color: #1976D2;
}

/* Search Icon */
.t07-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #99a1af;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.t07-search-icon svg {
    width: 16px;
    height: 16px;
}

/* Search Input Wrapper */
.t07-search-input-wrapper {
    flex: 1;
    position: relative;
}

/* Search Input Field */
.t07-search-field {
    width: 100%;
    padding: 10px 15px 10px 38px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
    outline: none;
    background-color: #f5f7fa;
    border: 1px solid #e8ecf1;
    border-radius: 4px;
    transition: all 0.3s ease;

}
.t07-search-field:hover {
    border-color: #d0d7e2;
    background-color: #fff;
}

.t07-search-field:focus-within {
    border-color: #2196F3;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}


.t07-search-field::placeholder {
    color: #99a1af;
}

.t07-search-field:focus {
    color: #333;
}

/* Header Tools: Language Selector */
.t07-header-tools {
    display: flex;
    flex-shrink: 0;
}

.t07-lang-switcher {
    display: flex;
}

.t07-lang-selector {
    height: 40px;
    padding: 8px 32px 8px 12px;
    border: 1px solid #e8ecf1;
    border-radius: 4px;
    background-color: #fff;
    color: #333;
    font-size: 13px;
    cursor: pointer;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%2399a1af'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    transition: all 0.3s ease;
}

.t07-lang-selector:hover {
    border-color: #2196F3;
    color: #2196F3;
}

.t07-lang-selector:focus {
    border-color: #2196F3;
    box-shadow: 0 0 0 2px rgba(33, 150, 243, 0.1);
}

/* Hamburger Menu Button - Desktop: Hidden */
.t07-hamburger-menu {
    display: none;
}

.t07-hamburger-btn {
    background: #f5f7fa;
    border: 1px solid #e8ecf1;
    border-radius: 4px;
    cursor: pointer;
    padding: 12px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.t07-hamburger-btn:hover {
    background: #e8ecf1;
    border-color: #d0d7e2;
}

.t07-hamburger-icon {
    display: block;
    width: 20px;
    height: 2px;
    background-color: #333;
    position: relative;
    transition: all 0.3s ease;
}

.t07-hamburger-icon::before,
.t07-hamburger-icon::after {
    content: '';
    position: absolute;
    right: 0;
    width: 20px;
    height: 2px;
    background-color: #333;
    transition: all 0.3s ease;
}

.t07-hamburger-icon::before {
    top: -6px;
}

.t07-hamburger-icon::after {
    top: 6px;
    width: 20px;
}

/* Hamburger active state (X icon) */
.t07-hamburger-btn.active .t07-hamburger-icon {
    background-color: transparent;
}

.t07-hamburger-btn.active .t07-hamburger-icon::before {
    transform: rotate(45deg);
    top: 0;
}

.t07-hamburger-btn.active .t07-hamburger-icon::after {
    transform: rotate(-45deg);
    top: 0;
}

/* Mobile Navigation Dropdown */
.t07-mobile-nav {
    display: none;
    background-color: #fff;
    border-top: 1px solid #e8ecf1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.t07-mobile-nav.t07-mobile-nav-open {
    max-height: 300px;
}

.t07-mobile-nav-menu ul {
    list-style: none;
    margin: 0;
    padding: 12px 20px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.t07-mobile-nav-menu li {
    border-bottom: 1px solid #f0f2f5;
}

.t07-mobile-nav-menu li:last-child {
    border-bottom: none;
}

.t07-mobile-nav-menu a {
    display: block;
    padding: 12px 0;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: all 0.3s ease;
}

.t07-mobile-nav-menu a:hover {
    color: #2196F3;
    padding-left: 8px;
}

.t07-mobile-nav-menu a span {
    font-weight: 400;
}

/* Bottom Navigation */
.t07-header-navigation {
    border-top: none;
    padding: 0;
    background-color: #fff;
}

.t07-nav-menu {
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.t07-nav-menu ul {
    display: flex;
    list-style: none;
    gap: 45px;
    margin: 0;
    padding: 0;
}

.t07-nav-menu li {
    margin: 0;
}

.t07-nav-menu a {
    text-decoration: none;
    color: #6b7280;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    padding: 14px 0;
    position: relative;
    white-space: nowrap;
}

.t07-nav-menu span {
    font-weight: 400;
}

/* Navigation Hover State */
.t07-nav-menu a:hover {
    color: #2196F3;
}

/* Navigation Active State */
.t07-nav-active {
    color: #2196F3 !important;
    font-weight: 600 !important;
}

.t07-nav-active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #2196F3;
    border-radius: 1px 1px 0 0;
}

.t07-nav-active span {
    font-weight: 600;
    color: #2196F3;
}

/* Responsive Design */
/* 1. 手机 */
@media (max-width: 767px) {
    .t07-header-container {
        position: relative;
    }

    .t07-header-main {
        flex-direction: column;
        gap: 0;
        padding: 0;
        position: relative;
        min-height: 45px;
    }

    /* Logo on top-left */
    .t07-header-brand {
        position: absolute;
        top: 8px;
        left: 0;
    }

    /* Language selector and hamburger on top-right */
    .t07-header-tools {
        position: absolute;
        top: 8px;
        right: 0;
        height: 32px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    /* Show hamburger menu on mobile */
    .t07-hamburger-menu {
        display: block;
    }

    /* Hide desktop navigation on mobile */
    .t07-header-navigation {
        display: none;
    }

    /* Show mobile navigation dropdown */
    .t07-mobile-nav {
        display: block;
    }

    /* Search area below logo/language */
    .t07-header-searcharea {
        max-width: 100%;
        margin: 42px 0 8px;
        order: 2;
    }

    .search-wrapper {
        flex-direction: row;
        gap: 8px;
        align-items: center;
    }

    .t07-catalog-button span {
        display: inline;
    }

    .t07-catalog-button {
        padding: 10px 16px;
    }

    .t07-catalog-button::before {
        display: none;
    }

    .t07-lang-selector {
        height: 32px !important;
        padding: 4px 24px 4px 8px;
        font-size: 11px;
        min-height: 32px;
        max-height: 32px;
    }
}

/* 2. 平板 */
@media (min-width: 768px) and (max-width: 991px) {
    .t07-header-searcharea {
        max-width: 500px;
        margin: 0 20px;
        gap: 10px;
    }

    .t07-catalog-button {
        padding: 8px 14px;
        font-size: 13px;
    }

    .t07-nav-menu ul {
        gap: 30px;
    }

    .t07-nav-menu a {
        font-size: 13px;
    }
}

/* 3. 小屏手机 */
@media (max-width: 576px) {
    .t07-header-container {
        padding: 0 8px;
    }

    .t07-header-main {
        min-height: 40px;
    }

    .t07-header-brand {
        top: 6px;
    }

    .t07-header-tools {
        top: 6px;
        height: 28px;
    }

    .t07-brand-logo {
        height: 25px;
    }

    .t07-header-searcharea {
        margin: 36px 0 6px;
    }

    .t07-search-field {
        padding: 8px 12px 8px 34px;
        font-size: 12px;
    }

    .t07-nav-menu ul {
        gap: 10px;
    }

    .t07-nav-menu a {
        font-size: 11px;
        padding: 5px 0;
    }

    .t07-lang-selector {
        height: 28px !important;
        padding: 3px 20px 3px 6px;
        font-size: 10px;
        min-height: 28px;
        max-height: 28px;
    }
}