/* ============================
   Media → MP3 · Neon Studio
   ============================ */

:root {
    /* Surfaces */
    --ink: #030307;
    --surface: #0a0a10;
    --panel: rgba(14, 14, 22, 0.72);
    --panel-solid: #101018;
    --panel-hover: rgba(22, 22, 34, 0.9);

    /* Borders */
    --line: rgba(255, 255, 255, 0.07);
    --line-strong: rgba(255, 255, 255, 0.12);
    --line-glow: rgba(168, 85, 247, 0.35);

    /* Text */
    --text: #f4f4f7;
    --text-dim: #9b9bb0;
    --text-mute: #5c5c72;

    /* Accents — violet → cyan spectrum */
    --violet: #a855f7;
    --magenta: #e879f9;
    --cyan: #22d3ee;
    --accent: #a855f7;
    --accent-2: #22d3ee;
    --gradient: linear-gradient(120deg, #a855f7 0%, #7c3aed 40%, #22d3ee 100%);
    --gradient-hot: linear-gradient(120deg, #e879f9 0%, #a855f7 50%, #22d3ee 100%);
    --glow-violet: rgba(168, 85, 247, 0.45);
    --glow-cyan: rgba(34, 211, 238, 0.35);

    /* Status */
    --ok: #4ade80;
    --ok-dim: rgba(74, 222, 128, 0.15);
    --danger: #fb7185;
    --danger-dim: rgba(251, 113, 133, 0.12);

    /* Type */
    --font-display: "Syne", system-ui, sans-serif;
    --font-body: "DM Sans", system-ui, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, monospace;

    /* Shape */
    --r-sm: 6px;
    --r-md: 12px;
    --r-lg: 18px;
    --r-xl: 24px;

    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --fast: 0.15s var(--ease);
    --smooth: 0.3s var(--ease);

    /* Legacy aliases (used by app.js inline styles) */
    --text-primary: var(--text);
    --text-secondary: var(--text-dim);
    --text-muted: var(--text-mute);
    --accent-color: var(--violet);
    --danger-color: var(--danger);
    --accent-gradient: var(--gradient);
    --success-color: var(--ok);
}

/* ---------- Reset ---------- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    color-scheme: dark;
}

body {
    font-family: var(--font-body);
    background: var(--ink);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* ---------- Ambient ---------- */
.bg-scene {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    opacity: 0.85;
}

.bg-grid {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, black 20%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, black 20%, transparent 75%);
}

.bg-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 0;
    pointer-events: none;
    opacity: 0.7;
}

.bg-glow-a {
    top: -12vh;
    left: 10vw;
    width: 42vw;
    height: 42vw;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.22) 0%, transparent 70%);
    animation: driftA 18s ease-in-out infinite alternate;
}

.bg-glow-b {
    bottom: -8vh;
    right: -5vw;
    width: 48vw;
    height: 48vw;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.14) 0%, transparent 70%);
    animation: driftB 22s ease-in-out infinite alternate;
}

.bg-glow-c {
    top: 40vh;
    left: -10vw;
    width: 30vw;
    height: 30vw;
    background: radial-gradient(circle, rgba(232, 121, 249, 0.08) 0%, transparent 70%);
}

@keyframes driftA {
    from { transform: translate(0, 0); }
    to { transform: translate(4vw, 3vh); }
}

@keyframes driftB {
    from { transform: translate(0, 0); }
    to { transform: translate(-3vw, -2vh); }
}

/* ---------- Layout ---------- */
.app-container {
    position: relative;
    z-index: 1;
    max-width: 720px;
    margin: 0 auto;
    padding: 48px 22px 64px;
}

/* ---------- Header ---------- */
.app-header {
    margin-bottom: 36px;
    animation: rise 0.7s var(--ease) both;
}

.brand-row {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 16px;
}

.logo-mark {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 3px;
    width: 56px;
    height: 56px;
    padding: 12px 10px 10px;
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(168, 85, 247, 0.25), rgba(34, 211, 238, 0.08));
    border: 1px solid rgba(168, 85, 247, 0.35);
    box-shadow:
        0 0 0 1px rgba(0, 0, 0, 0.4) inset,
        0 12px 32px var(--glow-violet);
    flex-shrink: 0;
}

