/* =========================================================
   GDRIVE DOWNLOADER — RESPONSIVE APPLE LIGHT THEME WEBSITE
   + 100% IDENTICAL DARK DESKTOP APP INTERFACE
========================================================= */

/* ---------------------------------------------------------
   WEBSITE ROOT & GLOBAL RESETS
--------------------------------------------------------- */
:root {
    --bg-page: #FBFBFD;
    --bg-surface: #FFFFFF;
    --bg-subtle: #F5F5F7;

    --border-light: #E5E5EA;
    --border-medium: #D1D1D6;

    --text-primary: #1D1D1F;
    --text-secondary: #6E6E73;
    --text-tertiary: #86868B;

    --apple-blue: #0071E3;
    --apple-blue-hover: #0077ED;
    --apple-blue-active: #0062C4;
    --apple-blue-light: rgba(0, 113, 227, 0.08);

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-pill: 980px;

    --shadow-window: 0 16px 48px rgba(0, 0, 0, 0.14), 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.05);

    --font-apple: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", "Inter", sans-serif;
}

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

html {
    scroll-behavior: smooth;
    color-scheme: light;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-page);
    color: var(--text-primary);
    font-family: var(--font-apple);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    width: 100%;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------------------------------------------------------
   NAVBAR
--------------------------------------------------------- */
.nav-wrapper {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--border-light);
    height: 52px;
}

.navbar {
    max-width: 1140px;
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
    flex-shrink: 0;
}

.brand-logo {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    object-fit: contain;
}

.brand-name {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: color 0.15s ease;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

/* ---------------------------------------------------------
   BUTTONS (NO SCALE / NO TRANSLATE ON HOVER)
--------------------------------------------------------- */
.btn-apple-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: var(--apple-blue);
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    border-radius: var(--radius-pill);
    border: none;
    cursor: pointer;
    transition: background-color 0.15s ease;
    line-height: 1;
    text-align: center;
}

.btn-apple-primary:hover {
    background-color: var(--apple-blue-hover);
}

.btn-apple-primary:active {
    background-color: var(--apple-blue-active);
}

.btn-apple-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: var(--bg-surface);
    color: var(--text-primary);
    border: 1px solid var(--border-medium);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease;
    line-height: 1;
    text-align: center;
}

.btn-apple-secondary:hover {
    background-color: var(--bg-subtle);
    border-color: var(--text-secondary);
}

.hero-buttons {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
}

.nav-github-link {
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: color 0.15s ease;
}

.nav-github-link:hover {
    color: var(--text-primary);
}

.btn-sm {
    height: 30px;
    padding: 0 14px;
}

.btn-lg {
    height: 48px;
    padding: 0 24px;
    font-size: 14.5px;
    font-weight: 600;
}

/* KO-FI BUTTON (BORDER ONLY ON HOVER) */
.kofi-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    text-decoration: none;
    line-height: 0;
    transition: border-color 0.15s ease;
    cursor: pointer;
    box-sizing: border-box;
    flex-shrink: 0;
}

.kofi-btn:hover {
    border-color: var(--apple-blue);
}

.kofi-btn img {
    display: block;
    border-radius: 5px;
    max-width: 100%;
}

/* ---------------------------------------------------------
   HERO SECTION
--------------------------------------------------------- */
.hero-section {
    padding: 64px 0 44px;
    text-align: center;
}

.hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-tag {
    font-size: 12px;
    font-weight: 600;
    color: var(--apple-blue);
    background: var(--apple-blue-light);
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    margin-bottom: 18px;
}

.hero-title {
    font-size: clamp(28px, 5.5vw, 46px);
    line-height: 1.18;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    margin-bottom: 14px;
    max-width: 780px;
}

.hero-subtitle {
    font-size: clamp(14px, 2.2vw, 16.5px);
    line-height: 1.55;
    color: var(--text-secondary);
    max-width: 620px;
    margin-bottom: 26px;
}

.hero-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.hero-download-meta {
    font-size: 11.5px;
    color: var(--text-tertiary);
}

/* ---------------------------------------------------------
   PREVIEW SECTION & DESKTOP FRAME
--------------------------------------------------------- */
.preview-section {
    padding: 30px 0 70px;
}

.section-heading {
    text-align: center;
    margin-bottom: 28px;
}

