/* LUX HORIZON - Global Styles & Design System */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@300;400;500;600;700;800&family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap');

:root {
    /* Color Palette */
    --color-primary: #C5A059;       /* Luxury Brushed Gold */
    --color-primary-light: #E6C687; /* Soft Champagne Gold */
    --color-primary-dark: #9B7633;  /* Deep Gold */
    --color-bg-dark: #061A11;       /* Deep Emerald Forest Green */
    --color-bg-card: #0A241A;       /* Rich Emerald Dark Card */
    --color-bg-glass: rgba(10, 36, 26, 0.7); /* Translucent Emerald Glass */
    --color-text-light: #F8F9FA;    /* Off-white text */
    --color-text-muted: #A0ABA6;   /* Muted warm sage text */
    --color-border: rgba(197, 160, 89, 0.15); /* Soft gold border */
    --color-border-active: rgba(197, 160, 89, 0.4);
    
    /* Functional Accents */
    --color-green: #0E7A5D;         /* Low-carbon Eco Green */
    --color-green-light: #22C55E;   /* Bright Green status */
    --color-blue: #0A84FF;          /* Info blue */
    --color-error: #FF453A;         /* Warning Red */
    
    /* Typography */
    --font-heading-en: 'Playfair Display', Georgia, serif;
    --font-body-en: 'Outfit', 'Inter', sans-serif;
    
    /* Fallback fonts specifically optimized for Chinese */
    --font-heading-zh: 'Source Han Serif SC', 'Noto Serif CJK SC', 'Songti SC', 'SimSun', serif;
    --font-body-zh: 'Noto Sans CJK SC', 'Microsoft YaHei', 'PingFang SC', sans-serif;
    
    /* Transition states */
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s ease;
    
    /* Blur Effects */
    --blur-glass: blur(16px);
    
    /* Spacing */
    --section-padding: 100px 0;
    --section-padding-mobile: 60px 0;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --radius-full: 9999px;
}

/* Base resets & styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--color-bg-dark);
    color: var(--color-text-light);
    font-family: var(--font-body-en);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Adjust fonts for Chinese language pages */
html[lang="zh"] body {
    font-family: var(--font-body-zh);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading-en);
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--color-text-light);
    line-height: 1.2;
}

html[lang="zh"] h1, 
html[lang="zh"] h2, 
html[lang="zh"] h3, 
html[lang="zh"] h4 {
    font-family: var(--font-heading-zh);
    font-weight: 600;
}

p {
    font-weight: 300;
    color: var(--color-text-muted);
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

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

/* Grid & Layout System */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

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

@media (max-width: 768px) {
    .section {
        padding: var(--section-padding-mobile);
    }
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
    align-items: center;
}

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

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 992px) {
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-2, .grid-3, .grid-4 {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Header Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: var(--transition-smooth);
}

.header.scrolled {
    background-color: var(--color-bg-glass);
    border-bottom: 1px solid var(--color-border);
    backdrop-filter: var(--blur-glass);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 48px;
    width: auto;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 32px;
    align-items: center;
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    position: relative;
    padding: 8px 0;
}

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

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--color-primary);
    transition: var(--transition-fast);
}

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Language Toggler */
.lang-switch {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--color-border);
    padding: 6px 12px;
    border-radius: var(--radius-full);
}

.lang-btn {
    color: var(--color-text-muted);
    transition: var(--transition-fast);
}

.lang-btn.active {
    color: var(--color-primary-light);
    font-weight: 700;
}

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

.lang-separator {
    color: rgba(255, 255, 255, 0.2);
}

/* Mobile Menu Button */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-text-light);
    transition: var(--transition-fast);
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--color-bg-dark);
        border-left: 1px solid var(--color-border);
        flex-direction: column;
        justify-content: center;
        gap: 40px;
        transition: var(--transition-smooth);
        z-index: 999;
    }
    
    .nav-menu.active {
        right: 0;
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    border-radius: var(--radius-sm);
    transition: var(--transition-smooth);
    cursor: pointer;
    gap: 8px;
    text-transform: uppercase;
}

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

.btn-primary:hover {
    background-color: var(--color-primary-light);
    border-color: var(--color-primary-light);
    box-shadow: 0 0 20px rgba(197, 160, 89, 0.4);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-text-light);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: var(--color-text-light);
    transform: translateY(-2px);
}

