:root {
    --primary-color: #1d74c4;
    --primary-dark: #082f55;
    --accent-color: #16a0bf;
    --warm-accent: #f2ad38;
    --ink: #10263d;
    --muted: #637487;
    --line: #b6ccdc;
    --surface: #ffffff;
    --soft: #ffffff;
    --dark: #092744;
    --header-dark: #071f36;
    --footer-dark: #2b2b2b;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: #ffffff;
    font-family: "Inter", "Segoe UI", "Roboto", "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(1800px, calc(100% - 48px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #ffffff;
    border-bottom: 1px solid #dde8f0;
    backdrop-filter: blur(14px);
    transition: box-shadow 0.24s ease;
}

.site-header.top-hidden {
    box-shadow: 0 10px 24px rgba(3, 13, 24, 0.16);
}

.top-strip {
    background: #074f91;
    color: rgba(245, 250, 255, 0.9);
    font-size: 0.95rem;
    max-height: 30px;
    overflow: hidden;
    transition: max-height 0.16s ease, opacity 0.12s ease;
}

.site-header.top-hidden .top-strip {
    max-height: 0;
    opacity: 0;
    pointer-events: none;
}

.top-strip-inner,
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.top-strip-inner {
    min-height: 30px;
}

.top-strip-inner span,
.top-contact {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.top-contact {
    margin-left: auto;
    gap: 22px;
}

.header-inner {
    min-height: 60px;
    transition: min-height 0.24s ease;
}

.brand img {
    max-height: 80px;
/*    margin: 8px 0;*/
    width: auto;
    transition: max-height 0.24s ease, margin 0.24s ease;
}

.brand-text {
    color: var(--ink);
    font-size: 1.08rem;
    font-weight: 800;
    letter-spacing: 0;
    transition: font-size 0.24s ease;
}

.main-nav > ul {
    display: flex;
    align-items: center;
    gap: 34px;
    margin: 0;
    padding: 0;
    list-style: none;
    transition: gap 0.24s ease;
}

.main-nav > ul > li {
    position: relative;
}

.main-nav > ul > li > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 36px;
    padding: 0 4px;
    color: #4b5563;
    font-family: "Segoe UI", "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
    font-weight: 600;
    font-size: 1.18rem;
    letter-spacing: 0.01em;
    transition: min-height 0.24s ease, font-size 0.24s ease, color 0.2s ease;
}

.site-header.top-hidden .header-inner {
    min-height: 48px;
}

.site-header.top-hidden .brand img {
    max-height: 52px;
    margin: 4px 0;
}

.site-header.top-hidden .brand-text {
    font-size: 1rem;
}

.site-header.top-hidden .main-nav > ul {
    gap: 28px;
}

.site-header.top-hidden .main-nav > ul > li > a {
    min-height: 30px;
    font-size: 1.08rem;
}

.main-nav > ul > li > a:hover {
    color: var(--primary-color);
}

.dropdown-container {
    position: absolute;
    top: 100%;
    left: 50%;
    display: none;
    width: min(1400px, 90vw);
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 22px;
    padding: 24px;
    background: #ffffff;
    box-shadow: 0 20px 50px rgba(8, 39, 68, 0.18);
    border: 1px solid #dce7ef;
    border-radius: 8px;
    transform: translateX(-50%);
}

.dropdown-container-simple {
    width: min(260px, 78vw);
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 14px 16px;
}

.dropdown-align-right {
    left: auto;
    right: 0;
    transform: none;
}

.main-nav > ul > li > a .fa-chevron-down {
    color: #8d98a6;
    font-size: 0.72rem;
    transition: transform 0.2s ease, color 0.2s ease;
}

.main-nav > ul > li.has-dropdown:hover > a .fa-chevron-down {
    color: var(--primary-color);
    transform: rotate(180deg);
}

.has-dropdown:hover .dropdown-container {
    display: grid;
}

.dropdown-section h4 {
    margin: 0 0 6px;
    color: var(--ink);
    font-size: 0.95rem;
}

.dropdown-section h4 a {
    color: inherit;
    text-decoration: none;
}

.dropdown-section ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.dropdown-section a {
    display: block;
    padding: 7px 0;
    color: var(--muted);
    font-size: 0.92rem;
    border-radius: 4px;
    transition: all 0.24s ease;
}

.dropdown-section a:hover {
    color: var(--primary-color);
/*    background-color: #f8faff;*/
    padding-left: 10px;
}

.dropdown-subcategory-list {
    list-style: none;
    margin: 0 0 4px;
    padding-left: 14px;
}

.dropdown-subcategory-list a {
    color: #7a8795;
    font-size: 0.86rem;
    padding: 5px 8px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-popover {
    position: relative;
}

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 36px;
    min-width: 36px;
    border: 0;
    border-radius: 5px;
    color: var(--ink);
    background: transparent;
    cursor: pointer;
    font-size: 1.08rem;
}

