:root {
    --bg-color: #0f172a;
    --surface-color: rgba(30, 41, 59, 0.7);
    --primary-color: #3b82f6;
    --primary-hover: #2563eb;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --danger: #ef4444;
    --border-color: rgba(255, 255, 255, 0.1);
    --success: #10b981;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Inter', sans-serif; -webkit-tap-highlight-color: transparent; }
body { background-color: var(--bg-color); color: var(--text-main); line-height: 1.6; padding-bottom: 90px; background-image: radial-gradient(circle at top right, rgba(59, 130, 246, 0.1), transparent 400px); min-height: 100vh; overflow-x: hidden; }

header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.5rem; border-bottom: 1px solid var(--border-color); background: rgba(15, 23, 42, 0.9); backdrop-filter: blur(12px); position: sticky; top: 0; z-index: 100;}
.logo { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1.15rem; }
.header-right { display: flex; align-items: center; gap: 15px; }
.attribution { font-size: 0.85rem; color: #93c5fd; font-weight: 600; background: rgba(59, 130, 246, 0.1); padding: 4px 10px; border-radius: 20px; border: 1px solid rgba(59, 130, 246, 0.2); }
.panic-btn { background: rgba(239, 68, 68, 0.2); color: #fca5a5; border: 1px solid rgba(239, 68, 68, 0.4); padding: 6px 12px; border-radius: 6px; cursor: pointer; font-weight: 600; font-size: 0.8rem; transition: 0.2s; }
.panic-btn:hover { background: var(--danger); color: white; }

main { max-width: 760px; margin: 1.5rem auto; padding: 0 1rem; display: flex; flex-direction: column; gap: 1.25rem; }

/* Features Banner - Selling Points */
.features-banner { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 1.5rem; justify-content: center; }
.feature-badge { 
    background: rgba(59, 130, 246, 0.1); 
    padding: 6px 14px; 
    border-radius: 20px; 
    font-size: 0.8rem; 
    font-weight: 600; 
    border: 1px solid rgba(59, 130, 246, 0.2); 
    color: #93c5fd; 
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
@media (max-width: 480px) {
    .features-banner { flex-direction: column; align-items: stretch; gap: 6px; }
    .feature-badge { text-align: center; justify-content: center; display: flex; }
}

.glass-card { background: var(--surface-color); backdrop-filter: blur(16px); border: 1px solid var(--border-color); border-radius: 16px; padding: 1.25rem; position: relative; overflow: hidden; transition: all 0.3s ease; }
.glass-card.hidden { display: none; opacity: 0; transform: translateY(10px); }
.step-badge { position: absolute; top: 0; left: 0; background: rgba(59, 130, 246, 0.2); color: #93c5fd; font-size: 0.7rem; font-weight: 700; padding: 4px 12px; border-bottom-right-radius: 12px; text-transform: uppercase; letter-spacing: 1px; }

.mode-switcher { display: flex; background: var(--surface-color); border: 1px solid var(--border-color); padding: 6px; border-radius: 12px; backdrop-filter: blur(12px); }
.mode-btn { flex: 1; padding: 10px; border: none; background: transparent; color: var(--text-muted); cursor: pointer; border-radius: 8px; font-weight: 600; transition: 0.2s; font-size: 0.9rem;}
.mode-btn.active { background: var(--primary-color); color: white; box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); }

.info-banner { background: rgba(59, 130, 246, 0.1); border-left: 4px solid var(--primary-color); padding: 1rem; border-radius: 8px; font-size: 0.9rem; margin-bottom: 0.5rem; }
.info-banner.hidden { display: none; }

.section-header { margin: 10px 0 1rem 0; display: flex; justify-content: space-between; align-items: center;}
.section-title { font-weight: 600; font-size: 1rem; }
.drop-zone { border: 2px dashed var(--border-color); border-radius: 12px; padding: 2rem 1rem; text-align: center; background: rgba(15, 23, 42, 0.4); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.drop-text { font-size: 0.9rem; color: var(--text-muted); }
.drop-actions { display: flex; gap: 10px; margin-top: 5px; flex-wrap: wrap; justify-content: center;}

/* File List Elements - Updated for long names */
.file-list { margin-top: 1rem; display: flex; flex-direction: column; gap: 8px; }
.file-item { display: flex; justify-content: space-between; align-items: center; background: rgba(15, 23, 42, 0.6); padding: 10px 14px; border-radius: 8px; font-size: 0.85rem; border: 1px solid rgba(255, 255, 255, 0.05); }

/* Force min-width: 0 on flex child so text-overflow works */
.file-info { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1; margin-right: 15px; }
.file-icon { flex-shrink: 0; }
.file-count { flex-shrink: 0; color: var(--text-muted); font-size: 0.8rem; }
.file-name { 
    display: inline-block; 
    max-width: 100%; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
}

.remove-btn { background: transparent; border: none; color: var(--danger); cursor: pointer; font-size: 1.1rem; padding: 0 5px; transition: 0.2s; }
.remove-btn:hover { color: #f87171; transform: scale(1.1); }

.options-box { background: rgba(15, 23, 42, 0.5); padding: 12px 15px; border-radius: 8px; margin-top: 1rem; border: 1px solid var(--border-color); }
.options-title { font-size: 0.85rem; font-weight: 600; color: #cbd5e1; margin-bottom: 8px; }
.radio-group { display: flex; flex-direction: column; gap: 8px; }
.checkbox-group { display: flex; flex-wrap: wrap; gap: 12px; }
.radio-label, .check-label { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; cursor: pointer; color: var(--text-main); }
.radio-label input[type="radio"], .check-label input[type="checkbox"] { accent-color: var(--primary-color); width: 16px; height: 16px; cursor: pointer;}
.hidden { display: none !important; }

.key-input { width: 100%; padding: 12px; border-radius: 8px; border: 1px solid var(--border-color); background: rgba(15, 23, 42, 0.6); color: var(--text-main); font-family: 'JetBrains Mono', monospace; font-size: 0.85rem; }
.key-input:focus { outline: none; border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2); }
.ack-warning { background: rgba(239, 68, 68, 0.1); border-left: 4px solid var(--danger); padding: 1rem; border-radius: 8px; font-size: 0.85rem; color: #fca5a5; margin-bottom: 1rem; }
.ack-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

.btn { padding: 10px 18px; border-radius: 8px; border: none; cursor: pointer; font-weight: 600; font-size: 0.9rem; transition: 0.2s; }
.btn-sm { padding: 6px 12px; font-size: 0.8rem; }
.btn-primary { background: var(--primary-color); color: white; box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); }
.btn-primary:hover:not(:disabled) { background: var(--primary-hover); }
.btn-primary:disabled { background: var(--border-color); color: var(--text-muted); cursor: not-allowed; box-shadow: none; }
.btn-secondary { background: rgba(255, 255, 255, 0.05); color: var(--text-main); border: 1px solid var(--border-color); }
.action-bar { position: fixed; bottom: 0; left: 0; right: 0; background: rgba(15, 23, 42, 0.95); backdrop-filter: blur(12px); padding: 1rem 1.5rem; display: flex; justify-content: space-between; border-top: 1px solid var(--border-color); z-index: 100; }

/* Mobile Adjustments */
@media (max-width: 480px) {
    header { padding: 1rem 0.75rem; }
    .logo span { display: inline-block; font-size: 1rem; }
    .logo svg { width: 18px; height: 18px; }
    .header-right { gap: 8px; }
    .attribution { font-size: 0.7rem; padding: 4px 6px;}
    .panic-btn { padding: 6px 8px; font-size: 0.75rem; }
    .action-bar { padding: 1rem; }
    .btn { padding: 10px 12px; font-size: 0.85rem;}
}