.btn-outline-gold {
    background-color: transparent;
    color: var(--color-primary-light);
    border: 1px solid var(--color-border);
}

.btn-outline-gold:hover {
    background-color: rgba(197, 160, 89, 0.05);
    border-color: var(--color-primary-light);
    transform: translateY(-2px);
    box-shadow: 0 0 15px rgba(197, 160, 89, 0.15);
}

.btn-whatsapp {
    background-color: #25D366;
    color: #FFF;
    border: 1px solid #25D366;
}

.btn-whatsapp:hover {
    background-color: #20BA5A;
    border-color: #20BA5A;
    box-shadow: 0 0 20px rgba(37, 211, 102, 0.35);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.8rem;
}

/* Glass Cards */
.glass-card {
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    padding: 40px;
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(197, 160, 89, 0.08) 0%, transparent 100%);
    opacity: 0;
    transition: var(--transition-smooth);
    z-index: 0;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-border-active);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 30px rgba(197, 160, 89, 0.03);
}

.glass-card:hover::before {
    opacity: 1;
}

.glass-card > * {
    position: relative;
    z-index: 1;
}

/* Title Decorations */
.section-subtitle {
    font-family: var(--font-body-en);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    color: var(--color-primary);
    margin-bottom: 12px;
    display: inline-block;
}

.section-title {
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 24px;
}

.section-title span {
    font-style: italic;
    color: var(--color-primary-light);
}

.text-center {
    text-align: center;
}

.section-header {
    max-width: 700px;
    margin: 0 auto 60px auto;
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 700px;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background-color: #000;
}

.hero-slider {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    background-size: cover;
    background-position: center;
}

.hero-slide.active {
    opacity: 0.45;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, var(--color-bg-dark) 0%, rgba(6, 26, 17, 0.7) 50%, rgba(6, 26, 17, 0.4) 100%);
    z-index: -1;
}

.hero-content {
    max-width: 850px;
    z-index: 10;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 24px;
    line-height: 1.15;
    animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 40px;
    max-width: 680px;
    animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-ctas {
    display: flex;
    gap: 20px;
    animation: fadeInUp 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.2rem;
    }
    .hero p {
        font-size: 1rem;
    }
    .hero-ctas {
        flex-direction: column;
        width: 100%;
    }
    .hero-ctas .btn {
        width: 100%;
    }
}

/* Painpoints Section */
.painpoints {
    background-color: var(--color-bg-dark);
}

.painpoint-card {
    border-top: 3px solid rgba(255, 255, 255, 0.05);
}

.painpoint-card:hover {
    border-top: 3px solid var(--color-primary);
}

.painpoint-icon {
    font-size: 2.5rem;
    color: var(--color-primary);
    margin-bottom: 24px;
}

.painpoint-card h3 {
    font-size: 1.35rem;
    margin-bottom: 16px;
}

.painpoint-solution {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--color-primary-light);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Case Studies Room */
.case-room {
    background-color: #03100A;
}

.case-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
}

.case-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 4 / 3;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.case-item.col-4 {
    grid-column: span 4;
}

.case-item.col-2 {
    grid-column: span 2;
}

.case-item.col-3 {
    grid-column: span 3;
}

.case-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.case-item:hover .case-image {
    transform: scale(1.08);
}

.case-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 50%, transparent 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
    opacity: 0;
    transition: var(--transition-smooth);
}

.case-item:hover .case-overlay {
    opacity: 1;
}

.case-category {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-primary-light);
    margin-bottom: 6px;
}

.case-title {
    font-size: 1.15rem;
    font-family: var(--font-body-en);
    font-weight: 500;
}

html[lang="zh"] .case-title {
    font-family: var(--font-body-zh);
    font-weight: 600;
}

@media (max-width: 992px) {
    .case-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .case-item.col-4, .case-item.col-2, .case-item.col-3 {
        grid-column: span 2;
    }
}

@media (max-width: 576px) {
    .case-grid {
        grid-template-columns: 1fr;
    }
    .case-item.col-4, .case-item.col-2, .case-item.col-3 {
        grid-column: span 1;
    }
}

/* Services Packages Page */
.service-hero {
    padding: 160px 0 80px 0;
    background-color: var(--color-bg-dark);
}

.packages-grid {
    margin-bottom: 80px;
}

