/* ═══════════════════════════════════════════════
   GLOBAL DESIGN TOKENS & BASE STYLES - WHITE ARCHITECTURAL STUDIO
   High-End European Architectural Lighting Standard
   ═══════════════════════════════════════════════ */
:root {
    /* Primary palette - Crisp Architectural Slate & Dark Graphite */
    --c-primary: #0f172a;
    --c-primary-light: #334155;
    --c-primary-dark: #020617;
    --c-primary-glow: rgba(15, 23, 42, 0.08);

    /* Architectural Precision Accent - Sleek Technical Cobalt / Navy */
    --c-accent: #1e293b;
    --c-accent-light: #3b82f6;
    --c-accent-dark: #b91c1c;
    --c-accent-glow: rgba(37, 99, 235, 0.15);

    /* Backgrounds - Pure, Crisp White & Architectural Greys */
    --c-bg-deep: #f8fafc;
    --c-bg: #ffffff;
    --c-bg-card: #ffffff;
    --c-bg-card-hover: #f8fafc;
    --c-bg-surface: #f1f5f9;
    --c-bg-elevated: #ffffff;

    /* Borders - Subtle Hairline Architectural Precision */
    --c-border: #e2e8f0;
    --c-border-light: #edf2f7;
    --c-border-accent: #0f172a;

    /* Text - High Contrast Graphite & Slate */
    --c-text: #0f172a;
    --c-text-secondary: #475569;
    --c-text-muted: #94a3b8;

    /* Accents */
    --c-success: #10b981;
    --c-warning: #1e293b;
    --c-danger: #ef4444;
    --c-info: #1e293b;

    /* Radii */
    --r-sm: 6px;
    --r-md: 10px;
    --r-lg: 14px;
    --r-xl: 20px;

    /* Shadows - Soft, Elegant Natural Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.08), 0 4px 8px rgba(0, 0, 0, 0.03);
    --shadow-glow: 0 0 30px rgba(37, 99, 235, 0.12);

    /* Transitions */
    --t-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --t-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --t-smooth: 0.35s cubic-bezier(0.4, 0, 0.2, 1);

    /* Font */
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ═══════════ RESET ═══════════ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font);
    background: var(--c-bg-deep);
    color: var(--c-text);
    overflow-x: hidden;
    line-height: 1.6;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    color: inherit;
}

input, select, textarea {
    font-family: inherit;
    color: var(--c-text);
    background: #ffffff;
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    padding: 10px 14px;
    font-size: 13px;
    transition: border-color var(--t-fast), box-shadow var(--t-fast);
    outline: none;
    width: 100%;
}

input:focus, select:focus, textarea:focus {
    border-color: var(--c-primary);
    box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.08);
}

.hidden {
    display: none !important;
}

/* ═══════════ HERO LANGUAGE TOGGLE ═══════════ */
.hero-lang-toggle {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--c-border);
    border-radius: 24px;
    backdrop-filter: blur(12px);
    font-size: 12px;
    font-weight: 700;
    color: var(--c-text);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: all var(--t-normal);
}

.hero-lang-toggle:hover {
    border-color: var(--c-primary);
    background: #ffffff;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.hero-lang-toggle svg {
    color: #64748b;
}

/* Hide hero lang toggle when designer is open */
#designerApp:not(.hidden) ~ .hero-lang-toggle,
body:has(#designerApp:not(.hidden)) .hero-lang-toggle {
    display: none !important;
}

/* ═══════════ HERO SECTION (ARCHITECTURAL SHOWROOM) ═══════════ */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 64px 48px;
    gap: 56px;
    background: #f8fafc;
    background-image: 
        radial-gradient(#e2e8f0 1px, transparent 1px),
        linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    background-size: 24px 24px, 100% 100%;
}

.hero-content {
    max-width: 580px;
    z-index: 2;
    flex-shrink: 0;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: #ffffff;
    border: 1px solid var(--c-border);
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--c-primary);
    margin-bottom: 22px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.hero-badge svg {
    color: var(--c-accent);
}

.hero-title {
    font-size: clamp(34px, 4.4vw, 52px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
    color: var(--c-primary);
}

.hero-title span {
    display: block;
    color: #475569;
    font-weight: 600;
    font-size: clamp(24px, 3.2vw, 36px);
    letter-spacing: -0.02em;
    margin-bottom: 4px;
}

.hero-title strong {
    display: block;
    color: #0f172a;
}

.hero-desc {
    font-size: 16px;
    color: var(--c-text-secondary);
    line-height: 1.65;
    margin-bottom: 32px;
    max-width: 520px;
}

.hero-steps {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 34px;
}

.hero-step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 13px;
    background: #ffffff;
    border: 1px solid var(--c-border);
    border-radius: var(--r-md);
    font-size: 12px;
    font-weight: 600;
    color: var(--c-text);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: border-color var(--t-fast), transform var(--t-fast);
}

.hero-step:hover {
    border-color: #94a3b8;
    transform: translateY(-1px);
}