.section-title {
    font-size: clamp(22px, 4vw, 28px);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.section-sub {
    font-size: 14.5px;
    color: var(--text-secondary);
}

.window-shell {
    background: #090b0e;
    border: 1px solid #20252d;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-window);
    overflow: hidden;
    position: relative;
    width: 100%;
}

.window-header {
    height: 38px;
    background: #101318;
    border-bottom: 1px solid #20252d;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
}

.window-buttons {
    display: flex;
    gap: 6px;
}

.win-btn {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.close-btn { background: #FF5F56; }
.min-btn { background: #FFBD2E; }
.max-btn { background: #27C93F; }

.window-title-text {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 500;
    color: #858e9b;
}

.win-app-icon {
    width: 14px;
    height: 14px;
}

.window-status-pill {
    font-size: 10px;
    font-weight: 600;
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.12);
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(59, 130, 246, 0.25);
}

/* ==========================================================================
   100% IDENTICAL DESKTOP APP SCOPED CSS (MATCHING Frontend/css/style.css)
========================================================================== */

.desktop-app-scope {
    position: relative;
    user-select: none;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    background: var(--background);
    color: var(--text);
    transition: background-color 0.15s ease, color 0.15s ease;
    width: 100%;
    overflow-x: hidden;
}

.desktop-app-scope[data-theme="dark"] {
    color-scheme: dark;
    --background: #090b0e;
    --surface: #101318;
    --surface-hover: #151920;
    --surface-active: #1c222b;
    --input-bg: #0b0d11;
    --input-focus: #0e1116;
    --border: #20252d;
    --border-hover: #323945;
    --text: #f4f6f8;
    --text-inverse: #090b0e;
    --muted: #858e9b;
    --subtle: #525a66;
    --accent: #3b82f6;
    --accent-rgb: 59, 130, 246;
    --accent-hover: #2563eb;
    --accent-alpha: rgba(59, 130, 246, 0.15);
    --accent-glow: rgba(59, 130, 246, 0.35);
    --danger: #ef4444;
    --danger-hover: #dc2626;
    --danger-bg: rgba(239, 68, 68, 0.12);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.12);
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.12);
    --radius: 14px;
    --radius-sm: 8px;
    --radius-md: 10px;
    --shadow-modal: 0 24px 48px -12px rgba(0, 0, 0, 0.75);
}

.desktop-app-scope[data-theme="light"] {
    color-scheme: light;
    --background: #f8fafc;
    --surface: #ffffff;
    --surface-hover: #f1f5f9;
    --surface-active: #e2e8f0;
    --input-bg: #f8fafc;
    --input-focus: #ffffff;
    --border: #e2e8f0;
    --border-hover: #cbd5e1;
    --text: #0f172a;
    --text-inverse: #ffffff;
    --muted: #64748b;
    --subtle: #94a3b8;
    --accent: #2563eb;
    --accent-rgb: 37, 99, 235;
    --accent-hover: #1d4ed8;
    --accent-alpha: rgba(37, 99, 235, 0.12);
    --accent-glow: rgba(37, 99, 235, 0.25);
    --danger: #dc2626;
    --danger-hover: #b91c1c;
    --danger-bg: rgba(220, 38, 38, 0.08);
    --warning: #d97706;
    --warning-bg: rgba(217, 119, 6, 0.08);
    --success: #059669;
    --success-bg: rgba(5, 150, 105, 0.08);
    --shadow-modal: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
}

.desktop-app-scope * {
    box-sizing: border-box;
}

.desktop-app-scope .app-container {
    width: 100%;
    max-width: 1380px;
    margin: 0 auto;
    padding: 24px 28px 40px;
}

.desktop-app-scope .app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 12px;
}

.desktop-app-scope .header-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.desktop-app-scope .app-logo {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    object-fit: contain;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.desktop-app-scope .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 11px;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.desktop-app-scope .app-title {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
}

.desktop-app-scope .header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.desktop-app-scope .kofi-btn-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    text-decoration: none;
    line-height: 0;
    transition: border-color 0.15s ease;
    cursor: pointer;
    flex-shrink: 0;
    box-sizing: border-box;
}

.desktop-app-scope .kofi-btn-link:hover {
    border-color: var(--accent);
}

.desktop-app-scope .kofi-btn-link img {
    height: 34px;
    display: block;
    border-radius: 7px;
}

.desktop-app-scope .icon-button {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 36px;
    padding: 0 13px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    flex-shrink: 0;
}

.desktop-app-scope .icon-button:hover {
    background-color: var(--surface-hover);
    border-color: var(--accent);
    color: var(--accent);
}

/* CARDS */
.desktop-app-scope .card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
    transition: background-color 0.15s ease, border-color 0.15s ease;
    width: 100%;
}

