:root {
    --accent: #10b981;
    --primary: #10b981;
    --accent-hover: #059669;
    --accent-glow: rgba(16, 185, 129, 0.15);
    --bg-color: #0f172a;
    --surface-color: #1e293b;
    --surface-hover: #263548;
    --border-color: rgba(255, 255, 255, 0.08);
    --text-main: #f1f5f9;
    --text-muted: #94a3b8;
    --text-dim: #64748b;

    --font-ui: 'Outfit', sans-serif;
    --font-arabic: 'Amiri', serif;
    --font-urdu: 'Noori Nastaleeq', 'Amiri', serif;

    --radius-xl: 20px;
    --radius-lg: 16px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --radius-pill: 999px;
    --shadow-soft: 0 4px 24px rgba(0,0,0,0.25);
    --shadow-glow: 0 0 20px rgba(16,185,129,0.12);
    --glass-bg: rgba(30, 41, 59, 0.75);
    --glass-border: rgba(255, 255, 255, 0.06);
    --card-bg: var(--surface-color);
    --button-bg: var(--bg-color);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ─── Themes ─── */
[data-theme="light"] {
    --bg-color: #f1f5f9; --surface-color: #ffffff; --surface-hover: #f8fafc;
    --border-color: rgba(0,0,0,0.08); --text-main: #0f172a; --text-muted: #475569; --text-dim: #94a3b8;
    --shadow-soft: 0 4px 24px rgba(0,0,0,0.06); --glass-bg: rgba(255,255,255,0.85);
    --accent-glow: rgba(16,185,129,0.08);
}
[data-theme="sepia"] {
    --bg-color: #f5ebe0; --surface-color: #fefcf3; --surface-hover: #f7f0e4;
    --border-color: rgba(139,69,19,0.1); --text-main: #3e2723; --text-muted: #6d4c41; --text-dim: #8d6e63;
    --glass-bg: rgba(254,252,243,0.85);
}
[data-theme="night-blue"] {
    --bg-color: #0a1628; --surface-color: #162032; --surface-hover: #1c2d44;
    --text-main: #e2e8f0; --border-color: rgba(255,255,255,0.06);
}
[data-theme="amoled"] {
    --bg-color: #000000; --surface-color: #0a0a0a; --surface-hover: #111111;
    --border-color: #1a1a1a; --text-main: #ffffff; --glass-bg: rgba(10,10,10,0.9);
}

/* ─── Accents ─── */
[data-color="blue"]    { --accent: #3b82f6; --primary: #3b82f6; --accent-hover: #2563eb; --accent-glow: rgba(59,130,246,0.15); }
[data-color="purple"]  { --accent: #8b5cf6; --primary: #8b5cf6; --accent-hover: #7c3aed; --accent-glow: rgba(139,92,246,0.15); }
[data-color="gold"]    { --accent: #f59e0b; --primary: #f59e0b; --accent-hover: #d97706; --accent-glow: rgba(245,158,11,0.15); }
[data-color="soft-red"]{ --accent: #ef4444; --primary: #ef4444; --accent-hover: #dc2626; --accent-glow: rgba(239,68,68,0.15); }

/* ─── Professional Arabic Fonts ─── */
@import url('https://fonts.googleapis.com/css2?family=Amiri:wght@400;700&display=swap');

/* Uthmanic Style (Simulated with Scheherazade New) */
@import url('https://fonts.googleapis.com/css2?family=Scheherazade+New:wght@400;700&display=swap');

/* Indo-Pak Style (Simulated with Lateef) */
@import url('https://fonts.googleapis.com/css2?family=Lateef&display=swap');

[data-font="amiri"] { --font-arabic: 'Amiri', serif; }
[data-font="uthmanic"] { --font-arabic: 'Scheherazade New', serif; }
[data-font="indopak"] { --font-arabic: 'Lateef', cursive; }

/* ─── Micro-Animations ─── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.animate-fade-in { animation: fadeInUp 0.4s ease-out forwards; }
.animate-scale-in { animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }

/* Hover effects for cards and buttons */
.side-item, .nav-item, .tasbih-pro-card, .auth-pro-card, .btn-pro, .card-pro {
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s ease;
}

.side-item:hover, .nav-item:hover { transform: translateX(4px); }
.tasbih-pro-card:hover, .auth-pro-card:hover { transform: translateY(-2px); box-shadow: 0 12px 40px -12px rgba(0,0,0,0.4); }
button:active { transform: scale(0.96); }

/* ─── Global Reset ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: var(--font-ui);
    background: var(--bg-color);
    color: var(--text-main);
    transition: background var(--transition), color var(--transition);
    min-height: 100vh;
    -webkit-tap-highlight-color: transparent;
}

/* Hide scrollbars on mobile for sidebar and other scrollable areas */
@media (max-width: 1024px) {
    .app-sidebar::-webkit-scrollbar,
    .admin-sidebar::-webkit-scrollbar,
    nav::-webkit-scrollbar,
    .h-scroll::-webkit-scrollbar {
        display: none !important;
        width: 0 !important;
        height: 0 !important;
    }
    .app-sidebar, .admin-sidebar, nav, .h-scroll {
        scrollbar-width: none !important;
        -ms-overflow-style: none !important;
    }
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }
.hide-mobile { display: initial; }
.show-mobile { display: none !important; }

/* ─── Typography ─── */
.arabic-text { font-family: var(--font-arabic); font-size: 1.7rem; line-height: 2.4; text-align: right; direction: rtl; }
.urdu-text { font-family: var(--font-urdu); font-size: 1.5rem; line-height: 2.2; text-align: right; direction: rtl; }
.bismillah { font-family: var(--font-arabic); font-size: 2.2rem; text-align: center; color: var(--accent); padding: 1.5rem 0; opacity: 0.9; }

/* ─── Top Header Bar ─── */
.top-header {
    position: sticky; top: 0; z-index: 200;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0.8rem 1.2rem;
    background: var(--glass-bg); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
}
.top-header .brand { display: flex; align-items: center; gap: 0.6rem; font-size: 1.2rem; font-weight: 700; color: var(--accent); }
.top-header .brand i { font-size: 1.1rem; }
.top-header .header-actions { display: flex; align-items: center; gap: 0.6rem; }
.header-icon-btn {
    width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--border-color);
    background: transparent; color: var(--text-muted); display: flex; align-items: center; justify-content: center;
    transition: var(--transition); font-size: 1rem;
}
.header-icon-btn:hover { color: var(--accent); border-color: var(--accent); background: var(--accent-glow); }
.header-search {
    flex: 1; max-width: 400px; margin: 0 1rem;
    display: flex; align-items: center; gap: 0.5rem;
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-pill); padding: 0.5rem 1rem; transition: var(--transition);
}
.header-search:focus-within { border-color: var(--accent); box-shadow: var(--shadow-glow); }
.header-search i { color: var(--text-dim); font-size: 0.9rem; }
.header-search input {
    flex: 1; background: transparent; border: none; outline: none;
    color: var(--text-main); font-size: 0.95rem; font-family: inherit;
}
.header-search input::placeholder { color: var(--text-dim); }

/* ─── Page Container ─── */
.page-container { max-width: 1100px; margin: 0 auto; padding: 1.5rem 1rem; padding-bottom: 100px; width: 100%; box-sizing: border-box; }

/* ─── Home Hero / Search ─── */
.home-pro-hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at top right, rgba(16, 185, 129, 0.22), transparent 32%),
        linear-gradient(135deg, rgba(15, 23, 42, 0.55), rgba(30, 41, 59, 0.92));
    border: 1px solid var(--border-color);
    border-radius: 30px;
    padding: 2.25rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-soft);
    color: #ffffff; /* Ensure text is always white on this dark background */
}

[data-theme="light"] .home-pro-hero {
    background: 
        radial-gradient(circle at top right, rgba(16, 185, 129, 0.15), transparent 40%),
        linear-gradient(135deg, #064e3b, #065f46); /* Darker green gradient for light mode contrast */
    border-color: transparent;
}
.home-pro-hero::before {
    content: '';
    position: absolute;
    inset: auto -15% -45% auto;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.16), transparent 70%);
    pointer-events: none;
}
.hero-content {
    position: relative;
    z-index: 1;
    max-width: 760px;
}
.bismillah-header {
    font-family: var(--font-arabic);
    color: var(--accent);
    font-size: 1.15rem;
    margin-bottom: 0.5rem;
    opacity: 0.92;
}
.home-pro-hero h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.05;
    margin-bottom: 0.75rem;
    letter-spacing: -0.03em;
    color: #ffffff;
}
.home-pro-hero p {
    max-width: 680px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    line-height: 1.7;
}
.global-search-container {
    margin-top: 1.35rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 18px;
    padding: 0.9rem 1rem;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.02);
    cursor: text;
}