.package-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.package-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: var(--color-primary);
    color: var(--color-bg-dark);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: var(--radius-full);
}

.package-card.retrofit {
    border-top: 3px solid var(--color-green);
}

.package-card.retrofit .package-badge {
    background-color: var(--color-green);
    color: var(--color-text-light);
}

.package-header {
    margin-bottom: 30px;
}

.package-title {
    font-size: 1.75rem;
    margin-bottom: 12px;
    font-family: var(--font-body-en);
    font-weight: 600;
}

html[lang="zh"] .package-title {
    font-family: var(--font-body-zh);
}

.package-desc {
    font-size: 0.95rem;
}

.package-features {
    list-style: none;
    margin-bottom: 40px;
    flex-grow: 1;
}

.package-features li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.95rem;
    margin-bottom: 16px;
    color: var(--color-text-muted);
}

.package-features li svg {
    color: var(--color-primary-light);
    flex-shrink: 0;
    margin-top: 4px;
}

.package-card.retrofit .package-features li svg {
    color: var(--color-green-light);
}

.package-footer {
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.package-footer .btn {
    width: 100%;
}

/* Service Info Panel */
.comparison-section {
    background-color: #03100A;
    padding: 80px 0;
}

.comparison-table-wrapper {
    overflow-x: auto;
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 700px;
}

.comparison-table th, .comparison-table td {
    padding: 20px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.comparison-table th {
    background-color: rgba(255, 255, 255, 0.01);
    color: var(--color-primary-light);
    font-weight: 500;
}

.comparison-table tr:hover td {
    background-color: rgba(255, 255, 255, 0.01);
}

/* Owner Portal Page */
.portal-hero {
    padding: 160px 0 100px 0;
    background-color: var(--color-bg-dark);
}

/* Interactive Phone Mock-up */
.mockup-wrapper {
    position: relative;
    max-width: 340px;
    margin: 0 auto;
    perspective: 1000px;
}

.phone-mockup {
    position: relative;
    width: 320px;
    height: 650px;
    background-color: #000;
    border-radius: 40px;
    border: 10px solid #2d2d2a;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8), 0 0 0 2px var(--color-border);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Phone details */
.phone-notch {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 130px;
    height: 25px;
    background-color: #2d2d2a;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
    z-index: 100;
}

.phone-screen {
    width: 100%;
    height: 100%;
    background-color: #051810;
    padding-top: 25px; /* offset notch */
    display: flex;
    flex-direction: column;
    color: #FFF;
    font-size: 0.85rem;
}

.app-header {
    background-color: #09261A;
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-brand {
    font-family: var(--font-heading-en);
    color: var(--color-primary-light);
    font-size: 0.95rem;
}

.app-property {
    font-size: 0.7rem;
    color: var(--color-text-muted);
}

.app-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 15px;
}

.app-tabs {
    display: flex;
    background-color: #09261A;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    height: 60px;
}

.app-tab-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    color: var(--color-text-muted);
    background: transparent;
    border: none;
    cursor: pointer;
    gap: 4px;
    transition: var(--transition-fast);
}

.app-tab-btn.active {
    color: var(--color-primary-light);
}

.app-tab-btn svg {
    width: 18px;
    height: 18px;
}

/* Mockup Content Views */
.portal-view {
    display: none;
    animation: fadeIn 0.4s ease-out;
}

.portal-view.active {
    display: block;
}

/* Construction feed styles */
.feed-item {
    background-color: #0D2C20;
    border-radius: var(--radius-md);
    margin-bottom: 15px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.03);
}

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

.feed-avatar {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    background-color: var(--color-primary);
    color: var(--color-bg-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
}

.feed-author-meta {
    line-height: 1.2;
}

.feed-author {
    font-weight: 600;
    font-size: 0.75rem;
}

.feed-time {
    font-size: 0.65rem;
    color: var(--color-text-muted);
}

.feed-media {
    width: 100%;
    aspect-ratio: 16 / 10;
    background-color: #000;
    position: relative;
}

.feed-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feed-body {
    padding: 10px;
}

.feed-title {
    font-weight: 600;
    font-size: 0.8rem;
    margin-bottom: 4px;
}

.feed-desc {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

/* Financial Dashboard Styles */
.currency-switcher {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.currency-switcher-label {
    font-size: 0.65rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.currency-toggle-group {
    display: inline-flex;
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border);
    border-radius: 4px;
    padding: 2px;
}

.currency-toggle-btn {
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 2px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.currency-toggle-btn.active {
    background-color: var(--color-primary);
    color: var(--color-bg-dark);
}

.currency-toggle-btn:hover:not(.active) {
    color: var(--color-primary-light);
    background-color: rgba(255, 255, 255, 0.05);
}

.stat-widget {
    background-color: #0D2C20;
    border-radius: var(--radius-md);
    padding: 15px;
    margin-bottom: 15px;
    border-left: 3px solid var(--color-primary);
}

.stat-label {
    font-size: 0.7rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
}

.stat-val {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--color-text-light);
    margin: 4px 0;
}

.stat-sub {
    font-size: 0.65rem;
    color: var(--color-green-light);
    display: flex;
    align-items: center;
    gap: 4px;
}

.ledger-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ledger-meta {
    line-height: 1.2;
}

.ledger-title {
    font-weight: 600;
    font-size: 0.75rem;
}

.ledger-date {
    font-size: 0.65rem;
    color: var(--color-text-muted);
}

.ledger-amount {
    font-weight: 600;
    font-size: 0.8rem;
}

.ledger-amount.plus {
    color: var(--color-green-light);
}

/* Maintenance Work Order Styles */
.wo-card {
    background-color: #0D2C20;
    border-radius: var(--radius-md);
    padding: 12px;
    margin-bottom: 12px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.wo-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.wo-id {
    font-size: 0.7rem;
    color: var(--color-text-muted);
}

.wo-status {
    font-size: 0.65rem;
    padding: 2px 6px;
    border-radius: var(--radius-full);
}

.wo-status.completed {
    background-color: rgba(34, 197, 94, 0.15);
    color: var(--color-green-light);
}

.wo-status.pending {
    background-color: rgba(243, 239, 224, 0.1);
    color: var(--color-primary-light);
}

.wo-desc {
    font-size: 0.75rem;
    font-weight: 600;
}

/* Contact & ROI Calculator Page */
.contact-hero {
    padding: 160px 0 80px 0;
    background-color: var(--color-bg-dark);
}

/* Interactive ROI Calculator Styles */
.calculator-card {
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-light);
    margin-bottom: 8px;
    font-weight: 500;
}

.form-select, .form-range, .form-input {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--color-border);
    color: var(--color-text-light);
    border-radius: var(--radius-sm);
    padding: 14px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: var(--transition-fast);
}

.form-select:focus, .form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    background-color: rgba(255, 255, 255, 0.04);
}

.range-wrap {
    display: flex;
    align-items: center;
    gap: 15px;
}

.range-val {
    width: 90px;
    font-family: var(--font-body-en);
    font-weight: 600;
    text-align: right;
    color: var(--color-primary-light);
}

/* Results Display */
.calc-results {
    background-color: #03100A;
    border: 1px dashed var(--color-border);
    padding: 30px;
    border-radius: var(--radius-md);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.results-header {
    margin-bottom: 24px;
}

.results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.result-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 12px;
}

.result-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.result-val {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary-light);
    margin-top: 4px;
}

.result-val.highlight {
    font-size: 2.2rem;
    color: var(--color-primary);
}

.calc-note {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    text-align: center;
    margin-top: 15px;
}

/* Contact Info Area */
.contact-details {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.detail-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.detail-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    background-color: rgba(197, 160, 89, 0.08);
    border: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary-light);
    flex-shrink: 0;
}

