        :root { 
            --bg-color: #f0f4f8; 
            --primary-color: #1a5f7a; 
            --secondary-color: #0e8388; 
            --accent-color: #ff9800;
            --text-color: #222; 
            --header-height: 52px;
            --ticker-height: 38px;
        }
        *, *::before, *::after { box-sizing: border-box; }

        /* 🆕 ACCESSIBILITY: screen-reader-only utility + skip link + focus visibility */
        .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
        .skip-link { position: absolute; left: 8px; top: -60px; background: #ffffff; color: var(--primary-color); padding: 10px 18px; border-radius: 6px; font-weight: bold; z-index: 1000000; transition: top 0.2s ease; box-shadow: 0 4px 10px rgba(0,0,0,0.25); }
        .skip-link:focus { top: 8px; }
        button:focus-visible, a:focus-visible, .header-title:focus-visible, .day-summary:focus-visible, .offset-summary:focus-visible {
            outline: 3px solid var(--accent-color);
            outline-offset: 2px;
        }
        input:focus-visible, select:focus-visible {
            outline: none;
            box-shadow: 0 0 0 3px rgba(26, 95, 122, 0.35);
        }

        html, body { 
            width: 100%; 
            min-height: 100vh; 
            margin: 0; 
            padding: 0; 
            -webkit-text-size-adjust: 100%; 
            text-size-adjust: 100%; 
        }
        body { 
            font-family: 'Rasa', 'Nirmala UI', 'Shruti', serif; 
            background-color: var(--bg-color); 
            color: var(--text-color); 
            display: flex; 
            flex-direction: column; 
            overflow-x: hidden; 
        }
        
        /* App Main Header */
        .app-header { background: linear-gradient(135deg, var(--primary-color), #0f4357); color: white; padding: 12px 18px; display: flex; flex-wrap: nowrap; justify-content: space-between; align-items: center; box-shadow: 0 2px 5px rgba(0,0,0,0.1); width: 100%; position: sticky; top: 0; z-index: 100; }
        .header-title { font-size: 22px; font-weight: bold; display: flex; align-items: center; gap: 8px; cursor: pointer; min-width: 0; flex-shrink: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
        .header-buttons { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }
        .nav-btn { padding: 6px 12px; min-height: 36px; border: none; border-radius: 6px; font-weight: bold; cursor: pointer; font-family: inherit; font-size: 14px; transition: 0.2s; display: flex; align-items: center; gap: 4px; }
        .btn-refresh { background-color: #ffffff; color: var(--primary-color); }
        .btn-refresh:hover { background-color: #e0e0e0; }
        .btn-logout { background-color: #d32f2f; color: white; }
        .btn-logout:hover { background-color: #b71c1c; }

        /* 🌈 કલરફુલ ન્યૂઝ ટીકર (હેડરની નીચે, મેનુ બારની ઉપર) */
        .colorful-ticker {
            position: sticky;
            top: var(--header-height);
            z-index: 98;
            width: 100%;
            height: var(--ticker-height);
            overflow: hidden;
            display: flex;
            align-items: center;
            /* 🆕 સ્ક્રોલ ફ્લિકર ટાળવા સ્ટેટિક ગ્રેડિયન્ટ (background-position એનિમેશન દર ફ્રેમે repaint કરાવે છે,
               જે sticky + scroll સાથે ભળીને જન્ક/ફ્લિકર પેદા કરતું હતું) */
            background: linear-gradient(90deg, #ff512f, #f09819, #ff9800, #1a5f7a, #0e8388, #ff512f);
            box-shadow: 0 2px 6px rgba(0,0,0,0.15);
        }
        .ticker-track {
            display: flex;
            flex-shrink: 0;
            width: max-content;
            white-space: nowrap;
            animation: tickerScroll 24s linear infinite;
            will-change: transform;
        }
        @keyframes tickerScroll {
            0% { transform: translateX(0); }
            100% { transform: translateX(-50%); }
        }
        .colorful-ticker:hover .ticker-track { animation-play-state: paused; }
        .ticker-content {
            display: flex;
            flex-shrink: 0;
            align-items: center;
            gap: 12px;
            white-space: nowrap;
            padding: 0 30px 0 15px;
            font-size: 15px;
            font-weight: 700;
            color: #ffffff;
            text-shadow: 0 1px 2px rgba(0,0,0,0.3);
        }
        .ticker-welcome { color: #fffde7; }
        .ticker-sep { color: #ffe082; font-size: 12px; }
        .ticker-msg { color: #ffffff; }
        .ticker-wa-badge {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            background: #25D366;
            color: #ffffff !important;
            padding: 3px 10px;
            border-radius: 14px;
            font-weight: 800;
            text-decoration: none;
            margin: 0 4px;
            box-shadow: 0 2px 4px rgba(0,0,0,0.25);
            text-shadow: none;
        }
        .ticker-wa-badge:hover { background: #1eb956; }
        @media (max-width: 600px) {
            .ticker-content { font-size: 13px; gap: 8px; padding: 0 20px 0 10px; }
        }
        @media (max-width: 480px) {
            :root { --ticker-height: 32px; }
            .ticker-content { font-size: 12px; }
        }

        /* Sub-Header Navigation Bar */
        .sub-header-bar { 
            background: #0f4357; 
            padding: 6px 10px; 
            display: flex; 
            justify-content: center; 
            gap: 8px; 
            flex-wrap: wrap; 
            box-shadow: 0 3px 6px rgba(0,0,0,0.1);
            position: sticky;
            top: calc(var(--header-height) + var(--ticker-height));
            z-index: 99;
        }
        .sub-nav-btn { 
            background: rgba(255,255,255,0.12); 
            color: #ffffff; 
            border: 1px solid rgba(255,255,255,0.25); 
            padding: 5px 12px; 
            min-height: 36px;
            border-radius: 20px; 
            font-size: 14px; 
            font-weight: 700; 
            cursor: pointer; 
            font-family: inherit; 
            transition: 0.2s; 
            text-decoration: none; 
            display: flex; 
            align-items: center; 
            gap: 5px; 
        }
        .sub-nav-btn:hover, .sub-nav-btn.active { 
            background: #ffffff; 
            color: var(--primary-color); 
            border-color: #ffffff; 
        }
        .sub-nav-admin { 
            background: #ff9800 !important; 
            border-color: #f57c00 !important; 
            color: white !important; 
        }
        .sub-nav-admin:hover, .sub-nav-admin.active { 
            background: #e65100 !important; 
            color: white !important; 
        }

        .page-top-nav { display: flex; justify-content: space-between; align-items: center; background: white; padding: 12px 16px; border-radius: 10px; box-shadow: 0 2px 6px rgba(0,0,0,0.06); margin-bottom: 15px; border-left: 5px solid var(--primary-color); }
        .btn-back-home { background: var(--primary-color); color: white; border: none; padding: 8px 16px; border-radius: 6px; font-size: 15px; font-weight: bold; cursor: pointer; font-family: inherit; display: flex; align-items: center; gap: 6px; transition: 0.2s; }
        .btn-back-home:hover { background: #0f4357; }
        .page-nav-title { font-size: 18px; font-weight: bold; color: var(--primary-color); margin: 0; }

        /* Main Container - Desktop Full Width Fix */
        .main-container { padding: 15px 15px; max-width: 900px; margin: 0 auto; width: 100%; flex: 1 0 auto; transition: max-width 0.3s; }
        @media (min-width: 1024px) {
            .main-container { max-width: 1400px !important; }
        }

        .controls-card { background: white; padding: 20px; border-radius: 12px; box-shadow: 0 4px 14px rgba(0,0,0,0.06); margin-bottom: 20px; border-top: 4px solid var(--primary-color); }
        
        .segment-container { display: flex; background: #e2e8f0; border-radius: 30px; padding: 4px; max-width: 380px; margin: 0 auto 18px auto; }
        .segment-btn { flex: 1; padding: 8px 12px; min-height: 44px; border: none; background: transparent; font-size: 16px; font-weight: 700; font-family: inherit; color: #475569; border-radius: 25px; cursor: pointer; transition: 0.2s; text-align: center; }
        .segment-btn.active { background: var(--primary-color); color: white; box-shadow: 0 2px 6px rgba(0,0,0,0.15); }

        .input-group { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; justify-content: center; }
        .date-field { display: flex; flex-direction: column; text-align: left; }
        .date-field label { font-size: 15px; font-weight: 700; color: #475569; margin-bottom: 4px; }
        input[type="date"], input[type="text"], input[type="number"], select { padding: 10px 14px; border: 1.5px solid #cbd5e1; border-radius: 6px; font-size: 16px; font-weight: 700; font-family: inherit; outline: none; transition: 0.2s; }
        input:focus, select:focus { border-color: var(--primary-color); }

        /* 🆕 હોમ પેજ કંટ્રોલ્સ — ટેબ + તારીખ + PDF બટન + ઝૂમ એક જ લાઈનમાં (ટેબલ માટે વધુ જગ્યા) */
        .home-controls-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; }
        .home-controls-row .segment-container { margin: 0; max-width: 230px; flex: 0 1 auto; }
        .home-controls-row .segment-btn { min-height: 38px; padding: 6px 10px; font-size: 14px; white-space: nowrap; }
        .home-controls-row .date-field { flex-direction: row; align-items: center; gap: 6px; }
        .home-controls-row .date-field label { margin-bottom: 0; font-size: 13px; white-space: nowrap; }
        .home-controls-row input[type="date"] { padding: 7px 10px; font-size: 14px; max-width: 150px; }
        .home-controls-row button.main-btn.compact-btn { flex: 0 0 auto; padding: 8px 14px; min-height: 38px; font-size: 13px; }
        #mainForm.controls-card { padding: 12px; margin-bottom: 12px; }
        .action-btns { display: contents; } /* 🆕 wrapper ને layout માંથી પારદર્શક બનાવ્યું જેથી બંને બટન સરખા flex item તરીકે વર્તે */
        button.main-btn { padding: 12px 28px; min-height: 44px; border: none; border-radius: 8px; font-size: 17px; cursor: pointer; font-weight: 700; transition: 0.2s; font-family: inherit; color: white; display: flex; align-items: center; justify-content: center; gap: 8px; }
        button.main-btn.compact-btn { padding: 6px 4px; min-height: 34px; font-size: 12px; gap: 3px; flex: 1 1 0; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .btn-search { background-color: var(--secondary-color); } .btn-search:hover { background-color: #0b686c; }
        .btn-pdf { background-color: #d32f2f; box-shadow: 0 3px 8px rgba(211,47,47,0.3); } .btn-pdf:hover { background-color: #9a0007; }
        .btn-save { background-color: #2e7d32; width: 100%; margin-top: 15px; font-size: 18px; justify-content: center; }
        .loading { text-align: center; font-size: 18px; color: var(--primary-color); display: none; font-weight: bold; margin: 20px 0; }
        .empty-message { text-align: center; font-size: 18px; color: #dc2626; margin: 20px 0; font-weight: 700; background: #fef2f2; padding: 12px; border-radius: 8px; border: 1px solid #fecaca; }
        .success-message { text-align: center; font-size: 17px; color: #166534; font-weight: 700; margin-top: 10px; background: #f0fdf4; padding: 10px; border-radius: 6px; border: 1px solid #bbf7d0; }
        .hidden { display: none !important; }

        .settings-box { margin-bottom: 18px; background: #f8fafc; padding: 16px; border-radius: 8px; border: 1px solid #e2e8f0; }
        .settings-box label { font-weight: bold; color: var(--primary-color); display: block; margin-bottom: 5px; font-size: 15px; }
        .settings-box input[type="text"], .settings-box input[type="date"], .settings-box select { width: 100%; margin-bottom: 10px; }

        .offset-accordion { margin-bottom: 10px; background: white; border: 1.5px solid #cbd5e1; border-radius: 8px; overflow: hidden; transition: 0.2s; }
        .offset-accordion[open] { border-color: var(--secondary-color); box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
        .offset-summary { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; font-size: 16px; font-weight: bold; color: var(--primary-color); background: #ffffff; cursor: pointer; outline: none; user-select: none; }
        .offset-summary:hover { background: #f8fafc; }
        .offset-summary-left { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
        
        .offset-badge { font-size: 12px; font-weight: bold; padding: 3px 8px; border-radius: 12px; }
        .badge-normal { background: #f1f5f9; color: #475569; border: 1px solid #cbd5e1; }
        .badge-modified { background: #fff7ed; color: #c2410c; border: 1px solid #fdba74; }
        .btn-offset-badge { background: var(--secondary-color); color: white; font-size: 12px; padding: 3px 10px; border-radius: 12px; pointer-events: none; }
        .offset-content { padding: 12px; background: #f8fafc; border-top: 1px solid #e2e8f0; display: flex; flex-wrap: wrap; gap: 10px; }
        .offset-item { background: #ffffff; padding: 8px 12px; border-radius: 6px; border: 1px solid #cbd5e1; width: 48%; min-width: 220px; display: flex; justify-content: space-between; align-items: center; }

        .day-accordion { margin-bottom: 10px; background: white; border: 1.5px solid #cbd5e1; border-radius: 8px; overflow: hidden; transition: 0.2s; }
        .day-accordion[open] { border-color: var(--primary-color); box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
        .day-summary { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; font-size: 16px; font-weight: bold; color: var(--primary-color); background: #ffffff; cursor: pointer; outline: none; user-select: none; }
        .day-summary:hover { background: #f8fafc; }
        .day-summary-left { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
        
        .day-status-badge { font-size: 12px; font-weight: bold; padding: 3px 8px; border-radius: 12px; }
        .badge-incomplete { background: #fff3e0; color: #e65100; border: 1px solid #ffb74d; }
        .badge-complete { background: #e8f5e9; color: #2e7d32; border: 1px solid #81c784; }
        .btn-edit-badge { background: var(--secondary-color); color: white; font-size: 12px; padding: 3px 10px; border-radius: 12px; pointer-events: none; }
        .day-content { padding: 14px; background: #f8fafc; border-top: 1px solid #e2e8f0; }

        .period-row { display: flex; gap: 6px; align-items: center; margin-bottom: 10px; justify-content: space-between; flex-wrap: nowrap; }
        .period-lbl { font-weight: bold; min-width: 48px; font-size: 14px; color: #334155; flex-shrink: 0; }
        .period-row select { padding: 6px 4px; min-height: 38px; border-radius: 4px; border: 1px solid #cbd5e1; font-family: inherit; font-size: 14px; font-weight: bold; width: 31%; min-width: 0; }

        #adminArea { background: #f8fafc; padding: 16px; border-radius: 10px; border: 2px solid #ff9800; }
        .admin-stats-row { display: flex; gap: 10px; margin-bottom: 15px; flex-wrap: wrap; }
        .adm-stat { flex: 1; min-width: 110px; background: white; padding: 10px; border-radius: 8px; border: 1px solid #cbd5e1; text-align: center; box-shadow: 0 1px 3px rgba(0,0,0,0.05); box-sizing: border-box; }
        .adm-stat h4 { margin: 0 0 4px 0; font-size: 13px; color: #64748b; font-weight: bold; }
        .adm-stat p { margin: 0; font-size: 22px; font-weight: bold; color: var(--primary-color); }
        
        .adm-scroll-hint { display: none; font-size: 13px; color: #ea580c; text-align: center; margin-bottom: 8px; font-weight: bold; background: #fff7ed; padding: 5px; border-radius: 4px; border: 1px solid #fed7aa; }
        @media (max-width: 768px) { .adm-scroll-hint { display: block; } }

        .adm-table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; background: #ffffff; border-radius: 8px; border: 1px solid #cbd5e1; box-shadow: 0 2px 6px rgba(0,0,0,0.05); margin-top: 10px; }
        table.adm-table { width: 100% !important; min-width: 650px !important; border-collapse: collapse !important; font-size: 15px !important; table-layout: auto !important; background: #ffffff !important; margin: 0 !important; }
        table.adm-table th, table.adm-table td { border: 1px solid #e2e8f0 !important; padding: 10px 12px !important; vertical-align: middle !important; font-size: 15px !important; line-height: 1.4 !important; white-space: normal !important; word-break: normal !important; color: #1e293b !important; text-align: left !important; }
        table.adm-table th { background-color: var(--primary-color) !important; color: #ffffff !important; font-weight: bold !important; font-size: 15px !important; padding: 12px !important; white-space: nowrap !important; }
        table.adm-table tr:hover { background-color: #f1f5f9 !important; }
        
        .badge-pro { background-color: #dcfce7 !important; color: #15803d !important; padding: 5px 12px !important; border-radius: 15px !important; font-weight: bold; border: 1px solid #86efac !important; font-size: 12px !important; white-space: nowrap !important; display: inline-block !important; }
        .badge-free { background-color: #fee2e2 !important; color: #b91c1c !important; padding: 5px 12px !important; border-radius: 15px !important; font-weight: bold; border: 1px solid #fca5a5 !important; font-size: 12px !important; white-space: nowrap !important; display: inline-block !important; }
        .btn-toggle-pay { background-color: #0288d1 !important; color: #ffffff !important; border: none !important; padding: 6px 12px !important; border-radius: 6px !important; font-size: 13px !important; font-weight: bold !important; cursor: pointer !important; white-space: nowrap !important; display: inline-block !important; }
        .btn-toggle-pay:hover { background-color: #01579b !important; }
        .btn-toggle-pay.is-free-btn { background-color: #dc2626 !important; }

        /* 📋 રોજનીશી પ્રીવ્યુ ટેબલ */
        .preview-wrapper { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 20px; box-sizing: border-box; }
        /* scale/height હવે JS (updateMobilePreviewLayout) થી દરેક સ્ક્રીન પર exact ગણાય — નીચે ખાલી જગ્યા રહેતી નથી */
        .preview-scale { transform-origin: top left; }
        /* 🧩 Sizer: transform scale layout box ને નાનો ન કરે એટલે scroll area exact રાખવા — container absolute, sizer નું size JS થી scaled size જેટલું */
        #previewSizer { position: relative; overflow: hidden; }
        #multiPageContainer { position: absolute; top: 0; left: 0; display: flex; flex-direction: column; gap: 40px; align-items: flex-start; width: 3200px; }
        #multiPageContainer:empty { display: none !important; }

        /* 🔍 મોબાઈલ પ્રિવ્યૂ ઝૂમ નિયંત્રણ બટન (હવે quick-actions-row માં અન્ય બટનો સાથે એક જ લાઈનમાં) */
        .preview-zoom-controls {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 1px;
            background: #ffffff;
            border: 1px solid #cbd5e1;
            border-radius: 16px;
            padding: 2px;
            width: max-content;
            flex: 0 0 auto;
            box-shadow: 0 2px 6px rgba(0,0,0,0.08);
        }
        .zoom-btn {
            background: var(--primary-color);
            color: #fff;
            border: none;
            border-radius: 12px;
            min-width: 20px;
            min-height: 30px;
            font-size: 10px;
            font-weight: bold;
            cursor: pointer;
            font-family: inherit;
            padding: 3px 4px;
        }
        .zoom-btn:hover { background: #0f4357; }
        .zoom-reset-btn { min-width: 30px; background: #64748b; }
        .zoom-reset-btn:hover { background: #475569; }
        
        .print-area { width: 3200px; height: max-content; background: white; padding: 40px 15px 30px 15px; box-shadow: 0 4px 15px rgba(0,0,0,0.15); display: flex; flex-direction: column; border: 2px solid #ddd; page-break-after: always; }
        .header-container { display: flex; justify-content: space-between; align-items: center; margin-bottom: 25px; padding: 0 25px; }
        .logo-section { width: 140px; display: flex; justify-content: flex-start; }
        .round-logo { width: 120px; height: 120px; background-color: var(--primary-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 4px solid white; outline: 3px solid var(--primary-color); }
        .logo-spacer { width: 140px; }
        .school-header { text-align: center; flex-grow: 1; }
        .school-header h1 { margin: 0; font-size: 75px; color: var(--primary-color); font-weight: 700; }
        .address-dise { font-size: 38px; font-weight: 700; color: #444; margin: 10px 0 0 0; }
        .info-row { display: flex; justify-content: space-between; font-size: 42px; font-weight: 700; margin-bottom: 25px; border-bottom: 5px solid var(--primary-color); padding-bottom: 12px; padding-left: 25px; padding-right: 25px; color: var(--primary-color); }
        .info-row span { color: #222; }
        
        .print-area table { width: 100%; border-collapse: collapse; font-size: 36px; table-layout: fixed; } 
        .print-area th:nth-child(1), .print-area td:nth-child(1) { width: 4%; text-align: center; } 
        .print-area th:nth-child(2), .print-area td:nth-child(2) { width: 5.5%; text-align: center; } 
        .print-area th:nth-child(3), .print-area td:nth-child(3) { width: 9.5%; text-align: center; } 
        .print-area th:nth-child(4), .print-area td:nth-child(4) { width: 10%; } 
        .print-area th:nth-child(5), .print-area td:nth-child(5) { width: 11%; } 
        .print-area th:nth-child(6), .print-area td:nth-child(6) { width: 10%; } 
        .print-area th:nth-child(7), .print-area td:nth-child(7) { width: 26%; } 
        .print-area th:nth-child(8), .print-area td:nth-child(8) { width: 12%; } 
        .print-area th:nth-child(9), .print-area td:nth-child(9) { width: 12%; }
        
        .print-area td[contenteditable="true"]:focus { background-color: #fff9c4 !important; outline: 3px dashed var(--primary-color); }
        .print-area th, .print-area td { border: 3px solid #444; padding: 16px 12px; vertical-align: top; line-height: 1.35; font-weight: 700; word-break: break-word; overflow-wrap: break-word; white-space: pre-wrap; }
        .print-area th { background-color: var(--primary-color); color: white; text-align: center; font-size: 38px; padding: 22px 10px; }
        .sub-gujarati { background-color: #E1F5FE; } .sub-maths { background-color: #E8F5E9; } .sub-evs { background-color: #FFF9C4; } .sub-english { background-color: #F3E5F5; } .sub-hindi { background-color: #FFE0B2; } .sub-sanskrit { background-color: #FCE4EC; } .sub-other { background-color: #F5F5F5; }
        .signature-row { display: flex; justify-content: space-between; font-size: 45px; font-weight: 700; padding: 20px 25px 10px 25px; margin-top: 15px; }
        
        @media (max-width: 600px) {
            .main-container { max-width: 100%; padding: 10px; overflow: hidden; }
            .preview-wrapper { overflow: auto; -webkit-overflow-scrolling: touch; padding-bottom: 0; }
            button.main-btn:not(.compact-btn) { width: 100%; justify-content: center; }
            .home-controls-row { gap: 6px; }
            .home-controls-row .segment-container { max-width: 100%; }
            .home-controls-row input[type="date"] { max-width: 135px; }
            .admin-stats-row { gap: 8px; }
            .adm-stat { min-width: calc(50% - 4px); flex: 0 0 calc(50% - 4px); }
            .period-row { gap: 4px; }
            .period-lbl { min-width: 40px; font-size: 13px; }
            .period-row select { font-size: 13px; padding: 6px 2px; }
        }

        /* 📱 નાના મોબાઈલ સ્ક્રીન (≤480px) માટે હેડર/બટન કોમ્પેક્ટ ગોઠવણ */
        @media (max-width: 480px) {
            :root { --header-height: 46px; }
            .app-header { padding: 8px 10px; }
            .header-title { font-size: 15px; gap: 5px; }
            .header-buttons { gap: 5px; }
            .nav-btn { padding: 5px 8px; font-size: 11px; min-height: 32px; }
            .sub-header-bar { padding: 5px 6px; gap: 6px; }
            .sub-nav-btn { padding: 5px 10px; font-size: 13px; }
            .page-top-nav { flex-wrap: wrap; gap: 8px; padding: 10px 12px; }
            .page-nav-title { font-size: 16px; }
            .btn-back-home { font-size: 13px; padding: 7px 12px; }
            .segment-container { max-width: 100%; }
            .segment-btn { font-size: 14px; padding: 8px 6px; }
            .adm-stat { min-width: 100%; flex: 0 0 100%; }
        }
        
        input[type="date"] { position: relative; color: transparent !important; }
        input[type="date"]::before { content: attr(data-date); position: absolute; left: 14px; color: #222; font-family: inherit; top: 50%; transform: translateY(-50%); font-size: 16px; pointer-events: none; }
        input[type="date"]::-webkit-calendar-picker-indicator { position: absolute; top: 0; left: 0; right: 0; bottom: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }

        /* 📄 PDF Portrait Mode (ફક્ત html2canvas ના અદ્રશ્ય ક્લોન પર જ લાગુ થાય છે, લાઈવ પેજ પર નહીં) */
        .pdf-portrait-mode * {
            max-height: 1000000px !important;
            -webkit-text-size-adjust: 100% !important;
            text-size-adjust: 100% !important;
        }

        .pdf-portrait-mode .print-area { 
            width: 1400px !important; 
            max-width: 1400px !important; 
            min-height: 1980px !important; 
            height: auto !important;
            max-height: none !important;
            background: white !important; 
            color: black !important; 
            padding: 40px 35px 35px 35px !important; 
            border: none !important; 
            box-shadow: none !important; 
            display: flex !important;
            flex-direction: column !important;
            justify-content: space-between !important;
            box-sizing: border-box !important;
            page-break-after: always !important;
            overflow: visible !important;
        }
        .pdf-portrait-mode .logo-section, .pdf-portrait-mode .logo-spacer { display: none !important; }
        .pdf-portrait-mode .school-header { text-align: center !important; width: 100% !important; }
        .pdf-portrait-mode .school-header h1 { font-size: 44px !important; color: black !important; margin: 0 0 8px 0 !important; font-weight: 800 !important; }
        .pdf-portrait-mode .address-dise { font-size: 25px !important; color: #222 !important; margin: 0 !important; font-weight: 700 !important; }
        .pdf-portrait-mode .info-row { font-size: 26px !important; color: black !important; border-bottom: 4px solid black !important; padding: 10px 5px !important; margin-bottom: 16px !important; display: flex !important; justify-content: space-between !important; }
        .pdf-portrait-mode .info-row span { color: black !important; font-weight: 800 !important; }
        .pdf-portrait-mode .table-container { width: 100% !important; flex-grow: 1 !important; display: flex !important; }
        .pdf-portrait-mode .print-area table { width: 100% !important; border-collapse: collapse !important; font-size: 22px !important; table-layout: fixed !important; height: 100% !important; }
        .pdf-portrait-mode .print-area th, .pdf-portrait-mode .print-area td { border: 2.5px solid black !important; padding: 10px 8px !important; color: black !important; background-color: white !important; font-weight: 700 !important; vertical-align: middle !important; line-height: 1.35 !important; word-break: break-word !important; overflow-wrap: break-word !important; }
        .pdf-portrait-mode .print-area th { background-color: #f2f2f2 !important; font-size: 24px !important; font-weight: 800 !important; text-align: center !important; padding: 12px 6px !important; }
        
        .pdf-portrait-mode .print-area th:nth-child(1), .pdf-portrait-mode .print-area td:nth-child(1) { width: 4% !important; text-align: center; font-weight: 800; } 
        .pdf-portrait-mode .print-area th:nth-child(2), .pdf-portrait-mode .print-area td:nth-child(2) { width: 5.5% !important; text-align: center; font-weight: 800; } 
        .pdf-portrait-mode .print-area th:nth-child(3), .pdf-portrait-mode .print-area td:nth-child(3) { width: 9.5% !important; text-align: center; font-weight: 800; } 
        .pdf-portrait-mode .print-area th:nth-child(4), .pdf-portrait-mode .print-area td:nth-child(4) { width: 10% !important; } 
        .pdf-portrait-mode .print-area th:nth-child(5), .pdf-portrait-mode .print-area td:nth-child(5) { width: 11% !important; } 
        .pdf-portrait-mode .print-area th:nth-child(6), .pdf-portrait-mode .print-area td:nth-child(6) { width: 10% !important; } 
        .pdf-portrait-mode .print-area th:nth-child(7), .pdf-portrait-mode .print-area td:nth-child(7) { width: 26% !important; } 
        .pdf-portrait-mode .print-area th:nth-child(8), .pdf-portrait-mode .print-area td:nth-child(8) { width: 12% !important; } 
        .pdf-portrait-mode .print-area th:nth-child(9), .pdf-portrait-mode .print-area td:nth-child(9) { width: 12% !important; }

        .pdf-portrait-mode .signature-row { font-size: 26px !important; font-weight: 800 !important; padding: 20px 10px 10px 10px !important; margin-top: auto !important; display: flex !important; justify-content: space-between !important; }

        .modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.75); z-index: 2000; justify-content: center; align-items: center; display: flex; backdrop-filter: blur(3px); }
        .modal-box { background: white; padding: 0; border-radius: 16px; width: 92%; max-width: 420px; text-align: center; box-shadow: 0 10px 25px rgba(0,0,0,0.3); overflow: hidden; animation: popIn 0.3s ease-out; }
        @keyframes popIn { from { transform: scale(0.85); opacity: 0; } to { transform: scale(1); opacity: 1; } }

        .modal-header-banner { background: linear-gradient(135deg, var(--primary-color), #0e8388); color: white; padding: 20px 15px; }
        .modal-header-banner h2 { margin: 0; font-size: 24px; }
        .modal-body { padding: 20px; }
        .modal-desc { font-size: 16px; color: #444; line-height: 1.5; margin-bottom: 18px; }
        .contact-card-box { background: #f4fbfb; border: 1.5px dashed #0e8388; border-radius: 10px; padding: 12px; margin-bottom: 18px; }
        .btn-contact { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 12px; border: none; border-radius: 8px; font-size: 16px; font-weight: bold; cursor: pointer; text-decoration: none; font-family: inherit; margin-bottom: 10px; transition: 0.2s; color: white; box-shadow: 0 2px 5px rgba(0,0,0,0.15); }
        .btn-wa { background: #25D366; } .btn-wa:hover { background: #1eb956; }
        .btn-call { background: #0288d1; } .btn-call:hover { background: #01579b; }
        .btn-close-modal { background: #757575; color: white; padding: 8px; border: none; border-radius: 6px; font-size: 14px; font-weight: bold; width: 100%; cursor: pointer; margin-top: 5px; }

        /* 🦶 ફૂટર CSS */
        .app-footer { 
            background: linear-gradient(135deg, var(--primary-color), #0f4357) !important; 
            color: #ffffff !important; 
            text-align: center !important; 
            padding: 22px 15px !important; 
            margin-top: 40px !important; 
            width: 100% !important; 
            box-sizing: border-box !important; 
            border-top: 3px solid rgba(255,255,255,0.2) !important; 
            clear: both !important;
            display: block !important;
        }
        .app-footer p { margin: 4px 0 !important; font-size: 15px !important; font-weight: bold !important; color: #ffffff !important; text-align: center !important; }
        .app-footer a { color: #ffffff !important; text-decoration: underline !important; }

        /* ================================================================
           🆕 LOADING OVERLAY - Reusable Component
           ================================================================ */
        .loading-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.85);
            z-index: 9999999;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            color: #fff;
            font-family: 'Rasa', 'Segoe UI', sans-serif;
            opacity: 0;
            visibility: hidden;
            transition: opacity 0.3s ease, visibility 0.3s ease;
        }

        .loading-overlay.active {
            opacity: 1;
            visibility: visible;
        }

        .loading-box {
            background: linear-gradient(135deg, #1a5f7a, #0f4357);
            padding: 35px 55px;
            border-radius: 24px;
            text-align: center;
            box-shadow: 0 25px 70px rgba(0, 0, 0, 0.6);
            border: 2px solid rgba(255, 152, 0, 0.4);
            animation: loadingPulse 1.5s ease-in-out infinite;
            max-width: 90%;
            min-width: 280px;
        }

        @keyframes loadingPulse {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.02); }
        }

        .loading-icon {
            font-size: 55px;
            color: #ff9800;
            margin-bottom: 18px;
            display: block;
            animation: loadingBounce 1.2s ease-in-out infinite;
        }

        @keyframes loadingBounce {
            0%, 100% { transform: translateY(0); }
            50% { transform: translateY(-10px); }
        }

        .loading-title {
            font-size: 24px;
            font-weight: 700;
            margin-bottom: 8px;
            color: #ffffff;
            letter-spacing: 0.5px;
        }

        .loading-subtitle {
            font-size: 15px;
            opacity: 0.85;
            color: #e2e8f0;
            margin-bottom: 20px;
        }

        .loading-spinner {
            width: 45px;
            height: 45px;
            border: 4px solid rgba(255, 255, 255, 0.15);
            border-top-color: #ff9800;
            border-radius: 50%;
            animation: loadingSpin 0.9s linear infinite;
            margin: 0 auto;
        }

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

        .loading-progress {
            width: 200px;
            height: 6px;
            background: rgba(255, 255, 255, 0.15);
            border-radius: 10px;
            overflow: hidden;
            margin: 15px auto 0;
        }

        .loading-progress-bar {
            height: 100%;
            width: 40%;
            background: linear-gradient(90deg, #ff9800, #f39c12);
            border-radius: 10px;
            animation: loadingProgress 1.5s ease-in-out infinite;
        }

        .loading-progress-bar.determinate {
            width: 0%;
            animation: none;
            transition: width 0.25s ease;
        }

        .loading-progress-text {
            font-size: 13px;
            color: #e2e8f0;
            margin-top: 6px;
            font-weight: 700;
        }

        @keyframes loadingProgress {
            0% { margin-left: -40%; }
            100% { margin-left: 100%; }
        }

        @media (max-width: 600px) {
            .loading-box { padding: 25px 35px; }
            .loading-icon { font-size: 45px; }
            .loading-title { font-size: 20px; }
            .loading-subtitle { font-size: 14px; }
        }

        /* ================================================================
           🆕 DOWNLOAD SUCCESS TOAST
           ================================================================ */
        .download-toast {
            position: fixed;
            bottom: 25px;
            right: 20px;
            background: linear-gradient(135deg, #2e7d32, #1b5e20);
            color: #fff;
            padding: 16px 20px;
            border-radius: 12px;
            box-shadow: 0 10px 30px rgba(0,0,0,0.35);
            display: flex;
            align-items: center;
            gap: 12px;
            z-index: 999999999;
            max-width: 340px;
            opacity: 0;
            visibility: hidden;
            transform: translateY(20px);
            transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
        }
        .download-toast.show { opacity: 1; visibility: visible; transform: translateY(0); }
        .toast-icon { font-size: 32px; color: #a5d6a7; flex-shrink: 0; }
        .toast-text { line-height: 1.35; }
        .toast-title { font-weight: 700; font-size: 16px; }
        .toast-sub { font-size: 13px; opacity: 0.9; margin-top: 2px; word-break: break-all; }

        @media (max-width: 600px) {
            .download-toast { left: 15px; right: 15px; bottom: 15px; max-width: none; }
        }
/* ================================================================
   🆕 SUPER ADMIN PANEL — Action Buttons + Edit Inputs + Profile Modal
   ================================================================ */

/* 🎯 Table Action Buttons */
.adm-act-btn {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 14px;
    cursor: pointer;
    margin: 0 2px;
    transition: 0.15s;
    display: inline-block;
    line-height: 1;
    font-family: inherit;
}
.adm-act-btn:hover { background: #e2e8f0; transform: translateY(-1px); }
.adm-act-btn:active { transform: translateY(0); }

.btn-view-adm   { background: #e0f2fe; border-color: #7dd3fc; }
.btn-view-adm:hover { background: #bae6fd; }

.btn-edit-adm   { background: #fff7ed; border-color: #fdba74; }
.btn-edit-adm:hover { background: #fed7aa; }

.btn-pay-adm    { background: #dcfce7; border-color: #86efac; }
.btn-pay-adm.is-free { background: #fee2e2; border-color: #fca5a5; }
.btn-pay-adm:hover { opacity: 0.85; }

.btn-del-adm    { background: #fee2e2; border-color: #fca5a5; }
.btn-del-adm:hover { background: #fecaca; }

.btn-save-adm   { background: #dcfce7; border-color: #22c55e; font-size: 15px; }
.btn-save-adm:hover { background: #bbf7d0; }

.btn-cancel-adm { background: #f1f5f9; border-color: #94a3b8; }
.btn-cancel-adm:hover { background: #e2e8f0; }

/* 🎯 Inline Edit Inputs */
.adm-edit-input {
    width: 100%;
    padding: 6px 8px !important;
    border: 1.5px solid #6366f1 !important;
    border-radius: 4px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    margin: 0 !important;
    background: #f5f3ff !important;
    font-family: inherit !important;
    box-sizing: border-box !important;
}
.adm-edit-input:focus {
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25) !important;
}

.adm-email { color: #666; font-size: 12px; display: block; margin-top: 2px; }

/* 🎯 User Profile Modal */
.prof-row {
    display: flex;
    gap: 10px;
    padding: 7px 0;
    align-items: flex-start;
    border-bottom: 1px dashed #f1f5f9;
}
.prof-row:last-child { border-bottom: none; }
.prof-lbl {
    font-weight: bold;
    color: #1a5f7a;
    min-width: 110px;
    font-size: 14px;
    flex-shrink: 0;
}
.prof-val {
    color: #222;
    font-size: 14px;
    font-weight: 600;
    flex: 1;
    word-break: break-word;
    line-height: 1.5;
}

@media (max-width: 480px) {
    .prof-lbl { min-width: 90px; font-size: 13px; }
    .prof-val { font-size: 13px; }
    .adm-act-btn { padding: 5px 6px; font-size: 13px; margin: 0 1px; }
}
/* ================================================================
   🆕 CHAPTER PICKER UI
   ================================================================ */
.chapter-picker-item {
    flex-direction: column !important;
    align-items: stretch !important;
    width: 100% !important;
    min-width: 300px !important;
    padding: 12px 14px !important;
    background: #ffffff !important;
    border-radius: 8px !important;
    border: 1px solid #cbd5e1 !important;
    margin-bottom: 10px !important;
}

.chapter-picker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px dashed #e2e8f0;
}

.chapter-subject-name {
    font-weight: bold;
    font-size: 15px;
    color: #1a5f7a;
}

.offset-preview-badge {
    font-size: 12px;
    font-weight: bold;
    padding: 3px 10px;
    border-radius: 12px;
}

.chapter-picker-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.chapter-picker-label {
    font-weight: bold;
    font-size: 13px;
    color: #475569;
    min-width: 60px;
    flex-shrink: 0;
}

.chapter-select {
    flex: 1;
    padding: 8px 10px !important;
    border: 1.5px solid #cbd5e1 !important;
    border-radius: 6px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    background: #f8fafc !important;
    font-family: inherit !important;
    cursor: pointer !important;
    color: #222 !important;
}

.chapter-select:focus {
    outline: none !important;
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 3px rgba(26, 95, 122, 0.15) !important;
}

.auto-offset-info {
    background: #f0fdf4;
    border-left: 3px solid #22c55e;
    border-radius: 6px;
    padding: 8px 12px;
    margin-top: 6px;
    font-size: 12px;
}

.auto-offset-detail {
    display: flex;
    flex-direction: column;
    gap: 3px;
    color: #166534;
}

.auto-calc-line {
    font-size: 11px;
    color: #475569;
}

@media (max-width: 600px) {
    .chapter-picker-row {
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
    }
    .chapter-picker-label {
        min-width: auto;
    }
    .chapter-picker-item {
        min-width: 100% !important;
    }
}
/* ================================================================
   🆕 ADMIN TAB BAR
   ================================================================ */
.admin-tab-bar {
    display: flex;
    gap: 6px;
    background: #f1f5f9;
    padding: 6px;
    border-radius: 10px;
    margin-bottom: 15px;
}
.adm-tab-btn {
    flex: 1;
    padding: 10px 12px;
    border: none;
    background: transparent;
    border-radius: 8px;
    font-weight: bold;
    font-size: 14px;
    cursor: pointer;
    font-family: inherit;
    color: #475569;
    transition: 0.2s;
}
.adm-tab-btn:hover { background: #e2e8f0; }
.adm-tab-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

/* 🆕 MASTER DATA */
.master-filter-box {
    background: #f8fafc;
    padding: 14px;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    margin-bottom: 12px;
}
.master-stats-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff7ed;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid #fdba74;
    margin-bottom: 12px;
    font-weight: bold;
    color: #9a3412;
    flex-wrap: wrap;
    gap: 10px;
}
.btn-danger-action {
    background: #dc2626;
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
}
.btn-danger-action:hover { background: #991b1b; }

.master-upload-box {
    background: #f0fdf4;
    padding: 16px;
    border-radius: 8px;
    border: 1.5px dashed #86efac;
    margin-top: 15px;
    text-align: center;
}
.master-upload-box h4 {
    margin: 0 0 12px 0;
    color: #166534;
    font-size: 15px;
}
.master-upload-box code {
    background: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    color: #166534;
}

@media (max-width: 600px) {
    .adm-tab-btn { font-size: 12px; padding: 8px 6px; }
    .master-filter-box > div > div { min-width: 100% !important; }
    .master-stats-row { font-size: 13px; }
}
/* ================================================================
   🆕 CSV EXPORT / IMPORT BOXES
   ================================================================ */
.master-csv-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin: 15px 0;
}

.csv-action-box {
    background: #eff6ff;
    border: 1.5px solid #93c5fd;
    border-radius: 10px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.csv-action-title {
    font-weight: bold;
    color: #1e40af;
    font-size: 15px;
}

.csv-action-desc {
    font-size: 12px;
    color: #475569;
    line-height: 1.4;
    margin-bottom: 6px;
}

.csv-action-box .main-btn {
    width: 100%;
    justify-content: center;
    font-weight: bold;
}

@media (max-width: 600px) {
    .master-csv-actions {
        grid-template-columns: 1fr;
    }
}
/* ================================================================
   🚨 DANGER ZONE
   ================================================================ */
.danger-zone {
    background: #fef2f2;
    border: 2px dashed #dc2626;
    border-radius: 10px;
    padding: 16px;
    margin: 15px 0;
}

.danger-zone-title {
    font-weight: bold;
    color: #991b1b;
    font-size: 16px;
    margin-bottom: 6px;
}

.danger-zone-desc {
    font-size: 13px;
    color: #7f1d1d;
    line-height: 1.5;
    margin-bottom: 12px;
}

.btn-danger-large {
    width: 100%;
    background: #dc2626;
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    transition: 0.2s;
    box-shadow: 0 3px 8px rgba(220, 38, 38, 0.3);
}
.btn-danger-large:hover {
    background: #991b1b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.4);
}
.btn-danger-large:active {
    transform: translateY(0);
}
/* ================================================================
   🆕 PRIVACY POLICY — In-App Styling
   ================================================================ */
.privacy-lang-toggle {
    display: flex;
    justify-content: center;
    gap: 4px;
    background: #e2e8f0;
    border-radius: 30px;
    padding: 4px;
    max-width: 260px;
    margin: 0 auto 20px auto;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.priv-lang-btn {
    flex: 1;
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 25px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    color: #475569;
    cursor: pointer;
    transition: 0.25s;
}

.priv-lang-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.privacy-main-title {
    color: var(--primary-color);
    font-size: 22px;
    margin: 0 0 6px 0;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--accent-color);
    font-weight: 700;
}

.privacy-updated {
    font-size: 13px;
    color: #64748b;
    font-weight: 700;
    margin: 0 0 18px 0;
}

.privacy-intro {
    background: #f0f9ff;
    border-left: 4px solid var(--secondary-color);
    padding: 12px 16px;
    border-radius: 0 8px 8px 0;
    font-size: 15px;
    color: #334155;
    line-height: 1.6;
    margin-bottom: 20px;
}

.privacy-h3 {
    color: #e65100;
    font-size: 16px;
    margin: 22px 0 8px 0;
    padding-left: 10px;
    border-left: 3px solid var(--accent-color);
    font-weight: 700;
}

#privacyArea p {
    font-size: 14.5px;
    color: #334155;
    line-height: 1.65;
    margin: 0 0 10px 0;
}

#privacyArea ul {
    padding-left: 22px;
    margin: 8px 0 12px 0;
}

#privacyArea li {
    font-size: 14.5px;
    color: #334155;
    line-height: 1.6;
    margin-bottom: 5px;
}

.privacy-contact-card {
    background: linear-gradient(135deg, #f8fafc, #f0f9ff);
    border: 1.5px solid #cbd5e1;
    border-radius: 12px;
    padding: 14px;
    margin-top: 12px;
}

.privacy-contact-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px dashed #e2e8f0;
}

.privacy-contact-row:last-child { border-bottom: none; }

.privacy-contact-row > span {
    width: 34px;
    height: 34px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 15px;
}

.privacy-contact-label {
    font-size: 11px;
    color: #64748b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.privacy-contact-value {
    font-size: 14px;
    color: #1e293b;
    font-weight: 600;
    word-break: break-word;
}

.privacy-contact-value a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
}

.privacy-contact-value a:hover { text-decoration: underline; }

@media (max-width: 480px) {
    .privacy-main-title { font-size: 19px; }
    .privacy-h3 { font-size: 15px; }
    #privacyArea p, #privacyArea li { font-size: 13.5px; }
    .privacy-contact-row > span { width: 30px; height: 30px; font-size: 13px; }
}
/* ================================================================
   🔄 OFFSET RESET + HISTORY + TOAST
   ================================================================ */
.offset-icon-btn {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 14px;
    cursor: pointer;
    transition: 0.15s;
    line-height: 1;
    font-family: inherit;
}
.offset-icon-btn:hover { background: #e2e8f0; transform: translateY(-1px); }
.offset-icon-btn:active { transform: translateY(0); }

.offset-reset-std-btn {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
    border-radius: 6px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    transition: 0.2s;
}
.offset-reset-std-btn:hover { background: #fecaca; }

/* 🆕 Toast Notification */
.offset-toast {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    color: white;
    padding: 14px 22px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    z-index: 9999999;
    max-width: 90%;
    min-width: 280px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}
.offset-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 480px) {
    .offset-toast { min-width: auto; max-width: 95%; font-size: 13px; }
    .offset-reset-std-btn { font-size: 11px; padding: 4px 8px; }
}
/* 🆕 Undo/Back buttons */
.undo-quick-btn {
    background: #ea580c;
    color: white;
    border: none;
    padding: 8px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    width: 100%;
    transition: 0.2s;
}
.undo-quick-btn:hover { background: #c2410c; }

.revert-entry-btn {
    background: #0288d1;
    color: white;
    border: none;
    padding: 6px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    font-size: 12px;
    width: 100%;
    margin-top: 8px;
    transition: 0.2s;
}
.revert-entry-btn:hover { background: #01579b; }
/* ================================================================
   🆕 HOLIDAY BLANK PAGE
   ================================================================ */
.holiday-page {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.holiday-blank-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 40px;
    background: linear-gradient(135deg, #fff9e6, #fff3cd);
    border: 4px dashed #f0ad4e;
    border-radius: 20px;
    margin: 20px 25px;
}

.holiday-icon {
    font-size: 120px;
    line-height: 1;
    margin-bottom: 20px;
}

.holiday-text-main {
    font-size: 90px;
    font-weight: 900;
    color: #c62828;
    letter-spacing: 4px;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.holiday-text-sub {
    font-size: 42px;
    font-weight: 700;
    color: #78350f;
    margin-bottom: 15px;
}

.holiday-text-note {
    font-size: 32px;
    font-weight: 600;
    color: #92400e;
    font-style: italic;
}

/* PDF Portrait Mode */
.pdf-portrait-mode .holiday-blank-body {
    padding: 100px 60px;
    margin: 30px 40px;
    border: 5px dashed #f0ad4e;
    border-radius: 30px;
}

.pdf-portrait-mode .holiday-icon {
    font-size: 180px;
    margin-bottom: 40px;
}

.pdf-portrait-mode .holiday-text-main {
    font-size: 140px;
    margin-bottom: 40px;
}

.pdf-portrait-mode .holiday-text-sub {
    font-size: 60px;
    margin-bottom: 25px;
}

.pdf-portrait-mode .holiday-text-note {
    font-size: 48px;
}

/* Mobile */
@media (max-width: 600px) {
    .holiday-icon { font-size: 70px; }
    .holiday-text-main { font-size: 50px; }
    .holiday-text-sub { font-size: 22px; }
    .holiday-text-note { font-size: 16px; }
    .holiday-blank-body { padding: 30px 20px; margin: 10px; }
}
/* ================================================================
   🆕 TICKER ADMIN MESSAGE
   ================================================================ */
.ticker-admin-msg {
    color: #fffde7;
    font-weight: 800;
    padding: 0 8px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* ================================================================
   🔔 POPUP NOTIFY MESSAGE (Colorful animated gradient text)
   ================================================================ */
.popup-notify-message {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.6;
    text-align: center;
    word-break: break-word;
    white-space: pre-wrap;
    background: linear-gradient(90deg, #ff512f, #dd2476, #7b2ff7, #0e8388, #2e7d32, #ff512f);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    animation: popupColorShift 6s linear infinite;
}

@keyframes popupColorShift {
    0% { background-position: 0% 50%; }
    100% { background-position: 300% 50%; }
}

/* ================================================================
   🆕 ADMIN FILTER BAR
   ================================================================ */
.admin-filter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    flex: 1;
    min-width: 100px;
    padding: 10px 12px;
    border: 1.5px solid #cbd5e1;
    background: #f8fafc;
    border-radius: 8px;
    font-weight: bold;
    font-size: 13px;
    cursor: pointer;
    font-family: inherit;
    color: #475569;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.filter-btn:hover { background: #e2e8f0; }

.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(26, 95, 122, 0.3);
}

.filter-badge {
    background: rgba(0,0,0,0.15);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 900;
    min-width: 20px;
    text-align: center;
}

.filter-btn.active .filter-badge {
    background: rgba(255,255,255,0.25);
}

/* ================================================================
   🆕 TICKER ADMIN PANEL
   ================================================================ */
.ticker-admin-box {
    background: #f0f9ff;
    border: 1.5px solid #93c5fd;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 15px;
}

.ticker-preview-box {
    background: #f0fdf4;
    border: 1.5px solid #86efac;
    border-radius: 12px;
    padding: 16px;
}

@media (max-width: 600px) {
    .filter-btn {
        flex: 1 1 calc(33.33% - 6px);
        min-width: auto;
        font-size: 12px;
        padding: 8px 6px;
    }
    .filter-badge { font-size: 10px; padding: 1px 6px; }
}
/* ================================================================
   📢 PDF ADVERTISEMENT PAGE
   ================================================================ */
.pdf-ad-page {
    width: 1400px;
    height: 1980px;
    background: linear-gradient(135deg, #1a5f7a 0%, #0e8388 100%);
    display: flex;
    flex-direction: column;
    padding: 60px;
    box-sizing: border-box;
    font-family: 'Rasa', sans-serif;
    color: white;
    position: relative;
    overflow: hidden;
}

.ad-bg-circle-1 {
    position: absolute;
    top: -200px;
    right: -200px;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(255,152,0,0.35), transparent 70%);
    border-radius: 50%;
}

.ad-bg-circle-2 {
    position: absolute;
    bottom: -250px;
    left: -250px;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(255,255,255,0.15), transparent 70%);
    border-radius: 50%;
}

.ad-content-wrapper {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

/* HEADER */
.ad-header {
    text-align: center;
    padding-bottom: 30px;
    border-bottom: 4px solid rgba(255,255,255,0.3);
}

.ad-app-icon {
    font-size: 140px;
    line-height: 1;
    margin-bottom: 20px;
}

.ad-app-name {
    font-size: 96px;
    font-weight: 900;
    margin: 0 0 15px 0;
    color: #fffde7;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.3);
    letter-spacing: 2px;
}

.ad-app-tagline {
    font-size: 36px;
    color: rgba(255,255,255,0.95);
    margin: 0;
    font-weight: 600;
}

/* FEATURES */
.ad-features-section {
    margin: 40px 0;
}

.ad-features-title {
    font-size: 44px;
    font-weight: 900;
    text-align: center;
    margin-bottom: 30px;
    color: #ffd54f;
    letter-spacing: 1px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.ad-features-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    background: rgba(255,255,255,0.1);
    padding: 40px;
    border-radius: 24px;
    border: 2px solid rgba(255,255,255,0.2);
}

.ad-feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px 24px;
    background: rgba(255,255,255,0.15);
    border-radius: 14px;
    font-size: 32px;
    font-weight: 700;
    color: white;
}

.ad-feature-icon {
    font-size: 44px;
    line-height: 1;
}

/* CTA */
.ad-cta-section {
    background: linear-gradient(135deg, #ff9800, #f57c00);
    border-radius: 28px;
    padding: 50px 40px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0,0,0,0.35);
    margin: 20px 0;
}

.ad-cta-label {
    font-size: 38px;
    font-weight: 700;
    margin-bottom: 25px;
    color: #fffde7;
    letter-spacing: 1px;
}

.ad-cta-button {
    background: white;
    color: #1a5f7a;
    padding: 28px 48px;
    border-radius: 18px;
    font-size: 52px;
    font-weight: 900;
    display: inline-block;
    box-shadow: 0 10px 25px rgba(0,0,0,0.25);
    margin-bottom: 22px;
}

.ad-cta-url {
    font-size: 24px;
    color: #fffde7;
    font-weight: 600;
    letter-spacing: 0.5px;
    word-break: break-all;
    margin-bottom: 15px;
}

.ad-cta-hint {
    font-size: 22px;
    color: #fffde7;
    font-weight: 700;
    opacity: 0.95;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.95; }
    50% { opacity: 0.6; }
}

/* FOOTER */
.ad-footer {
    text-align: center;
    padding-top: 25px;
    border-top: 3px solid rgba(255,255,255,0.3);
}

.ad-footer-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
}

.ad-footer-icon {
    font-size: 44px;
}

.ad-footer-note {
    font-size: 28px;
    color: rgba(255,255,255,0.9);
    font-weight: 600;
}