.step-num {
    width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    background: var(--c-primary);
    color: #ffffff;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 700;
}

.hero-step-arrow {
    color: var(--c-text-muted);
    font-size: 14px;
}

.hero-action-row {
    margin-bottom: 26px;
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 15px 34px;
    background: #0f172a;
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.01em;
    border-radius: var(--r-md);
    transition: background-color var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.18);
}

.hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.25);
    background: #1e293b;
}

.hero-cta svg {
    transition: transform var(--t-normal);
}

.hero-cta:hover svg {
    transform: translateX(4px);
}

.hero-feature-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 20px;
    padding-top: 18px;
    border-top: 1px solid var(--c-border);
}

.hero-feat-tag {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    font-weight: 500;
    color: #475569;
}

.hero-feat-tag svg {
    color: #10b981;
    flex-shrink: 0;
}

.hero-visual {
    position: relative;
    width: 520px;
    height: 500px;
    flex: 1;
    max-width: 560px;
    z-index: 2;
}

.hero-room-preview {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: var(--r-xl);
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.hero-card-header {
    position: absolute;
    top: 16px;
    left: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 10;
    pointer-events: none;
}

.hero-floating-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #0f172a;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    white-space: nowrap;
}

.hero-floating-badge.badge-3d {
    color: #475569;
    font-weight: 600;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #94a3b8;
}

.badge-dot.active {
    background: #10b981;
}

#heroCanvas {
    width: 100%;
    height: 100%;
    display: block;
    cursor: grab;
}

#heroCanvas:active {
    cursor: grabbing;
}

.hero-card-footer {
    position: absolute;
    bottom: 16px;
    left: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    z-index: 10;
    pointer-events: none;
}

.hero-spec-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 11px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    color: #334155;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    white-space: nowrap;
}

.hero-spec-pill svg {
    color: #1e293b;
    flex-shrink: 0;
}

/* ═══════════ HERO MOBILE RESPONSIVE ═══════════ */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        padding: 48px 24px;
        gap: 40px;
        text-align: center;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-title span {
        margin: 0 auto 4px auto;
    }

    .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-steps {
        justify-content: center;
    }

    .hero-feature-tags {
        justify-content: center;
    }

    .hero-visual {
        width: 100%;
        max-width: 480px;
        height: 400px;
    }
}

@media (max-width: 540px) {
    .hero {
        padding: 32px 16px;
        gap: 32px;
    }

    .hero-steps {
        gap: 6px;
    }

    .hero-step {
        padding: 5px 10px;
        font-size: 11px;
    }

    .hero-step-arrow {
        display: none;
    }

    .hero-cta {
        width: 100%;
        justify-content: center;
    }

    .hero-visual {
        height: 340px;
    }

    .hero-spec-pill {
        font-size: 10px;
        padding: 5px 8px;
    }
}

/* ═══════════ MODALS ═══════════ */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--t-normal);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: #ffffff;
    border: 1px solid var(--c-border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-lg);
    max-width: 520px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    transform: scale(0.96) translateY(10px);
    transition: transform var(--t-normal);
}

.modal-overlay.active .modal-card {
    transform: scale(1) translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--c-border);
}

.modal-title {
    font-size: 17px;
    font-weight: 800;
    color: var(--c-text);
    letter-spacing: -0.01em;
}

.modal-close {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: var(--r-sm);
    color: var(--c-text-muted);
    font-size: 20px;
    transition: all var(--t-fast);
}

.modal-close:hover {
    background: var(--c-bg-surface);
    color: var(--c-text);
}

.modal-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid var(--c-border);
    background: var(--c-bg-surface);
}

.modal-btn {
    padding: 10px 20px;
    border-radius: var(--r-sm);
    font-size: 13px;
    font-weight: 700;
    transition: all var(--t-normal);
}

.modal-btn.primary {
    background: var(--c-primary);
    color: #ffffff;
}

.modal-btn.primary:hover {
    background: #1e293b;
    box-shadow: var(--shadow-sm);
}

.modal-btn.secondary {
    background: #ffffff;
    border: 1px solid var(--c-border);
    color: var(--c-text-secondary);
}

.modal-btn.secondary:hover {
    border-color: var(--c-primary);
    color: var(--c-text);
}

.modal-lg {
    max-width: 820px;
}

/* ═══════════ TOAST NOTIFICATIONS ═══════════ */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

body:has(#landingWebsite:not(.hidden)) .toast-container,
body:has(#designerApp.hidden) .toast-container {
    display: none !important;
}

.toast {
    padding: 12px 18px;
    background: #ffffff;
    border: 1px solid var(--c-border);
    border-radius: var(--r-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    color: var(--c-text);
    font-size: 13px;
    font-weight: 600;
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: toastIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.toast.hide {
    opacity: 0;
    transform: translateY(10px);
}

.toast.success {
    border-left: 4px solid var(--c-success);
}

.toast.warning {
    border-left: 4px solid var(--c-warning);
}

.toast.info {
    border-left: 4px solid var(--c-primary);
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
