/* === 1. CSS Variables & Reset === */
:root {
    --paper: #F7F4EF;
    --ink: #0D0D0D;
    --accent: #2A6049;
    --accent-light: #E8F0EC;
    --text: #1A1A1A;
    --mist: #8A9490;
    --border: #DDD8D0;
    --white: #FFFFFF;
    --border-dark: #2A2A2A;
    --ink-light: #141414;
    --nav-height: 64px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--nav-height);
}

body {
    font-family: 'DM Sans', sans-serif;
    color: var(--text);
    background-color: var(--paper);
    line-height: 1.7;
    font-size: 16px;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Noto Serif SC', serif;
    font-weight: 600;
    line-height: 1.2;
}

/* Typography Classes */
.display-title {
    font-size: 80px;
    font-weight: 300;
    line-height: 1.1;
    color: var(--text);
}

.body-large {
    font-size: 18px;
    font-weight: 300;
    color: var(--mist);
}

.accent-italic {
    color: var(--accent);
    font-style: italic;
}

.section-label {
    display: inline-block;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.15em;
    color: var(--accent);
    margin-bottom: 12px;
}

.section-label.dark-mode {
    color: var(--accent-light);
}

.section-title {
    font-size: 40px;
    font-weight: 400;
    margin-bottom: 24px;
}

.section-title.white-text {
    color: var(--white);
}

.eyebrow {
    display: block;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.15em;
    color: var(--accent);
    margin-bottom: 24px;
}

/* Layout Utilities */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 6%;
}

.section {
    padding: 100px 0;
}

.bg-white {
    background-color: var(--white);
}

.bg-ink {
    background-color: var(--ink);
    color: var(--white);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--accent);
    color: var(--white);
    border: 1px solid var(--accent);
}

.btn-primary:hover {
    background-color: #1E4D38;
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text);
    border: 1px solid #C4C4C4;
}

.btn-secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-1px);
}

/* Animations */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-up {
    animation: fadeUp 0.7s ease both;
}

.scroll-fade-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.scroll-fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 {
    animation-delay: 0.1s;
    transition-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.2s;
    transition-delay: 0.2s;
}

.delay-3 {
    animation-delay: 0.3s;
    transition-delay: 0.3s;
}

.delay-4 {
    animation-delay: 0.4s;
    transition-delay: 0.4s;
}


/* === 2. Component Styles === */

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: rgba(247, 244, 239, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    z-index: 100;
    display: flex;
    align-items: center;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo-text-accent {
    font-family: 'Noto Serif SC', serif;
    font-size: 20px;
    font-weight: 600;
    color: var(--accent);
}

.logo-text-ink {
    font-family: 'Noto Serif SC', serif;
    font-size: 20px;
    font-weight: 600;
    color: var(--ink);
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-link {
    font-size: 13px;
    color: var(--mist);
    font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent);
}

.mobile-menu-btn {
    display: none;
    cursor: pointer;
    color: var(--text);
}

.mobile-nav {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    width: 100%;
    background: var(--white);
    flex-direction: column;
    padding: 20px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.mobile-nav.open {
    display: flex;
}

.mobile-nav-link {
    padding: 12px 0;
    font-size: 15px;
    color: var(--text);
    border-bottom: 1px solid var(--border);
}

.mobile-nav-link:last-child {
    border-bottom: none;
}

.hero-bg-glow {
    position: absolute;
    top: -200px;
    right: -200px;
    width: 1000px;
    height: 1000px;
    background: radial-gradient(circle, rgba(42, 96, 73, 0.15) 0%, transparent 70%);
    opacity: 0.6;
    border-radius: 50%;
    z-index: 0;
    pointer-events: none;
    filter: blur(80px);
}

.hero-bg-glow-2 {
    position: absolute;
    bottom: -300px;
    left: -100px;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(90, 106, 102, 0.1) 0%, transparent 60%);
    opacity: 0.4;
    border-radius: 50%;
    z-index: 0;
    pointer-events: none;
    filter: blur(60px);
}

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--nav-height);
    background-color: var(--paper);
    background-image:
        radial-gradient(rgba(0, 0, 0, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 100%;
}

.hero .body-large {
    margin: 24px 0 40px;
    color: var(--mist);
}

.hero-actions {
    display: flex;
    gap: 16px;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--mist);
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.scroll-indicator .mouse {
    width: 20px;
    height: 32px;
    border: 1.5px solid var(--mist);
    border-radius: 20px;
    position: relative;
}

.scroll-indicator .mouse::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 6px;
    background-color: var(--mist);
    border-radius: 2px;
    animation: scrollMouse 2s infinite;
}