.detail-content h4 {
    font-size: 1.1rem;
    margin-bottom: 4px;
    font-family: var(--font-body-en);
    font-weight: 600;
}

html[lang="zh"] .detail-content h4 {
    font-family: var(--font-body-zh);
}

.detail-content p, .detail-content a {
    font-size: 0.95rem;
}

.detail-content a:hover {
    color: var(--color-primary-light);
}

/* Footer styling */
.footer {
    background-color: #030D08;
    padding: 60px 0 30px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
}

.footer-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 50px;
}

@media (max-width: 768px) {
    .footer-top {
        flex-direction: column;
        gap: 40px;
    }
}

.footer-logo-area {
    max-width: 320px;
}

.footer-logo-area p {
    font-size: 0.9rem;
    margin-top: 20px;
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 60px;
}

@media (max-width: 576px) {
    .footer-links-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.footer-col h5 {
    font-family: var(--font-body-en);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-primary-light);
    margin-bottom: 20px;
}

html[lang="zh"] .footer-col h5 {
    font-family: var(--font-body-zh);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

.footer-links a:hover {
    color: var(--color-primary-light);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-link {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
    transition: var(--transition-fast);
}

.social-link:hover {
    background-color: var(--color-primary);
    color: var(--color-bg-dark);
    border-color: var(--color-primary);
    transform: translateY(-2px);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-bottom p {
    font-size: 0.8rem;
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

.footer-bottom-links a {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.footer-bottom-links a:hover {
    color: var(--color-primary-light);
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1100;
}

.toast {
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-primary);
    border-left: 4px solid var(--color-primary);
    padding: 16px 24px;
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    gap: 15px;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-icon {
    color: var(--color-primary-light);
    font-size: 1.25rem;
}

.toast-msg {
    font-size: 0.9rem;
    color: var(--color-text-light);
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 24px;
    left: 24px;
    max-width: 420px;
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    padding: 24px;
    border-radius: var(--radius-md);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
    z-index: 1099;
    transform: translateY(150%);
    transition: var(--transition-smooth);
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-text {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: 16px;
}

.cookie-ctas {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Contact Popup Form */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: var(--blur-glass);
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-fast);
}

.popup-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.popup-content {
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    width: 90%;
    max-width: 500px;
    padding: 40px;
    border-radius: var(--radius-md);
    position: relative;
    transform: scale(0.9);
    transition: var(--transition-smooth);
}

.popup-overlay.show .popup-content {
    transform: scale(1);
}

.popup-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition-fast);
}

.popup-close:hover {
    color: var(--color-text-light);
}

.popup-title {
    font-size: 1.75rem;
    margin-bottom: 10px;
}

.popup-desc {
    margin-bottom: 24px;
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Before & After Transformations Section */
.transformations {
    background-color: var(--color-bg-dark);
    border-top: 1px solid var(--color-border);
}

.ba-grid {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 50px;
}

.ba-row-item {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 40px;
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    padding: 40px;
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
}

.ba-row-item:hover {
    border-color: var(--color-border-active);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 30px rgba(197, 160, 89, 0.03);
}

.ba-meta {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ba-meta h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--color-text-light);
    font-weight: 600;
}

.ba-meta p {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 18px;
}

.ba-duration {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-primary);
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    gap: 6px;
}

.ba-comparison {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 20px;
}

.ba-image-container {
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    aspect-ratio: 16 / 10;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ba-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.ba-image-container:hover img {
    transform: scale(1.03);
}

.ba-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 6px 12px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
    z-index: 2;
}

.ba-badge.before-badge {
    background-color: #C0392B;
    color: #FFF;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ba-badge.after-badge {
    background-color: var(--color-primary);
    color: var(--color-bg-dark);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.ba-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background-color: rgba(197, 160, 89, 0.08);
    color: var(--color-primary-light);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-full);
    font-size: 1.35rem;
    font-weight: bold;
    user-select: none;
}

@media (max-width: 992px) {
    .ba-row-item {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px;
    }
}

@media (max-width: 576px) {
    .ba-comparison {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .ba-arrow {
        transform: rotate(90deg);
        margin: 0 auto;
    }
}

/* Portfolio Filter Bar */
.filter-bar {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 50px;
}

.filter-btn {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
    padding: 10px 24px;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition-fast);
}

.filter-btn:hover, .filter-btn.active {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-bg-dark);
    box-shadow: 0 0 15px rgba(197, 160, 89, 0.3);
}