.eq-bar {
    display: block;
    width: 4px;
    border-radius: 2px;
    background: var(--gradient-hot);
    transform-origin: bottom;
    animation: eqPulse 1.1s ease-in-out infinite;
}

.eq-bar:nth-child(1) { height: 28%; animation-delay: 0s; }
.eq-bar:nth-child(2) { height: 55%; animation-delay: 0.12s; }
.eq-bar:nth-child(3) { height: 90%; animation-delay: 0.24s; }
.eq-bar:nth-child(4) { height: 48%; animation-delay: 0.36s; }
.eq-bar:nth-child(5) { height: 68%; animation-delay: 0.18s; }

@keyframes eqPulse {
    0%, 100% { transform: scaleY(0.45); opacity: 0.7; }
    50% { transform: scaleY(1); opacity: 1; }
}

.brand-text {
    min-width: 0;
}

.eyebrow {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    color: var(--cyan);
    margin-bottom: 6px;
    text-transform: uppercase;
}

.brand-text h1 {
    font-family: var(--font-display);
    font-size: clamp(1.85rem, 5vw, 2.55rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.05;
    color: var(--text);
}

.brand-text h1 .arrow {
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin: 0 0.06em;
}

.subtitle {
    font-size: 0.98rem;
    color: var(--text-dim);
    max-width: 36em;
    margin-bottom: 18px;
}

.feature-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pill {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: var(--text-dim);
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.03);
}

/* ---------- Glass panel ---------- */
.glass-panel {
    background: var(--panel);
    backdrop-filter: blur(28px) saturate(160%);
    -webkit-backdrop-filter: blur(28px) saturate(160%);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow:
        0 24px 48px rgba(0, 0, 0, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

/* ---------- Drop zone ---------- */
.drop-zone {
    position: relative;
    border-radius: var(--r-xl);
    padding: 52px 28px 44px;
    text-align: center;
    cursor: pointer;
    overflow: hidden;
    isolation: isolate;
    background:
        linear-gradient(180deg, rgba(20, 16, 32, 0.55) 0%, rgba(8, 8, 14, 0.85) 100%);
    border: 1px solid var(--line-strong);
    transition: border-color var(--smooth), box-shadow var(--smooth), transform var(--smooth);
    animation: rise 0.8s var(--ease) 0.05s both;
}

.drop-zone-ring {
    position: absolute;
    inset: 10px;
    border-radius: calc(var(--r-xl) - 6px);
    border: 1.5px dashed rgba(168, 85, 247, 0.25);
    pointer-events: none;
    transition: border-color var(--smooth), opacity var(--smooth);
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: rgba(168, 85, 247, 0.55);
    box-shadow:
        0 0 0 1px rgba(168, 85, 247, 0.2),
        0 0 48px rgba(168, 85, 247, 0.18),
        0 20px 40px rgba(0, 0, 0, 0.4);
    transform: translateY(-2px);
}

.drop-zone:hover .drop-zone-ring,
.drop-zone.drag-over .drop-zone-ring {
    border-color: rgba(34, 211, 238, 0.45);
    border-style: solid;
}

.drop-zone-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.drop-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dim);
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--line);
    transition: all var(--smooth);
}

.drop-zone:hover .drop-icon,
.drop-zone.drag-over .drop-icon {
    color: #fff;
    background: var(--gradient);
    border-color: transparent;
    box-shadow: 0 12px 28px var(--glow-violet);
    transform: translateY(-3px) scale(1.04);
}

.drop-text {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 6px;
}

.drop-subtext {
    font-size: 0.88rem;
    color: var(--text-mute);
    margin-bottom: 22px;
}

/* Waveform decoration */
.wave-deco {
    position: absolute;
    left: 50%;
    bottom: 14px;
    transform: translateX(-50%);
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 28px;
    opacity: 0.35;
    z-index: 1;
    pointer-events: none;
    transition: opacity var(--smooth);
}

.drop-zone:hover .wave-deco,
.drop-zone.drag-over .wave-deco {
    opacity: 0.75;
}

.wave-deco span {
    width: 3px;
    border-radius: 2px;
    background: var(--gradient);
    animation: wave 1.4s ease-in-out infinite;
}