[data-theme="light"] .global-search-container {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}
.global-search-container:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
}
.global-search-container .search-icon {
    color: var(--accent);
    font-size: 1rem;
}
.global-search-container input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    font-size: 1rem;
    font-family: inherit;
}
.global-search-container input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}
.search-hint {
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.82rem;
}
.search-hint kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    padding: 0.2rem 0.45rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: rgba(255,255,255,0.04);
    color: var(--text-main);
    font: inherit;
    font-weight: 600;
}

/* ─── Hero Section ─── */
.hero-section {
    text-align: center; padding: 2.5rem 1rem 2rem;
    background: linear-gradient(135deg, var(--accent-glow), transparent);
    border-radius: var(--radius-xl); margin-bottom: 2rem;
}
.hero-section .hero-arabic { font-family: var(--font-arabic); font-size: 2.4rem; color: var(--accent); margin-bottom: 0.5rem; opacity: 0.85; }
.hero-section h1 { font-size: 1.8rem; font-weight: 700; margin-bottom: 0.3rem; }
.hero-section p { color: var(--text-muted); font-size: 1rem; }

/* ─── Quick Action Cards ─── */
.quick-actions { display: flex; gap: 1rem; justify-content: center; margin-bottom: 2rem; overflow-x: auto; padding-bottom: 0.5rem; }
.qa-card {
    display: flex; flex-direction: column; align-items: center; gap: 0.6rem;
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); padding: 1.2rem 1.8rem; min-width: 120px;
    transition: var(--transition); cursor: pointer;
}
.qa-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-glow); }
.qa-card .qa-icon { width: 42px; height: 42px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; font-size: 1.2rem; }
.qa-card span { font-size: 0.85rem; font-weight: 500; color: var(--text-muted); white-space: nowrap; }

/* ─── Horizontal Scroll Section ─── */
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.section-header h2 { font-size: 1.2rem; font-weight: 600; display: flex; align-items: center; gap: 0.5rem; }
.section-header h2 i { color: var(--accent); }
.section-header .sub-text { color: var(--text-dim); font-size: 0.85rem; }

.h-scroll { display: flex; gap: 0.75rem; overflow-x: auto; padding-bottom: 0.5rem; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.h-scroll::-webkit-scrollbar { display: none; }
.juz-chip {
    min-width: 60px; text-align: center; padding: 0.7rem 0.5rem;
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-md); cursor: pointer; transition: var(--transition);
}
.juz-chip:hover, .juz-chip.active { border-color: var(--accent); color: var(--accent); background: var(--accent-glow); }
.juz-chip .juz-num { font-size: 1.1rem; font-weight: 600; }
.juz-chip .juz-label { font-size: 0.7rem; color: var(--text-dim); }

/* ─── Filter Chips ─── */
.filter-chips { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.chip {
    padding: 0.4rem 1rem; border-radius: var(--radius-pill); font-size: 0.85rem; font-weight: 500;
    border: 1px solid var(--border-color); background: transparent; color: var(--text-muted);
    transition: var(--transition);
}
.chip:hover, .chip.active { border-color: var(--accent); color: var(--accent); background: var(--accent-glow); }

/* ─── Surah List Cards ─── */
.surah-list { display: flex; flex-direction: column; gap: 0.5rem; margin-top: 1rem; }
.surah-item {
    display: flex; align-items: center; gap: 1rem; padding: 0.9rem 1rem;
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-md); transition: var(--transition); cursor: pointer;
    width: 100%; box-sizing: border-box;
}
.surah-item:hover { border-color: var(--accent); background: var(--surface-hover); }
.surah-number {
    width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
    font-weight: 600; font-size: 0.9rem; color: var(--accent);
    background: var(--accent-glow); border-radius: var(--radius-sm);
}
.surah-info { flex: 1; }
.surah-info .surah-name-en { font-weight: 600; font-size: 0.95rem; }
.surah-info .surah-meta { color: var(--text-dim); font-size: 0.8rem; margin-top: 2px; }
.surah-arabic { font-family: var(--font-arabic); font-size: 1.2rem; color: var(--text-muted); }

/* ─── Ayah Cards (Reader View) ─── */
.reader-settings-bar {
    display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.8rem;
    padding: 0.8rem 1rem; background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); margin-bottom: 1.5rem;
}
.reader-settings-bar select, .reader-settings-bar button {
    padding: 0.45rem 0.9rem; border-radius: var(--radius-sm); font-size: 0.85rem;
    background: var(--bg-color); border: 1px solid var(--border-color); color: var(--text-main);
    outline: none; transition: var(--transition); font-family: inherit;
}
.reader-settings-bar select:focus, .reader-settings-bar button:hover { border-color: var(--accent); }
.reader-settings-bar button.active { background: var(--accent); color: white; border-color: var(--accent); }

.quran-read-meta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1.25rem;
    padding: 0.85rem 1rem;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    text-align: center;
}
.quran-read-meta .reader-subnote {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-dim);
    line-height: 1.45;
    max-width: 42rem;
}
.quran-resume-btn {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    padding: 0.55rem 1.1rem;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(16, 185, 129, 0.45);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.18), rgba(16, 185, 129, 0.06));
    color: var(--accent);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}
.quran-resume-btn:hover {
    border-color: var(--accent);
    background: rgba(16, 185, 129, 0.22);
    color: var(--text-main);
}

.ayah-card {
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); padding: 1.2rem 1rem; margin-bottom: 0.8rem;
    transition: var(--transition); position: relative;
}
.ayah-card:hover { border-color: var(--accent); }
.ayah-card .ayah-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.8rem; }
.ayah-num-badge {
    background: var(--accent-glow); color: var(--accent); font-weight: 600; font-size: 0.85rem;
    padding: 0.3rem 0.7rem; border-radius: var(--radius-pill);
}
.ayah-actions { display: flex; gap: 0.4rem; }
.ayah-action-btn {
    width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border-color);
    background: transparent; color: var(--text-dim); display: flex; align-items: center; justify-content: center;
    font-size: 0.8rem; transition: var(--transition);
}
.ayah-action-btn:hover { color: var(--accent); border-color: var(--accent); background: var(--accent-glow); }
.ayah-card .ayah-arabic { font-family: var(--font-arabic); font-size: 1.6rem; line-height: 2.4; text-align: right; direction: rtl; margin-bottom: 0.5rem; }
.ayah-card .translation-en { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; padding-top: 0.5rem; border-top: 1px dashed var(--border-color); display: none; }
.ayah-card .translation-ur { font-family: var(--font-urdu); color: var(--text-muted); font-size: 1.2rem; line-height: 2; direction: rtl; text-align: right; padding-top: 0.5rem; display: none; }
.ayah-card .translation-en.visible, .ayah-card .translation-ur.visible { display: block; }

/* ─── Pro floating audio player ─── */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.nq-audio-player {
    position: fixed;
    z-index: 320;
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    width: min(560px, calc(100vw - 1.25rem));
    max-width: calc(100vw - 1.25rem);
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.45), rgba(59, 130, 246, 0.2), rgba(16, 185, 129, 0.15));
    box-shadow:
        0 18px 50px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(255, 255, 255, 0.06) inset;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}
