/* =========================================
   AI Interview Assistant
   Main Application Styles
========================================= */

:root {

    --bg-primary: #050816;
    --bg-secondary: #0b1220;
    --bg-card: rgba(255, 255, 255, 0.04);

    --text-primary: #ffffff;
    --text-secondary: #94a3b8;

    --border-primary: rgba(255,255,255,0.08);

    --cyan: #22d3ee;
    --green: #10b981;
    --red: #ef4444;
    --yellow: #f59e0b;

    --shadow-glow: 0 0 35px rgba(34, 211, 238, 0.25);

    --radius-xl: 24px;
    --radius-lg: 18px;

    --transition: all 0.3s ease;

}

/* =========================================
   RESET
========================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
}

/* =========================================
   SCROLLBAR
========================================= */

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #020617;
}

::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.12);
    border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.22);
}

/* =========================================
   GLASS EFFECT
========================================= */

.glass-card {

    background: rgba(255,255,255,0.04);

    backdrop-filter: blur(18px);

    -webkit-backdrop-filter: blur(18px);

    border: 1px solid rgba(255,255,255,0.06);

    box-shadow: 0 10px 40px rgba(0,0,0,0.35);

}

.glass-heavy {

    background: rgba(2,6,23,0.72);

    backdrop-filter: blur(30px);

    -webkit-backdrop-filter: blur(30px);

}

/* =========================================
   BUTTONS
========================================= */

.btn-primary {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 10px;

    background: linear-gradient(135deg, #06b6d4, #3b82f6);

    color: white;

    font-weight: 700;

    border-radius: 18px;

    padding: 14px 22px;

    border: none;

    outline: none;

    cursor: pointer;

    transition: var(--transition);

    box-shadow: var(--shadow-glow);

}

.btn-primary:hover {

    transform: translateY(-2px) scale(1.02);

    opacity: 0.96;

}

.btn-secondary {

    background: rgba(255,255,255,0.06);

    border: 1px solid rgba(255,255,255,0.08);

    color: white;

    padding: 14px 20px;

    border-radius: 18px;

    transition: var(--transition);

    cursor: pointer;

}

.btn-secondary:hover {

    background: rgba(255,255,255,0.1);

}

.btn-danger {

    background: rgba(239,68,68,0.15);

    border: 1px solid rgba(239,68,68,0.35);

    color: #fecaca;

    padding: 14px 20px;

    border-radius: 18px;

    transition: var(--transition);

    cursor: pointer;

}

.btn-danger:hover {

    background: rgba(239,68,68,0.25);

}

/* =========================================
   FLOATING MIC
========================================= */

#floatingMicButton {

    border: 4px solid rgba(255,255,255,0.08);

    transition: 0.3s ease;

}

#floatingMicButton.active {

    background: #10b981 !important;

    box-shadow: 0 0 40px rgba(16,185,129,0.5);

    transform: scale(1.08);

}

#floatingMicButton.listening::before {

    content: '';

    position: absolute;

    width: 100%;

    height: 100%;

    border-radius: 999px;

    border: 2px solid rgba(34,211,238,0.45);

    animation: micPulse 2s infinite;

}

@keyframes micPulse {

    0% {
        transform: scale(1);
        opacity: 1;
    }

    100% {
        transform: scale(1.8);
        opacity: 0;
    }

}

/* =========================================
   ANSWER STREAM UI
========================================= */

.answer-stream-container {

    width: 100%;

    display: flex;

    flex-direction: column;

    gap: 16px;

}

.answer-card {

    position: relative;

    overflow: hidden;

    border-radius: 22px;

    padding: 20px;

    background: rgba(255,255,255,0.04);

    border: 1px solid rgba(255,255,255,0.08);

    backdrop-filter: blur(20px);

    transition: 0.25s ease;

}

.answer-card:hover {

    transform: translateY(-2px);

    border-color: rgba(34,211,238,0.28);

}

.answer-card::before {

    content: '';

    position: absolute;

    inset: 0;

    background: linear-gradient(
        90deg,
        transparent,
        rgba(255,255,255,0.03),
        transparent
    );

    transform: translateX(-100%);

    animation: shine 4s infinite;

}

@keyframes shine {

    100% {
        transform: translateX(100%);
    }

}

.answer-label {

    font-size: 11px;

    letter-spacing: 2px;

    text-transform: uppercase;

    color: #22d3ee;

    margin-bottom: 10px;

    font-weight: 700;

}

.answer-text {

    font-size: 16px;

    line-height: 1.8;

    color: #f8fafc;

    font-weight: 500;

}

.answer-meta {

    display: flex;

    align-items: center;

    justify-content: space-between;

    margin-top: 16px;

    font-size: 12px;

    color: #94a3b8;

}

/* =========================================
   LIVE STATUS
========================================= */

.live-indicator {

    display: inline-flex;

    align-items: center;

    gap: 10px;

    font-size: 13px;

    font-weight: 600;

    color: #86efac;

}

