:root {
    --brand: #4f46e5;
    --brand-light: #818cf8;
    --canvas: #f8fafc;
    --surface: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --border-subtle: #e2e8f0;
    --success: #10b981;
    --danger: #ef4444;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Plus Jakarta Sans', sans-serif; }
body { background: var(--canvas); color: var(--text-primary); padding-bottom: 80px; }
.container { max-width: 850px; margin: 0 auto; padding: 16px; }

header { display: flex; justify-content: space-between; align-items: center; background: var(--surface); padding: 16px 20px; border-bottom: 1px solid var(--border-subtle); position: sticky; top: 0; z-index: 90; }
.nav-brand { font-size: 1.15rem; font-weight: 700; color: var(--brand); display: flex; align-items: center; gap: 6px; }
.logout-trigger { background: transparent; border: none; color: var(--danger); font-size: 1.4rem; cursor: pointer; }

/* Auth / Login Panel styling */
.auth-wrapper { display: flex; justify-content: center; align-items: center; min-height: 75vh; }
.auth-card { background: var(--surface); padding: 32px 24px; border-radius: 20px; width: 100%; max-width: 360px; box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05); border: 1px solid var(--border-subtle); text-align: center; }
.auth-icon-badge { width: 60px; height: 60px; background: #e0e7ff; color: var(--brand); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; font-size: 1.8rem; }
.auth-card h2 { font-size: 1.35rem; font-weight: 700; margin-bottom: 4px; }
.subtitle { font-size: 0.85rem; color: var(--text-secondary); }
.section-desc { font-size: 0.85rem; color: var(--text-secondary); }
.text-margin { margin-bottom: 16px; }

.input-field-group { position: relative; margin-top: 14px; }
.input-field-group i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-secondary); font-size: 1.2rem; }
.input-field-group input { width: 100%; padding: 12px 14px 12px 42px; border: 1px solid var(--border-subtle); border-radius: 12px; font-size: 0.9rem; outline: none; background: #fdfdfd; }
.input-field-group input:focus { border-color: var(--brand); background: #fff; }

/* Action components */
button { border: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; font-weight: 600; border-radius: 12px; transition: all 0.2s; }
.w-100 { width: 100%; }
.btn-action-primary { background: var(--brand); color: #fff; padding: 14px; font-size: 0.95rem; box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2); }
.btn-action-primary:active { transform: scale(0.98); }
.btn-action-sm { padding: 8px 12px; font-size: 0.8rem; }
.btn-action-sm.accent { background: #e0e7ff; color: var(--brand); }
.btn-back-nav { background: var(--surface); border: 1px solid var(--border-subtle); padding: 8px 14px; font-size: 0.85rem; color: var(--text-primary); }

.dashboard-section-title { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.dashboard-section-title.inline { justify-content: flex-start; gap: 12px; }
.dashboard-section-title h3 { font-size: 1.2rem; font-weight: 700; }

.search-wrapper { position: relative; margin-bottom: 20px; }
.search-wrapper i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-secondary); }
.search-wrapper input { width: 100%; padding: 12px 14px 12px 40px; border: 1px solid var(--border-subtle); border-radius: 12px; outline: none; font-size: 0.9rem; }

/* Workspace Container Card */
.workspace-card { background: var(--surface); padding: 24px; border-radius: 16px; border: 1px solid var(--border-subtle); }
.control-label { display: block; font-size: 0.8rem; font-weight: 700; margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-secondary); }
.custom-select-box { width: 100%; padding: 12px; border: 1px solid var(--border-subtle); border-radius: 12px; outline: none; margin-bottom: 20px; background: #fff; font-size: 0.9rem; }

/* Deck Selector Layout */
.media-selector-deck { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px; margin-bottom: 20px; }
.deck-btn { background: var(--surface); border: 1px solid var(--border-subtle); padding: 12px 8px; flex-direction: column; gap: 6px; font-size: 0.8rem; color: var(--text-primary); box-shadow: 0 2px 4px rgba(0,0,0,0.02); }
.deck-btn i { font-size: 1.6rem; }
.deck-btn:active { background: #f1f5f9; border-color: #cbd5e1; }

/* Live queue preview area */
.live-stream-preview-area { background: #f1f5f9; border: 2px dashed #cbd5e1; padding: 16px; border-radius: 12px; font-size: 0.85rem; color: var(--text-secondary); text-align: center; }
.preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(60px, 1fr)); gap: 10px; margin-top: 10px; }
.preview-item { width: 60px; height: 60px; border-radius: 8px; overflow: hidden; background: #fff; border: 1px solid var(--border-subtle); display: flex; align-items: center; justify-content: center; position: relative; }
.preview-item img, .preview-item video { width: 100%; height: 100%; object-fit: cover; }
.preview-item i { font-size: 1.6rem; }

/* Folders Deck Grid style */
.folders-layout-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 14px; }
.folder-capsule { background: var(--surface); border: 1px solid var(--border-subtle); border-radius: 14px; padding: 16px; text-align: center; cursor: pointer; transition: all 0.2s; box-shadow: 0 2px 5px rgba(0,0,0,0.02); }
.folder-capsule i { font-size: 2.8rem; color: #eab308; margin-bottom: 4px; display: block; }
.folder-capsule p { font-size: 0.8rem; font-weight: 600; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
.folder-capsule:active { transform: translateY(2px); background: #fafafa; }

/* Media Grid Display cards */
.assets-layout-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.asset-display-card { background: var(--surface); border: 1px solid var(--border-subtle); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 2px 6px rgba(0,0,0,0.02); }
.asset-thumbnail-frame { height: 110px; width: 100%; background: #0f172a; display: flex; align-items: center; justify-content: center; position: relative; }
.asset-thumbnail-frame img, .asset-thumbnail-frame video { width: 100%; height: 100%; object-fit: cover; }
.asset-thumbnail-frame audio { width: 90%; }
.asset-thumbnail-frame .doc-icon { font-size: 3.5rem; color: #ef4444; }

.asset-details-pane { padding: 10px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.asset-name-string { font-size: 0.75rem; font-weight: 600; color: var(--text-primary); line-height: 1.3; word-break: break-all; }
.link-hidden-buffer { display: flex; background: var(--canvas); border-radius: 8px; padding: 6px; align-items: center; border: 1px solid var(--border-subtle); }
.link-hidden-buffer input { flex: 1; background: transparent; border: none; font-size: 0.65rem; color: var(--text-secondary); outline: none; }
.asset-card-controls { display: flex; gap: 6px; margin-top: auto; }
.btn-control-action { flex: 1; padding: 8px; font-size: 1rem; color: white; border-radius: 8px; }
.btn-control-action.copy { background: var(--success); }
.btn-control-action.delete { background: var(--danger); }

/* Unified Parallel Upload Stream Progress style */
.terminal-progress-area { margin-top: 16px; max-height: 200px; overflow-y: auto; }
.upload-status-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; border-radius: 8px; font-size: 0.8rem; font-weight: 500; margin-bottom: 6px; border: 1px solid var(--border-subtle); }
.upload-status-row.processing { background: #f0fdf4; color: #166534; border-color: #bbf7d0; }
.upload-status-row.success { background: #ecfdf5; color: #065f46; border-color: #a7f3d0; }
.upload-status-row.error { background: #fef2f2; color: #991b1b; border-color: #fecaca; }

/* Dock Navigation layout design */
.docked-navigation { position: fixed; bottom: 0; left: 0; width: 100%; background: var(--surface); display: flex; justify-content: space-around; padding: 8px 0; border-top: 1px solid var(--border-subtle); z-index: 99; box-shadow: 0 -4px 12px rgba(0,0,0,0.03); }
.dock-tab { display: flex; flex-direction: column; align-items: center; color: #94a3b8; font-size: 0.75rem; font-weight: 500; padding: 4px 12px; border-radius: 10px; cursor: pointer; }
.dock-tab i { font-size: 1.4rem; margin-bottom: 2px; }
.dock-tab.active { color: var(--brand); font-weight: 700; }
.msg-alert { font-size: 0.85rem; color: var(--danger); margin-top: 10px; font-weight: 500; }