.icon-btn:hover {
    color: var(--primary-color);
}

.desktop-search {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    display: none;
    width: 260px;
    height: 42px;
    border: 1px solid #cddfea;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 16px 36px rgba(8, 39, 68, 0.16);
}

.search-popover.active .desktop-search {
    display: flex;
}

.desktop-search input,
.mobile-search-box input {
    min-width: 0;
    width: 100%;
    border: 0;
    padding: 0 10px;
    outline: none;
}

.desktop-search button,
.mobile-search-box button {
    width: 40px;
    border: 0;
    color: #fff;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    cursor: pointer;
}

.language-switcher {
    position: relative;
    margin: -8px 0;
    padding: 8px 0;
}

.language-toggle {
    padding: 0 10px;
    font-size: 0.8rem;
    font-weight: 500;
}

.language-toggle .fa-earth-americas {
    font-size: 1.18rem;
}

.language-toggle span {
    font-weight: 500;
}

.language-toggle .fa-chevron-down {
    font-size: 0.68rem;
}

.language-menu {
    position: absolute;
    top: 100%;
    right: 0;
    display: block;
    min-width: 142px;
    padding: 8px;
    border: 1px solid #dce7ef;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 16px 36px rgba(8, 39, 68, 0.16);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
}

.language-menu:before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: -12px;
    height: 12px;
}

.language-switcher:hover .language-menu,
.language-switcher:focus-within .language-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.language-menu a {
    display: block;
    padding: 8px 10px;
    border-radius: 4px;
    color: var(--ink);
    font-size: 0.9rem;
}

.language-menu a:hover {
    color: var(--primary-color);
    background: #eef6fb;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 20px;
    border-radius: 5px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
    color: #fff;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-outline {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.48);
    background: rgba(9, 39, 68, 0.34);
}

.btn-light {
    color: #0b2f52;
    background: #ffffff;
}

.nav-toggle {
    display: none;
    width: 38px;
    height: 38px;
    border: 1px solid #d6e2ec;
    border-radius: 5px;
    background: #fff;
    color: var(--ink);
}

.mobile-search-box {
    display: none;
}

.page-title {
    min-height: 260px;
    display: flex;
    align-items: flex-end;
    padding: 120px 0 42px;
    color: #ffffff;
    background:
        linear-gradient(100deg, rgba(7, 31, 54, 0.92), rgba(12, 64, 105, 0.72)),
        url('/upload/image/banner.webp') center/cover no-repeat;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.breadcrumb li {
    color: rgba(255, 255, 255, 0.72);
}

.breadcrumb li + li:before {
    content: "/";
    margin-right: 10px;
    color: rgba(255, 255, 255, 0.45);
}

.breadcrumb a {
    color: #ffffff;
}

.section,
.about-company,
.product-list,
.news-section,
.service-section,
.philosophy-section,
.contact-section,
.cert-section,
.case-section,
.honor-section {
    padding: 76px 0;
}

.section-heading,
.section-header,
.news-header {
    max-width: 760px;
    margin: 0 auto 36px;
    text-align: center;
}

.section-heading.split {
    max-width: none;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    text-align: left;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--primary-color);
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.78rem;
}

h1,
h2,
h3,
h4,
p {
    overflow-wrap: anywhere;
}

.section-heading h2,
.section-header h2,
.news-header h2 {
    margin: 0 0 12px;
    color: var(--ink);
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    line-height: 1.2;
}

.section-heading p,
.section-header p,
.news-header p {
    color: var(--muted);
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
    font-weight: 800;
}

.empty-state {
    padding: 42px 24px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    color: var(--muted);
    background: #ffffff;
    text-align: center;
}

.site-footer {
    color: #ffffff;
    background: #2b2b2b;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 1.1fr;
    gap: 42px;
    padding: 64px 100px;
}

.footer-brand {
    max-width: 320px;
}

.footer-brand h2,
.footer-column h3 {
    margin: 0 0 16px;
    color: #ffffff;
}

.footer-brand h2 {
    display: block;
    line-height: 1.25;
}

.footer-brand-logo {
    display: block;
    width: auto;
    max-width: 260px;
    max-height: 80px;
    margin: 0 0 18px;
    object-fit: contain;
}

.footer-brand p,
.footer-contact p {
    margin: 0 0 12px;
    color: rgba(255, 255, 255, 0.78);
}

.footer-column ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-column a {
    display: block;
    padding: 5px 0;
    color: rgba(255, 255, 255, 0.78);
}

.footer-column a:hover {
    color: #7ed9ef;
}