.desktop-app-scope .input-card {
    margin-bottom: 16px;
    padding: 12px 14px;
}

.desktop-app-scope .input-row {
    display: flex;
    gap: 10px;
    align-items: center;
    width: 100%;
}

.desktop-app-scope .input-with-icon {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
    min-width: 0;
}

.desktop-app-scope .input-icon {
    position: absolute;
    left: 14px;
    color: var(--subtle);
    pointer-events: none;
}

.desktop-app-scope .input-with-icon input[type="text"] {
    padding-left: 42px;
    width: 100%;
}

.desktop-app-scope input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 0 14px;
    outline: none;
    background: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text);
    font-size: 13.5px;
    transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.desktop-app-scope input[type="text"]::placeholder {
    color: var(--subtle);
}

.desktop-app-scope input[type="text"]:focus {
    background-color: var(--input-focus);
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent-alpha);
}

.desktop-app-scope button {
    height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.desktop-app-scope button:disabled {
    cursor: not-allowed;
    opacity: 0.4;
}

.desktop-app-scope #analyzeButton,
.desktop-app-scope .primary-btn {
    background: var(--accent);
    color: #ffffff;
    flex-shrink: 0;
}

.desktop-app-scope #analyzeButton:hover:not(:disabled),
.desktop-app-scope .primary-btn:hover:not(:disabled) {
    background: var(--accent-hover);
}

.desktop-app-scope .secondary {
    background: var(--surface-hover);
    color: var(--text);
    border: 1px solid var(--border);
    flex-shrink: 0;
}

.desktop-app-scope .secondary:hover:not(:disabled) {
    background: var(--surface-active);
    border-color: var(--border-hover);
}

.desktop-app-scope .danger {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--danger);
}

.desktop-app-scope .danger:hover:not(:disabled) {
    background: var(--danger-bg);
    border-color: var(--danger);
    color: var(--danger-hover);
}

.desktop-app-scope .ghost-btn {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--muted);
}

.desktop-app-scope .ghost-btn:hover:not(:disabled) {
    background: var(--surface-hover);
    color: var(--text);
    border-color: var(--border-hover);
}

.desktop-app-scope .message {
    min-height: 0;
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
}

/* DASHBOARD GRID */
.desktop-app-scope .dashboard-grid {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 16px;
    align-items: stretch;
}

.desktop-app-scope .dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.desktop-app-scope .queue-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 520px;
    margin-bottom: 0;
}

.desktop-app-scope .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.desktop-app-scope .section-label {
    color: var(--subtle);
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.desktop-app-scope h2 {
    margin: 3px 0 0;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text);
}

.desktop-app-scope .single-line-ellipsis {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 230px;
}

.desktop-app-scope .status-badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 600;
    border: 1px solid var(--border);
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-transform: capitalize;
    flex-shrink: 0;
}

.desktop-app-scope .status-badge.status-ready { color: var(--muted); }
.desktop-app-scope .status-badge.status-downloading { color: var(--accent); border-color: var(--accent); background: var(--accent-alpha); }
.desktop-app-scope .status-badge.status-completed { color: var(--success); border-color: var(--success); background: var(--success-bg); }
.desktop-app-scope .status-badge.status-paused { color: var(--warning); border-color: var(--warning); background: var(--warning-bg); }
.desktop-app-scope .status-badge.status-failed { color: var(--danger); border-color: var(--danger); background: var(--danger-bg); }

/* CIRCULAR PROGRESS */
.desktop-app-scope .current-download-body {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 4px 0 12px;
}