/* Hidden state for portfolio filtering */
.ba-row-item.hidden {
    display: none;
}



/* ==========================================================================
   Trust Upgrades & Interactive Elements (Slider, Portal Logs, Legal Modal)
   ========================================================================== */

/* 1. Header CTA & Sticky Enhancements */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.btn-header-cta {
    display: inline-block;
    padding: 8px 16px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
    border-radius: var(--radius-sm);
    background: transparent;
    transition: var(--transition-fast);
    text-decoration: none;
}

.btn-header-cta:hover {
    background: var(--color-primary);
    color: var(--color-bg-dark);
    box-shadow: 0 0 10px rgba(197, 160, 89, 0.3);
}

@media (max-width: 768px) {
    .btn-header-cta {
        display: none; /* Hide on mobile to prevent navbar crowding */
    }
}

/* 2. Live Portal logs Mockup */
.portal-mockup-container {
    margin-top: 40px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.portal-log-widget {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 24px;
    width: 100%;
    max-width: 600px;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
}

.portal-log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.portal-log-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.portal-log-status {
    font-size: 0.75rem;
    padding: 4px 10px;
    background: rgba(197, 160, 89, 0.1);
    color: var(--color-primary);
    border: 1px solid rgba(197, 160, 89, 0.3);
    border-radius: var(--radius-full);
    font-weight: 500;
}

.portal-log-timeline {
    position: relative;
    padding-left: 20px;
    border-left: 2px solid rgba(197, 160, 89, 0.2);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.portal-log-item {
    position: relative;
}

.portal-log-item::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--color-primary);
    border: 2px solid var(--color-card);
}

