/*
  LegalSuvidha OS — Premium UI/UX Aesthetic
  High-Fidelity, Liquid Flow, Glassmorphism
*/

/* ═══ TOKENS & ANIMATIONS ═══ */
:root {
    --canvas: #f0f4f8;
    /* Soft textured blueish-gray */
    --panel: rgba(255, 255, 255, 0.85);
    /* Glass */
    --panel-solid: #ffffff;

    --primary: #f28b27;
    --primary-glow: rgba(242, 139, 39, 0.25);
    --primary-gradient: linear-gradient(135deg, #f28b27, #f97316);
    --primary-hover: #e67e16;

    --secondary: #0d233e;
    --secondary-gradient: linear-gradient(135deg, #0d233e, #1e3a5f);

    --accent: #229954;
    --accent-glow: rgba(34, 153, 84, 0.2);

    --error: #ef4444;
    --warning: #f59e0b;
    --success: #10b981;

    --text-main: #0f172a;
    --text-dim: #475569;
    --text-faint: #94a3b8;

    --border: rgba(15, 23, 42, 0.08);
    --border-glow: rgba(242, 139, 39, 0.4);

    --radius-pill: 100px;
    --radius-xl: 16px;
    --radius-lg: 12px;
    --radius-md: 8px;
    --radius-sm: 6px;

    --shadow-float: 0 10px 30px -10px rgba(13, 35, 62, 0.08), 0 0 0 1px rgba(255, 255, 255, 1) inset;
    --shadow-pop: 0 8px 20px -5px var(--primary-glow);
    --shadow-btn: 0 4px 12px -2px rgba(242, 139, 39, 0.3);

    --font-main: 'Poppins', system-ui, sans-serif;
    --font-heading: 'Urbanist', sans-serif;
}

@keyframes liquid-fill {
    0% {
        transform: scaleX(0);
        opacity: 0;
    }

    100% {
        transform: scaleX(1);
        opacity: 1;
    }
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(242, 139, 39, 0.5);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(242, 139, 39, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(242, 139, 39, 0);
    }
}

/* ═══ RESET ═══ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background: var(--canvas);
    background-image: radial-gradient(at 0% 0%, rgba(242, 139, 39, 0.04) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(13, 35, 62, 0.04) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-main);
    min-height: 100vh;
    line-height: 1.6;
}

/* ═══ NAVBAR ═══ */
.nav-bar {
    position: sticky;
    top: 0;
    z-index: 200;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border);
    gap: 16px;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo img {
    height: 48px;
    width: auto;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.logo:hover img {
    transform: scale(1.05);
}

.nav-links {
    display: flex;
    gap: 20px;
    align-items: center;
    flex: 1;
    justify-content: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--secondary);
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.2s;
    white-space: nowrap;
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-tag {
    font-size: 0.7rem;
    color: var(--secondary);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: white;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    box-shadow: var(--shadow-float);
    white-space: nowrap;
}

.btn-contact-mini {
    background: var(--secondary);
    color: white;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    transition: all 0.2s;
}

.btn-contact-mini:hover {
    background: var(--primary);
    transform: translateY(-1px);
}

.hamburger {
    display: none;
    cursor: pointer;
    color: var(--secondary);
}

/* ═══ MOBILE MENU OVERLAY ═══ */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    flex-direction: column;
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    padding: 24px;
    height: 100%;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.close-menu {
    font-size: 2rem;
    font-weight: bold;
    color: var(--secondary);
    cursor: pointer;
}

.mobile-links {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: auto;
}

.mobile-links a {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--secondary);
    text-decoration: none;
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
}

.mobile-footer {
    margin-top: auto;
    text-align: center;
    padding-bottom: 24px;
}

.contact-email {
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.wa-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #25D366;
    /* WhatsApp Green */
    color: white;
    text-decoration: none;
    padding: 16px 24px;
    border-radius: var(--radius-pill);
    font-weight: 800;
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    width: 100%;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    transition: transform 0.2s;
}

.wa-btn:active {
    transform: scale(0.95);
}

/* ═══ LOADER ═══ */
.loader-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(240, 244, 248, 0.95);
    backdrop-filter: blur(10px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 24px;
}

.loader-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 900;
    color: var(--secondary);
    text-align: center;
}

.loader-status {
    color: var(--primary);
    font-size: 1.1rem;
    font-weight: 600;
    padding: 12px 24px;
    background: white;
    border-radius: 100px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    text-align: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.spinner-sm {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    display: inline-block;
    animation: spin 0.6s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ═══ LAYOUT ═══ */
.app-container {
    padding: 24px 24px 40px;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
}

/* ═══ WIZARD CARD ═══ */
.wizard-card {
    background: var(--panel);
    backdrop-filter: blur(25px) saturate(150%);
    border: 1px solid white;
    border-radius: var(--radius-xl);
    padding: 32px 40px;
    box-shadow: var(--shadow-float);
    position: relative;
    overflow: hidden;
}

.wizard-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-gradient);
}

/* ═══ STEP PROGRESS BARS ═══ */
.step-progress {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
}

.progress-dot {
    height: 6px;
    flex: 1;
    background: rgba(13, 35, 62, 0.08);
    border-radius: var(--radius-pill);
    position: relative;
    overflow: hidden;
}

.progress-dot.active {
    background: rgba(13, 35, 62, 0.15);
}

.progress-dot.active::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    background: var(--primary-gradient);
    border-radius: var(--radius-pill);
    transform-origin: left;
    animation: liquid-fill 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.step-label {
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--primary);
    margin-bottom: 12px;
    text-transform: uppercase;
}