.desktop-app-scope .circular-progress-wrapper {
    position: relative;
    width: 108px;
    height: 108px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.desktop-app-scope .progress-ring {
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
}

.desktop-app-scope .progress-ring-circle-bg {
    stroke: var(--border);
}

.desktop-app-scope .progress-ring-circle {
    stroke: var(--accent);
    stroke-dasharray: 282.743;
    stroke-dashoffset: 282.743;
    transition: stroke-dashoffset 0.25s ease, stroke 0.15s ease;
}

.desktop-app-scope .progress-ring-content {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    pointer-events: none;
}

.desktop-app-scope .ring-percent {
    font-size: 19px;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
    line-height: 1;
}

.desktop-app-scope .ring-subtext {
    margin-top: 3px;
    font-size: 9.5px;
    font-weight: 600;
    color: var(--muted);
}

.desktop-app-scope .current-details-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.desktop-app-scope .metric-card {
    padding: 9px 12px;
    background: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.desktop-app-scope .metric-icon-group {
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.desktop-app-scope .metric-icon {
    color: var(--accent);
}

.desktop-app-scope .metric-value {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desktop-app-scope .controls {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
}

.desktop-app-scope .controls button {
    flex: 1;
    height: 34px;
    padding: 0 8px;
    font-size: 11.5px;
    min-width: 65px;
}

/* TOTAL CARD */
.desktop-app-scope .total-card {
    margin-bottom: 0;
}

.desktop-app-scope .total-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    color: var(--muted);
    font-size: 12px;
}

.desktop-app-scope .total-header-left {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}

.desktop-app-scope .total-header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.desktop-app-scope .total-eta-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10.5px;
    color: var(--accent);
    font-weight: 600;
    background: var(--accent-alpha);
    padding: 2px 7px;
    border-radius: 5px;
}

.desktop-app-scope .progress-track {
    width: 100%;
    height: 6px;
    overflow: hidden;
    background: var(--border);
    border-radius: 999px;
}

.desktop-app-scope .progress-bar {
    width: 0;
    height: 100%;
    background: var(--accent);
    border-radius: inherit;
    transition: width 0.2s ease, background-color 0.15s ease;
}

.desktop-app-scope .total-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    color: var(--muted);
    font-size: 11.5px;
}

.desktop-app-scope #totalPercent {
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
}

/* QUEUE */
.desktop-app-scope .queue-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.desktop-app-scope .queue-count {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

.desktop-app-scope .queue-list {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    overflow-y: auto;
    padding-right: 4px;
    max-height: 480px;
}

.desktop-app-scope .queue-list::-webkit-scrollbar {
    width: 6px;
}
.desktop-app-scope .queue-list::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

.desktop-app-scope .empty-queue {
    padding: 48px 16px;
    text-align: center;
    color: var(--subtle);
    font-size: 13px;
    border: 1px dashed var(--border);
    border-radius: var(--radius-md);
    margin: auto 0;
}

.desktop-app-scope .queue-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background-color: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: background-color 0.15s ease, border-color 0.15s ease;
    width: 100%;
}

.desktop-app-scope .queue-item:hover {
    background-color: var(--surface-hover);
    border-color: var(--border-hover);
}

.desktop-app-scope .queue-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.desktop-app-scope .queue-info {
    flex: 1;
    min-width: 0;
}

.desktop-app-scope .queue-name {
    overflow: hidden;
    color: var(--text);
    font-size: 12.5px;
    font-weight: 600;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.desktop-app-scope .queue-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 2px;
    overflow: hidden;
    color: var(--subtle);
    font-size: 10.5px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.desktop-app-scope .queue-eta-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    color: var(--accent);
    font-weight: 600;
}

.desktop-app-scope .queue-status-cell {
    width: 82px;
    text-align: right;
    flex-shrink: 0;
}

.desktop-app-scope .queue-item-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.desktop-app-scope .queue-icon-btn {
    width: 30px;
    height: 30px;
    padding: 0;
    border-radius: 7px;
    background-color: var(--surface);
    border: 1px solid var(--border);
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.desktop-app-scope .queue-icon-btn:hover {
    background-color: var(--surface-active);
    color: var(--text);
    border-color: var(--border-hover);
}

.desktop-app-scope .queue-icon-btn.btn-play:hover {
    background-color: var(--accent-alpha);
    color: var(--accent);
    border-color: var(--accent);
}

.desktop-app-scope .queue-icon-btn.btn-pause:hover {
    background-color: var(--warning-bg);
    color: var(--warning);
    border-color: var(--warning);
}

.desktop-app-scope .queue-icon-btn.btn-danger:hover {
    background-color: var(--danger-bg);
    color: var(--danger);
    border-color: var(--danger);
}

/* APP FOOTER */
.desktop-app-scope .app-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 14px;
    padding-top: 10px;
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--muted);
}