.nq-audio-player.hidden {
    transform: translate(-50%, calc(100% + 24px));
    opacity: 0;
    pointer-events: none;
}
.nq-ap-inner {
    display: flex;
    gap: 0.85rem;
    align-items: stretch;
    padding: 0.75rem 0.85rem 0.85rem;
    border-radius: 18px;
    background: linear-gradient(165deg, rgba(15, 23, 42, 0.97), rgba(17, 24, 39, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}
.nq-ap-art {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.25), rgba(16, 185, 129, 0.08));
    color: var(--accent);
    font-size: 1.35rem;
    border: 1px solid rgba(16, 185, 129, 0.25);
}
.nq-ap-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}
.nq-ap-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
}
.nq-ap-text { min-width: 0; flex: 1; }
.nq-ap-title {
    font-weight: 700;
    font-size: 0.92rem;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-main);
}
.nq-ap-sub {
    font-size: 0.78rem;
    color: var(--text-dim);
    margin-top: 0.15rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.nq-ap-btn {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
}
.nq-ap-btn:hover {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
    border-color: rgba(16, 185, 129, 0.25);
}
.nq-ap-btn--ghost {
    background: transparent;
    border-color: var(--border-color);
    color: var(--text-dim);
}
.nq-ap-btn--ghost:hover {
    color: var(--text-main);
    border-color: var(--accent);
}
.nq-ap-btn--play {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    border: none;
    font-size: 1.05rem;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
}
.nq-ap-btn--play:hover {
    background: var(--accent-hover);
    color: #fff;
    transform: scale(1.04);
}
.nq-ap-scrub {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}
.nq-ap-time {
    font-size: 0.68rem;
    font-variant-numeric: tabular-nums;
    color: var(--text-muted);
    width: 2.35rem;
    flex-shrink: 0;
    text-align: center;
}
.nq-ap-seek-wrap {
    flex: 1;
    min-width: 0;
    height: 20px;
    display: flex;
    align-items: center;
}
.nq-ap-seek {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    cursor: pointer;
}
.nq-ap-seek:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.nq-ap-seek::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25);
    margin-top: -4px;
    cursor: grab;
}
.nq-ap-seek::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    border: none;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25);
    cursor: grab;
}
.nq-ap-seek::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.12);
}
.nq-ap-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.5rem;
    padding-top: 0.15rem;
}
.nq-ap-skip {
    width: auto;
    min-width: 38px;
    padding: 0 0.35rem;
    gap: 0.2rem;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-dim);
}
.nq-ap-skip-lbl {
    font-size: 0.62rem;
    opacity: 0.85;
}
.nq-ap-volume-block {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex: 1 1 120px;
    min-width: 100px;
    max-width: 160px;
}
.nq-ap-volume {
    flex: 1;
    min-width: 48px;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
.nq-ap-volume::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #e2e8f0;
    margin-top: -3px;
    cursor: pointer;
}
.nq-ap-volume::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #e2e8f0;
    border: none;
    cursor: pointer;
}
.nq-ap-rate-wrap { margin-left: auto; }
.nq-ap-rate {
    height: 34px;
    padding: 0 0.5rem;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-main);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    min-width: 4.2rem;
}
.nq-ap-rate:focus {
    outline: none;
    border-color: var(--accent);
}

@media (min-width: 768px) {
    .nq-audio-player {
        bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
    }
}

@media (max-width: 420px) {
    .nq-ap-inner {
        flex-direction: column;
        align-items: stretch;
    }
    .nq-ap-art {
        display: none;
    }
    .nq-ap-volume-block {
        max-width: none;
        flex: 1 1 100%;
        order: 5;
    }
    .nq-ap-rate-wrap {
        margin-left: 0;
        width: 100%;
    }
    .nq-ap-rate {
        width: 100%;
    }
    .nq-ap-controls {
        justify-content: space-between;
    }
}

/* ─── FAB Button ─── */
.fab {
    position: fixed; bottom: 85px; right: 1.5rem; z-index: 250;
    width: 56px; height: 56px; border-radius: 50%; border: none;
    background: var(--accent); color: white; font-size: 1.3rem;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 20px rgba(16,185,129,0.4); cursor: pointer;
    transition: var(--transition);
}
.fab:hover { transform: scale(1.08); background: var(--accent-hover); }

/* ─── Bottom Navigation ─── */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; width: 100%; z-index: 200;
    display: flex; justify-content: flex-start; align-items: center;
    gap: 0.15rem;
    padding: 0.5rem 0.35rem; padding-bottom: calc(0.5rem + env(safe-area-inset-bottom));
    background: var(--glass-bg); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--glass-border);
    overflow-x: auto; -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.bottom-nav::-webkit-scrollbar { display: none; }
.bottom-nav .nav-item {
    display: flex; flex-direction: column; align-items: center; gap: 0.2rem;
    color: var(--text-dim); font-size: 0.65rem; transition: var(--transition); padding: 0.35rem 0.45rem;
    flex: 1 0 auto; min-width: 56px; max-width: 88px;
}
.bottom-nav .nav-item i { font-size: 1.2rem; }
.bottom-nav .nav-item.active { color: var(--accent); }
.bottom-nav .nav-item:hover { color: var(--accent); }

/* ─── Cards / Panels ─── */
.card {
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); padding: 1.2rem; transition: var(--transition);
}
.card:hover { border-color: var(--accent); }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }

/* ─── Badges ─── */
.badge { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.25rem 0.7rem; border-radius: var(--radius-pill); font-size: 0.8rem; font-weight: 500; }
.badge-success { background: rgba(16,185,129,0.15); color: #10b981; }
.badge-warning { background: rgba(245,158,11,0.15); color: #f59e0b; }
.badge-info { background: rgba(59,130,246,0.15); color: #3b82f6; }

/* ─── Buttons ─── */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.55rem 1.2rem; border-radius: var(--radius-sm); font-weight: 600; font-size: 0.9rem; border: none; transition: var(--transition); }
.btn-primary { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: transparent; border: 1px solid var(--border-color); color: var(--text-main); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ─── Loading ─── */
.loading-spinner { text-align: center; padding: 3rem; color: var(--accent); font-size: 1.5rem; }

/* ─── Modal ─── */
.modal { display: none; position: fixed; z-index: 1000; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(5px); }
.modal-content {
    background: var(--surface-color); margin: 8vh auto; padding: 2rem; border-radius: var(--radius-xl);
    width: 92%; max-width: 460px; border: 1px solid var(--border-color);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5); animation: slideUp 0.3s ease-out;
}
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border-color); }
.close { color: var(--text-muted); font-size: 1.6rem; cursor: pointer; transition: var(--transition); background: none; border: none; }
.close:hover { color: var(--accent); }
.theme-options, .color-options { display: flex; gap: 0.6rem; flex-wrap: wrap; margin: 0.8rem 0 1.5rem; }
.theme-options button { padding: 0.45rem 0.9rem; border-radius: var(--radius-pill); background: transparent; border: 1px solid var(--border-color); color: var(--text-main); font-size: 0.85rem; transition: var(--transition); }
.theme-options button:hover { border-color: var(--accent); }
.color-options .c-btn { width: 36px; height: 36px; border-radius: 50%; border: 2px solid transparent; transition: var(--transition); }
.color-options .c-btn:hover { transform: scale(1.15); }

/* ─── Hadith Book Cards ─── */
.books-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; }
.book-card {
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); padding: 1.5rem; cursor: pointer;
    transition: var(--transition); position: relative; overflow: hidden;
}
.book-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-glow); }
.book-card h3 { font-size: 1.05rem; margin-bottom: 0.3rem; }
.book-card p { color: var(--text-dim); font-size: 0.85rem; }
.book-card .icon-bg { position: absolute; right: -15px; bottom: -15px; font-size: 5rem; opacity: 0.04; color: var(--accent); }

/* ─── Hadith Items ─── */
.hadith-list { display: flex; flex-direction: column; gap: 1rem; }
.hadith-item { background: var(--surface-color); padding: 1.5rem; border-radius: var(--radius-lg); border: 1px solid var(--border-color); }
.hadith-item:hover { border-color: var(--accent); }
.hadith-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; padding-bottom: 0.8rem; border-bottom: 1px solid var(--border-color); }
.hadith-number { font-weight: 700; color: var(--accent); }

/* ─── Search Page ─── */
.search-big-box {
    background: var(--surface-color); border: 1px solid var(--border-color);
    border-radius: var(--radius-xl); padding: 2rem; text-align: center; margin-bottom: 2rem;
}
.search-big-input {
    width: 100%; max-width: 500px; margin: 1rem auto 0;
    padding: 0.9rem 1rem 0.9rem 2.8rem; font-size: 1.1rem;
    background: var(--bg-color); border: 1px solid var(--border-color); border-radius: var(--radius-pill);
    color: var(--text-main); outline: none; transition: var(--transition); font-family: inherit;
}
.search-big-input:focus { border-color: var(--accent); box-shadow: var(--shadow-glow); }

/* ─── Responsive / Mobile ─── */
@media (min-width: 768px) {
    .bottom-nav { display: none; }
    .page-container { padding-bottom: 2rem; }
    .nq-audio-player { bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px)); }
    .fab { bottom: 2rem; }
}
/* ── Main Layout (Desktop Sidebar) ── */
.app-layout { display: flex; min-height: calc(100vh - 65px); }
@media (max-width: 767px) {
    .app-layout { display: block; }
}
@media (min-width: 768px) {
    /* Stretch sidebar with tall pages (e.g. login) breaks position:sticky — keep column viewport-height */
    .app-layout { align-items: flex-start; }
}
.app-sidebar { 
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 280px;
    background: var(--surface-color);
    border-right: 1px solid var(--border-color);
    z-index: 9999;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 20px 0 50px rgba(0,0,0,0);
    display: flex;
    flex-direction: column;
}
@media (min-width: 768px) {
    .app-sidebar {
        position: sticky;
        top: 65px;
        left: 0;
        align-self: flex-start;
        flex-shrink: 0;
        height: calc(100vh - 65px);
        max-height: calc(100vh - 65px);
        width: 260px;
        transform: none;
        z-index: 90;
        box-shadow: none;
        overflow: hidden;
    }
}
/* Middle nav scrolls so Sign in / footer stay reachable; no fake gap from flex:1 on empty space */
.sidebar-nav {
    flex: 1 1 auto;
    min-height: 0;
    padding: 0.85rem 0.9rem 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}