.wave-deco span:nth-child(1)  { height: 30%; animation-delay: 0.00s; }
.wave-deco span:nth-child(2)  { height: 55%; animation-delay: 0.08s; }
.wave-deco span:nth-child(3)  { height: 80%; animation-delay: 0.16s; }
.wave-deco span:nth-child(4)  { height: 45%; animation-delay: 0.24s; }
.wave-deco span:nth-child(5)  { height: 95%; animation-delay: 0.32s; }
.wave-deco span:nth-child(6)  { height: 60%; animation-delay: 0.40s; }
.wave-deco span:nth-child(7)  { height: 35%; animation-delay: 0.48s; }
.wave-deco span:nth-child(8)  { height: 70%; animation-delay: 0.56s; }
.wave-deco span:nth-child(9)  { height: 50%; animation-delay: 0.64s; }
.wave-deco span:nth-child(10) { height: 88%; animation-delay: 0.72s; }
.wave-deco span:nth-child(11) { height: 40%; animation-delay: 0.80s; }
.wave-deco span:nth-child(12) { height: 65%; animation-delay: 0.88s; }
.wave-deco span:nth-child(13) { height: 75%; animation-delay: 0.96s; }
.wave-deco span:nth-child(14) { height: 42%; animation-delay: 1.04s; }
.wave-deco span:nth-child(15) { height: 58%; animation-delay: 1.12s; }
.wave-deco span:nth-child(16) { height: 32%; animation-delay: 1.20s; }

@keyframes wave {
    0%, 100% { transform: scaleY(0.4); }
    50% { transform: scaleY(1); }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    font-family: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--fast);
    outline: none;
    text-decoration: none;
}

.btn:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
}

.btn-select {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    padding: 12px 20px 12px 22px;
    border-radius: 999px;
    font-size: 0.92rem;
    border: 1px solid var(--line-strong);
    gap: 12px;
}

.btn-select:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.22);
    transform: translateY(-1px);
}

.btn-kbd {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--text-mute);
    padding: 3px 7px;
    border-radius: 5px;
    border: 1px solid var(--line);
    background: rgba(0, 0, 0, 0.35);
}

.btn-ghost {
    background: transparent;
    color: var(--text-dim);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 500;
}

.btn-ghost:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
}

.btn-sm {
    font-size: 0.78rem;
    padding: 6px 10px;
}

.btn-danger:hover {
    color: var(--danger);
    background: var(--danger-dim);
}

.btn-cancel {
    background: var(--danger-dim);
    color: var(--danger);
    border: 1px solid rgba(251, 113, 133, 0.25);
    padding: 10px 22px;
    border-radius: 999px;
    font-size: 0.9rem;
}

.btn-cancel:hover {
    background: rgba(251, 113, 133, 0.2);
    border-color: rgba(251, 113, 133, 0.45);
    box-shadow: 0 0 20px rgba(251, 113, 133, 0.15);
}

.btn-convert {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: var(--gradient);
    color: #fff;
    padding: 18px 40px;
    font-family: var(--font-display);
    font-size: 1.08rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    border-radius: var(--r-md);
    box-shadow:
        0 14px 36px var(--glow-violet),
        inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.btn-convert-glow {
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.22) 50%, transparent 70%);
    transform: translateX(-100%);
    animation: sheen 2.8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes sheen {
    0%, 55% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.btn-convert:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
    box-shadow:
        0 18px 44px var(--glow-violet),
        0 0 40px rgba(34, 211, 238, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.btn-convert:active {
    transform: translateY(1px);
}

.btn-convert:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
    filter: grayscale(0.4);
    box-shadow: none;
}

.btn-convert:disabled .btn-convert-glow {
    animation: none;
}

.btn-download {
    background: #fff;
    color: var(--ink);
    padding: 14px 28px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 999px;
    min-width: 220px;
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.08);
}

.btn-download:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 14px 32px rgba(255, 255, 255, 0.14);
    background: #f0f0f5;
}

/* ---------- Tooltip ---------- */
.info-tooltip {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--text-mute);
    cursor: help;
    border: 1px solid transparent;
    transition: color var(--fast), border-color var(--fast), background var(--fast);
}

