/* Nova Intelligence Agent - Professional UI */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Spline Bento Glassmorphism Palette */
    --bg-dark: #000000;
    --bg-card: rgba(28, 28, 30, 0.7);
    --bg-elevated: rgba(45, 45, 50, 0.8);
    --accent: #007AFF;
    --accent-hover: #005FB3;
    --accent-light: rgba(0, 122, 255, 0.15);
    --text-primary: #FFFFFF;
    --text-secondary: rgba(255, 255, 255, 0.6);
    --text-muted: rgba(255, 255, 255, 0.4);
    --success: #34C759;
    --warning: #FF9F0A;
    --error: #FF3B30;
    --border: rgba(255, 255, 255, 0.12);
    --shadow-sm: inset 0 1px 1px rgba(255, 255, 255, 0.1);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.6);
    --shadow-inset: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

body.light-theme {
    --bg-dark: #f2f2f7;
    --bg-card: rgba(255, 255, 255, 0.8);
    --bg-elevated: rgba(240, 240, 245, 0.9);
    --text-primary: #000000;
    --text-secondary: rgba(0, 0, 0, 0.6);
    --text-muted: rgba(0, 0, 0, 0.4);
    --border: rgba(0, 0, 0, 0.12);
}

body {
    font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    padding: 2rem;
    line-height: 1.5;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 2rem;
}