.side-item { 
    display: flex; 
    align-items: center; 
    gap: 0.85rem; 
    padding: 0.65rem 0.95rem; 
    color: var(--text-muted); 
    text-decoration: none; 
    border-radius: var(--radius-md); 
    font-weight: 500;
    transition: 0.2s;
}
.side-item i { font-size: 1.2rem; min-width: 24px; text-align: center; }
.side-item:hover, .side-item.active { background: rgba(16, 185, 129, 0.1); color: var(--accent); }
.sidebar-brand-wrap {
    flex-shrink: 0;
    padding: 1.1rem 1rem 0.4rem;
    border-bottom: 1px solid rgba(255,255,255,0.03);
}
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.9rem 1rem;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(16,185,129,0.14), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.05);
}
.sidebar-brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: rgba(16,185,129,0.14);
    color: var(--accent);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}
.sidebar-brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.sidebar-brand-text strong {
    font-size: 1rem;
    line-height: 1.1;
    color: var(--text-main);
}
.sidebar-brand-text small {
    margin-top: 0.2rem;
    color: var(--text-dim);
    font-size: 0.76rem;
    line-height: 1.35;
}
.sidebar-extra-nav {
    flex-shrink: 0;
    padding: 0.35rem 0.9rem 0.15rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.sidebar-extra-nav .side-item {
    background: rgba(16, 185, 129, 0.06);
    border: 1px solid rgba(16, 185, 129, 0.12);
}
.sidebar-extra-nav .side-item:hover,
.sidebar-extra-nav .side-item.active {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.28);
}

.sidebar-account {
    flex-shrink: 0;
    padding: 0.5rem 0.9rem 0.65rem;
    margin-top: 0.35rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    background: rgba(0, 0, 0, 0.12);
    border-radius: 14px;
    margin-inline: 0.65rem;
}
.sidebar-account .side-item.side-item-muted {
    color: var(--text-dim);
}
.sidebar-account .side-item.side-item-muted:hover {
    color: #f87171;
    background: rgba(248, 113, 113, 0.08);
}

.sidebar-bottom {
    flex-shrink: 0;
    padding: 0.75rem 1rem 1rem;
    border-top: 1px solid var(--border-color);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
}

/* ── Collapsed Sidebar ── */
body.sidebar-collapsed .app-sidebar { width: 80px; }
body.sidebar-collapsed .side-item span,
body.sidebar-collapsed .sidebar-brand-text,
body.sidebar-collapsed .sidebar-bottom p { display: none; }
body.sidebar-collapsed .side-item { justify-content: center; padding: 0.9rem; }
body.sidebar-collapsed .side-item i { font-size: 1.4rem; }
body.sidebar-collapsed .sidebar-account {
    margin-inline: 0.35rem;
    padding: 0.35rem 0.25rem;
}
body.sidebar-collapsed .sidebar-brand {
    justify-content: center;
    padding-inline: 0.75rem;
}

/* ── Responsive Refinements ── */
.header-left { display: flex; align-items: center; gap: 0.5rem; }
.sidebar-trigger { border: none; background: transparent; cursor: pointer; display: flex; color: var(--text-muted); font-size: 1.1rem; padding: 0.4rem; }
.sidebar-trigger:hover { color: var(--accent); }
@media (min-width: 768px) {
    .sidebar-trigger { display: flex; } /* Always available for collapse/open */
}

@media (min-width: 768px) {
    .bottom-nav { display: none; }
    .page-container {
        flex: 1;
        min-width: 0;
        padding: 2.5rem;
        max-width: 100%;
        overflow-x: hidden;
    }
}

/* Mobile Sidebar Active State */
body.mobile-sidebar-open .app-sidebar { transform: translateX(0); box-shadow: 20px 0 50px rgba(0,0,0,0.5); }
body.mobile-sidebar-open #sidebarOverlay { display: block !important; opacity: 1; }

.header-search .hide-mobile { display: block; }
@media (max-width: 767px) {
    .header-search { flex: 0 0 40px; background: transparent !important; border: none !important; margin: 0 !important; padding: 0 !important; }
    .header-search .hide-mobile { display: none !important; }
    .header-search i { font-size: 1.25rem; color: var(--accent); cursor: pointer; padding: 10px; }
}

/* ── Pro Toast Notification System ── */
.toast-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    pointer-events: none;
}
.toast-item {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    padding: 0.9rem 1.4rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 280px;
    animation: toast-in 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
    pointer-events: auto;
}
.toast-item i { font-size: 1.25rem; }
.toast-item.success i { color: #10b981; }
.toast-item.error i { color: #ef4444; }
.toast-item.warning i { color: #f59e0b; }
.toast-item.info i { color: #3b82f6; }

.toast-item.fade-out {
    animation: toast-out 0.5s ease-in forwards;
}

@keyframes toast-in {
    from { opacity: 0; transform: translateX(50px) scale(0.9); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes toast-out {
    from { opacity: 1; transform: scale(1); }
    to { opacity: 0; transform: scale(0.9); }
}

@media (max-width: 767px) {
    .toast-container { top: 1rem; right: 1rem; left: 1rem; }
    .toast-item { min-width: auto; }
}

/* ── Final Layout Tweaks ── */
.app-layout { transition: margin 0.3s ease; }
body.sidebar-collapsed .page-container { max-width: 100vw; }

/* ── Audio Pulse ── */
.playing-pulse {
    animation: pulse-glow 2s infinite;
}
@keyframes pulse-glow {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* ── More responsive tweaks ── */
/* Mobile Search Icon Perfection */
@media (max-width: 767px) {
    .header-search { background: transparent; border: none; max-width: 40px; margin: 0; box-shadow: none; }
    .header-search .hide-mobile { display: none; }
    .header-search:focus-within { box-shadow: none; border: none; }
    .header-search i { font-size: 1.2rem; color: var(--accent); padding: 0.5rem; }
}
.hidden { display: none !important; }

/* ─── Enhancement Pack ─── */
.header-hijri-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.85rem;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.8rem;
    background: var(--surface-color);
}
.theme-section-title {
    font-size: 0.85rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.75rem;
}
.theme-picker-block + .theme-picker-block { margin-top: 1rem; }
.theme-options .t-btn.active {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-glow);
}
.color-options .c-btn.active {
    border-color: white;
    box-shadow: 0 0 0 3px var(--accent-glow);
    transform: scale(1.08);
}
.mini-player-toggle {
    position: fixed;
    right: max(1rem, env(safe-area-inset-right));
    bottom: calc(200px + env(safe-area-inset-bottom, 0px));
    z-index: 310;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(145deg, var(--accent), #059669);
    color: white;
    box-shadow: 0 10px 28px rgba(16, 185, 129, 0.4);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.mini-player-toggle:hover {
    transform: scale(1.06);
    box-shadow: 0 12px 32px rgba(16, 185, 129, 0.5);
}
.search-result-card {
    display: block;
    border: 1px solid var(--border-color);
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    padding: 1rem;
    margin-bottom: 0.85rem;
    transition: var(--transition);
}
.search-result-card:hover {
    border-color: var(--accent);
    background: var(--surface-hover);
}
.search-result-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}
.search-result-ref { color: var(--text-dim); font-size: 0.8rem; }
.search-result-arabic {
    font-family: var(--font-arabic);
    font-size: 1.5rem;
    text-align: right;
    direction: rtl;
    margin-bottom: 0.75rem;
}
.search-result-meta { color: var(--text-muted); font-size: 0.88rem; }
.continue-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.continue-card, .compact-stat {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1.25rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
}
.continue-card h3, .compact-stat h3 { font-size: 1.2rem; margin: 0.65rem 0 0.35rem; }
.continue-card p, .compact-stat p { color: var(--text-dim); font-size: 0.92rem; }
.prayer-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 0 0 1.5rem;
}
.prayer-item {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    min-height: 52px;
    padding: 0.9rem 1rem;
    border-radius: 18px;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    box-shadow: var(--shadow-soft);
}
.prayer-item i {
    color: var(--accent);
    font-size: 1rem;
}
.prayer-item strong {
    color: var(--text-main);
}
.prayer-item.loading-p {
    width: 100%;
    justify-content: center;
    color: var(--text-muted);
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.dua-card h3 { margin-bottom: 1rem; font-size: 1.1rem; }
.dua-arabic {
    font-family: var(--font-arabic);
    font-size: 1.7rem;
    line-height: 2.1;
    text-align: right;
    direction: rtl;
    margin-bottom: 1rem;
}
.dua-translation { color: var(--text-muted); line-height: 1.7; }
.dua-ref { margin-top: 1rem; color: var(--accent); font-size: 0.85rem; display: inline-flex; gap: 0.4rem; align-items: center; }
.event-list { display: flex; flex-direction: column; gap: 0.85rem; }
.event-item {
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    border-radius: var(--radius-lg);
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}
.event-item h4 { margin-bottom: 0.2rem; font-size: 1rem; }
.event-item p { color: var(--text-dim); font-size: 0.85rem; }
.event-badge {
    white-space: nowrap;
    padding: 0.45rem 0.8rem;
    border-radius: var(--radius-pill);
    background: var(--accent-glow);
    color: var(--accent);
    font-weight: 600;
    font-size: 0.82rem;
}
.quick-tools-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1.75rem;
}
.quick-tool-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}
.quick-tool-card i {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: var(--accent-glow);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}
.quick-tool-card h3 { margin-bottom: 0.35rem; }
.quick-tool-card p { color: var(--text-dim); font-size: 0.88rem; line-height: 1.6; }
.reader-subnote {
    margin-bottom: 1rem;
    color: var(--text-dim);
    text-align: center;
    font-size: 0.9rem;
}
.social-like-btn.active,
.ayah-action-btn.active {
    color: #ef4444;
    border-color: rgba(239,68,68,0.3);
    background: rgba(239,68,68,0.08);
}
.progress-hero {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1rem;
    align-items: center;
}
.progress-hero h2 { margin: 0.75rem 0 0.35rem; font-size: 1.75rem; }
.progress-last-read { color: var(--text-dim); font-size: 0.92rem; }
.progress-circle-wrap { display: flex; justify-content: center; }
.progress-circle {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: conic-gradient(var(--accent) 0% 0%, var(--accent-glow) 0% 100%);
}
.progress-circle span {
    width: 122px;
    height: 122px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--surface-color);
    color: var(--text-main);
    font-size: 1.4rem;
    font-weight: 700;
}
.surah-progress-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}
.surah-progress-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.85rem;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-main);
    font-size: 0.88rem;
}
.surah-progress-pill:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.zakat-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 1rem;
}
.zakat-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}
.zakat-form-grid label {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}
.zakat-form-grid input {
    width: 100%;
    padding: 0.85rem 0.95rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-main);
    font-family: inherit;
}
.zakat-form-grid input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: var(--shadow-glow);
}
.zakat-switcher {
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}
.zakat-result-card h2 {
    margin: 1rem 0 0.4rem;
    font-size: 2.25rem;
    color: var(--accent);
}
.zakat-result-card > p { color: var(--text-muted); line-height: 1.7; }
.zakat-breakdown {
    margin-top: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}