.desktop-app-scope .footer-left {
    display: flex;
    align-items: center;
    gap: 6px;
}

.desktop-app-scope .footer-sep {
    color: var(--subtle);
}

.desktop-app-scope .footer-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desktop-app-scope .kofi-footer-link {
    display: inline-flex;
    align-items: center;
    border-radius: 6px;
    border: 1px solid transparent;
    text-decoration: none;
    line-height: 0;
    transition: border-color 0.15s ease;
    cursor: pointer;
}

.desktop-app-scope .kofi-footer-link:hover {
    border-color: var(--accent);
}

.desktop-app-scope .kofi-footer-link img {
    display: block;
    border-radius: 5px;
}

.desktop-app-scope .footer-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
    background: transparent;
    border: 0;
    height: auto;
    padding: 0;
}

.desktop-app-scope .footer-link:hover {
    color: #e1306c;
}

/* SETTINGS MODAL */
.desktop-app-scope .modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    padding: 16px;
}

.desktop-app-scope .modal-card {
    width: min(560px, 100%);
    max-height: 92%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-modal);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.desktop-app-scope .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

.desktop-app-scope .modal-title-group h3 {
    margin: 3px 0 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--text);
}

.desktop-app-scope .close-btn {
    width: 30px;
    height: 30px;
    padding: 0;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--muted);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.desktop-app-scope .close-btn:hover {
    background-color: var(--surface-hover);
    color: var(--text);
}

.desktop-app-scope .modal-body {
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.desktop-app-scope .settings-section h4 {
    margin: 0 0 10px;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
}

.desktop-app-scope .settings-field {
    margin-bottom: 12px;
}

.desktop-app-scope .settings-field:last-child {
    margin-bottom: 0;
}

.desktop-app-scope .settings-field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.desktop-app-scope .field-hint {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    font-size: 10.5px;
}

.desktop-app-scope .field-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.desktop-app-scope .badge {
    padding: 2px 7px;
    background: var(--accent-alpha);
    color: var(--accent);
    border-radius: 5px;
    font-size: 10px;
    font-weight: 700;
}

.desktop-app-scope .theme-toggle-group {
    display: flex;
    gap: 8px;
}

.desktop-app-scope .toggle-btn {
    flex: 1;
    height: 36px;
    background-color: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.desktop-app-scope .toggle-btn.active {
    background-color: var(--surface-active);
    border-color: var(--accent);
    color: var(--text);
}

.desktop-app-scope .accent-presets {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    flex-wrap: wrap;
}

.desktop-app-scope .color-preset-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    padding: 0;
    transition: box-shadow 0.15s ease;
    flex-shrink: 0;
}

.desktop-app-scope .color-preset-btn.active {
    border-color: var(--text);
    box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent);
}

.desktop-app-scope .folder-picker-row {
    display: flex;
    gap: 8px;
}

.desktop-app-scope .folder-picker-row input {
    height: 38px;
}

.desktop-app-scope .folder-picker-row button {
    height: 38px;
    padding: 0 14px;
}

.desktop-app-scope .slider-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
}

.desktop-app-scope .slider-limit {
    font-size: 10.5px;
    color: var(--muted);
    font-weight: 600;
}

.desktop-app-scope input[type="range"] {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 5px;
    background: var(--border);
    border-radius: 999px;
    outline: none;
}

.desktop-app-scope input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: 2px solid var(--surface);
}

/* SWITCH */
.desktop-app-scope .switch-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.desktop-app-scope .switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex-shrink: 0;
}

.desktop-app-scope .switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.desktop-app-scope .slider-switch {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border);
    transition: 0.2s;
    border-radius: 22px;
}

.desktop-app-scope .slider-switch:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.2s;
    border-radius: 50%;
}

.desktop-app-scope input:checked + .slider-switch {
    background-color: var(--accent);
}

.desktop-app-scope input:checked + .slider-switch:before {
    transform: translateX(18px);
}

/* TAGS */
.desktop-app-scope .tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
    min-height: 28px;
}

.desktop-app-scope .tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    background-color: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: 7px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text);
}

