/* Custom Properties / Design Tokens */
:root {
    /* Colors */
    --primary-color: #1e3a5f;      /* Deep Esteem Realty Blue */
    --primary-light: #2c5282;      /* Lighter Blue */
    --accent-color: #cda86f;       /* Premium Gold */
    --accent-hover: #b5925a;       /* Darker Gold */
    
    --bg-light: #f8fafc;
    --text-dark: #1e293b;
    --text-light: #64748b;
    --white: #ffffff;
    
    /* Typography */
    --font-sans: 'Inter', sans-serif;
    --font-serif: 'Playfair Display', serif;
    
    /* Effects */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.3);
    
    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

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

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-serif);
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

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

a:hover {
    color: var(--accent-color);
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

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

.bg-light {
    background-color: #eff6ff;
}

.highlight {
    color: var(--primary-color);
}

/* Typography Utilities */
.section-title {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
    border-radius: 2px;
}

.text-center .section-title::after {
    left: 50%;
    transform: translateX(-50%);
}

.section-subtitle {
    font-family: var(--font-sans);
    font-weight: 500;
    color: var(--text-light);
    font-size: 1.125rem;
    margin-bottom: 2rem;
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: var(--font-sans);
}

.btn-primary {
    background-color: var(--accent-color);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(205, 168, 111, 0.4);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(205, 168, 111, 0.6);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

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

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(30, 58, 95, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1rem 5%;
    box-shadow: var(--shadow-sm);
}

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

.nav-logo-img {
    height: 48px;
    margin-right: 10px;
    background: rgba(255, 255, 255, 0.95);
    padding: 6px 12px;
    border-radius: 6px;
    box-shadow: var(--shadow-sm);
    object-fit: contain;
}

.logo-name {
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--white);
    letter-spacing: 1px;
}

.logo-name-cn {
    font-size: 1.25rem;
    color: var(--accent-color);
}

.nav-links {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--white);
}

.nav-cta {
    background-color: var(--accent-color);
    color: var(--white) !important;
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
}

.nav-cta::after {
    display: none;
}

.nav-cta:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(205, 168, 111, 0.3);
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 700px;
    background-image: url('assets/hero_house.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    display: flex;
    align-items: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(15, 23, 42, 0.9) 0%, rgba(30, 58, 95, 0.7) 60%, rgba(30, 58, 95, 0.3) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 5%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.hero-text {
    max-width: 600px;
}

.hero-title {
    font-size: 4rem;
    color: var(--white);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2.5rem;
    font-weight: 300;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-avatar-container {
    perspective: 1000px;
}

.avatar-glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1.5rem;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: rotateY(-10deg) rotateX(5deg);
    transition: var(--transition);
}

.avatar-glass:hover {
    transform: rotateY(0) rotateX(0) translateY(-10px);
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.6);
    background: rgba(255, 255, 255, 0.15);
}

.avatar-img {
    width: 300px;
    height: 380px;
    object-fit: cover;
    border-radius: 12px;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

/* Sections */
section {
    padding: 6rem 0;
}

/* About Section */
.about-grid {
    display: flex;
    gap: 4rem;
    align-items: center;
    justify-content: center;
}

.about-info {
    max-width: 800px;
    text-align: center;
}

.about-description {
    font-size: 1.125rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

.certifications {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.certifications i {
    color: var(--accent-color);
    margin-right: 0.5rem;
}

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--white);
    padding: 3rem 2rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.03);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.service-icon {
    width: 70px;
    height: 70px;
    background: rgba(205, 168, 111, 0.1);
    color: var(--accent-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    margin: 0 auto 1.5rem;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--accent-color);
    color: var(--white);
}

/* Contact Section */
.contact-section {
    background: url('assets/hero_house.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    color: var(--white);
}

.contact-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(30, 58, 95, 0.92);
}

.contact-section .container {
    position: relative;
    z-index: 2;
}

.glass-panel {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 4rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin-bottom: 2rem;
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-header h2 {
    color: var(--white);
}

.contact-header h2::after {
    display: none;
}

.contact-header p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.icon-circle {
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--accent-color);
    flex-shrink: 0;
    transition: var(--transition);
}

.contact-item:hover .icon-circle {
    background: var(--accent-color);
    color: var(--white);
    transform: scale(1.1);
}

.contact-item h4 {
    color: rgba(255, 255, 255, 0.6);
    font-family: var(--font-sans);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.25rem;
}

.contact-item a, .contact-item span {
    color: var(--white);
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
}

.contact-item a:hover {
    color: var(--accent-color);
}

.address-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    color: var(--text-dark);
}