.footer-cta {
    display: inline-flex;
    margin-top: 16px;
    color: #8fe4f5;
    font-weight: 800;
}

.footer-social {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.footer-social a:hover {
    color: #ffffff;
    border-color: rgba(143, 228, 245, 0.58);
    background: #1d74c4;
    transform: translateY(-2px);
}

.floating-contact {
    position: fixed;
    right: 18px;
    top: 80%;
    z-index: 960;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transform: translateY(-50%);
}

.floating-contact-link {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    min-height: 46px;
    padding: 0;
    border: 0;
    border-radius: 23px;
    color: #ffffff;
    background: #0a5fa8;
    box-shadow: 0 12px 28px rgba(5, 31, 54, 0.22);
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s ease, transform 0.2s ease;
}

.floating-contact-link i {
    flex: 0 0 22px;
    width: 22px;
    text-align: center;
    font-size: 1rem;
}

.floating-whatsapp i {
    font-size: 1.4rem;
    margin-left: 0.15rem;
}

.floating-contact-link span {
    position: absolute;
    right: calc(100% + 10px);
    top: 50%;
    min-width: 92px;
    padding: 8px 12px;
    border-radius: 18px;
    opacity: 0;
    color: #ffffff;
    background: #0f7fc8;
    box-shadow: 0 10px 24px rgba(5, 31, 54, 0.2);
    font-size: 0.9rem;
    font-weight: 700;
    text-align: right;
    pointer-events: none;
    transform: translate(8px, -50%);
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.floating-contact-link:hover,
.floating-contact-link:focus-visible {
    color: #ffffff;
    background: #0f7fc8;
    transform: none;
}

.floating-contact-link:hover span,
.floating-contact-link:focus-visible span {
    opacity: 1;
    transform: translate(0, -50%);
}

.floating-contact-link.icon-only span,
.floating-contact-link.icon-only:hover span,
.floating-contact-link.icon-only:focus-visible span {
    display: none;
}

/*.floating-contact-link.back-to-top {
    background: #f2ad38;
    color: #10263d;
}

.floating-contact-link.back-to-top:hover,
.floating-contact-link.back-to-top:focus-visible {
    color: #10263d;
    background: #ffc15a;
}

.floating-contact-link.back-to-top span {
    color: #10263d;
    background: #ffc15a;
}*/

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 18px 0;
    color: rgba(255, 255, 255, 0.58);
}

.footer-bottom p {
    margin: 0;
}

@media (max-width: 980px) {
    .container {
        width: min(100% - 28px, 1200px);
    }

    .search-popover,
    .top-strip-inner > span:first-child {
        display: none;
    }

    .nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .main-nav {
        position: fixed;
        top: 90px;
        right: 14px;
        left: 14px;
        display: none;
        max-height: calc(100vh - 128px);
        overflow: auto;
        padding: 18px;
        border-radius: 8px;
        background: #ffffff;
        box-shadow: 0 20px 50px rgba(8, 39, 68, 0.18);
    }

    .site-header.top-hidden .main-nav {
        top: 58px;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav > ul {
        display: block;
    }

    .main-nav > ul > li > a {
        width: 100%;
        justify-content: space-between;
        padding: 10px 0;
    }

    .dropdown-container,
    .has-dropdown:hover .dropdown-container {
        position: static;
        display: grid;
        width: 100%;
        transform: none;
        grid-template-columns: 1fr;
        box-shadow: none;
        border: 0;
        padding: 8px 0 12px 16px;
    }

    .dropdown-container-simple,
    .dropdown-align-right {
        width: 100%;
        transform: none;
    }

    .mobile-search-box {
        display: block;
        margin-top: 14px;
    }

    .mobile-search-box .search-container {
        display: flex;
        height: 42px;
        border: 1px solid var(--line);
        border-radius: 5px;
        overflow: hidden;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .floating-contact {
        right: 10px;
        gap: 6px;
    }

    .floating-contact-link {
        width: 42px;
        min-height: 42px;
        padding: 0;
    }

    .floating-contact-link:hover,
    .floating-contact-link:focus-visible {
        transform: none;
    }

    .floating-contact-link span {
        display: none;
    }
}

@media (max-width: 640px) {
    .header-inner {
        min-height: 58px;
    }

    .main-nav {
        top: 88px;
    }

    .site-header.top-hidden .main-nav {
        top: 58px;
    }

    .page-title {
        min-height: 210px;
        padding-top: 92px;
    }

    .section,
    .about-company,
    .product-list,
    .news-section,
    .service-section,
    .philosophy-section,
    .contact-section,
    .cert-section,
    .case-section,
    .honor-section {
        padding: 54px 0;
    }

    .section-heading.split {
        align-items: flex-start;
        flex-direction: column;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        padding: 44px 0;
    }
}