h1 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 900;
    letter-spacing: -0.5px;
    color: var(--secondary);
    line-height: 1.1;
    margin-bottom: 12px;
}

p.subtitle {
    color: var(--text-dim);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 24px;
    max-width: 700px;
    line-height: 1.6;
}

/* ═══ OPTION GRID & CARDS ═══ */
.option-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}

.single-col {
    grid-template-columns: 1fr;
}

.two-col-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.option-card {
    position: relative;
    background: var(--panel-solid);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    overflow: hidden;
}

.option-card::after {
    content: '✓';
    position: absolute;
    top: 12px;
    right: 12px;
    width: 20px;
    height: 20px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.option-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 16px rgba(13, 35, 62, 0.05);
    border-color: rgba(242, 139, 39, 0.2);
}

.option-card.selected {
    border-color: var(--primary);
    background: #fffdfa;
    box-shadow: var(--shadow-pop);
}

.option-card.selected::after {
    opacity: 1;
    transform: scale(1);
}

.option-card-sm {
    padding: 16px;
    text-align: left;
    align-items: flex-start;
    border-radius: var(--radius-md);
}

.option-icon {
    font-size: 1.8rem;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.option-card:hover .option-icon {
    transform: scale(1.1) rotate(5deg);
}

.option-label {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1rem;
    color: var(--secondary);
    line-height: 1.2;
}

.option-sub {
    font-size: 0.8rem;
    color: var(--text-dim);
}

.tag-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
}

.option-tag {
    padding: 12px 16px;
    border-radius: var(--radius-pill);
    font-size: 0.85rem;
    font-weight: 600;
    text-align: center;
}

/* ═══ SLIDER ═══ */
.slider-box {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-float);
}

.slider-value {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--primary);
    line-height: 1;
}

input[type="range"] {
    width: 100%;
    accent-color: var(--primary);
    height: 6px;
    cursor: pointer;
    margin: 16px 0;
}

.slider-hints {
    display: flex;
    justify-content: space-between;
    width: 100%;
}

.slider-hints span {
    font-weight: 600;
    color: var(--text-dim);
    font-size: 0.8rem;
}

/* ═══ SELECT ═══ */
.select-wrapper {
    position: relative;
}

.state-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-family: inherit;
    font-weight: 500;
    color: var(--secondary);
    appearance: none;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
}

.state-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-glow);
}

