/* ────────────────────────────────────────────
   Design tokens
──────────────────────────────────────────── */
:root {
    /* Default: Light Theme */
    --bg:            #FDFCFB;
    --surface:       #F5F3F1;
    --card:          #FFFFFF;
    --border:        #E5E2DE;
    --border-hover:  #D5D2CE;
    --text:          #1A1815;
    --text-muted:    #5D5450;
    --text-dim:      #8D8480;
    --accent:        #C8893C;
    --accent-soft:   rgba(200, 137, 60, 0.08);
    --accent-glow:   rgba(200, 137, 60, 0.15);
    --radius:        13px;
    --radius-pill:   100px;
    --font-display:  system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --font-body:     system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-mono:     'Courier New', Courier, monospace;

    /* Dynamic tokens */
    --bg-gradient:       rgba(200, 137, 60, 0.04);
    --card-shadow-inner: inset 0 1px 0 rgba(255,255,255,0.5);
    --card-shadow-outer: 0 4px 20px rgba(0,0,0,0.03);
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg:            #0C0B0A;
        --surface:       #141210;
        --card:          #1A1815;
        --border:        #282420;
        --border-hover:  #3A3530;
        --text:          #ECE6DC;
        --text-muted:    #7D7470;
        --text-dim:      #433F3B;
        --accent-soft:   rgba(200, 137, 60, 0.10);
        --accent-glow:   rgba(200, 137, 60, 0.22);
        --bg-gradient:       rgba(200, 137, 60, 0.06);
        --card-shadow-inner: inset 0 1px 0 rgba(255,255,255,0.02);
        --card-shadow-outer: none;
    }
}

/* ────────────────────────────────────────────
   Base
──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Subtle grain overlay */
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -10%, var(--bg-gradient) 0%, transparent 60%),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='256' height='256'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='256' height='256' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
}

/* Override Bootstrap's body margin reset inside container */
.container {
    max-width: 440px !important;
    padding: 0 20px 80px !important;
    margin: 0 auto;
}

/* ────────────────────────────────────────────
   Header
──────────────────────────────────────────── */
.header {
    text-align: center;
    padding: 52px 0 36px;
    animation: riseIn 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.business-logo {
    width: 60px;
    height: 60px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    font-size: 1.5rem;
    /* dynamic inner shadow */
    box-shadow: var(--card-shadow-inner);
}

.header h2 {
    font-family: var(--font-display) !important;
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    color: var(--text) !important;
    letter-spacing: -0.025em;
    line-height: 1.15;
    margin-bottom: 8px;
}

.header p,
.header .text-muted {
    font-size: 0.85rem !important;
    color: var(--text-muted) !important;
    font-weight: 300 !important;
    letter-spacing: 0.03em;
}

/* ────────────────────────────────────────────
   Main card
──────────────────────────────────────────── */
.card {
    background: var(--card) !important;
    border: 1px solid var(--border) !important;
    border-radius: 20px !important;
    padding: 26px 22px !important;
    margin-bottom: 16px;
    box-shadow: var(--card-shadow-inner), var(--card-shadow-outer) !important;
    backdrop-filter: none !important;
    animation: riseIn 0.55s cubic-bezier(0.22, 1, 0.36, 1) 0.08s both;
}

/* ────────────────────────────────────────────
   Section labels (shared)
──────────────────────────────────────────── */
.section-label {
    font-size: 0.72rem;
    letter-spacing: 0.09em;
    font-weight: 600;
    color: var(--text-dim);
    text-transform: uppercase;
    margin-bottom: 12px;
    display: block;
}

/* ────────────────────────────────────────────
   Language selector
──────────────────────────────────────────── */
.language-selector {
    margin-bottom: 26px;
    text-align: left;
}

.language-selector label {
    font-size: 0.62rem !important;
    letter-spacing: 0.13em !important;
    font-weight: 600 !important;
    color: var(--text-dim) !important;
    margin-bottom: 8px !important;
}

.language-selector select {
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border) !important;
    border-radius: var(--radius) !important;
    padding: 10px 36px 10px 14px !important;
    color: var(--text) !important;
    font-family: var(--font-body);
    font-size: 0.875rem;
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%237D7470' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    background-color: var(--surface);
    transition: border-color 0.18s;
}