.desktop-app-scope .tag-chip button {
    height: auto;
    padding: 0;
    background: transparent;
    border: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1;
    display: flex;
    align-items: center;
    transition: color 0.15s ease;
}

.desktop-app-scope .tag-chip button:hover {
    color: var(--danger);
}

.desktop-app-scope .add-tag-row {
    display: flex;
    gap: 8px;
}

.desktop-app-scope .add-tag-row input {
    height: 38px;
}

.desktop-app-scope .add-tag-row button {
    height: 38px;
    padding: 0 14px;
}

/* DEVELOPER & SUPPORT CARDS */
.desktop-app-scope .developer-card,
.desktop-app-scope .support-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    background: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    gap: 12px;
    margin-bottom: 10px;
}

.desktop-app-scope .developer-details,
.desktop-app-scope .support-details {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.desktop-app-scope .developer-icon-wrapper {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e1306c;
    flex-shrink: 0;
}

.desktop-app-scope .developer-name {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text);
}

.desktop-app-scope .developer-sub {
    font-size: 11px;
    color: var(--muted);
}

.desktop-app-scope .developer-link-btn {
    height: 34px;
    padding: 0 12px;
    font-size: 11.5px;
    text-decoration: none;
    flex-shrink: 0;
}

/* MODAL FOOTER */
.desktop-app-scope .modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    border-top: 1px solid var(--border);
    background: var(--surface);
}

.desktop-app-scope .modal-footer-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desktop-app-scope .modal-footer-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desktop-app-scope .danger-ghost-btn {
    height: 34px;
    padding: 0 10px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--danger);
    font-size: 11.5px;
    font-weight: 600;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.desktop-app-scope .danger-ghost-btn:hover {
    background: var(--danger-bg);
    border-color: var(--danger);
    color: var(--danger-hover);
}

.desktop-app-scope .save-status {
    font-size: 11px;
    color: var(--success);
    font-weight: 500;
}

/* CONFIRM MODAL */
.desktop-app-scope .confirm-modal-card {
    width: min(440px, 94%);
}

.desktop-app-scope .confirm-modal-header {
    padding: 16px 18px 14px;
}

.desktop-app-scope .confirm-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desktop-app-scope .confirm-icon-badge {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.desktop-app-scope .confirm-icon-badge.danger {
    background: var(--danger-bg);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.desktop-app-scope .danger-label {
    color: var(--danger);
}

.desktop-app-scope .confirm-modal-body {
    padding: 16px 18px 12px;
    gap: 12px;
}

.desktop-app-scope .confirm-message {
    margin: 0;
    font-size: 13px;
    line-height: 1.45;
    color: var(--text);
}

.desktop-app-scope .confirm-item-details {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.desktop-app-scope .confirm-item-icon {
    color: var(--muted);
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.desktop-app-scope .confirm-item-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
}

.desktop-app-scope .confirm-item-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desktop-app-scope .confirm-item-meta {
    font-size: 10.5px;
    color: var(--muted);
}

.desktop-app-scope .confirm-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
}

.desktop-app-scope .danger-btn {
    background: var(--danger);
    color: #ffffff;
}

.desktop-app-scope .danger-btn:hover {
    background: var(--danger-hover);
}

.desktop-app-scope .spinner {
    width: 13px;
    height: 13px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 0.6s linear infinite;
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ---------------------------------------------------------
   FEATURES & SPECS (APPLE LIGHT THEME SITE)
--------------------------------------------------------- */
.features-section {
    padding: 64px 0;
    background: #FFFFFF;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.feature-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 22px;
    transition: border-color 0.15s ease;
}

.feature-card:hover {
    border-color: var(--border-medium);
}

.feature-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--bg-subtle);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--apple-blue);
    margin-bottom: 14px;
}

