/* Base Variables - Serious, Premium, US Tax Theme */
:root {
    /* US Flag / Tax Official Colors */
    --primary-navy: #0A192F;
    /* Deep trust-building navy */
    --primary-light: #172A45;
    --accent-gold: #D4AF37;
    /* Premium service indicator */
    --accent-red: #B22222;
    /* Subtle US flag red for specific alerts/accents */

    /* Neutral scale */
    --text-dark: #1F2937;
    --text-light: #F3F4F6;
    --text-muted: #6B7280;

    /* Backgrounds */
    --bg-white: #FFFFFF;
    --bg-offwhite: #F9FAFB;
    --bg-gray: #E5E7EB;

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-serif: 'Playfair Display', Georgia, serif;
    /* For professional headings */

    /* UI Elements */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Animations */
    --transition-fast: 150ms ease;
    --transition-normal: 250ms ease;
}

/* Reset & Scaffolding */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    color: var(--text-dark);
    background-color: var(--bg-offwhite);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-serif);
    color: var(--primary-navy);
    margin-bottom: 1rem;
    line-height: 1.2;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.75rem;
}

p {
    margin-bottom: 1rem;
}

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

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

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

/* Layout Utilities */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 5rem 0;
}

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

.section-dark {
    background-color: var(--primary-navy);
    color: var(--text-light);
}

.section-dark h2,
.section-dark h3 {
    color: var(--text-light);
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-normal);
    border: 2px solid transparent;
    font-family: var(--font-sans);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.875rem;
}

.btn-primary {
    background-color: var(--accent-gold);
    color: var(--primary-navy);
}

.btn-primary:hover {
    background-color: #e6c243;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    color: var(--primary-navy);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.btn-outline:hover {
    background-color: var(--accent-gold);
    color: var(--primary-navy);
}

/* Navigation */
.navbar {
    background-color: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo span {
    color: var(--accent-gold);
}

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

.nav-links a {
    color: var(--text-light);
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

.lang-toggle {
    background: transparent;
    border: 1px solid var(--text-light);
    color: var(--text-light);
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.8rem;
    transition: all var(--transition-fast);
}

.lang-toggle:hover {
    background: var(--text-light);
    color: var(--primary-navy);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    /* Offset for navbar */
    background: linear-gradient(135deg, var(--primary-navy) 0%, var(--primary-light) 100%);
    position: relative;
    overflow: hidden;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    color: var(--text-light);
}

.hero-subtitle {
    color: var(--accent-gold);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    display: block;
}

.hero h1 {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
    max-width: 500px;
}

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

.hero-image {
    position: relative;
}

.hero-image img {
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Trust Badge */
.trust-badges {
    display: flex;
    gap: 2rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-light);
    opacity: 0.8;
}

.badge i {
    color: var(--accent-gold);
    font-size: 1.25rem;
}

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

.service-card {
    background: var(--bg-white);
    padding: 2.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid var(--bg-gray);
    border-top: 4px solid var(--primary-navy);
}

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

.service-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(10, 25, 47, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary-navy);
    font-size: 1.5rem;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-image img {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

.stat-item {
    border-left: 3px solid var(--accent-gold);
    padding-left: 1rem;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-navy);
    font-family: var(--font-serif);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Scheduling & Payments (Cards) */
.action-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

.action-card {
    background: var(--bg-white);
    padding: 3rem;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.action-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--primary-navy);
}

.action-card.gold::before {
    background: var(--accent-gold);
}

/* Footer */
.footer {
    background-color: var(--primary-navy);
    color: var(--text-light);
    padding: 4rem 0 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer h4 {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 1.1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links a:hover {
    color: var(--accent-gold);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

/* Demo Watermark Overlay */
.demo-watermark {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    font-size: 1.5rem;
    font-weight: 800;
    color: rgba(0, 0, 0, 0.2);
    /* Slightly darker to be legible at smaller size */
    text-transform: uppercase;
    font-family: var(--font-sans);
    pointer-events: none;
    /* Allows clicking right through it */
    z-index: 9998;
    /* Below chatbot, above content */
    white-space: nowrap;
    -webkit-user-select: none;
    user-select: none;
    letter-spacing: 2px;
}

/* Chatbot Floating Widget */
.chatbot-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 9999;
}

.chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--primary-navy);
    color: var(--bg-white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(10, 25, 47, 0.3);
    cursor: pointer;
    transition: all var(--transition-normal);
    border: 2px solid var(--accent-gold);
}

.chatbot-toggle:hover {
    transform: scale(1.05);
}

.chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: var(--bg-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all var(--transition-normal);
    border: 1px solid var(--bg-gray);
}

.chatbot-window.active {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.chatbot-header {
    background: var(--primary-navy);
    color: var(--text-light);
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbot-header h3 {
    margin: 0;
    color: var(--text-light);
    font-size: 1rem;
    font-family: var(--font-sans);
}

.chatbot-close {
    cursor: pointer;
    color: var(--text-light);
    opacity: 0.7;
}

.chatbot-close:hover {
    opacity: 1;
}

.chatbot-body {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
    background: var(--bg-offwhite);
}

.chat-message {
    margin-bottom: 1rem;
    max-width: 80%;
}

.chat-message.bot {
    background: var(--bg-white);
    padding: 0.75rem;
    border-radius: 12px 12px 12px 0;
    border: 1px solid var(--bg-gray);
    align-self: flex-start;
}

.chatbot-input {
    padding: 1rem;
    border-top: 1px solid var(--bg-gray);
    display: flex;
    gap: 0.5rem;
    background: var(--bg-white);
}

.chatbot-input input {
    flex: 1;
    padding: 0.5rem 1rem;
    border: 1px solid var(--bg-gray);
    border-radius: 20px;
    outline: none;
}

.chatbot-input input:focus {
    border-color: var(--primary-navy);
}

.chatbot-input button {
    background: var(--primary-navy);
    color: var(--bg-white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Responsive Design */
@media (max-width: 992px) {

    .hero .container,
    .about-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-actions {
        justify-content: center;
    }

    .trust-badges {
        justify-content: center;
        flex-wrap: wrap;
    }

    .about-image {
        order: -1;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .nav-links {
        display: none;
        /* Add hamburger menu logic in JS if needed */
    }

    .action-cards {
        grid-template-columns: 1fr;
    }

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