.language-selector select:focus {
    border-color: var(--accent) !important;
}

.language-selector select option {
    background: var(--surface);
    color: var(--text);
}

/* ────────────────────────────────────────────
   Topic pills
──────────────────────────────────────────── */
.topic-pills-container {
    margin-bottom: 0;
}

.capsule-group {
    display: flex;
    flex-wrap: wrap;
    gap: 9px 10px;
    margin-bottom: 0;
    justify-content: flex-start;
}

.capsule-btn {
    font-family: var(--font-body);
    font-size: 0.925rem;
    font-weight: 500;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-pill);
    padding: 9px 17px;
    color: var(--text);
    cursor: pointer;
    transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
    letter-spacing: -0.01em;
    line-height: 1.35;
    /* stagger set in JS / below */
    opacity: 0;
    animation: fadeSlide 0.35s ease forwards;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.capsule-btn:hover {
    border-color: var(--border-hover);
    color: var(--text);
    background: var(--card);
    transform: translateY(-1px);
}

.capsule-btn.active {
    background: var(--accent-soft);
    border-color: var(--accent);
    color: var(--accent);
    font-weight: 600;
    box-shadow: 0 0 0 1px var(--accent-glow), 0 3px 10px var(--accent-soft);
}

/* Staggered appear */
.capsule-btn:nth-child(1)  { animation-delay: 0.04s; }
.capsule-btn:nth-child(2)  { animation-delay: 0.08s; }
.capsule-btn:nth-child(3)  { animation-delay: 0.12s; }
.capsule-btn:nth-child(4)  { animation-delay: 0.16s; }
.capsule-btn:nth-child(5)  { animation-delay: 0.20s; }
.capsule-btn:nth-child(6)  { animation-delay: 0.24s; }
.capsule-btn:nth-child(7)  { animation-delay: 0.28s; }
.capsule-btn:nth-child(8)  { animation-delay: 0.32s; }
.capsule-btn:nth-child(9)  { animation-delay: 0.36s; }
.capsule-btn:nth-child(10) { animation-delay: 0.40s; }
.capsule-btn:nth-child(11) { animation-delay: 0.44s; }
.capsule-btn:nth-child(12) { animation-delay: 0.48s; }
.capsule-btn:nth-child(13) { animation-delay: 0.52s; }
.capsule-btn:nth-child(14) { animation-delay: 0.56s; }
.capsule-btn:nth-child(n+15) { animation-delay: 0.60s; }

/* ────────────────────────────────────────────
   Staff section
──────────────────────────────────────────── */
details#staffSection {
    margin-top: 24px;
    border-top: 1px solid var(--border);
    padding-top: 22px;
}

details#staffSection > summary {
    font-size: 0.62rem;
    letter-spacing: 0.13em;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
    -webkit-user-select: none;
    transition: color 0.15s;
}

details#staffSection > summary:hover { color: var(--text); }
details#staffSection > summary::-webkit-details-marker { display: none; }
details#staffSection > summary::marker { display: none; }

details#staffSection > summary::after {
    content: '+';
    font-size: 1rem;
    font-weight: 300;
    font-family: var(--font-body);
    color: var(--text-dim);
    transition: transform 0.2s ease, color 0.15s;
    line-height: 1;
}

details#staffSection[open] > summary::after {
    transform: rotate(45deg);
    color: var(--text-muted);
}

/* Search box */
#staffSearch {
    display: block;
    width: 100%;
    margin-top: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 10px 14px;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 0.875rem;
    outline: none;
    transition: border-color 0.18s;
}

#staffSearch::placeholder { color: var(--text-dim); }
#staffSearch:focus { border-color: var(--border-hover); }

/* Staff list */
#staffList {
    margin-top: 6px;
    max-height: 200px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}

#staffList::-webkit-scrollbar { width: 4px; }
#staffList::-webkit-scrollbar-track { background: transparent; }
#staffList::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.staff-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 12px;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.15s;
    gap: 12px;
}

.staff-row:hover {
    background: var(--surface);
}

.staff-row:hover .staff-name {
    color: var(--text);
}

.staff-name {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
    transition: color 0.15s;
    flex: 1;
}

.staff-designation {
    font-size: 0.65rem;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--text-dim);
    white-space: nowrap;
}

.staff-row--selected {
    background: var(--accent-soft);
}