.zakat-breakdown-item {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--border-color);
}
.zakat-note {
    margin-top: 1.25rem;
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1rem;
}
.zakat-note i { color: var(--accent); margin-top: 0.15rem; }
@media (max-width: 900px) {
    .continue-row,
    .feature-grid,
    .progress-hero,
    .zakat-grid,
    .quick-tools-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 767px) {
    .hide-mobile { display: none !important; }
    .show-mobile { display: inline-flex !important; }
    .top-header {
        padding: 0.85rem 0.9rem;
        gap: 0.65rem;
    }
    .header-left {
        min-width: 0;
        flex: 1;
    }
    .top-header .brand {
        min-width: 0;
        font-size: 1.05rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .home-pro-hero {
        padding: 1.35rem 1rem 1.1rem;
        border-radius: 24px;
    }
    .bismillah-header {
        font-size: 1rem;
    }
    .home-pro-hero h1 {
        font-size: 2.1rem;
    }
    .global-search-container {
        padding: 0.85rem 0.95rem;
        gap: 0.7rem;
        flex-wrap: wrap;
    }
    .search-hint {
        width: 100%;
        font-size: 0.78rem;
    }
    .continue-card, .compact-stat { flex-direction: column; align-items: flex-start; }
    .prayer-strip {
        display: grid;
        grid-template-columns: 1fr;
    }
    .prayer-item {
        width: 100%;
    }
    .zakat-form-grid { grid-template-columns: 1fr; }
    .event-item { align-items: flex-start; flex-direction: column; }
    .header-hijri-pill { display: none; }
    .search-drawer-overlay { padding: 0.75rem; }
    .search-drawer-container {
        height: calc(100vh - 1.5rem);
        max-width: 100%;
        border-radius: 20px;
    }
    .search-drawer-header {
        padding: 1rem;
        align-items: stretch;
    }
    .search-input-wrapper {
        padding: 0.75rem 0.95rem;
    }
    #drawerSearchInput {
        font-size: 1rem;
    }
    .search-close-btn {
        padding: 0.75rem 0.95rem;
    }
    .mini-player-toggle { bottom: calc(118px + env(safe-area-inset-bottom, 0px)); }
    .nq-audio-player { bottom: calc(70px + env(safe-area-inset-bottom, 0px)); }
}

/* ─── Auth pages (login / register) ─── */
.auth-page {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem 4rem;
    background:
        radial-gradient(ellipse 80% 60% at 50% -20%, rgba(16, 185, 129, 0.18), transparent 55%),
        radial-gradient(ellipse 60% 40% at 100% 50%, rgba(59, 130, 246, 0.08), transparent 50%);
}
.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 2rem 1.75rem;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}
.auth-card-wide { max-width: 460px; }
.auth-card-head { margin-bottom: 1.5rem; text-align: center; }
.auth-card-head h1 {
    font-size: 1.65rem;
    font-weight: 700;
    margin: 0.75rem 0 0.35rem;
    color: var(--text-main);
}
.auth-card-head p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.45;
}
.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--accent);
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.25);
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius-pill);
}
.auth-alert {
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    margin-bottom: 1.1rem;
    text-align: center;
}
.auth-alert-error {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
}
.auth-alert-success {
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent);
    border: 1px solid rgba(16, 185, 129, 0.25);
}
.auth-form { display: flex; flex-direction: column; gap: 1rem; }
.auth-field { display: flex; flex-direction: column; gap: 0.4rem; }
.auth-field span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
}
.auth-field input {
    width: 100%;
    padding: 0.75rem 0.95rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-main);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition);
}
.auth-field input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}
.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.85rem;
    color: var(--text-dim);
    cursor: pointer;
    user-select: none;
}
.auth-check input { margin-top: 0.2rem; accent-color: var(--accent); }
.auth-submit { width: 100%; justify-content: center; margin-top: 0.25rem; padding: 0.75rem 1rem; }
.auth-divider {
    display: flex; align-items: center; gap: 1rem;
    margin: 1.25rem 0; color: var(--text-muted); font-size: 0.8rem;
}
.auth-divider::before, .auth-divider::after {
    content: ''; flex: 1; height: 1px; background: var(--border-color);
}
.auth-google {
    width: 100%;
    justify-content: center;
    background: #1a73e8;
    color: #fff;
    text-decoration: none;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    gap: 0.55rem;
    transition: var(--transition);
}
.auth-google:hover { background: #1557b0; color: #fff; }
.auth-footer-links {
    margin-top: 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
    font-size: 0.9rem;
}
.auth-footer-links a { color: var(--accent); text-decoration: none; font-weight: 500; }
.auth-footer-links a:hover { text-decoration: underline; }
.auth-back { margin-top: 1.25rem; text-align: center; font-size: 0.9rem; }
.auth-back a { color: var(--accent); text-decoration: none; display: inline-flex; align-items: center; gap: 0.45rem; }
.auth-back a:hover { text-decoration: underline; }

/* ─── User dashboard ─── */
.user-dashboard-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.25rem;
    margin-bottom: 1.75rem;
    padding: 1.5rem 1.75rem;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.14), rgba(15, 23, 42, 0.6));
    border: 1px solid var(--border-color);
}
.dash-kicker {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
    font-weight: 600;
    margin: 0 0 0.35rem;
}
.user-dashboard-hero h1 {
    margin: 0;
    font-size: 1.85rem;
    font-weight: 700;
    color: var(--text-main);
}
.dash-sub { margin: 0.35rem 0 0; color: var(--text-dim); font-size: 0.95rem; }
.dash-hero-actions { display: flex; flex-wrap: wrap; gap: 0.65rem; }
.user-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1rem;
    margin-bottom: 1.25rem;
}
.dash-stat-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.25rem;
}
.dash-stat-icon {
    width: 48px; height: 48px;
    border-radius: 14px;
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.dash-stat-card h3 { margin: 0; font-size: 1.65rem; font-weight: 700; color: var(--text-main); }
.dash-stat-card p { margin: 0.2rem 0 0.5rem; font-size: 0.88rem; color: var(--text-dim); }
.dash-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.dash-link:hover { text-decoration: underline; }
.dash-hint { font-size: 0.78rem; color: var(--text-muted); display: block; margin-top: 0.25rem; }
.dash-prefs-card { padding: 1.35rem 1.5rem; margin-bottom: 2rem; }
.user-dashboard-page .dash-prefs-card { margin-bottom: 0; }
.dash-dl {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 0.65rem 1rem;
    font-size: 0.9rem;
    margin: 0;
}
.dash-dl dt { color: var(--text-muted); font-weight: 600; margin: 0; }
.dash-dl dd { margin: 0; color: var(--text-main); }
.dash-muted { color: var(--text-muted); }

.user-dashboard-page {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    min-height: calc(100vh - 65px - 3.5rem);
    box-sizing: border-box;
}

.dash-quick-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 11rem;
    padding: 1.15rem 1.25rem 1.35rem;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    background: linear-gradient(165deg, rgba(16, 185, 129, 0.06), rgba(15, 23, 42, 0.35));
}
.dash-quick-head {
    margin-bottom: 1rem;
}
.dash-quick-head h2 {
    margin: 0 0 0.25rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.45rem;
}
.dash-quick-head .sub-text { font-size: 0.82rem; color: var(--text-dim); }
.dash-quick-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.65rem;
    align-content: start;
}
.dash-quick-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 1rem 0.75rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: var(--surface-color);
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    transition: var(--transition);
}
.dash-quick-tile i {
    font-size: 1.35rem;
    color: var(--accent);
}
.dash-quick-tile:hover {
    border-color: var(--accent);
    background: rgba(16, 185, 129, 0.08);
    color: var(--accent);
    transform: translateY(-2px);
}