.select-wrapper::after {
    content: '▼';
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--primary);
    font-size: 0.7rem;
}

/* ═══ BUTTONS ═══ */
.nav-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 32px;
    border-top: 1px solid var(--border);
    padding-top: 24px;
}

.btn-base {
    padding: 12px 32px;
    border-radius: var(--radius-pill);
    font-weight: 700;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: var(--shadow-btn);
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px -6px rgba(242, 139, 39, 0.5);
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: white;
    color: var(--secondary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    border-color: var(--secondary);
    background: var(--canvas);
}

/* ═══ BENTO GRID ═══ */
.results-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 16px;
    width: 100%;
}

.bento-card {
    background: var(--panel-solid);
    border-radius: var(--radius-xl);
    padding: 24px;
    box-shadow: var(--shadow-float);
    border: 1px solid white;
}

.card-hero {
    grid-column: span 8;
    grid-row: span 2;
    background: var(--secondary-gradient);
    color: white;
    position: relative;
    overflow: hidden;
    padding: 32px;
}

.card-hero::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
}

.card-hero h1 {
    color: white;
    margin: 8px 0;
    font-size: 3rem;
}

.card-mini {
    grid-column: span 4;
    border: 1px solid var(--border);
}

.card-wide {
    grid-column: span 12;
}

.bento-label {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 4px;
}

.card-hero .bento-label {
    color: rgba(255, 255, 255, 0.7);
}

.big-cost {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 900;
    letter-spacing: -1px;
    line-height: 1;
}

.cost-sub {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.big-number {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--secondary);
}

.msme-badge {
    display: inline-flex;
    background: linear-gradient(135deg, var(--accent), #15803d);
    color: white;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.75rem;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    box-shadow: 0 2px 8px var(--accent-glow);
}

/* ═══ GATE OVERLAY ═══ */
.gate-card {
    padding: 0;
    position: relative;
}

.preview-blur {
    filter: blur(10px);
    opacity: 0.3;
    padding: 24px;
}

.gate-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 32px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    z-index: 10;
}

.gate-icon {
    font-size: 3rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    animation: pulse-ring 2s infinite;
}

.gate-card h2 {
    font-size: 2rem;
    color: var(--secondary);
    margin: 16px 0 8px;
}

.gate-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    max-width: 420px;
    margin: 24px auto 16px;
}

.gate-inputs-wrap {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.gate-input {
    width: 100%;
    padding: 14px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    font-family: inherit;
    font-size: 1rem;
    font-weight: 500;
    background: white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
    transition: all 0.2s;
}

.gate-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.gate-form .btn-primary {
    width: 100%;
    justify-content: center;
    padding: 16px;
    font-size: 1.1rem;
    border-radius: var(--radius-lg);
}

/* ═══ CRITICAL RISK ALERTS ═══ */
.risk-alert {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    border-radius: var(--radius-md);
    background: white;
    border: 1px solid var(--border);
    margin-bottom: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    transition: transform 0.2s, box-shadow 0.2s;
}

.risk-alert:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.05);
}

.risk-alert.risk-very-high {
    border-left: 4px solid var(--error);
    background: linear-gradient(90deg, rgba(239, 68, 68, 0.05) 0%, white 100%);
}

.risk-alert.risk-high {
    border-left: 4px solid var(--warning);
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.05) 0%, white 100%);
}

.risk-icon-badge {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--border);
}

.risk-alert strong {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: var(--secondary);
    display: block;
    margin-bottom: 4px;
}

.risk-alert p {
    color: var(--text-dim);
    font-size: 0.9rem;
    margin-top: 0;
    line-height: 1.6;
}

/* ═══ PRIORITY ACTION PLAN ═══ */
.action-item {
    display: flex;
    flex-direction: column;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    background: #f8fafc;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-left: 4px solid var(--border);
    margin-bottom: 8px;
    transition: transform 0.2s;
}

.action-item:hover {
    transform: translateX(4px);
    background: #f1f5f9;
}