.staff-row--selected .staff-name {
    color: var(--accent);
}

.staff-row--selected .staff-designation {
    color: rgba(200, 137, 60, 0.55);
}

/* No-results message */
.staff-no-results {
    padding: 12px;
    font-size: 0.8rem;
    color: var(--text-dim);
    text-align: center;
}

/* ── Selected staff chip ── */
.staff-chip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 14px;
    background: var(--accent-soft);
    border: 1px solid rgba(200, 137, 60, 0.35);
    border-radius: var(--radius-pill);
    padding: 9px 12px 9px 16px;
    animation: fadeSlide 0.25s ease both;
}

#selectedStaffLabel {
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
}

.staff-chip-remove {
    cursor: pointer;
    color: var(--text-dim);
    font-size: 1.2rem;
    line-height: 1;
    padding: 0 2px;
    transition: color 0.15s;
    flex-shrink: 0;
}

.staff-chip-remove:hover { color: var(--text); }

.staff-hint {
    font-size: 0.7rem;
    color: var(--text-dim);
    margin-top: 7px;
    padding-left: 4px;
}

/* ────────────────────────────────────────────
   CTA button
──────────────────────────────────────────── */
.action-btn {
    background: var(--accent) !important;
    color: #0C0B0A !important;
    border: none !important;
    border-radius: var(--radius-pill) !important;
    padding: 15px !important;
    font-family: var(--font-body) !important;
    font-size: 0.88rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.05em !important;
    text-transform: uppercase !important;
    width: 100%;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, transform 0.15s !important;
    margin-top: 24px;
    box-shadow: 0 4px 20px var(--accent-glow) !important;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -70%;
    width: 55%;
    height: 200%;
    background: linear-gradient(
        60deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.45) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    animation: btnShimmerSweep 3.2s infinite ease-in-out;
    pointer-events: none;
}

.ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(135deg, #60A5FA 0%, #C084FC 55%, #F472B6 100%);
    color: #fff;
    border-radius: 100px;
    padding: 3px 9px 3px 8px;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    vertical-align: middle;
    margin: 0 3px;
    position: relative;
    top: -1px;
    box-shadow: 0 2px 12px rgba(192,132,252,0.55), inset 0 1px 0 rgba(255,255,255,0.2);
    text-transform: uppercase;
}

.action-btn:hover:not(:disabled) {
    background: #D49946 !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 8px 28px var(--accent-glow) !important;
}

.action-btn:active:not(:disabled) {
    transform: translateY(0) !important;
    box-shadow: 0 2px 10px var(--accent-glow) !important;
}

.action-btn:disabled {
    opacity: 0.4 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

/* ────────────────────────────────────────────
   AI Loading Overlay — Fluid AI Wave Ring (Siri/Halo Style)
──────────────────────────────────────────── */
#loadingOverlay {
    padding: 24px 0 16px;
    animation: riseIn 0.4s ease both;
}

.ai-loading-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 32px 24px 28px;
    text-align: center;
    box-shadow: var(--card-shadow-inner), var(--card-shadow-outer);
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;
}

.fluid-ai-ring-container {
    position: relative;
    width: 144px;
    height: 144px;
    margin: 8px auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Layer 1: Ambient Outer Halo Glow (Image 2) */
.fluid-halo-aura {
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 50%, rgba(0, 229, 255, 0.25) 0%, rgba(208, 0, 255, 0.2) 45%, rgba(245, 158, 11, 0.15) 70%, transparent 85%);
    filter: blur(10px);
    animation: haloAuraBreathe 3.2s ease-in-out infinite alternate;
    pointer-events: none;
}

@keyframes haloAuraBreathe {
    0% { transform: scale(0.92); opacity: 0.5; }
    100% { transform: scale(1.15); opacity: 0.9; }
}

/* Layer 2: Undulating Siri Fluid Wave Layers (Image 1) */
.fluid-wave-layer {
    position: absolute;
    inset: 4px;
    pointer-events: none;
    mix-blend-mode: screen;
    opacity: 0.85;
}

.fluid-wave-layer.w1 {
    border-radius: 43% 57% 65% 35% / 55% 45% 55% 45%;
    border: 2px solid #00e5ff;
    box-shadow: 0 0 15px #00e5ff, inset 0 0 10px rgba(0, 229, 255, 0.4);
    animation: fluidSpin1 6s linear infinite, fluidMorph1 4s ease-in-out infinite alternate;
}