.dash-daily-card {
    padding: 1.35rem 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    background: linear-gradient(165deg, rgba(16, 185, 129, 0.07), var(--surface-color));
}
.dash-daily-head {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.1rem;
}
.dash-daily-head h2 {
    margin: 0 0 0.35rem;
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}
.dash-daily-sub {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-dim);
    max-width: 36rem;
    line-height: 1.45;
}
.dash-daily-score {
    text-align: right;
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.15);
}
.dash-daily-score span {
    display: block;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1.1;
}
.dash-daily-score small {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.dash-daily-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.dash-daily-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
    padding: 0.65rem 0.85rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: var(--bg-color);
}
.dash-daily-check {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    cursor: pointer;
    flex: 1;
    min-width: 0;
    margin: 0;
}
.dash-daily-check input {
    width: 1.1rem;
    height: 1.1rem;
    accent-color: var(--accent);
    flex-shrink: 0;
}
.dash-daily-title {
    font-weight: 600;
    font-size: 0.92rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--text-main);
}
.dash-daily-link {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    white-space: nowrap;
}
.dash-daily-link:hover {
    text-decoration: underline;
}
.dash-spotlight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1rem;
    margin-bottom: 1.25rem;
}
.dash-spot-card {
    padding: 1.15rem 1.25rem;
}
.dash-spot-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    color: var(--accent);
    display: block;
    margin-bottom: 0.35rem;
}
.dash-spot-card h3 {
    margin: 0 0 0.5rem;
    font-size: 1rem;
    line-height: 1.3;
}
.dash-spot-snippet {
    margin: 0 0 0.75rem;
    font-size: 0.85rem;
    color: var(--text-dim);
    line-height: 1.5;
}

@media (max-width: 520px) {
    .dash-dl { grid-template-columns: 1fr; }
    .user-dashboard-hero { flex-direction: column; align-items: flex-start; }
    .user-dashboard-page { min-height: auto; }
}


/* ════════════════════════════════════════════════════════════════
   PROFESSIONAL AUTH PAGES (Login / Register / Forgot / Reset)
   App-like on mobile, split-screen on desktop
   ════════════════════════════════════════════════════════════════ */

/* Material Symbols base sizing helper */
.material-symbols-rounded, .material-icons, .material-icons-outlined, .material-icons-round {
    font-size: 1.1em;
    vertical-align: middle;
    line-height: 1;
    font-variation-settings: 'FILL' 0, 'wght' 500, 'GRAD' 0, 'opsz' 24;
}
.mi-filled { font-variation-settings: 'FILL' 1, 'wght' 500, 'GRAD' 0, 'opsz' 24; }

/* ─── Professional Auth Redesign ─── */
.auth-pro-wrap {
    min-height: calc(100vh - 60px);
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    background: var(--bg-color);
    position: relative;
    overflow: hidden;
}

/* Hero/brand panel (left on desktop) */
.auth-pro-hero {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 3rem 3rem;
    color: #fff;
    overflow: hidden;
    background:
        radial-gradient(ellipse 90% 70% at 20% 10%, rgba(16, 185, 129, 0.35), transparent 55%),
        radial-gradient(ellipse 80% 60% at 90% 100%, rgba(59, 130, 246, 0.25), transparent 55%),
        linear-gradient(135deg, #0b1628 0%, #0f172a 50%, #111f36 100%);
    isolation: isolate;
}
.auth-pro-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 25% 30%, rgba(255,255,255,0.04) 0, transparent 2px),
        radial-gradient(circle at 75% 70%, rgba(255,255,255,0.04) 0, transparent 2px);
    background-size: 60px 60px, 40px 40px;
    opacity: 0.6;
    pointer-events: none;
}
.auth-pro-hero::after {
    content: "";
    position: absolute;
    inset: auto -120px -120px auto;
    width: 380px; height: 380px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(16,185,129,0.28), transparent 70%);
    filter: blur(20px);
    pointer-events: none;
    z-index: 0;
}
.auth-pro-hero-inner { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 2rem; max-width: 500px; }

.auth-pro-logo {
    display: inline-flex; align-items: center; gap: 0.75rem;
    font-size: 1.25rem; font-weight: 700; color: #fff;
}
.auth-pro-logo-icon {
    width: 44px; height: 44px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 10px 25px rgba(16,185,129,0.45);
    color: #fff;
    font-size: 1.4rem;
}

.auth-pro-tagline {
    font-family: var(--font-arabic);
    font-size: 2rem;
    color: rgba(255,255,255,0.92);
    letter-spacing: 0.02em;
    text-align: center;
    line-height: 1.6;
    padding: 0.5rem 0;
}

.auth-pro-headline {
    font-size: clamp(1.9rem, 3.5vw, 2.6rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.6rem;
}
.auth-pro-sub {
    color: rgba(255,255,255,0.72);
    font-size: 1.02rem;
    line-height: 1.7;
    max-width: 440px;
}

.auth-pro-features {
    display: flex; flex-direction: column; gap: 0.9rem;
    margin-top: 1.5rem;
}
.auth-pro-feat {
    display: flex; align-items: center; gap: 0.9rem;
    color: rgba(255,255,255,0.86);
    font-size: 0.95rem;
}
.auth-pro-feat-ic {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: rgba(16,185,129,0.15);
    color: #34d399;
    display: inline-flex; align-items: center; justify-content: center;
    flex: 0 0 36px;
    border: 1px solid rgba(16,185,129,0.25);
}
.auth-pro-feat-ic .material-symbols-rounded { font-size: 20px; }

.auth-pro-foot {
    position: relative; z-index: 1;
    color: rgba(255,255,255,0.45);
    font-size: 0.8rem;
}

/* Form panel (right on desktop) */
.auth-pro-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: var(--bg-color);
    position: relative;
}
.auth-pro-card {
    width: 100%;
    max-width: 440px;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 2.25rem 2rem;
    box-shadow: 0 30px 60px -20px rgba(0,0,0,0.45);
    animation: authFadeUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes authFadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

.auth-pro-card-head {
    margin-bottom: 1.6rem;
    text-align: left;
}
.auth-pro-eyebrow {
    display: inline-flex; align-items: center; gap: 0.4rem;
    font-size: 0.72rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--accent);
    background: var(--accent-glow);
    border: 1px solid rgba(16,185,129,0.25);
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    margin-bottom: 0.9rem;
}
.auth-pro-eyebrow .material-symbols-rounded { font-size: 14px; }
.auth-pro-card-head h1 {
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-main);
    margin-bottom: 0.4rem;
}
.auth-pro-card-head p {
    font-size: 0.93rem;
    color: var(--text-muted);
    line-height: 1.55;
    margin: 0;
}