.company-logo h3 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.5rem;
}

.footer-logo-img {
    max-width: 250px;
    margin: 0 auto 1.5rem;
    object-fit: contain;
}

.brokerage {
    font-size: 0.75rem;
    letter-spacing: 2px;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.address-text {
    font-weight: 500;
    color: var(--text-dark);
}

.address-text i {
    color: var(--accent-color);
    margin-right: 0.5rem;
}

/* Footer */
footer {
    background-color: #0f172a;
    color: rgba(255,255,255,0.6);
    text-align: center;
    padding: 3rem 0;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.qr-code-section {
    margin-bottom: 2rem;
    display: inline-block;
}

.qr-img {
    width: 150px;
    height: 150px;
    object-fit: cover;
    margin-bottom: 1rem;
    border-radius: 8px;
    transition: var(--transition);
    border: 3px solid rgba(255,255,255,0.1);
}

.qr-img:hover {
    transform: scale(1.05);
    border-color: var(--accent-color);
}

.footer-disclaimer {
    font-size: 0.8rem;
    margin-top: 1rem;
    color: rgba(255,255,255,0.4);
}

/* Animations */
.fade-in-up {
    animation: fadeInUp 1s ease forwards;
}

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

.slide-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.slide-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 992px) {
    .hero-title { font-size: 3rem; }
    .hero-content { flex-direction: column; text-align: center; gap: 3rem; margin-top: 5rem; }
    .hero-text { align-items: center; display: flex; flex-direction: column; }
    .hero-overlay { background: linear-gradient(to bottom, rgba(15, 23, 42, 0.9) 0%, rgba(30, 58, 95, 0.8) 100%); }
    .avatar-glass { transform: none; }
    
    .nav-links { display: none; /* simple mobile hide for now, could add burger */ }
    
    .glass-panel { padding: 2rem; }
    .mobile-lang { display: inline-block !important; }
}

@media (max-width: 768px) {
    .navbar { padding: 0.75rem 1rem; }
    .logo { gap: 0.25rem; }
    .nav-logo-img { height: 28px; padding: 2px 6px; margin-right: 2px; border-radius: 4px; }
    .logo-name { font-size: 1.1rem; }
    .logo-name-cn { font-size: 0.9rem; }
    .lang-btn.mobile-lang { padding: 0.25rem 0.5rem; font-size: 0.85rem; margin-left: 0; }
    
    .hero { align-items: flex-start; }
    .hero-content { margin-top: 6rem; padding-top: 2rem; gap: 2rem; }
    .hero-title { font-size: 2.2rem; }
    
    section { padding: 4rem 0; }
    .contact-grid { grid-template-columns: 1fr; }
    .avatar-img { width: 220px; height: 280px; }
}

/* --- Multi-Language Styles --- */
body.lang-en .zh {
    display: none !important;
}

body.lang-zh .en {
    display: none !important;
}

body.lang-zh {
    /* If needed, override fonts here for Chinese text */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
}

.lang-btn {
    background: transparent;
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    font-family: var(--font-sans);
    margin-left: 1rem;
}

.lang-btn:hover {
    background: var(--accent-color);
    color: var(--white);
}

.mobile-lang {
    display: none;
}