.header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.tagline {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Feature Toggle Badges - Spline Pill Style */
.features {
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.badge {
    background: var(--bg-card);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    padding: 0.6rem 1.4rem;
    border-radius: 100px;
    /* Pill Shape */
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.2px;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: var(--shadow-sm);
}

.badge:hover {
    background: var(--bg-elevated);
    transform: translateY(-2px) scale(1.02);
    color: var(--text-primary);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3), inset 0 1px 1px rgba(255, 255, 255, 0.15);
}

.badge:active {
    transform: translateY(0) scale(0.98);
}

.badge.active {
    background: linear-gradient(180deg, #007AFF, #005FB3);
    color: white;
    border-color: rgba(0, 122, 255, 0.5);
    box-shadow: 0 0 15px rgba(0, 122, 255, 0.3), inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

/* Select All Button */
.select-all-badge {
    background: linear-gradient(135deg, #2d3346, #3a3f55) !important;
    border: 1px solid rgba(234, 179, 8, 0.3) !important;
    color: #eab308 !important;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.select-all-badge:hover {
    background: linear-gradient(135deg, #3a3f55, #454b63) !important;
    border-color: rgba(234, 179, 8, 0.5) !important;
    box-shadow: var(--shadow-md), 0 0 15px rgba(234, 179, 8, 0.2) !important;
}

.select-all-badge.active {
    background: linear-gradient(135deg, #92700c, #b8860b) !important;
    color: #fff !important;
    border-color: #eab308 !important;
    box-shadow: var(--shadow-md), 0 0 20px rgba(234, 179, 8, 0.35) !important;
}

/* Divider between Select All and tool badges */
.feature-divider {
    width: 1px;
    height: 28px;
    background: rgba(255, 255, 255, 0.12);
    align-self: center;
    margin: 0 0.15rem;
}

.toggle-hint {
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* =========================================================
   LANDING / AUTH VIEW
   ========================================================= */
.landing-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

.spline-bg {
    position: absolute;
    width: 100vw;
    height: 100vh;
    z-index: 0;
}

.landing-content {
    position: relative;
    z-index: 10;
    width: 90%;
    max-width: 500px;
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border-radius: 40px;
    padding: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.8), inset 0 1px 2px rgba(255, 255, 255, 0.05);
    color: white;
    text-align: center;
}

.landing-title {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(90deg, #fff, #a1a1aa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.landing-subtitle {
    color: #a1a1aa;
    font-size: 1rem;
    margin-bottom: 2rem;
    line-height: 1.5;
}

.auth-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 0.3rem;
    border-radius: 100px;
}

.auth-tab {
    flex: 1;
    padding: 0.8rem;
    border: none;
    background: transparent;
    color: #a1a1aa;
    font-weight: 600;
    cursor: pointer;
    border-radius: 100px;
    transition: all 0.2s;
}

.auth-tab.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.auth-form input {
    padding: 1rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.4);
    color: white;
    outline: none;
    transition: 0.3s;
}

.auth-form input:focus {
    border-color: #007AFF;
}

.auth-btn {
    width: 100%;
    margin-top: 0.5rem;
}

.auth-error {
    font-size: 0.85rem;
    color: #FF3B30;
    min-height: 1rem;
    text-align: center;
}

.landing-docs {
    text-align: left;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.landing-docs h3 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.landing-docs ul {
    list-style: none;
    padding: 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #a1a1aa;
}

.landing-docs li {
    margin-bottom: 0.75rem;
}

/* =========================================================
   MARKETING (GETTING STARTED) PAGE
   ========================================================= */
.marketing-page {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background: #000;
    overflow-x: hidden;
    overflow-y: auto;
    z-index: 10001;
    /* Above auth view */
}

.mkt-spline-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    opacity: 0.6;
}

.mkt-nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 20;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mkt-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: white;
    letter-spacing: -1px;
}

.mkt-content {
    position: relative;
    z-index: 10;
    padding-top: 15vh;
    padding-bottom: 10vh;
    max-width: 1200px;
    margin: 0 auto;
}

.mkt-hero {
    text-align: center;
    margin-bottom: 10vh;
}

.mkt-hero .mkt-title {
    font-size: 4rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(135deg, #fff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.mkt-hero .mkt-subtitle {
    font-size: 1.25rem;
    color: #a1a1aa;
    max-width: 600px;
    margin: 0 auto 3rem auto;
    line-height: 1.6;
}

.mkt-hero-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.mkt-hero-actions .mkt-main-btn {
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
    border-radius: 100px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 15px rgba(0, 122, 255, 0.4);
}

.mkt-hero-actions .mkt-main-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(0, 122, 255, 0.8);
}

.mkt-scroll-link {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.mkt-scroll-link:hover {
    color: white;
}

.mkt-features {
    display: flex;
    gap: 2rem;
    padding: 3rem;
    margin-bottom: 10vh;
}

.mkt-feature-card {
    flex: 1;
    padding: 2.5rem;
    border-radius: 30px;
    background: rgba(20, 20, 25, 0.6);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: default;
}

.mkt-feature-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 122, 255, 0.2);
    border-color: rgba(0, 122, 255, 0.5);
}

.mkt-f-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.mkt-feature-card h3 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.mkt-feature-card p {
    color: #a1a1aa;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Dynamic Pipeline Visual */
.mkt-pipeline {
    margin: 5rem 0;
    padding: 3rem;
}

.mkt-pipeline-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.pipe-node {
    padding: 1.5rem 2rem;
    background: rgba(20, 20, 25, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
}

.pipe-node:hover {
    transform: scale(1.1);
    border-color: #007AFF;
    box-shadow: 0 0 20px rgba(0, 122, 255, 0.3);
}

.pipe-line {
    width: 100px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    position: relative;
    overflow: hidden;
}

.pipe-progress {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 50%;
    background: #007AFF;
    border-radius: 2px;
    animation: pipeline 2s infinite ease-in-out;
}

@keyframes pipeline {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(200%);
    }
}

/* 3D Use-Case Orbit Section */
.mkt-usecases {
    margin: 6rem auto 4rem auto;
    max-width: 1100px;
    position: relative;
}

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

.mkt-tag {
    display: inline-block;
    padding: 0.25rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.5);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #e5e7eb;
    background: rgba(15, 23, 42, 0.8);
}

.mkt-usecases-header h2 {
    margin-top: 1rem;
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
}

.mkt-usecases-sub {
    margin-top: 0.75rem;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
    color: #a1a1aa;
    font-size: 0.95rem;
}

.mkt-usecases-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.75rem;
    perspective: 1400px;
}

.mkt-usecase-card {
    position: relative;
    padding: 2rem 1.8rem 2.2rem 1.8rem;
    border-radius: 28px;
    background: radial-gradient(circle at top left, rgba(148, 163, 255, 0.35), rgba(15, 23, 42, 0.96));
    border: 1px solid rgba(148, 163, 255, 0.4);
    box-shadow:
        0 30px 80px rgba(15, 23, 42, 0.9),
        0 0 40px rgba(59, 130, 246, 0.28);
    transform-style: preserve-3d;
    transform: rotateX(14deg) rotateY(-12deg) translateY(0);
    transition:
        transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1),
        box-shadow 0.6s cubic-bezier(0.22, 0.61, 0.36, 1),
        border-color 0.3s ease;
}

.mkt-usecase-card:hover {
    transform: rotateX(6deg) rotateY(-2deg) translateY(-18px) scale(1.02);
    box-shadow:
        0 40px 120px rgba(15, 23, 42, 1),
        0 0 60px rgba(96, 165, 250, 0.7);
    border-color: rgba(191, 219, 254, 0.9);
}

.mkt-usecase-card h3 {
    margin-top: 3.25rem;
    margin-bottom: 0.75rem;
    font-size: 1.15rem;
    color: #f9fafb;
}

.mkt-usecase-card p {
    font-size: 0.9rem;
    color: #d1d5db;
    line-height: 1.55;
    margin-bottom: 0.85rem;
}

.mkt-usecase-card ul {
    list-style: none;
    padding-left: 0;
    margin: 0.25rem 0 0;
    font-size: 0.8rem;
    color: #9ca3af;
}

.mkt-usecase-card li {
    position: relative;
    padding-left: 1.1rem;
    margin-bottom: 0.35rem;
}

.mkt-usecase-card li::before {
    content: "●";
    position: absolute;
    left: 0;
    top: 0.15rem;
    font-size: 0.6rem;
    color: #60a5fa;
}

.mkt-orbit-ring {
    position: absolute;
    top: 1.1rem;
    left: 1.4rem;
    width: 70px;
    height: 70px;
    border-radius: 999px;
    border: 1px solid rgba(191, 219, 254, 0.8);
    box-shadow:
        0 0 20px rgba(191, 219, 254, 0.9),
        0 0 60px rgba(129, 140, 248, 0.6);
    transform: translateZ(40px) rotateX(48deg) rotateZ(-26deg);
    transform-origin: center;
}

.mkt-orbit-ring::after {
    content: "";
    position: absolute;
    inset: 12px;
    border-radius: inherit;
    border: 1px dashed rgba(191, 219, 254, 0.5);
    opacity: 0.7;
}

.mkt-orbit-core {
    position: absolute;
    top: 1.7rem;
    left: 2.2rem;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 0%, #ffffff, #60a5fa);
    color: #020617;
    font-size: 1.4rem;
    box-shadow:
        0 0 25px rgba(96, 165, 250, 0.9),
        0 0 80px rgba(129, 140, 248, 1);
    transform: translateZ(60px);
}

.mkt-orbit-ring.alt {
    border-color: rgba(45, 212, 191, 0.9);
    box-shadow:
        0 0 20px rgba(45, 212, 191, 0.8),
        0 0 60px rgba(16, 185, 129, 0.7);
}

.mkt-orbit-core.alt {
    background: radial-gradient(circle at 30% 0%, #ffffff, #22c55e);
}

.mkt-orbit-ring.purple {
    border-color: rgba(192, 132, 252, 0.9);
    box-shadow:
        0 0 20px rgba(192, 132, 252, 0.9),
        0 0 60px rgba(147, 51, 234, 0.8);
}

.mkt-orbit-core.purple {
    background: radial-gradient(circle at 30% 0%, #ffffff, #a855f7);
}

@media (max-width: 1024px) {
    .mkt-usecases-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .mkt-usecase-card {
        transform: rotateX(10deg) rotateY(-8deg);
    }
}

@media (max-width: 768px) {
    .mkt-usecases {
        margin-top: 4rem;
    }

    .mkt-usecases-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .mkt-usecase-card {
        transform: none;
    }

    .mkt-usecase-card:hover {
        transform: translateY(-10px);
    }
}

/* Utilities for Auth & Marketing */
.spline-watermark-hider {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 140px;
    height: 40px;
    background: #000;
    z-index: 100;
    border-radius: 5px;
    pointer-events: none;
}

.back-btn-auth {
    position: absolute;
    top: 20px;
    left: 20px;
    background: transparent;
    border: none;
    color: #a1a1aa;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.back-btn-auth:hover {
    color: white;
    transform: translateX(-5px);
}

.mkt-footer {
    position: relative;
    z-index: 10;
    padding: 3rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(0, 0, 0, 0.8);
    color: #a1a1aa;
    font-size: 0.9rem;
}

.mkt-footer a {
    color: #93c5fd;
    text-decoration: none;
}

.mkt-footer a:hover {
    text-decoration: underline;
}

.mkt-made-by {
    color: #e5e7eb;
}

/* ROBO GUIDE */
.robo-body {
    text-align: center;
}

.robo-screen {
    background: #000;
    padding: 2rem;
    border-radius: 20px;
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.robo-face {
    font-size: 3rem;
    color: #007AFF;
    font-family: monospace;
    margin-bottom: 1rem;
    animation: float 2s ease-in-out infinite;
}

.robo-text {
    font-size: 1.1rem;
    color: #fff;
    line-height: 1.5;
}

.robo-btn {
    width: 100%;
    margin-top: 1rem;
    flex: 1;
}

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0);
    }
}

/* =========================================================
   SPLINE iOS 26 BENTO DASHBOARD UI
   ========================================================= */
.bento-layout {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 1.5rem;
    background: var(--bg-dark);
    padding: 1.5rem;
    border-radius: 40px;
    margin-bottom: 2rem;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.8), inset 0 1px 2px rgba(255, 255, 255, 0.05);
}