.feature-title {
    font-size: 15.5px;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.feature-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.specs-section {
    padding: 64px 0;
}

.specs-panel {
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 34px;
    max-width: 680px;
    margin: 0 auto;
    box-shadow: var(--shadow-card);
}

.specs-pill {
    font-size: 11px;
    font-weight: 600;
    color: var(--apple-blue);
    letter-spacing: 0.04em;
    display: inline-block;
    margin-bottom: 6px;
}

.specs-header {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.specs-paragraph {
    font-size: 13.5px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.specs-details {
    display: flex;
    flex-direction: column;
    gap: 9px;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
    padding: 14px 0;
    margin-bottom: 22px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    font-size: 12.5px;
}

.detail-label {
    color: var(--text-tertiary);
}

.detail-val {
    font-weight: 500;
    color: var(--text-primary);
}

.support-section {
    padding: 80px 0;
    background: #FFFFFF;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.support-grid {
    display: grid;
    grid-template-columns: 1fr 480px;
    gap: 52px;
    align-items: center;
}

.support-heading {
    font-size: clamp(24px, 3.8vw, 34px);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    line-height: 1.25;
    margin-bottom: 14px;
}

.support-desc {
    font-size: 14.5px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
}

.support-widget-col {
    display: flex;
    justify-content: center;
    width: 100%;
}

.widget-card {
    width: 100%;
    max-width: 480px;
    background: transparent;
    border: none;
    box-shadow: none;
    overflow: hidden;
    padding: 0;
}

/* ---------------------------------------------------------
   FOOTER
--------------------------------------------------------- */
.site-footer {
    background: #F5F5F7;
    border-top: 1px solid var(--border-light);
    padding: 22px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-secondary);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-logo {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.footer-brand-name {
    font-weight: 600;
    color: var(--text-primary);
}

.footer-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
}

.footer-link:hover {
    color: #E1306C;
}

/* ==========================================================================
   SUPER-RESPONSIVE MEDIA QUERIES (TABLETS, MOBILES, SMALL DEVICES)
========================================================================== */

@media (max-width: 1024px) {
    .container {
        padding: 0 20px;
    }
    .desktop-app-scope .app-container {
        padding: 20px;
    }
}

@media (max-width: 960px) {
    .desktop-app-scope .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .desktop-app-scope .queue-card {
        min-height: 400px;
    }
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .support-grid {
        grid-template-columns: 1fr;
        gap: 36px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    .navbar {
        padding: 0 16px;
    }
    .hero-section {
        padding: 48px 0 36px;
    }
    .hero-cta {
        width: 100%;
    }
    .hero-cta .btn-apple-primary,
    .hero-cta .btn-apple-secondary {
        width: 100%;
        max-width: 420px;
    }
    .desktop-app-scope .app-container {
        padding: 16px 14px;
    }
    .preview-section {
        display: none !important;
    }
    .footer-content {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

@media (max-width: 640px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
    .specs-panel {
        padding: 24px 18px;
    }
    .specs-buttons {
        flex-direction: column;
        width: 100%;
    }
    .specs-buttons .btn-apple-primary,
    .specs-buttons .btn-apple-secondary,
    .specs-buttons .kofi-btn {
        width: 100%;
    }
    .specs-buttons .kofi-btn img {
        height: 38px;
    }
    .desktop-app-scope .input-row {
        flex-direction: column;
        gap: 8px;
    }
    .desktop-app-scope .input-with-icon {
        width: 100%;
    }
    .desktop-app-scope .input-row button {
        width: 100%;
    }
    .desktop-app-scope .app-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .desktop-app-scope .header-actions {
        width: 100%;
        justify-content: space-between;
    }
    .desktop-app-scope .developer-card,
    .desktop-app-scope .support-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .desktop-app-scope .developer-link-btn,
    .desktop-app-scope .support-card .kofi-btn-link {
        width: 100%;
        justify-content: center;
    }
    .desktop-app-scope .folder-picker-row,
    .desktop-app-scope .add-tag-row {
        flex-direction: column;
        gap: 6px;
    }
    .desktop-app-scope .folder-picker-row button,
    .desktop-app-scope .add-tag-row button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 14px;
    }
    .window-header {
        padding: 0 10px;
    }
    .window-title-text span {
        font-size: 10.5px;
    }
    .desktop-app-scope .current-download-body {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .desktop-app-scope .current-details-col {
        width: 100%;
    }
    .desktop-app-scope .controls button {
        flex: 1 1 calc(50% - 4px);
    }
    .desktop-app-scope .total-stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 3px;
    }
    .desktop-app-scope .queue-item {
        flex-wrap: wrap;
        padding: 8px 10px;
    }
    .desktop-app-scope .queue-status-cell {
        order: 3;
        width: auto;
        text-align: left;
    }
    .desktop-app-scope .queue-item-actions {
        order: 4;
        margin-left: auto;
    }
}