.live-dot {

    width: 10px;

    height: 10px;

    border-radius: 999px;

    background: #10b981;

    box-shadow: 0 0 12px rgba(16,185,129,0.8);

    animation: liveBlink 1.2s infinite;

}

@keyframes liveBlink {

    0%, 100% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

}

/* =========================================
   TRANSCRIPT AREA
========================================= */

.transcript-box {

    min-height: 140px;

    max-height: 300px;

    overflow-y: auto;

    border-radius: 24px;

    background: rgba(255,255,255,0.03);

    border: 1px solid rgba(255,255,255,0.06);

    padding: 20px;

    color: white;

    line-height: 1.7;

}

.transcript-line {

    margin-bottom: 12px;

    color: #cbd5e1;

}

.transcript-line.question {

    color: #ffffff;

}

.transcript-line.filtered {

    opacity: 0.45;

    text-decoration: line-through;

}

/* =========================================
   INTERVIEW MODES
========================================= */

.mode-badge {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 8px;

    padding: 10px 14px;

    border-radius: 999px;

    background: rgba(255,255,255,0.05);

    border: 1px solid rgba(255,255,255,0.08);

    font-size: 13px;

    font-weight: 700;

    transition: var(--transition);

    cursor: pointer;

}

.mode-badge.active {

    background: rgba(34,211,238,0.12);

    border-color: rgba(34,211,238,0.4);

    color: #67e8f9;

    box-shadow: 0 0 20px rgba(34,211,238,0.2);

}

/* =========================================
   SETTINGS PANEL
========================================= */

.settings-group {

    margin-bottom: 28px;

}

.settings-label {

    display: block;

    margin-bottom: 12px;

    color: #f1f5f9;

    font-size: 14px;

    font-weight: 700;

}

.settings-input {

    width: 100%;

    height: 54px;

    border-radius: 18px;

    background: rgba(255,255,255,0.04);

    border: 1px solid rgba(255,255,255,0.08);

    padding: 0 18px;

    color: white;

    outline: none;

    transition: var(--transition);

}

.settings-input:focus {

    border-color: rgba(34,211,238,0.45);

    box-shadow: 0 0 0 4px rgba(34,211,238,0.08);

}

/* =========================================
   SWITCH TOGGLE
========================================= */

.switch {

    position: relative;

    width: 58px;

    height: 30px;

    display: inline-block;

}

.switch input {

    opacity: 0;

    width: 0;

    height: 0;

}

.slider {

    position: absolute;

    inset: 0;

    cursor: pointer;

    background: rgba(255,255,255,0.08);

    border-radius: 999px;

    transition: .3s;

}

.slider::before {

    content: '';

    position: absolute;

    width: 22px;

    height: 22px;

    left: 4px;

    top: 4px;

    border-radius: 999px;

    background: white;

    transition: .3s;

}

.switch input:checked + .slider {

    background: #06b6d4;

}

.switch input:checked + .slider::before {

    transform: translateX(28px);

}

/* =========================================
   STEALTH HEADER
========================================= */

.stealth-topbar {

    position: sticky;

    top: 0;

    z-index: 999;

    backdrop-filter: blur(24px);

    background: rgba(5,8,22,0.75);

    border-bottom: 1px solid rgba(255,255,255,0.06);

}

/* =========================================
   LOADER
========================================= */

.loader-ring {

    width: 42px;

    height: 42px;

    border: 4px solid rgba(255,255,255,0.08);

    border-top-color: #22d3ee;

    border-radius: 999px;

    animation: spin 1s linear infinite;

}

@keyframes spin {

    to {
        transform: rotate(360deg);
    }

}

/* =========================================
   MOBILE OPTIMIZATION
========================================= */

@media (max-width: 768px) {

    .answer-text {

        font-size: 15px;

        line-height: 1.7;

    }

    .answer-card {

        padding: 16px;

        border-radius: 18px;

    }

    .transcript-box {

        min-height: 120px;

        padding: 16px;

    }

    #floatingMicButton {

        width: 72px !important;

        height: 72px !important;

        bottom: 22px !important;

        right: 18px !important;

    }

}

/* =========================================
   UTILITIES
========================================= */

.hidden-soft {
    opacity: 0;
    pointer-events: none;
}

.fade-in {

    animation: fadeIn 0.35s ease forwards;

}

@keyframes fadeIn {

    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0px);
    }

}

.text-gradient {

    background: linear-gradient(90deg, #67e8f9, #60a5fa);

    -webkit-background-clip: text;

    -webkit-text-fill-color: transparent;

}

.blur-bg {

    backdrop-filter: blur(20px);

    -webkit-backdrop-filter: blur(20px);

}

.border-soft {

    border: 1px solid rgba(255,255,255,0.06);

}

.shadow-soft {

    box-shadow: 0 10px 30px rgba(0,0,0,0.35);

}