.info-tooltip:hover {
    color: var(--cyan);
    background: rgba(34, 211, 238, 0.08);
    border-color: rgba(34, 211, 238, 0.25);
}

.tooltip-text {
    visibility: hidden;
    opacity: 0;
    width: 280px;
    background: rgba(10, 10, 16, 0.96);
    color: var(--text);
    text-align: left;
    border-radius: var(--r-md);
    padding: 16px;
    position: absolute;
    z-index: 100;
    bottom: calc(100% + 10px);
    right: -8px;
    font-size: 0.82rem;
    line-height: 1.65;
    border: 1px solid var(--line-strong);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.65);
    transition: all var(--fast);
    transform: translateY(8px);
    backdrop-filter: blur(12px);
    font-weight: 400;
    pointer-events: none;
}

.tooltip-text strong {
    color: var(--cyan);
    font-weight: 600;
}

.info-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Section index ---------- */
.section-index {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--violet);
    letter-spacing: 0.06em;
    padding: 3px 7px;
    border-radius: 5px;
    background: rgba(168, 85, 247, 0.12);
    border: 1px solid rgba(168, 85, 247, 0.25);
}

/* ---------- File list ---------- */
.file-list-container {
    margin-top: 28px;
    animation: rise 0.5s var(--ease) both;
}

.file-list-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid var(--line);
}

.file-list-header h2,
.settings-header h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--text);
}

.file-list-actions {
    display: flex;
    gap: 4px;
}

.file-list {
    padding: 12px;
    min-height: 60px;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.025);
    border-radius: var(--r-md);
    margin-bottom: 8px;
    cursor: grab;
    transition: all var(--fast);
    border: 1px solid transparent;
}

.file-item:last-child {
    margin-bottom: 0;
}

.file-item:hover {
    background: rgba(168, 85, 247, 0.06);
    border-color: rgba(168, 85, 247, 0.2);
    transform: translateX(3px);
}

.file-item.dragging {
    opacity: 0.45;
    transform: scale(0.98);
    background: rgba(168, 85, 247, 0.1);
}

.file-item.drag-over-item {
    border-color: var(--cyan);
    background: rgba(34, 211, 238, 0.06);
    box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.25);
}

.file-item-drag {
    color: var(--text-mute);
    cursor: grab;
    display: flex;
    align-items: center;
}

.file-item-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: linear-gradient(145deg, rgba(168, 85, 247, 0.25), rgba(34, 211, 238, 0.1));
    border: 1px solid rgba(168, 85, 247, 0.3);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 600;
    flex-shrink: 0;
}

.file-item-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
}

.file-item-info {
    flex: 1;
    min-width: 0;
}

.file-item-name {
    font-size: 0.92rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text);
}

.file-item-meta {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-mute);
    margin-top: 3px;
    letter-spacing: 0.01em;
}

.file-item-remove {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid transparent;
    color: var(--text-dim);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--fast);
    flex-shrink: 0;
}

.file-item-remove:hover {
    background: var(--danger-dim);
    border-color: rgba(251, 113, 133, 0.3);
    color: var(--danger);
    transform: scale(1.08);
}

.file-summary {
    padding: 14px 22px;
    border-top: 1px solid var(--line);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-dim);
    display: flex;
    justify-content: space-between;
    gap: 12px;
    background: rgba(0, 0, 0, 0.28);
    border-bottom-left-radius: var(--r-lg);
    border-bottom-right-radius: var(--r-lg);
}

/* ---------- Settings ---------- */
.settings-container {
    margin-top: 20px;
    padding: 22px;
    animation: rise 0.55s var(--ease) both;
}

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.settings-header h2 {
    margin-bottom: 0;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
}

.setting-item label {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-mute);
    margin-bottom: 8px;
}

.setting-item select,
.setting-item input {
    width: 100%;
    padding: 13px 14px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid var(--line-strong);
    border-radius: var(--r-sm);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 0.92rem;
    transition: all var(--smooth);
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.35);
}

.setting-item select:focus,
.setting-item input:focus {
    outline: none;
    border-color: var(--violet);
    background: rgba(0, 0, 0, 0.55);
    box-shadow:
        inset 0 2px 6px rgba(0, 0, 0, 0.35),
        0 0 0 3px rgba(168, 85, 247, 0.2);
}