.bento-col {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* --- Left Column: Pillars & Icons --- */
.bento-vertical-grid {
    display: flex;
    gap: 0.75rem;
    height: 180px;
}

.bento-tall {
    flex: 1;
    background: rgba(28, 28, 30, 0.7);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 40px;
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem 0;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    color: #fff;
    box-shadow: var(--shadow-sm);
}

.bento-tall:hover {
    background: rgba(45, 45, 50, 0.8);
    transform: translateY(-2px);
}

.bento-tall.active {
    border-color: rgba(255, 255, 255, 0.3);
}

.bento-tall .bento-icon {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.bento-slider-track {
    width: 24px;
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    margin-top: 0.5rem;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.5);
}

.bento-slider-fill {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 12px;
}

.bento-app-icons {
    display: flex;
    gap: 1rem;
}

.bento-app {
    width: 80px;
    height: 80px;
    border-radius: 24px;
    /* Squircle */
    font-size: 2.5rem;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.bento-app:hover {
    transform: scale(1.05);
}

.bento-app.btn-green {
    background: linear-gradient(135deg, #4ade80, #16a34a);
    box-shadow: 0 10px 20px rgba(22, 163, 74, 0.3);
}

.bento-app.btn-blue {
    background: linear-gradient(135deg, #60a5fa, #2563eb);
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.3);
}

.bento-menu-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.bento-menu-tabs {
    display: flex;
    background: rgba(28, 28, 30, 0.7);
    border-radius: 100px;
    padding: 0.3rem;
    border: 1px solid var(--border);
}

.bento-tab {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    padding: 0.5rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.bento-tab.active {
    background: #5c5c5e;
}

.bento-menu-box {
    background: rgba(28, 28, 30, 0.7);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--border);
}

.bento-menu-row {
    padding: 1rem;
    background: transparent;
    color: #fff;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-align: left;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.bento-menu-row:last-child {
    border-bottom: none;
}

.bento-menu-row:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* --- Center Column: Main Dialog --- */
.bento-main-dialog {
    background: var(--bg-card);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-radius: 40px;
    padding: 2.5rem;
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.05);
}

.bento-main-dialog h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.bento-main-dialog p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 0.95rem;
    line-height: 1.4;
}

.bento-input-wrapper {
    display: flex;
    background: var(--bg-dark);
    border-radius: 100px;
    padding: 0.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border);
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.5);
}

.bento-input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    padding: 0 1rem;
    font-size: 1rem;
    outline: none;
}

.bento-mic {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.2s;
}

.bento-mic:hover {
    background: rgba(255, 255, 255, 0.1);
}

.bento-mic.listening {
    background: #FF3B30;
    box-shadow: 0 0 15px rgba(255, 59, 48, 0.5);
}

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