/* Alerts */
.auth-pro-alert {
    display: flex; align-items: flex-start; gap: 0.6rem;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    font-size: 0.9rem;
    margin-bottom: 1.15rem;
    line-height: 1.45;
}
.auth-pro-alert .material-symbols-rounded { font-size: 20px; flex: 0 0 20px; margin-top: 1px; }
.auth-pro-alert--error {
    background: rgba(239,68,68,0.10);
    color: #fca5a5;
    border: 1px solid rgba(239,68,68,0.28);
}
.auth-pro-alert--success {
    background: rgba(16,185,129,0.10);
    color: #6ee7b7;
    border: 1px solid rgba(16,185,129,0.28);
}

/* Form */
.auth-pro-form { display: flex; flex-direction: column; gap: 1rem; }

.auth-pro-field { display: flex; flex-direction: column; gap: 0.4rem; }
.auth-pro-field > span {
    font-size: 0.82rem; font-weight: 600;
    color: var(--text-muted);
    display: inline-flex; align-items: center; gap: 0.4rem;
}
.auth-pro-field > span .material-symbols-rounded { font-size: 16px; color: var(--accent); }

.auth-pro-input-wrap {
    position: relative;
    display: flex; align-items: center;
    background: var(--bg-color);
    border: 1.5px solid var(--border-color);
    border-radius: 14px;
    transition: var(--transition);
}
.auth-pro-input-wrap:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
}
.auth-pro-input-wrap .material-symbols-rounded.auth-pro-input-ic {
    position: absolute; left: 0.9rem;
    color: var(--text-dim); font-size: 20px;
    pointer-events: none;
    transition: var(--transition);
}
.auth-pro-input-wrap:focus-within .auth-pro-input-ic { color: var(--accent); }
.auth-pro-input-wrap input {
    width: 100%;
    padding: 0.85rem 0.95rem 0.85rem 2.7rem;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-main);
    font-size: 0.97rem;
    font-family: inherit;
    border-radius: 14px;
}
.auth-pro-input-wrap input::placeholder { color: var(--text-dim); }

.auth-pro-input-wrap .auth-pro-toggle {
    position: absolute; right: 0.4rem;
    background: transparent; border: none;
    color: var(--text-dim);
    width: 36px; height: 36px;
    border-radius: 10px;
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer; transition: var(--transition);
}
.auth-pro-input-wrap .auth-pro-toggle:hover { color: var(--accent); background: var(--accent-glow); }
.auth-pro-input-wrap .auth-pro-toggle .material-symbols-rounded { font-size: 20px; }
.auth-pro-input-wrap input[type="password"] + .auth-pro-toggle,
.auth-pro-input-wrap input[type="text"] + .auth-pro-toggle {
    /* toggle always visible when present */
}
.auth-pro-input-wrap.has-toggle input { padding-right: 3rem; }