.setting-item select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%229b9bb0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

.setting-item select option {
    background: #12121a;
    color: white;
}

/* ---------- Convert ---------- */
.convert-section {
    margin-top: 28px;
    animation: rise 0.6s var(--ease) both;
}

/* ---------- Progress ---------- */
.progress-container {
    margin-top: 22px;
    padding: 32px 28px;
    text-align: center;
    animation: rise 0.45s var(--ease) both;
    border-color: rgba(168, 85, 247, 0.25);
}

.progress-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-bottom: 22px;
}

.progress-label,
#progressText {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: var(--text-dim);
    text-transform: uppercase;
}

.progress-percent,
#progressPercent {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 100px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--line);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: var(--gradient);
    border-radius: 100px;
    transition: width 0.2s ease-out;
    position: relative;
    box-shadow: 0 0 16px var(--glow-violet);
}

.progress-fill::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
    animation: shimmer 1.1s infinite linear;
}

@keyframes shimmer {
    from { transform: translateX(-100%); }
    to { transform: translateX(100%); }
}

.progress-eq {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 4px;
    height: 24px;
    margin: 20px 0 8px;
}

.progress-eq span {
    width: 3px;
    height: 100%;
    border-radius: 2px;
    background: var(--gradient);
    animation: eqPulse 0.9s ease-in-out infinite;
}

.progress-eq span:nth-child(1) { animation-delay: 0.00s; }
.progress-eq span:nth-child(2) { animation-delay: 0.08s; }
.progress-eq span:nth-child(3) { animation-delay: 0.16s; }
.progress-eq span:nth-child(4) { animation-delay: 0.24s; }
.progress-eq span:nth-child(5) { animation-delay: 0.12s; }
.progress-eq span:nth-child(6) { animation-delay: 0.32s; }
.progress-eq span:nth-child(7) { animation-delay: 0.20s; }
.progress-eq span:nth-child(8) { animation-delay: 0.40s; }
.progress-eq span:nth-child(9) { animation-delay: 0.28s; }
.progress-eq span:nth-child(10) { animation-delay: 0.04s; }

/* ---------- Result ---------- */
.result-container {
    margin-top: 22px;
    padding: 44px 28px;
    text-align: center;
    animation: rise 0.5s var(--ease) both;
    border-color: rgba(74, 222, 128, 0.28);
    background:
        radial-gradient(ellipse 80% 50% at 50% 0%, rgba(74, 222, 128, 0.12) 0%, transparent 60%),
        var(--panel);
}

.result-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(145deg, #4ade80, #22c55e);
    color: #052e16;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow:
        0 12px 32px rgba(74, 222, 128, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
    animation: successPop 0.55s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes successPop {
    0% { transform: scale(0.4); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.result-text {
    font-family: var(--font-display);
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 8px;
}

.result-detail {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 28px;
    padding: 10px 18px;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 999px;
    display: inline-block;
    border: 1px solid var(--line);
}

.download-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    margin-bottom: 22px;
}

.result-actions {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ---------- Footer ---------- */
.app-footer {
    margin-top: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-mute);
    opacity: 0.7;
}

.app-footer .dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--violet);
    box-shadow: 0 0 8px var(--glow-violet);
}

/* ---------- Motion ---------- */
@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(18px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .bg-glow-a,
    .bg-glow-b {
        animation: none;
    }

    .bg-scene {
        display: none;
    }
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
    .app-container {
        padding: 28px 14px 48px;
    }

    .brand-row {
        gap: 14px;
    }

    .logo-mark {
        width: 48px;
        height: 48px;
        padding: 10px 8px 8px;
    }

    .drop-zone {
        padding: 40px 16px 36px;
    }

    .file-item {
        padding: 12px;
        gap: 10px;
    }

    .result-container,
    .progress-container,
    .settings-container {
        padding: 22px 14px;
    }

    .progress-percent,
    #progressPercent {
        font-size: 2.4rem;
    }

    .tooltip-text {
        width: 240px;
        right: -40px;
    }

    .btn-kbd {
        display: none;
    }
}