.fluid-wave-layer.w2 {
    border-radius: 62% 38% 34% 66% / 40% 65% 35% 60%;
    border: 2px solid #d000ff;
    box-shadow: 0 0 15px #d000ff, inset 0 0 10px rgba(208, 0, 255, 0.4);
    animation: fluidSpin2 7.5s linear infinite, fluidMorph2 4.5s ease-in-out infinite alternate;
}

.fluid-wave-layer.w3 {
    border-radius: 51% 49% 42% 58% / 62% 38% 62% 38%;
    border: 2px solid #3b82f6;
    box-shadow: 0 0 15px #3b82f6, inset 0 0 10px rgba(59, 130, 246, 0.4);
    animation: fluidSpin1 9s linear infinite reverse, fluidMorph1 5s ease-in-out infinite alternate;
}

@keyframes fluidSpin1 {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fluidSpin2 {
    0% { transform: rotate(360deg); }
    100% { transform: rotate(0deg); }
}

@keyframes fluidMorph1 {
    0% { border-radius: 43% 57% 65% 35% / 55% 45% 55% 45%; }
    50% { border-radius: 65% 35% 40% 60% / 40% 60% 50% 50%; }
    100% { border-radius: 35% 65% 58% 42% / 60% 40% 65% 35%; }
}

@keyframes fluidMorph2 {
    0% { border-radius: 62% 38% 34% 66% / 40% 65% 35% 60%; }
    50% { border-radius: 40% 60% 60% 40% / 65% 35% 55% 45%; }
    100% { border-radius: 55% 45% 45% 55% / 35% 65% 40% 60%; }
}

/* Layer 3: Inner Dark Glass Core with Golden Halo Edge (Image 2) */
.fluid-circle-core {
    width: 104px;
    height: 104px;
    border-radius: 50%;
    background: var(--surface);
    border: 1.5px solid rgba(245, 158, 11, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 5;
    box-shadow: inset 0 0 16px rgba(245, 158, 11, 0.25), 0 4px 20px rgba(0, 0, 0, 0.12);
    animation: corePulse 2.8s ease-in-out infinite alternate;
}

@keyframes corePulse {
    0% { transform: scale(0.97); }
    100% { transform: scale(1.02); }
}

.fluid-loading-text {
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.01em;
    line-height: 1.2;
    transition: opacity 0.2s ease;
}

.witty-message-container {
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}

.witty-message {
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
    letter-spacing: -0.01em;
    animation: fadeSlide 0.4s ease both;
}

.ai-status-subtext {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-dim);
    margin: 0;
    letter-spacing: 0.02em;
}

/* ────────────────────────────────────────────
   Suggestion cards
──────────────────────────────────────────── */
#suggestionsContainer {
    position: relative;
    width: 100%;
}

.suggestion-card {
    position: relative;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 10px;
    transition: border-color 0.18s;
    animation: riseIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.suggestion-card:hover {
    border-color: var(--border-hover);
    transform: none;
}

.suggestion-card p {
    font-size: 0.875rem;
    line-height: 1.7;
    color: var(--text-muted) !important;
    margin-bottom: 14px;
}

.proceed-btn {
    position: relative;
    overflow: hidden;
    width: 100%;
    background: transparent;
    color: var(--accent);
    border: 1.5px solid var(--accent);
    border-radius: var(--radius-pill);
    padding: 11px 18px;
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
}

.proceed-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -70%;
    width: 55%;
    height: 200%;
    background: linear-gradient(
        60deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(200, 137, 60, 0.4) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    animation: btnShimmerSweep 3.2s infinite ease-in-out;
    pointer-events: none;
}

@keyframes btnShimmerSweep {
    0%   { left: -70%; opacity: 0; }
    15%  { opacity: 1; }
    50%  { left: 140%; opacity: 1; }
    60%  { left: 140%; opacity: 0; }
    100% { left: 140%; opacity: 0; }
}

.proceed-btn:hover:not(:disabled) {
    background: var(--accent);
    border-color: var(--accent);
    color: #0C0B0A !important;
    box-shadow: 0 4px 18px var(--accent-glow);
}

.proceed-btn:disabled {
    opacity: 0.35;
    cursor: default;
}

/* ────────────────────────────────────────────
   Toast
──────────────────────────────────────────── */
.toast-container {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) !important;
    right: auto !important;
    z-index: 1050;
    width: auto;
}