.action-item strong {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 4px;
}

.action-item span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-dim);
    display: flex;
    align-items: center;
    gap: 6px;
}

.action-urgent .action-item {
    border-left-color: var(--error);
}

.action-medium .action-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.action-header {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 12px;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.action-urgent {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

.action-medium {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
}

/* ═══ FULL STATUTORY ROADMAP ═══ */
.roadmap-section {
    border: 1px solid var(--border);
    background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.section-header {
    margin-bottom: 24px;
}

.section-subtitle {
    font-size: 0.95rem;
    color: var(--text-dim);
    margin-top: 6px;
}

.compliance-list-modern {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.compliance-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    align-items: center;
    padding: 16px 24px;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.015);
}

.compliance-row:hover {
    border-color: rgba(242, 139, 39, 0.4);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.04);
    transform: scale(1.01);
}

.final-action-row {
    text-align: center;
    padding: 40px 0;
    border-top: 1px dashed var(--border);
    margin-top: 40px;
}

@media (max-width: 600px) {
    .compliance-row {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .compliance-row div:last-child {
        text-align: left !important;
    }
}

/* ═══ AI ADVISOR ═══ */
.ai-advisor {
    background: linear-gradient(180deg, #ffffff 0%, #f0f9ff 100%);
    border: 1px solid #bae6fd;
}

/* ═══ RESPONSIVE COMPAT ═══ */
@media (max-width: 900px) {
    .nav-links {
        display: none;
    }

    .nav-tag {
        display: none;
    }

    .hamburger {
        display: block;
    }

    .wizard-card {
        padding: 32px 24px;
    }
}

@media (max-width: 768px) {
    .nav-bar {
        padding: 12px 16px;
    }

    .hide-mobile {
        display: none;
    }

    .app-container {
        padding: 16px 12px 30px;
    }

    .wizard-card {
        padding: 24px 20px;
    }

    h1 {
        font-size: 1.8rem;
    }

    .nav-buttons {
        flex-direction: column-reverse;
        gap: 12px;
        margin-top: 24px;
        padding-top: 20px;
    }

    .btn-base {
        width: 100%;
        justify-content: center;
    }

    .two-col-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Force 2x1 grid for entity grid on mobile */
    #entityGrid {
        grid-template-columns: 1fr 1fr;
    }

    .card-hero,
    .card-mini {
        grid-column: span 12;
    }

    .big-cost {
        font-size: 2.5rem;
    }

    .option-card {
        padding: 16px 12px;
    }

    .gate-overlay {
        padding: 24px;
    }

    .gate-card h2 {
        font-size: 1.6rem;
    }

    .gate-form {
        max-width: 100%;
    }
}

/* ═══ COMPLIANCE INTELLIGENCE SECTION ═══ */
.compliance-intel-section {
    background: white;
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.section-title-wrap {
    text-align: center;
    margin-bottom: 50px;
}

.section-title-wrap h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--secondary);
    margin: 12px 0;
}

.intel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 60px;
}

.intel-card {
    padding: 32px;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    transition: transform 0.3s;
}

.intel-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
}

.intel-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.intel-card h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 12px;
}

.intel-card p {
    font-size: 0.95rem;
    color: var(--text-dim);
    line-height: 1.6;
}

.intel-footer-content {
    background: var(--secondary-gradient);
    color: white;
    padding: 40px;
    border-radius: var(--radius-xl);
}

.intel-footer-content h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 24px;
    color: var(--primary);
}

.matrix-list-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.matrix-list-wrap ul {
    list-style: none;
}

.matrix-list-wrap li {
    margin-bottom: 12px;
    font-size: 0.95rem;
    line-height: 1.4;
}

.matrix-list-wrap strong {
    color: var(--primary);
    display: block;
    margin-bottom: 4px;
}