.portal-log-item.active::before {
    background: #2ecc71;
    box-shadow: 0 0 8px #2ecc71;
}

.portal-log-time {
    font-size: 0.7rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.portal-log-desc {
    font-size: 0.85rem;
    color: var(--color-text);
    line-height: 1.4;
}

.portal-log-desc strong {
    color: #fff;
}

.portal-log-progress {
    margin-top: 20px;
    border-top: 1px solid var(--color-border);
    padding-top: 16px;
}

.portal-progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--color-text-muted);
    margin-bottom: 6px;
}

.portal-progress-bar-bg {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.portal-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-primary), #E6C687);
    border-radius: var(--radius-full);
}

/* 3. Interactive Before/After Comparison Slider */
.slider-showcase-container {
    width: 100%;
    max-width: 800px;
    margin: 40px auto 0 auto;
}

.slider-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.slider-tab-btn {
    background: transparent;
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
    padding: 8px 16px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition-fast);
}

.slider-tab-btn.active, .slider-tab-btn:hover {
    background: rgba(197, 160, 89, 0.1);
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.ba-slider {
    position: relative;
    width: 100%;
    height: 480px;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    user-select: none;
}

@media (max-width: 600px) {
    .ba-slider {
        height: 320px;
    }
}

.slider-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.slider-before {
    width: var(--slide-pos, 50%);
    z-index: 2;
    overflow: hidden;
}

.slider-before .slider-image {
    width: 800px; /* Lock width to container max-width to prevent squishing */
    max-width: none;
}

@media (max-width: 840px) {
    .slider-before .slider-image {
        width: calc(100vw - 40px); /* Responsive fallback */
        max-width: 800px;
    }
}

.slider-after {
    width: 100%;
    z-index: 1;
}

.slider-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--slide-pos, 50%);
    width: 2px;
    background: var(--color-primary);
    z-index: 3;
    transform: translateX(-50%);
    pointer-events: none;
}

.slider-handle-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--color-bg-dark);
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.slider-range-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: ew-resize;
    z-index: 4;
}

/* 4. High-End Legal Popups */
.legal-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.legal-modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.legal-modal-content {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 32px;
    width: 90%;
    max-width: 680px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: translateY(30px);
    transition: transform 0.3s ease;
    box-shadow: var(--shadow-lg);
}

.legal-modal-overlay.show .legal-modal-content {
    transform: translateY(0);
}

.legal-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 16px;
    margin-bottom: 20px;
}

.legal-modal-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--color-primary);
}

.legal-modal-close {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--color-text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
}

.legal-modal-close:hover {
    color: #fff;
}

.legal-modal-body {
    overflow-y: auto;
    font-size: 0.85rem;
    line-height: 1.6;
    color: var(--color-text-muted);
    padding-right: 10px;
}

.legal-modal-body h4 {
    color: #fff;
    margin: 16px 0 8px 0;
}

.legal-modal-body p {
    margin-bottom: 12px;
}

/* Scrollbar styling for legal body */
.legal-modal-body::-webkit-scrollbar {
    width: 6px;
}

.legal-modal-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}

.legal-modal-body::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: var(--radius-full);
}

.legal-modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
}

.footer-bottom-links span.separator {
    color: var(--color-border);
    font-size: 0.8rem;
    margin: 0 4px;
}