/* Override Bootstrap toast styling */
#toast.toast {
    background: var(--card) !important;
    border: 1px solid var(--border-hover) !important;
    border-radius: 12px !important;
    color: var(--text) !important;
    font-family: var(--font-body) !important;
    font-size: 0.85rem !important;
    min-width: 220px;
}

/* ────────────────────────────────────────────
   Google link
──────────────────────────────────────────── */
.google-link {
    display: none;
    text-align: center;
    margin-top: 24px;
}

.google-btn {
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    padding: 11px 22px;
    border-radius: var(--radius-pill);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: border-color 0.18s;
}

.google-btn:hover {
    border-color: var(--border-hover);
    color: var(--text);
}

/* ────────────────────────────────────────────
   Animations
──────────────────────────────────────────── */
@keyframes riseIn {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

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

/* ────────────────────────────────────────────
   Bootstrap utility replacements
   (replaces cdn.jsdelivr.net/npm/bootstrap@5.3.0)
──────────────────────────────────────────── */

/* Display */
.d-none    { display: none !important; }
.d-block   { display: block !important; }
.d-flex    { display: flex !important; }

/* Flex alignment */
.align-items-center { align-items: center !important; }

/* Text */
.text-center    { text-align: center !important; }
.text-uppercase { text-transform: uppercase !important; }
.text-muted     { color: var(--text-muted) !important; }
.fw-bold        { font-weight: 700 !important; }
.small          { font-size: 0.875em !important; }

/* Spacing */
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }
.mt-2 { margin-top: 0.5rem !important; }

/* Border */
.border-0 { border: 0 !important; }