@media (max-width: 768px) {
    .section-title-wrap h2 {
        font-size: 1.8rem;
    }
    .matrix-list-wrap {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .intel-card {
        padding: 24px;
    }
}

/* ═══ COMPLIANCE DIRECTORY INDEX ═══ */
.compliance-directory-section {
    background: #fdfdfd;
    padding: 80px 0 100px;
    border-top: 1px solid var(--border);
}

.directory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.directory-col h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.directory-col ul {
    list-style: none;
    padding: 0;
}

.directory-col li {
    font-size: 0.88rem;
    color: var(--text-dim);
    margin-bottom: 10px;
    padding-left: 14px;
    position: relative;
    transition: color 0.2s;
}

.directory-col li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

.directory-col li:hover {
    color: var(--primary);
    cursor: default;
}

.directory-summary {
    text-align: center;
    max-width: 800px;
    margin: 60px auto 0;
    padding: 30px;
    background: white;
    border: 1px dashed var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-dim);
    font-size: 0.95rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .directory-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* ═══ PREMIUM INTELLIGENCE TEASER ═══ */
.intelligence-teaser-section {
    padding: 60px 0 100px;
}

.premium-unlock-card {
    background: linear-gradient(135deg, #0a1f40 0%, #1a3a6d 100%);
    border-radius: var(--radius-xl);
    padding: 40px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(10, 31, 64, 0.15);
}

.premium-unlock-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px rgba(10, 31, 64, 0.25);
    border-color: var(--primary);
}

.glass-glimmer {
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: skewX(-25deg);
    transition: 0.8s;
}

.premium-unlock-card:hover .glass-glimmer {
    left: 200%;
}

.card-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.sparkle-icon {
    font-size: 2.8rem;
    filter: drop-shadow(0 0 15px var(--primary));
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.intelligence-tag {
    background: rgba(255, 122, 0, 0.15);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 900;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 122, 0, 0.3);
    margin-bottom: 12px;
    display: inline-block;
}

.teaser-info h3 {
    color: white;
    font-size: 1.8rem;
    font-weight: 900;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.teaser-info p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.05rem;
    max-width: 500px;
}

.access-btn {
    background: var(--primary-gradient);
    color: white;
    padding: 16px 32px;
    border-radius: var(--radius-pill);
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 20px rgba(255, 122, 0, 0.3);
    transition: all 0.3s;
}

.access-btn span {
    font-size: 1rem;
}

.premium-unlock-card:hover .access-btn {
    transform: scale(1.05);
    box-shadow: 0 15px 30px rgba(255, 122, 0, 0.5);
}

@media (max-width: 992px) {
    .premium-unlock-card {
        flex-direction: column;
        text-align: center;
        gap: 40px;
        padding: 50px 30px;
    }
    .card-left {
        flex-direction: column;
        gap: 20px;
    }
}

/* ═══ INTELLIGENCE DRAWER ═══ */
.intelligence-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100%;
    background: #f8fafc;
    z-index: 2000;
    transition: right 0.6s cubic-bezier(0.77, 0, 0.175, 1);
    overflow-y: auto;
}

.intelligence-drawer.active {
    right: 0;
}

.drawer-header {
    background: white;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.header-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-drawer {
    background: none;
    border: none;
    font-size: 3rem;
    color: var(--text-dim);
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.close-drawer:hover {
    color: var(--primary);
}

.drawer-body {
    padding: 60px 0 100px;
}

.drawer-footer {
    text-align: center;
    margin-top: 100px;
    padding-top: 60px;
    border-top: 1px solid var(--border);
}

.drawer-footer p {
    color: var(--text-faint);
    margin-bottom: 30px;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .teaser-card {
        flex-direction: column;
        text-align: center;
        padding: 40px 24px;
    }
    .teaser-action {
        width: 100%;
    }
    .teaser-action .btn {
        width: 100%;
    }
}

/* ═══ VIEWPORT OPTIMIZATION ═══ */
.tool-viewport-wrapper {
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.tool-viewport-wrapper .app-container {
    padding: 20px;
    margin: 0;
}

@media (max-width: 768px) {
    .tool-viewport-wrapper {
        min-height: auto;
        padding: 40px 0;
    }
}