/* Password strength bar */
.auth-pro-strength {
    display: flex; gap: 4px; margin-top: 4px;
}
.auth-pro-strength span {
    flex: 1; height: 4px; border-radius: 2px;
    background: var(--border-color);
    transition: background 0.3s;
}
.auth-pro-strength[data-level="1"] span:nth-child(-n+1) { background: #ef4444; }
.auth-pro-strength[data-level="2"] span:nth-child(-n+2) { background: #f59e0b; }
.auth-pro-strength[data-level="3"] span:nth-child(-n+3) { background: #10b981; }
.auth-pro-strength[data-level="4"] span { background: #10b981; }
.auth-pro-strength-lbl {
    font-size: 0.75rem; margin-top: 4px; color: var(--text-dim);
}

/* Row: remember + forgot */
.auth-pro-row {
    display: flex; align-items: center; justify-content: space-between;
    gap: 0.75rem; flex-wrap: wrap;
    margin: 0.25rem 0;
}
.auth-pro-check {
    display: flex; align-items: center; gap: 0.5rem;
    font-size: 0.86rem;
    color: var(--text-muted);
    cursor: pointer; user-select: none;
}
.auth-pro-check input {
    appearance: none; -webkit-appearance: none;
    width: 18px; height: 18px;
    border: 1.5px solid var(--border-color);
    background: var(--bg-color);
    border-radius: 5px;
    cursor: pointer;
    position: relative;
    transition: var(--transition);
    flex: 0 0 18px;
}
.auth-pro-check input:checked {
    background: var(--accent);
    border-color: var(--accent);
}
.auth-pro-check input:checked::after {
    content: "";
    position: absolute;
    left: 4px; top: 1px;
    width: 5px; height: 9px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.auth-pro-inline-link {
    font-size: 0.86rem; color: var(--accent);
    text-decoration: none; font-weight: 600;
}
.auth-pro-inline-link:hover { text-decoration: underline; }

/* Primary submit */
.auth-pro-submit {
    width: 100%;
    padding: 0.9rem 1.2rem;
    border-radius: 14px;
    border: none;
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    color: #fff;
    font-weight: 600;
    font-size: 1rem;
    display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem;
    cursor: pointer;
    transition: 0.25s ease;
    box-shadow: 0 10px 25px -5px var(--accent-glow);
    margin-top: 0.35rem;
}
.auth-pro-submit:hover { transform: translateY(-1px); box-shadow: 0 15px 30px -5px rgba(16,185,129,0.35); }
.auth-pro-submit:active { transform: translateY(0); }
.auth-pro-submit .material-symbols-rounded { font-size: 20px; }

/* Divider */
.auth-pro-divider {
    display: flex; align-items: center; gap: 1rem;
    margin: 1.4rem 0;
    color: var(--text-dim);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.auth-pro-divider::before, .auth-pro-divider::after {
    content: ""; flex: 1; height: 1px; background: var(--border-color);
}

/* Google button */
.auth-pro-google {
    width: 100%;
    padding: 0.85rem 1.2rem;
    border-radius: 14px;
    background: var(--bg-color);
    border: 1.5px solid var(--border-color);
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex; align-items: center; justify-content: center; gap: 0.7rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}
.auth-pro-google:hover {
    border-color: var(--accent);
    background: var(--surface-hover);
    color: var(--text-main);
    transform: translateY(-1px);
}
.auth-pro-google svg { width: 20px; height: 20px; flex: 0 0 20px; }

/* Footer area */
.auth-pro-foot-links {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.92rem;
    color: var(--text-muted);
}
.auth-pro-foot-links a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}
.auth-pro-foot-links a:hover { text-decoration: underline; }

.auth-pro-back {
    display: inline-flex; align-items: center; gap: 0.4rem;
    color: var(--accent);
    font-size: 0.9rem; font-weight: 600;
    text-decoration: none;
    margin-top: 1.25rem;
}
.auth-pro-back:hover { gap: 0.6rem; }
.auth-pro-back .material-symbols-rounded { font-size: 18px; }

/* ─── Mobile app-like look ─── */
@media (max-width: 900px) {
    .auth-pro-wrap {
        grid-template-columns: 1fr;
        min-height: 100vh;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .auth-pro-hero {
        display: none !important; /* Hide hero card on mobile as requested */
    }
    .auth-pro-panel {
        padding: 1.5rem 1rem;
        width: 100%;
    }
    .auth-pro-card {
        padding: 2rem 1.5rem;
        border-radius: 22px;
        margin-top: 0;
        box-shadow: none;
        background: transparent;
        border: none;
    }
    .auth-pro-card-head h1 { font-size: 1.6rem; }
}
@media (max-width: 480px) {
    .auth-pro-hero { padding: 1.75rem 1.25rem 1.25rem; min-height: 200px; }
    .auth-pro-logo { font-size: 1.1rem; }
    .auth-pro-logo-icon { width: 38px; height: 38px; font-size: 1.2rem; }
    .auth-pro-card { padding: 1.5rem 1.15rem; border-radius: 20px; }
    .auth-pro-card-head h1 { font-size: 1.35rem; }
    .auth-pro-card-head p { font-size: 0.88rem; }
}

/* ════════════════════════════════════════════════════════════════
   PROFESSIONAL DIGITAL TASBIH — compact, app-like, mobile-first
   ════════════════════════════════════════════════════════════════ */
.tasbih-pro-wrap {
    max-width: 860px;
    margin: 0 auto;
    padding: 0.5rem 0.25rem 1rem;
}

.tasbih-pro-head {
    text-align: center;
    margin-bottom: 1.25rem;
}
.tasbih-pro-eyebrow {
    display: inline-flex; align-items: center; gap: 0.4rem;
    font-size: 0.7rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--accent);
    background: var(--accent-glow);
    border: 1px solid rgba(16,185,129,0.22);
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    margin-bottom: 0.5rem;
}
.tasbih-pro-eyebrow .material-symbols-rounded { font-size: 14px; }
.tasbih-pro-head h1 {
    font-size: clamp(1.3rem, 4vw, 1.7rem);
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0 0 0.25rem;
    background: linear-gradient(135deg, var(--accent), #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.tasbih-pro-head p {
    color: var(--text-dim);
    font-size: 0.92rem;
    margin: 0;
}

.tasbih-pro-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1.25rem;
    align-items: start;
}

.tasbih-pro-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 22px;
    padding: 1.5rem 1.25rem;
    box-shadow: 0 10px 30px -15px rgba(0,0,0,0.35);
}

/* Counter card */
.tasbih-pro-counter {
    position: relative;
    display: flex; flex-direction: column; align-items: center;
    background:
        radial-gradient(ellipse at center, var(--accent-glow), transparent 70%),
        var(--surface-color);
    padding: 1.5rem 1rem 1.75rem;
}

.tasbih-pro-current {
    display: flex; align-items: center; justify-content: space-between;
    width: 100%;
    margin-bottom: 0.9rem;
    padding: 0 0.25rem;
}
.tasbih-pro-dhikr {
    display: flex; flex-direction: column; gap: 0.15rem;
}
.tasbih-pro-dhikr-ar {
    font-family: var(--font-arabic);
    font-size: 1.25rem;
    color: var(--text-main);
    line-height: 1.1;
    direction: rtl;
    text-align: right;
}
.tasbih-pro-dhikr-en {
    font-size: 0.78rem;
    color: var(--text-dim);
    font-weight: 600;
    letter-spacing: 0.02em;
}
.tasbih-pro-target-pill {
    display: inline-flex; align-items: center; gap: 0.35rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 600;
}
.tasbih-pro-target-pill .material-symbols-rounded { font-size: 15px; color: var(--accent); }

/* Ring + big button */
.tasbih-pro-ring {
    position: relative;
    width: 240px; height: 240px;
    display: flex; align-items: center; justify-content: center;
    margin: 0.5rem 0 1rem;
}
.tasbih-pro-ring svg {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    transform: rotate(-90deg);
}
.tasbih-pro-ring .t-track {
    stroke: var(--border-color);
    stroke-width: 8;
    fill: none;
}
.tasbih-pro-ring .t-progress {
    stroke: var(--accent);
    stroke-width: 8;
    fill: none;
    stroke-linecap: round;
    stroke-dasharray: 628.3;   /* 2*pi*100 */
    stroke-dashoffset: 628.3;
    transition: stroke-dashoffset 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    filter: drop-shadow(0 0 6px var(--accent-glow));
}

.tasbih-pro-tap {
    width: 190px; height: 190px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(145deg, var(--surface-hover), var(--bg-color));
    color: var(--accent);
    cursor: pointer;
    position: relative;
    z-index: 1;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    box-shadow:
        inset 0 2px 6px rgba(255,255,255,0.04),
        inset 0 -6px 14px rgba(0,0,0,0.25),
        0 18px 35px -10px rgba(0,0,0,0.5);
    transition: transform 0.12s cubic-bezier(0.4,0,0.2,1), box-shadow 0.2s;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.tasbih-pro-tap:active {
    transform: scale(0.96);
    box-shadow:
        inset 0 2px 10px rgba(0,0,0,0.35),
        0 5px 15px -5px var(--accent-glow);
}
.tasbih-pro-tap.is-pulse::before {
    content: "";
    position: absolute; inset: -4px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    animation: tasbihPulse 0.55s ease-out;
    pointer-events: none;
}
@keyframes tasbihPulse {
    0% { opacity: 1; transform: scale(0.95); }
    100% { opacity: 0; transform: scale(1.15); }
}
.tasbih-pro-count {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    text-shadow: 0 2px 14px var(--accent-glow);
}
.tasbih-pro-of {
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-top: 0.3rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.tasbih-pro-hint {
    font-size: 0.72rem;
    color: var(--text-dim);
    margin-top: 0.25rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tasbih-pro-ctrls {
    display: flex; gap: 0.6rem;
    margin-top: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
}
.tasbih-pro-ctrl {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 0.55rem 1rem;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.82rem; font-weight: 600;
    display: inline-flex; align-items: center; gap: 0.4rem;
    transition: var(--transition);
}
.tasbih-pro-ctrl:hover { color: var(--accent); border-color: var(--accent); background: var(--accent-glow); }
.tasbih-pro-ctrl.is-on { color: var(--accent); border-color: rgba(16,185,129,0.4); background: var(--accent-glow); }
.tasbih-pro-ctrl .material-symbols-rounded { font-size: 17px; }

/* Azkar side card */
.tasbih-pro-side-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 0.9rem;
}
.tasbih-pro-side-head h3 {
    font-size: 1rem; font-weight: 700; color: var(--text-main);
    display: inline-flex; align-items: center; gap: 0.5rem;
    margin: 0;
}
.tasbih-pro-side-head h3 .material-symbols-rounded { color: var(--accent); font-size: 20px; }
.tasbih-pro-side-count {
    font-size: 0.72rem; color: var(--text-dim);
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    padding: 0.25rem 0.6rem; border-radius: 999px;
    font-weight: 600;
}

.tasbih-pro-list { display: flex; flex-direction: column; gap: 0.55rem; }
.tasbih-pro-item {
    display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
    background: var(--bg-color);
    border: 1.5px solid var(--border-color);
    padding: 0.8rem 0.9rem;
    border-radius: 14px;
    cursor: pointer;
    transition: var(--transition);
    text-align: right;
}
.tasbih-pro-item:hover { border-color: var(--accent); background: var(--accent-glow); }
.tasbih-pro-item.is-active {
    border-color: var(--accent);
    background: linear-gradient(90deg, var(--accent-glow), transparent);
}
.tasbih-pro-item .tp-item-main {
    display: flex; flex-direction: column; gap: 0.15rem;
    align-items: flex-end;
    flex: 1; min-width: 0;
}
.tasbih-pro-item .tp-item-ar {
    font-family: var(--font-arabic);
    font-size: 1.25rem;
    line-height: 1.2;
    color: var(--text-main);
    direction: rtl;
}
.tasbih-pro-item .tp-item-en {
    font-size: 0.78rem; color: var(--text-dim);
    font-weight: 600;
}
.tasbih-pro-item .tp-item-meta {
    display: inline-flex; align-items: center; gap: 0.3rem;
    flex: 0 0 auto;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
    background: var(--surface-color);
    padding: 0.25rem 0.55rem;
    border-radius: 999px;
    border: 1px solid var(--border-color);
}
.tasbih-pro-item.is-active .tp-item-meta {
    color: var(--accent);
    border-color: rgba(16,185,129,0.35);
    background: var(--accent-glow);
}
.tasbih-pro-item .tp-item-check {
    color: var(--accent);
    font-size: 18px;
    margin-left: 0.25rem;
    opacity: 0;
    transition: 0.2s;
}
.tasbih-pro-item.is-active .tp-item-check { opacity: 1; }

/* Responsive: mobile app feel */
@media (max-width: 860px) {
    .tasbih-pro-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .tasbih-pro-ring { width: 210px; height: 210px; }
    .tasbih-pro-tap { width: 168px; height: 168px; }
    .tasbih-pro-count { font-size: 3rem; }
}
@media (max-width: 480px) {
    .tasbih-pro-wrap { padding: 0.25rem 0 1rem; }
    .tasbih-pro-card { border-radius: 18px; padding: 1.15rem 0.95rem; }
    .tasbih-pro-counter { padding: 1.1rem 0.75rem 1.4rem; }
    .tasbih-pro-ring { width: 190px; height: 190px; margin: 0.25rem 0 0.85rem; }
    .tasbih-pro-tap { width: 150px; height: 150px; }
    .tasbih-pro-count { font-size: 2.6rem; }
    .tasbih-pro-of { font-size: 0.78rem; }
    .tasbih-pro-dhikr-ar { font-size: 1.1rem; }
    .tasbih-pro-ctrl { padding: 0.5rem 0.85rem; font-size: 0.78rem; }
    .tasbih-pro-item { padding: 0.7rem 0.8rem; border-radius: 12px; }
    .tasbih-pro-item .tp-item-ar { font-size: 1.1rem; }
}