@keyframes scrollMouse {
    0% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }

    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(12px);
    }
}

/* About / Grids Container */
.grids-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.body-text p {
    margin-bottom: 16px;
    font-size: 15px;
    color: var(--text);
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.stat-card {
    background-color: var(--paper);
    padding: 32px;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.stat-number {
    font-family: 'Noto Serif SC', serif;
    font-size: 40px;
    color: var(--accent);
    font-weight: 300;
    line-height: 1.2;
    margin-bottom: 8px;
}

.stat-desc {
    font-size: 12px;
    color: var(--mist);
}

/* Products */
.section-desc {
    font-size: 16px;
    color: var(--mist);
    margin-bottom: 48px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.product-card {
    background-color: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 32px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.product-card:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
    transform: translateY(-3px);
}

.card-accent-top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--accent);
}

.card-icon {
    font-size: 32px;
    margin-bottom: 16px;
}

.status-badge {
    display: inline-block;
    background-color: var(--accent-light);
    color: var(--accent);
    font-size: 11px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 16px;
}

.card-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 24px;
    color: var(--text);
    margin-bottom: 12px;
}

.card-subtitle {
    font-size: 16px;
    color: var(--mist);
    font-family: 'DM Sans', sans-serif;
    font-weight: 400;
}

.card-desc {
    font-size: 14px;
    color: var(--mist);
    margin-bottom: 24px;
    min-height: 48px;
}

.card-features {
    border-top: 1px solid var(--border);
    padding-top: 16px;
}

.feature-item {
    font-size: 13px;
    color: var(--text);
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    border-bottom: 1px solid var(--border);
    padding-bottom: 8px;
}

.feature-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.feature-bullet {
    color: var(--accent);
    margin-right: 8px;
}

/* Services */
.services-header {
    margin-bottom: 48px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.service-card {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 32px;
    transition: all 0.3s ease;
    background-color: transparent;
}

.service-card:hover {
    background-color: var(--surface-light);
    border-color: var(--accent);
}

.service-icon {
    font-size: 24px;
    margin-bottom: 16px;
}

.service-title {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: var(--ink);
    margin-bottom: 8px;
}

.service-desc {
    font-size: 14px;
    color: var(--mist);
}

/* Legal (Tabs) */
.legal-content {
    max-width: 860px;
    margin: 0 auto;
}

.tabs-header {
    display: flex;
    gap: 32px;
}

.tab-btn {
    background: none;
    border: none;
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    color: var(--mist);
    padding-bottom: 12px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
    font-weight: 500;
}

.tab-divider {
    height: 1px;
    background-color: var(--border);
    margin-top: -1px;
    margin-bottom: 32px;
}

.update-info {
    background-color: var(--paper);
    border: 1px solid var(--border);
    padding: 12px 16px;
    font-size: 12px;
    color: var(--mist);
    border-radius: 6px;
    margin-bottom: 32px;
}

.tab-pane {
    display: none;
    animation: fadeUp 0.4s ease both;
}

.tab-pane.active {
    display: block;
}

.tab-pane h3 {
    font-family: 'Noto Serif SC', serif;
    font-size: 18px;
    color: var(--text);
    margin-top: 32px;
    margin-bottom: 16px;
}

.tab-pane p,
.tab-pane ul {
    font-size: 15px;
    color: #555555;
    line-height: 1.8;
    margin-bottom: 16px;
}

.tab-pane ul {
    padding-left: 24px;
}

.tab-pane li {
    margin-bottom: 8px;
}

/* Contact */
.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 24px;
}

.contact-icon {
    font-size: 20px;
    margin-right: 16px;
    margin-top: 2px;
}

.contact-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--mist);
    margin-bottom: 4px;
}