.bento-btn-dark,
.bento-btn-blue {
    flex: 1;
    padding: 1rem;
    border-radius: 100px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.bento-btn-dark {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}

.bento-btn-dark:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.bento-btn-blue {
    background: linear-gradient(180deg, #007AFF, #005FB3);
    color: #fff;
    box-shadow: 0 4px 10px rgba(0, 122, 255, 0.3), inset 0 1px 1px rgba(255, 255, 255, 0.2);
}

.bento-btn-blue:hover {
    transform: translateY(-2px) scale(1.02);
    filter: brightness(1.1);
    box-shadow: 0 6px 15px rgba(0, 122, 255, 0.4);
}

.bento-nav-bar {
    background: rgba(28, 28, 30, 0.7);
    border-radius: 100px;
    padding: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border);
}

.bento-nav-item {
    background: transparent;
    border: none;
    color: #fff;
    width: 65px;
    height: 55px;
    border-radius: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    cursor: pointer;
    transition: all 0.2s;
}

.bento-nav-item .icon {
    font-size: 1.1rem;
}

.bento-nav-item .label {
    font-size: 0.65rem;
    font-weight: 500;
    opacity: 0.6;
}

.bento-nav-item:hover,
.bento-nav-item.active {
    background: rgba(255, 255, 255, 0.08);
}

.bento-nav-item.active .icon {
    color: #007AFF;
    text-shadow: 0 0 10px rgba(0, 122, 255, 0.5);
}

.bento-nav-item.active .label {
    opacity: 1;
    color: #007AFF;
}

/* --- Right Column: Toggles & Sliders --- */
.bento-header-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.bento-action {
    padding: 0.85rem;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    color: #fff;
    transition: all 0.2s;
}

.bento-action.red {
    background: linear-gradient(180deg, #FF3B30, #D70015);
    box-shadow: 0 4px 10px rgba(255, 59, 48, 0.3);
}

.bento-action.dark {
    background: rgba(45, 45, 50, 0.8);
}

.bento-action:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.bento-switches {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    padding: 0.5rem 0;
}

.bento-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.02);
    padding: 0.75rem 1rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.bento-switch-row .icon {
    font-size: 1.2rem;
    margin-right: 0.75rem;
}

.bento-switch-row .label {
    flex: 1;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
}

.switch-ui {
    width: 60px;
    height: 32px;
    background: var(--bg-elevated);
    border-radius: 100px;
    border: 1px solid var(--border);
    position: relative;
    cursor: pointer;
    transition: background 0.3s;
}

.switch-ui .thumb {
    width: 24px;
    height: 24px;
    background: #fff;
    border-radius: 50%;
    position: absolute;
    top: 3px;
    left: 4px;
    transition: transform 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.switch-ui.active {
    background: #34C759;
    border-color: transparent;
}

.switch-ui.active .thumb {
    transform: translateX(26px);
}

.bento-h-sliders {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 0.5rem;
}

.h-slider-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.h-slider-row .icon {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
}

.bento-slider-h-track {
    flex: 1;
    height: 12px;
    background: rgba(45, 45, 50, 0.8);
    border-radius: 6px;
    position: relative;
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.5);
}

.bento-slider-h-fill {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    background: #007AFF;
    border-radius: 6px;
}

.bento-slider-h-thumb {
    width: 20px;
    height: 20px;
    background: #fff;
    position: absolute;
    top: -4px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.bento-slider-h-thumb.square {
    border-radius: 6px;
}

.bento-slider-h-thumb.pill {
    border-radius: 10px;
    width: 30px;
}

/* Status Notifications */
.status {
    padding: 0.75rem 1rem;
    background: var(--bg-card);
    border-radius: 8px;
    margin-bottom: 1.5rem;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
    box-shadow: var(--shadow-sm);
}

.status.success {
    border-left: 3px solid var(--success);
    color: var(--success);
}

.status.error {
    border-left: 3px solid var(--error);
    color: var(--error);
}

.status.loading {
    border-left: 3px solid var(--warning);
    color: var(--warning);
}

/* Results Grid */
.results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .results-grid {
        grid-template-columns: 1fr;
    }
}

/* Panels - 3D Glass Bento Card Effect */
.panel {
    background: var(--bg-card);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-radius: 40px;
    /* Spline style massive border radiuses */
    border: 1px solid var(--border);
    overflow: hidden;
    box-shadow: var(--shadow-lg), inset 0 1px 2px rgba(255, 255, 255, 0.08);
}

.panel-header {
    padding: 0.9rem 1.2rem;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
}

.panel-header h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.panel pre {
    padding: 1rem;
    margin: 0;
    font-size: 0.75rem;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    overflow-x: auto;
    max-height: 280px;
    background: var(--bg-dark);
    color: var(--text-secondary);
}

/* Intel Panel */
.intel-content {
    padding: 1rem;
}

.intel-section {
    margin-bottom: 1.2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.intel-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.intel-section h4 {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.intel-section p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.intel-section ul {
    margin-top: 0.5rem;
    padding-left: 1.2rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.intel-section li {
    margin-bottom: 0.3rem;
}

/* Sentiment Bar */
.sentiment-bar {
    height: 6px;
    background: var(--bg-dark);
    border-radius: 3px;
    overflow: hidden;
    margin: 0.5rem 0;
}

.sentiment-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.sentiment-fill.positive {
    background: var(--success);
}

.sentiment-fill.neutral {
    background: var(--warning);
}

.sentiment-fill.negative {
    background: var(--error);
}

/* Sentiment Intelligence Panel */
.sentiment-intel {
    background: rgba(79, 140, 255, 0.05);
    border-radius: 8px;
    padding: 1rem !important;
}

.sentiment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.mood-label {
    font-size: 1rem;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
}

.mood-label.positive {
    background: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

.mood-label.neutral {
    background: rgba(234, 179, 8, 0.15);
    color: var(--warning);
}

.mood-label.negative {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

.direction-badge {
    font-size: 0.8rem;
    color: var(--text-secondary);
    background: var(--bg-elevated);
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
}

.reasoning {
    background: var(--bg-dark);
    padding: 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 0.75rem 0;
    line-height: 1.5;
}

.reasoning strong {
    color: var(--accent);
}

.signals-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin: 0.75rem 0;
}

.signal-col {
    background: var(--bg-dark);
    padding: 0.6rem;
    border-radius: 6px;
    font-size: 0.8rem;
}

.signal-col strong {
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.75rem;
}

.signal-col.positive strong {
    color: var(--success);
}

.signal-col.negative strong {
    color: var(--error);
}

.signal-col ul {
    margin: 0;
    padding-left: 1rem;
    font-size: 0.75rem;
}

.signal-col li {
    margin-bottom: 0.2rem;
}

.sentiment-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

.conf-badge,
.risk-badge,
.breakdown {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    background: var(--bg-elevated);
    color: var(--text-muted);
}

.conf-high {
    color: var(--success);
}

.conf-med {
    color: var(--warning);
}

.conf-low {
    color: var(--text-muted);
}

.risk-high {
    color: var(--error);
    background: rgba(239, 68, 68, 0.1);
}

.risk-mod {
    color: var(--warning);
}

.risk-low {
    color: var(--success);
}

/* V2 Market Indicators */
.market-indicators {
    display: flex;
    gap: 1rem;
    margin: 0.75rem 0;
    padding: 0.6rem;
    background: var(--bg-dark);
    border-radius: 6px;
}

.market-indicators .indicator {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.market-indicators .indicator strong {
    color: var(--accent);
}

/* Emerging Themes */
.emerging-themes {
    margin: 0.75rem 0;
    padding: 0.6rem;
    background: var(--bg-dark);
    border-radius: 6px;
    font-size: 0.8rem;
}

.emerging-themes strong {
    color: var(--warning);
    margin-right: 0.5rem;
}

.theme-tag {
    display: inline-block;
    background: rgba(234, 179, 8, 0.15);
    color: var(--warning);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    margin: 0.2rem;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Trend Tags */
.trend-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.trend-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: var(--accent-light);
    color: var(--accent);
    padding: 0.3rem 0.7rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.trend-tag small {
    opacity: 0.7;
    font-size: 0.65rem;
}

.trend-tag.rising-tag {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.trend-tag.fading-tag {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
    opacity: 0.8;
}

/* Trend Categories */
.trend-category {
    margin: 0.6rem 0;
    padding: 0.5rem;
    border-radius: 8px;
}

.trend-category.rising {
    background: rgba(16, 185, 129, 0.05);
    border-left: 3px solid #10b981;
}

.trend-category.fading {
    background: rgba(239, 68, 68, 0.05);
    border-left: 3px solid #ef4444;
}

.trend-category .category-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.4rem;
    opacity: 0.8;
}

/* Narrative Signals */
.narrative-signals {
    margin-top: 1rem;
    padding: 0.75rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(16, 185, 129, 0.05));
    border-radius: 10px;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.narrative-signals h5 {
    font-size: 0.8rem;
    color: var(--accent);
    margin-bottom: 0.6rem;
}

.signal-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.signal-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
}

.signal-item.bullish {
    background: rgba(16, 185, 129, 0.1);
    border-left: 3px solid #10b981;
}

.signal-item.bearish {
    background: rgba(239, 68, 68, 0.1);
    border-left: 3px solid #ef4444;
}

.signal-item.neutral {
    background: rgba(148, 163, 184, 0.1);
    border-left: 3px solid #94a3b8;
}

.signal-icon {
    font-size: 1rem;
}

.signal-topic {
    font-weight: 600;
    color: var(--text-primary);
}

.signal-label {
    color: var(--text-muted);
    margin-left: auto;
    font-size: 0.7rem;
}

.market-narrative {
    margin-top: 0.6rem;
    padding-top: 0.5rem;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    font-size: 0.75rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Active News Narratives */
.active-narratives {
    margin-top: 1rem;
    padding: 0.75rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(99, 102, 241, 0.05));
    border-radius: 10px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.active-narratives h5 {
    font-size: 0.85rem;
    color: #3b82f6;
    margin-bottom: 0.6rem;
}

.narrative-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.narrative-card {
    padding: 0.6rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid #6b7280;
}

.narrative-card.positive {
    border-left-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.narrative-card.critical {
    border-left-color: #ef4444;
    background: rgba(239, 68, 68, 0.05);
}

.narrative-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.story-icon {
    font-size: 1rem;
}

.story-topic {
    font-weight: 600;
    color: var(--text-primary);
    flex: 1;
}

.news-cycle {
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
    background: rgba(99, 102, 241, 0.15);
    border-radius: 4px;
    color: var(--accent);
}

.narrative-details {
    display: flex;
    gap: 0.8rem;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}

.narrative-details span {
    cursor: help;
}

.why-trending {
    padding-top: 0.4rem;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.why-trending small {
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.why-trending ul {
    margin: 0.3rem 0 0;
    padding-left: 1rem;
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.why-trending li {
    margin-bottom: 0.2rem;
}

.news-summary {
    margin-top: 0.6rem;
    padding: 0.5rem;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* News Panel */
.news-panel {
    margin-bottom: 1.5rem;
}

.news-grid {
    padding: 0.75rem;
    max-height: 350px;
    overflow-y: auto;
}

.news-item {
    padding: 0.9rem;
    background: var(--bg-elevated);
    border-radius: 8px;
    margin-bottom: 0.5rem;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.news-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-md);
}

.news-item a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    display: block;
    line-height: 1.4;
}

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

.news-source {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Examples */
.examples {
    text-align: center;
    padding: 1rem;
}

.examples p {
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    font-size: 0.85rem;
}

.example-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.chip {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.chip:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.chip:active {
    transform: translateY(0);
}

/* Code styling */
code {
    background: var(--bg-dark);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-family: 'JetBrains Mono', monospace;
    color: var(--accent);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: var(--bg-elevated);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Responsive */
@media (max-width: 600px) {
    body {
        padding: 1rem;
    }

    .header h1 {
        font-size: 1.5rem;
    }

    .input-section {
        flex-wrap: wrap;
    }

    .mic-btn {
        width: 48px;
        height: 48px;
    }

    .send-btn {
        width: 100%;
    }
}

/* History Panel */
.history-panel {
    margin-bottom: 1rem;
}

.history-list {
    padding: 0.75rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    max-height: 120px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-elevated);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.history-item:hover {
    background: var(--accent);
    transform: translateY(-1px);
}

.history-query {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-primary);
}

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

.history-item:hover .history-time {
    color: rgba(255, 255, 255, 0.7);
}

.history-empty {
    color: var(--text-muted);
    font-size: 0.85rem;
    padding: 0.5rem;
}

/* Hover Tooltips for Finance Terms */
.term {
    position: relative;
    cursor: help;
    color: var(--accent);
    /* No underline - just color highlight */
}

[data-tooltip] {
    position: relative;
    cursor: help;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    background: var(--bg-dark);
    color: var(--text-primary);
    padding: 0.6rem 0.8rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1.4;
    width: max-content;
    max-width: 280px;
    text-align: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
    white-space: normal;
}

[data-tooltip]::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--bg-dark);
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

[data-tooltip]:hover::after,
[data-tooltip]:hover::before {
    opacity: 1;
    visibility: visible;
    transition-delay: 0.5s;
    /* 500ms delay */
}

/* Bottom tooltip for elements near top */
.sentiment-meta [data-tooltip]::after {
    bottom: auto;
    top: 100%;
    transform: translateX(-50%) translateY(4px);
}

.sentiment-meta [data-tooltip]::before {
    bottom: auto;
    top: 100%;
    border-top-color: transparent;
    border-bottom-color: var(--bg-dark);
}

/* Tooltip highlight on hover */
.term:hover {
    color: #60a5fa;
    text-shadow: 0 0 8px rgba(96, 165, 250, 0.5);
}

/* ============ SETTINGS BUTTON ============ */
.header {
    position: relative;
}

.settings-btn {
    position: absolute;
    top: 1rem;
    right: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem 0.8rem;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.settings-btn:hover {
    background: var(--accent);
    transform: scale(1.05);
}

/* ============ MODAL ============ */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: var(--bg-card);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-radius: 40px;
    /* Bento Radius */
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5), inset 0 1px 2px rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    margin: 0;
    color: var(--text-primary);
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
}

.close-btn:hover {
    color: var(--error);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
}

.save-btn {
    background: linear-gradient(135deg, var(--accent), #6366f1);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 140, 255, 0.4);
}

.setting-group {
    margin-bottom: 1.5rem;
}

.setting-group label {
    font-weight: 600;
    color: var(--text-primary);
    display: block;
    margin-bottom: 0.5rem;
}

.setting-hint {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

.toggle-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-elevated);
    padding: 0.75rem;
    border-radius: 8px;
}

.toggle-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--accent);
}

/* Tools info grid in settings */
.tools-info-grid {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.tool-info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.65rem;
    background: var(--bg-elevated);
    border-radius: 6px;
    font-size: 0.82rem;
    color: var(--text-primary);
}

.tool-info-item em {
    color: var(--text-muted);
    font-style: normal;
    font-size: 0.78rem;
}

.tool-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.tool-dot.core {
    background: var(--success);
    box-shadow: 0 0 4px rgba(34, 197, 94, 0.5);
}

.tool-dot.mas {
    background: #a855f7;
    box-shadow: 0 0 4px rgba(168, 85, 247, 0.5);
}

.setting-action-btn {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.setting-action-btn:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--error);
    color: var(--error);
}

/* ============ LANGUAGE SELECTOR ============ */
.language-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background: var(--bg-elevated);
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.lang-option:hover {
    background: var(--bg-dark);
}

.lang-option.selected {
    background: rgba(79, 140, 255, 0.2);
    border: 1px solid var(--accent);
}

.lang-option input {
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
}

/* ============ TRANSLATE CONTROLS ============ */
.translate-controls {
    margin-left: auto;
}

.translate-select {
    background: var(--bg-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
    cursor: pointer;
}

.translate-select:hover {
    border-color: var(--accent);
}

.translated-content {
    background: var(--bg-dark);
    border-radius: 8px;
    padding: 1rem;
}

.translate-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 0.75rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
    color: var(--accent);
    font-size: 0.85rem;
}

.show-original-btn {
    background: var(--bg-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.3rem 0.6rem;
    font-size: 0.75rem;
    cursor: pointer;
}

.show-original-btn:hover {
    background: var(--accent);
}

.translated-text {
    color: var(--text-secondary);
    line-height: 1.6;
    white-space: pre-wrap;
}

/* ============ DICTIONARY POPUP ============ */
.dict-popup {
    position: fixed;
    background: var(--bg-dark);
    border: 1px solid var(--accent);
    border-radius: 10px;
    padding: 1rem;
    max-width: 320px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    z-index: 3000;
    animation: dictFadeIn 0.2s ease;
}

.dict-popup.hidden {
    display: none;
}

@keyframes dictFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dict-word {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.25rem;
}

.dict-pos {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 0.5rem;
}

.dict-defs {
    margin-bottom: 0.75rem;
}

.dict-def {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.3rem;
    line-height: 1.4;
}

.dict-source {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-align: right;
}

/* Panel header flex for translate */
.panel-header {
    display: flex;
    align-items: center;
}

/* Header controls container */
.header-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: auto;
}

/* Dictionary Controls */
.dict-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dict-toggle-btn {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dict-toggle-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.dict-toggle-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

.dict-search-box {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    animation: slideIn 0.2s ease;
}

.dict-search-box.hidden {
    display: none;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.dict-search-box input {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.35rem 0.6rem;
    color: var(--text-primary);
    font-size: 0.8rem;
    width: 120px;
}

.dict-search-box input:focus {
    outline: none;
    border-color: var(--accent);
}

.dict-search-box button {
    background: var(--accent);
    border: none;
    border-radius: 4px;
    padding: 0.35rem 0.6rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dict-search-box button:hover {
    background: #6366f1;
}

/* ============ LIVE EXECUTION PIPELINE ============ */

.execution-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(26, 29, 41, 0.95);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.execution-overlay.hidden {
    display: none;
}

.execution-overlay.fade-out {
    animation: fadeOut 0.5s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

.execution-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    min-width: 450px;
    max-width: 550px;
    max-height: 70vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
}

.execution-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.agent-thinking {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.thinking-icon {
    font-size: 1.5rem;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.execution-strategy {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    font-style: italic;
}

/* Pipeline Steps */
.pipeline-steps {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 45vh;
    overflow-y: auto;
    padding-right: 4px;
}

.pipeline-steps::-webkit-scrollbar {
    width: 5px;
}

.pipeline-steps::-webkit-scrollbar-track {
    background: transparent;
}

.pipeline-steps::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.3);
    border-radius: 10px;
}

.pipeline-steps::-webkit-scrollbar-thumb:hover {
    background: rgba(99, 102, 241, 0.5);
}

.pipeline-step {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: var(--bg-elevated);
    border-radius: 8px;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.pipeline-step.pending {
    opacity: 0.5;
}

.pipeline-step.active {
    border-color: var(--accent);
    background: rgba(79, 140, 255, 0.1);
    animation: stepPulse 1s ease-in-out infinite;
}

@keyframes stepPulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(79, 140, 255, 0);
    }

    50% {
        box-shadow: 0 0 0 4px rgba(79, 140, 255, 0.2);
    }
}

.pipeline-step.completed {
    opacity: 1;
    border-color: var(--success);
    background: rgba(34, 197, 94, 0.1);
}

.pipeline-step.failed {
    border-color: var(--error);
    background: rgba(239, 68, 68, 0.1);
    animation: stepFail 0.3s ease;
}

@keyframes stepFail {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

.pipeline-step.skipped {
    opacity: 0.4;
    text-decoration: line-through;
}

.step-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    border-radius: 50%;
    background: var(--bg-dark);
    flex-shrink: 0;
}

.step-icon.pending {
    color: var(--text-muted);
}

.step-icon.active {
    color: var(--accent);
    animation: spin 1s linear infinite;
}

.step-icon.completed {
    color: var(--success);
    background: rgba(34, 197, 94, 0.2);
}

.step-icon.failed {
    color: var(--error);
    background: rgba(239, 68, 68, 0.2);
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.step-info {
    flex: 1;
}

.step-name {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.step-status {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.step-time {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: monospace;
}

/* Execution Summary */
.execution-summary {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding: 1rem;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid var(--success);
    border-radius: 8px;
    animation: slideUp 0.3s ease;
}

.execution-summary.hidden {
    display: none;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.summary-icon {
    font-size: 1.25rem;
}

#summaryText {
    flex: 1;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.view-trace-btn {
    background: transparent;
    border: 1px solid var(--success);
    color: var(--success);
    padding: 0.35rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-trace-btn:hover {
    background: var(--success);
    color: white;
}

/* Progress Line */
.step-progress-line {
    position: absolute;
    left: 14px;
    top: 28px;
    bottom: -12px;
    width: 2px;
    background: var(--border);
}

.step-progress-line.completed {
    background: var(--success);
}

/* ============ COLLAPSED SUMMARY CHIP ============ */

.summary-chip {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-card);
    border: 1px solid var(--success);
    border-radius: 50px;
    padding: 0.6rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: var(--shadow-lg);
    z-index: 100;
    animation: chipSlideUp 0.4s ease;
}

.summary-chip.hidden {
    display: none;
}

.summary-chip.has-errors {
    border-color: var(--warning);
}

@keyframes chipSlideUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.chip-icon {
    font-size: 1rem;
}

.chip-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.chip-expand-btn,
.chip-dismiss-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border-radius: 4px;
}

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

.chip-dismiss-btn:hover {
    background: var(--error);
    color: white;
}

/* ============ DYNAMIC PANEL GRID ============ */

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.results-grid .panel {
    animation: panelEnter 0.5s ease backwards;
}

.results-grid .panel:nth-child(1) {
    animation-delay: 0.1s;
}

.results-grid .panel:nth-child(2) {
    animation-delay: 0.2s;
}

.results-grid .panel:nth-child(3) {
    animation-delay: 0.3s;
}

.results-grid .panel:nth-child(4) {
    animation-delay: 0.4s;
}

@keyframes panelEnter {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Panel exit animation */
.panel.panel-exit {
    animation: panelExit 0.3s ease forwards;
}

@keyframes panelExit {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.9);
    }
}

/* Empty state when no panels */
.results-grid:empty::after {
    content: "Enable features to see results";
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    padding: 2rem;
    grid-column: 1 / -1;
}

/* Panel hover lift effect */
.panel {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.panel:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

/* ===== DYNAMIC PANEL VISIBILITY ===== */

/* Hidden panel state */
.panel.panel-hidden {
    display: none !important;
}

/* Panel entering animation */
.panel.panel-entering {
    animation: panelEnter 0.5s ease-out forwards;
}

/* Panel exiting animation */
.panel.panel-exiting {
    animation: panelExit 0.3s ease-in forwards;
    pointer-events: none;
}

/* Empty state when all panels hidden */
.empty-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.empty-state.visible {
    opacity: 1;
}

.empty-state .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1rem;
    margin: 0;
}

/* ===== EXPORT CONTROLS ===== */
.export-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: 1rem;
    padding-left: 1rem;
    border-left: 1px solid var(--border);
}

.export-format-select {
    background: var(--bg-dark);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.export-format-select:hover {
    border-color: var(--accent);
    background: rgba(99, 102, 241, 0.1);
}

.export-format-select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.download-btn {
    background: linear-gradient(135deg, var(--accent), #818cf8);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.download-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.download-btn:active {
    transform: translateY(0);
}

.download-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ===== INTELLIGENCE PACKAGE BUILDER ===== */

/* Package Builder Button */
.package-builder-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: linear-gradient(180deg, #34C759, #28A745);
    /* Spline Success Green */
    color: white;
    border: none;
    border-radius: 100px;
    padding: 0.5rem 1.4rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    margin-left: 1rem;
    box-shadow: 0 4px 10px rgba(52, 199, 89, 0.3), inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

.package-builder-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 15px rgba(52, 199, 89, 0.4), inset 0 1px 2px rgba(255, 255, 255, 0.4);
}

.package-builder-btn:active {
    transform: scale(0.98);
}

/* Package Modal - Glass Bento */
.package-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.package-modal.hidden {
    opacity: 0;
    pointer-events: none;
}

.package-modal-content {
    background: var(--bg-card);
    /* Spline Glass */
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    /* Bento Radius */
    padding: 2.5rem;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5), inset 0 1px 2px rgba(255, 255, 255, 0.08);
    animation: modalSlideIn 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.package-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.package-header h2 {
    font-size: 1.3rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent), #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.package-header .close-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.2s;
}

.package-header .close-btn:hover {
    color: var(--text-primary);
}

/* Quality Badge */
.quality-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-weight: 600;
    font-size: 0.9rem;
}

.quality-badge.quality-full {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #22c55e;
}

.quality-badge.quality-partial {
    background: rgba(234, 179, 8, 0.15);
    border: 1px solid rgba(234, 179, 8, 0.3);
    color: #eab308;
}

.quality-badge.quality-raw {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.quality-badge .badge-icon {
    font-size: 1.1rem;
}

/* Package Preview */
.package-preview {
    margin-bottom: 1.5rem;
}

.package-preview h3 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contents-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.content-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.8rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.content-item.included {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.content-item.excluded {
    opacity: 0.4;
    text-decoration: line-through;
}

.content-item .item-check {
    font-size: 0.9rem;
}

/* Intelligence Summary Box */
.intel-summary-box {
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 0.4rem 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.summary-row:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.summary-row span:last-child {
    font-weight: 600;
    color: var(--text-primary);
}

/* Format Recommendation */
.format-recommendation {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: rgba(234, 179, 8, 0.1);
    border: 1px solid rgba(234, 179, 8, 0.2);
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.format-recommendation .rec-icon {
    font-size: 1rem;
}

.format-recommendation strong {
    color: #eab308;
}

/* Export Strategy */
.export-strategy {
    text-align: center;
    margin-bottom: 1.5rem;
}

.export-strategy p {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Export Buttons Grid */
.export-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.export-buttons.five-col {
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
}

.export-buttons.five-col .export-btn {
    padding: 0.7rem 0.5rem;
    font-size: 0.7rem;
}

.export-buttons.five-col .btn-icon {
    font-size: 1.1rem;
}

.export-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.8rem;
    font-weight: 500;
}

.export-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.export-btn .btn-icon {
    font-size: 1.3rem;
}

.export-btn.export-json:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: rgba(99, 102, 241, 0.4);
}

.export-btn.export-md:hover {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.4);
}

.export-btn.export-csv:hover {
    background: rgba(234, 179, 8, 0.15);
    border-color: rgba(234, 179, 8, 0.4);
}

.export-btn.export-docx:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.4);
}

.export-btn.export-pdf:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.4);
}

/* Export All Button */
.export-all-btn {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(180deg, #007AFF, #005FB3);
    border: none;
    border-radius: 100px;
    color: white;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    margin-bottom: 0.75rem;
    box-shadow: 0 4px 10px rgba(0, 122, 255, 0.3), inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

.export-all-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.4), inset 0 1px 2px rgba(255, 255, 255, 0.4);
}

.export-all-btn:active {
    transform: scale(0.98);
}

/* Copy Button */
.copy-btn {
    width: 100%;
    padding: 0.85rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    transform: scale(1.02);
}

.copy-btn:active {
    transform: scale(0.98);
}

.copy-btn.copied {
    background: rgba(34, 197, 94, 0.15);
    border-color: rgba(34, 197, 94, 0.4);
    color: #22c55e;
}

/* ===== EXECUTION QUALITY ===== */
.exec-quality-box {
    background: rgba(147, 51, 234, 0.08);
    border: 1px solid rgba(147, 51, 234, 0.2);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.exec-quality-box h4 {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.exec-stats {
    display: flex;
    justify-content: space-around;
    margin-bottom: 0.75rem;
}

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

.exec-stat .stat-value {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
}

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

.exec-confidence {
    text-align: center;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.confidence-badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.confidence-badge.high {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.confidence-badge.medium {
    background: rgba(234, 179, 8, 0.15);
    color: #eab308;
}

.confidence-badge.low {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}