/* Toast color utilities (used by showToast() in qr_landing.js) */
.text-white      { color: #fff !important; }
.text-bg-success { background-color: #198754 !important; color: #fff !important; }
.bg-warning      { background-color: #ffc107 !important; color: #000 !important; }
.bg-danger       { background-color: #dc3545 !important; color: #fff !important; }
.bg-success      { background-color: #198754 !important; }

/* Toast show/hide — replaces Bootstrap's JS-managed .show state */
.toast {
    display: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    min-width: 220px;
    padding: 12px 20px;
}
.toast.show {
    display: block;
    opacity: 1;
}

/* ────────────────────────────────────────────
   Service Rating Card (0-10 Slider)
──────────────────────────────────────────── */
.rating-card {
    position: relative;
    overflow: hidden;
}

.rating-emoji-container {
    width: 68px;
    height: 68px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 14px;
    box-shadow: var(--card-shadow-inner);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.rating-emoji {
    font-size: 2.2rem;
    line-height: 1;
    display: block;
    user-select: none;
    transition: transform 0.2s ease;
}

.rating-title {
    font-family: var(--font-display) !important;
    font-size: 1.45rem !important;
    font-weight: 700 !important;
    color: var(--text) !important;
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}

.rating-sub {
    font-size: 0.82rem !important;
    color: var(--text-muted) !important;
    margin: 0;
}

.rating-slider-wrapper {
    margin: 22px 0 24px;
    padding: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.rating-badge-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.rating-badge {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.15rem;
    padding: 4px 14px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.04em;
    transition: all 0.2s ease;
}

.rating-badge--low {
    background: rgba(220, 53, 69, 0.12);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.rating-badge--mid {
    background: rgba(255, 193, 7, 0.14);
    color: #d97706;
    border: 1px solid rgba(255, 193, 7, 0.35);
}

.rating-badge--high {
    background: var(--accent-soft);
    color: var(--accent);
    border: 1px solid var(--accent);
}

.rating-label-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.service-rating-slider {
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    height: 10px;
    border-radius: 5px;
    background: var(--border);
    outline: none;
    margin: 10px 0 12px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.service-rating-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25), 0 0 0 3px var(--card);
    transition: transform 0.15s ease, background-color 0.15s ease;
}

.service-rating-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.service-rating-slider::-moz-range-thumb {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25), 0 0 0 3px var(--card);
    transition: transform 0.15s ease, background-color 0.15s ease;
}

.slider-scale-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-dim);
    padding: 0 2px;
}

.rating-continue-btn {
    margin-top: 10px !important;
}

/* ────────────────────────────────────────────
   Self-Explaining Automation Navigator Guide
──────────────────────────────────────────── */
.navigator-guide {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: var(--card);
    border: 1.5px solid var(--accent);
    border-radius: 16px;
    padding: 14px 16px;
    margin-bottom: 16px;
    box-shadow: 0 4px 20px var(--accent-glow), var(--card-shadow-inner);
    animation: riseIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
    position: relative;
}

.nav-guide-icon-box {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--accent-soft);
    border: 1px solid var(--accent-glow);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
    animation: fingerFloatTap 1.4s infinite ease-in-out;
}

@keyframes fingerFloatTap {
    0%, 100% { transform: translateY(0) scale(1) rotate(0deg); }
    30%      { transform: translateY(-5px) translateX(2px) scale(1.15) rotate(-6deg); }
    60%      { transform: translateY(2px) scale(0.95) rotate(2deg); }
}

.nav-guide-content {
    flex: 1;
}

.nav-guide-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.nav-guide-step-badge {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--accent);
    background: var(--accent-soft);
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.nav-guide-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.01em;
}

.nav-guide-text {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.45;
}

/* ────────────────────────────────────────────
   Dynamic Floating Finger Assistant Guide
──────────────────────────────────────────── */
.floating-finger-guide {
    position: absolute;
    pointer-events: none;
    z-index: 100;
    transition: left 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), top 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.finger-hint-tooltip {
    position: absolute;
    top: -34px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--card);
    border: 1.5px solid var(--accent);
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    box-shadow: 0 4px 14px var(--accent-glow), 0 2px 6px rgba(0, 0, 0, 0.12);
    white-space: nowrap;
    animation: tooltipFloatBounce 1.4s ease-in-out infinite alternate;
}

@keyframes tooltipFloatBounce {
    0%   { transform: translateX(-50%) translateY(0); }
    100% { transform: translateX(-50%) translateY(-4px); }
}

/* Shake animation when user clicks continue without sliding */
.slider-shake {
    animation: sliderShake 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes sliderShake {
    10%, 90% { transform: translate3d(-2px, 0, 0); }
    20%, 80% { transform: translate3d(4px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-6px, 0, 0); }
    40%, 60% { transform: translate3d(6px, 0, 0); }
}

/* ────────────────────────────────────────────
   Hand Touch Slider Animation (with touch splash & slow speed)
──────────────────────────────────────────── */
.slider-track-container {
    position: relative;
    width: 100%;
    margin: 16px 0 18px;
}

.slider-pointer-guide {
    position: absolute;
    top: -6px;
    left: 0;
    pointer-events: none;
    z-index: 10;
    animation: slideTouchHand 4.6s cubic-bezier(0.42, 0, 0.58, 1) infinite;
}

.slider-touch-hand {
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(8px) translateX(-12px);
}

.touch-hand-svg {
    filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.18));
}

.touch-splash-rays {
    animation: splashPulse 1.2s ease-in-out infinite alternate;
    transform-origin: 16px 13px;
}

@keyframes splashPulse {
    0%   { opacity: 0.3; transform: scale(0.8); }
    50%  { opacity: 1;   transform: scale(1.2); }
    100% { opacity: 0.5; transform: scale(0.9); }
}

@keyframes slideTouchHand {
    0% {
        left: 20%;
        opacity: 0;
    }
    8% {
        left: 20%;
        opacity: 1;
    }
    75% {
        left: 90%;
        opacity: 1;
    }
    85% {
        left: 90%;
        opacity: 0;
    }
    86% {
        left: 20%;
        opacity: 0;
    }
    100% {
        left: 20%;
        opacity: 0;
    }
}

.slider-animating::-webkit-slider-thumb {
    animation: thumbPulseGlow 1.6s infinite ease-in-out !important;
}

.slider-animating::-moz-range-thumb {
    animation: thumbPulseGlow 1.6s infinite ease-in-out !important;
}

@keyframes thumbPulseGlow {
    0%, 100% { box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25), 0 0 0 3px var(--card); }
    50%      { box-shadow: 0 2px 16px var(--accent-glow), 0 0 0 6px var(--accent-soft); }
}