.contact-value {
    font-size: 15px;
    color: var(--text);
    font-weight: 500;
}

.contact-link {
    color: var(--accent);
}

.contact-link:hover {
    text-decoration: underline;
}

/* Footer */
.footer {
    padding: 48px 0;
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 16px;
    color: #5A6A66;
    font-size: 13px;
    line-height: 2;
}

.footer-links {
    display: flex;
    gap: 12px;
    align-items: center;
}

.footer-links a,
.footer-beian a {
    color: #5A6A66;
}

.footer-links a:hover,
.footer-beian a:hover {
    color: #AAAAAA;
}

.divider {
    color: #333;
}

/* Dark Footer Overrides */
.footer.bg-ink .footer-container {
    color: var(--mist);
}

.footer.bg-ink .footer-links a,
.footer.bg-ink .footer-beian a {
    color: var(--mist);
}

.footer.bg-ink .footer-links a:hover,
.footer.bg-ink .footer-beian a:hover {
    color: white;
}

.footer.bg-ink .divider {
    color: rgba(255, 255, 255, 0.2);
}

.footer.bg-ink .capsule-btn {
    color: white;
    background-color: transparent;
    border-color: rgba(255, 255, 255, 0.15);
}

.footer.bg-ink .capsule-btn:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: white;
    color: white;
}

.footer.bg-ink .contact-row-label {
    color: var(--mist);
    opacity: 0.8;
}


/* === 3. Responsive === */

/* Tablet (max-width: 1024px) */
@media (max-width: 1024px) {
    .container {
        padding: 0 5%;
    }

    .hero-content {
        max-width: 80%;
    }

    .display-title {
        font-size: 64px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile (max-width: 768px) */
@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .section {
        padding: 64px 0;
    }

    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .display-title {
        font-size: clamp(36px, 10vw, 48px);
    }

    .hero-content {
        max-width: 100%;
        margin-top: 40px;
    }

    .hero-bg-glow {
        right: -30%;
        top: 0;
        width: 150vw;
        height: 150vw;
    }

    .grids-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .products-grid,
    .services-grid {
        grid-template-columns: 1fr;
    }

    .footer-container {
        font-size: 12px;
    }
}

/* Custom Language Dropdown */
.custom-lang-selector {
    position: relative;
    display: inline-block;
}

.desktop-lang {
    margin-left: 16px;
}

.desktop-lang::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 16px;
    background-color: var(--border);
}

.lang-selector-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    font-size: 13px;
    font-family: inherit;
    color: var(--mist);
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.lang-selector-btn:hover {
    color: var(--accent);
    background: rgba(0, 0, 0, 0.03);
}

.lang-selector-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-width: 120px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 100;
}

.custom-lang-selector.open .lang-selector-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    padding: 10px 16px;
    font-size: 13px;
    color: var(--text);
    cursor: pointer;
    transition: background 0.2s;
}

.lang-option:hover {
    background: var(--paper);
    color: var(--accent);
}

.lang-option:first-child {
    border-radius: 8px 8px 0 0;
}

.lang-option:last-child {
    border-radius: 0 0 8px 8px;
}

/* Mobile lang switcher specific */
.mobile-lang .lang-selector-btn {
    padding: 12px 0;
    font-size: 15px;
    color: var(--text);
}

.mobile-lang .lang-selector-dropdown {
    position: static;
    box-shadow: none;
    border: none;
    background: transparent;
    opacity: 1;
    visibility: visible;
    transform: none;
    display: none;
    margin-top: 0;
}

.mobile-lang.open .lang-selector-dropdown {
    display: block;
}

/* Footer redesign */
.bg-paper {
    background-color: var(--paper);
}

.footer.bg-paper {
    color: var(--text);
    border-top: 1px solid var(--border);
}

.footer-contact-row {
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.contact-row-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--mist);
}

.contact-capsules {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
}

.capsule-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 40px;
    border: 1px solid var(--border);
    background-color: var(--white);
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s, color 0.2s;
}

.capsule-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-color: var(--accent);
    color: var(--accent);
}

.footer-divider {
    width: 100%;
    height: 1px;
    background-color: var(--border);
    margin: 32px 0;
}