/* =====================================================
   PDF UNLOCKER â€” style.css
   Day & Night adaptive design
===================================================== */

/* â”€â”€ Shell Layout â”€â”€ */
.unlocker-shell {
    min-height: calc(100vh - 64px);
    margin-top: 64px;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--text);
    transition: background 0.3s, color 0.3s;
}

/* â”€â”€ Tool Navbar â”€â”€ */
.tool-navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky;
    top: 64px;
    z-index: 99;
    transition: background 0.3s;
}

.tool-brand { display: flex; align-items: center; gap: 12px; }

.btn-back {
    width: 36px; height: 36px;
    border-radius: 8px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex; align-items: center; justify-content: center;
    text-decoration: none; font-size: 14px;
    transition: background 0.2s;
}
.btn-back:hover { background: var(--border); }

.brand-icon {
    width: 38px; height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--success), var(--success-dark));
    display: flex; align-items: center; justify-content: center;
    color: white; font-size: 16px; flex-shrink: 0;
}

.brand-name { font-size: 15px; font-weight: 700; color: var(--text); }
.brand-sub { font-size: 11px; color: var(--text-muted); margin-top: 1px; }

/* â”€â”€ Body â”€â”€ */
.unlocker-body {
    flex: 1;
    display: flex; flex-direction: column; align-items: center;
    padding: 40px 20px 20px;
    gap: 24px;
}

/* â”€â”€ Hero â”€â”€ */
.upload-hero { width: 100%; max-width: 680px; text-align: center; }
.upload-hero-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; }

.hero-icon { display: flex; align-items: center; gap: 14px; font-size: 40px; margin-bottom: 4px; }
.hero-icon .fa-lock { color: var(--danger); }
.hero-icon .fa-lock-open { color: var(--success); }
.hero-arrow { font-size: 20px !important; color: var(--text-muted); animation: arrow-pulse 1.5s ease-in-out infinite; }

@keyframes arrow-pulse {
    0%, 100% { transform: translateX(0); opacity: 0.6; }
    50% { transform: translateX(4px); opacity: 1; }
}

.hero-title {
    font-size: 30px; font-weight: 800; margin: 0;
    background: linear-gradient(135deg, var(--success), var(--success-dark));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

.hero-sub { font-size: 15px; color: var(--text-muted); max-width: 520px; line-height: 1.6; margin: 0; }

.hero-drop-zone {
    width: 100%;
    border: 2px dashed var(--border);
    border-radius: 16px;
    padding: 36px 20px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}
.hero-drop-zone:hover, .hero-drop-zone.drag-over {
    border-color: var(--success);
    background: var(--success-bg);
}

.drop-icon { font-size: 34px; color: var(--success); margin-bottom: 10px; display: block; }
.drop-main { font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.drop-hint { font-size: 12px; color: var(--text-muted); }

.btn-hero-upload {
    padding: 12px 28px;
    background: linear-gradient(135deg, var(--success), var(--success-dark));
    color: white; border: none; border-radius: 10px;
    font-size: 15px; font-weight: 600; cursor: pointer;
    transition: filter 0.2s, transform 0.2s;
    display: flex; align-items: center; gap: 8px;
}
.btn-hero-upload:hover { filter: brightness(1.08); transform: translateY(-1px); }

.hero-features { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.feature-pill {
    padding: 6px 14px;
    background: var(--primary-light); border: 1px solid var(--border);
    border-radius: 20px; font-size: 12px; font-weight: 500; color: var(--text-muted);
    display: flex; align-items: center; gap: 5px;
}
.feature-pill .fa-check-circle { color: var(--success); }

/* â”€â”€ Unlock Panel â”€â”€ */
.unlock-panel { width: 100%; max-width: 600px; display: flex; flex-direction: column; gap: 20px; }

/* File Card */
.file-card {
    background: var(--primary-light); border: 1px solid var(--border);
    border-radius: 14px; padding: 16px;
    display: flex; align-items: center; gap: 14px;
    position: relative; transition: background 0.3s;
}

.file-card-icon {
    width: 48px; height: 48px;
    background: var(--danger-light); border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px; color: var(--danger); flex-shrink: 0;
}

.file-card-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.file-card-name { font-size: 14px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-card-size { font-size: 11px; color: var(--text-muted); }
.file-card-status { font-size: 11px; color: var(--danger); font-weight: 600; display: flex; align-items: center; gap: 4px; }
.file-card-status.unlocked { color: var(--success); }

.btn-remove-file {
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--border); border: none; color: var(--text-muted);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 12px; transition: background 0.2s, color 0.2s; flex-shrink: 0;
}
.btn-remove-file:hover { background: var(--danger-hover); color: var(--danger); }

/* Password Section */
.pw-section {
    background: var(--primary-light); border: 1px solid var(--border);
    border-radius: 14px; padding: 20px;
    display: flex; flex-direction: column; gap: 12px;
    transition: background 0.3s;
}

.pw-label { font-size: 13px; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 6px; }
.pw-label .fa-key { color: var(--warn); }

.pw-input-row { display: flex; gap: 10px; flex-wrap: wrap; }

.pw-input-wrap { position: relative; flex: 1; min-width: 200px; }

.pw-input {
    width: 100%; padding: 12px 42px 12px 14px;
    border: 1.5px solid var(--border); border-radius: 10px;
    background: var(--bg); color: var(--text); font-size: 14px;
    outline: none; transition: border-color 0.2s, background 0.3s;
    box-sizing: border-box;
}
.pw-input:focus { border-color: var(--success); }

.pw-input-wrap .fa-eye, .pw-input-wrap .fa-eye-slash {
    position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
    color: var(--text-muted); cursor: pointer; font-size: 14px; transition: color 0.2s;
}
.pw-input-wrap .fa-eye:hover, .pw-input-wrap .fa-eye-slash:hover { color: var(--text); }

.btn-unlock {
    padding: 12px 22px;
    background: linear-gradient(135deg, var(--success), var(--success-dark));
    color: white; border: none; border-radius: 10px;
    font-size: 14px; font-weight: 600; cursor: pointer;
    white-space: nowrap; display: flex; align-items: center; gap: 8px;
    transition: filter 0.2s, transform 0.2s; flex-shrink: 0;
}
.btn-unlock:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-unlock:disabled { opacity: 0.6; cursor: default; transform: none; }

.pw-hint { font-size: 11px; color: var(--text-muted); margin: 0; display: flex; align-items: center; gap: 5px; }
.pw-hint .fa-shield-alt { color: var(--success); }

/* Success Section */
.success-section {
    background: var(--primary-light); border: 1px solid var(--success);
    border-radius: 14px; padding: 32px 20px; text-align: center;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    animation: success-in 0.4s ease;
}

@keyframes success-in {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: scale(1); }
}

.success-icon { font-size: 48px; color: var(--success); line-height: 1; }
.success-msg { font-size: 20px; font-weight: 700; color: var(--text); }
.success-sub { font-size: 13px; color: var(--text-muted); margin-bottom: 8px; }

.btn-unlock-another {
    padding: 10px 24px;
    background: transparent; border: 1.5px solid var(--success); color: var(--success);
    border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer;
    display: flex; align-items: center; gap: 8px; transition: background 0.2s, color 0.2s;
}
.btn-unlock-another:hover { background: var(--success); color: white; }

/* FAQ */
.faq-section { max-width: 800px; margin: 20px auto 40px; padding: 0 20px; width: 100%; }
.faq-title { font-size: 22px; font-weight: 700; text-align: center; margin-bottom: 20px; color: var(--text); }
.faq-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; }
.faq-card {
    background: var(--primary-light); border: 1px solid var(--border);
    border-radius: 12px; padding: 16px; transition: background 0.3s;
}
.faq-q { font-size: 13px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.faq-q i { color: var(--success); }
.faq-a { font-size: 12px; color: var(--text-muted); line-height: 1.65; }

/* Loader */
.loader-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.65); z-index: 9999;
    align-items: center; justify-content: center;
    backdrop-filter: blur(4px);
}
.loader-box {
    background: var(--bg); border-radius: 16px; padding: 32px 28px;
    min-width: 220px; text-align: center; border: 1px solid var(--border);
    display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.loader-ring { width: 44px; height: 44px; animation: spin 1.2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.loader-ring-bg { fill: none; stroke: var(--border); stroke-width: 4; }
.loader-ring-track { fill: none; stroke: var(--success); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 60; stroke-dashoffset: 20; }
.loader-text { font-size: 15px; font-weight: 600; color: var(--text); }
.loader-sub { font-size: 12px; color: var(--text-muted); }

/* Toast */
.toast-container { position: fixed; top: 80px; right: 20px; z-index: 10000; display: flex; flex-direction: column; gap: 8px; }
.toast {
    padding: 12px 18px; border-radius: 10px; font-size: 13px; font-weight: 500;
    color: white; display: flex; align-items: center; gap: 10px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2); animation: toast-in 0.25s ease;
}
@keyframes toast-in {
    from { transform: translateX(40px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast.warning { background: var(--warn); }
.toast.info { background: #3b82f6; }

/* Responsive */
@media (max-width: 600px) {
    .pw-input-row { flex-direction: column; }
    .btn-unlock { width: 100%; justify-content: center; }
    .hero-icon { font-size: 30px; }
    .hero-title { font-size: 24px; }
}

