:root {
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont,
        "SF Pro Display", "Segoe UI", sans-serif;
    --font-arabic: "Harmattan", "Traditional Arabic", serif;

    --accent: #0a84ff;
    --accent-rgb: 10, 132, 255;

    --page-bg: #f5f5f7;
    --surface: rgba(255, 255, 255, 0.72);
    --surface-solid: #ffffff;
    --surface-secondary: rgba(255, 255, 255, 0.52);

    --text: #1d1d1f;
    --text-soft: #6e6e73;
    --border: rgba(0, 0, 0, 0.08);

    --shadow: 0 18px 60px rgba(31, 38, 64, 0.1);

    --radius-large: 30px;
    --radius-medium: 22px;
    --radius-small: 14px;

    --animation-duration: 420ms;
    --animation-easing: cubic-bezier(0.22, 1, 0.36, 1);

    --sidebar-width: 260px;
    --header-height: 78px;
}

[data-skin="sage"] {
    --accent: #2e8b70;
    --accent-rgb: 46, 139, 112;
}

[data-skin="rose"] {
    --accent: #e45678;
    --accent-rgb: 228, 86, 120;
}

[data-skin="violet"] {
    --accent: #7b61ff;
    --accent-rgb: 123, 97, 255;
}

[data-appearance="dark"] {
    --page-bg: #0d0d10;
    --surface: rgba(31, 31, 35, 0.76);
    --surface-solid: #1f1f23;
    --surface-secondary: rgba(43, 43, 48, 0.72);
    --text: #f5f5f7;
    --text-soft: #a1a1a6;
    --border: rgba(255, 255, 255, 0.1);
    --shadow: 0 18px 60px rgba(0, 0, 0, 0.3);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: auto;
    -webkit-text-size-adjust: 100%;
}

body {
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    background: var(--page-bg);
    color: var(--text);
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
    transition: background 300ms ease, color 300ms ease;
}

body.app-loading {
    opacity: 0;
}

button,
select,
input {
    font: inherit;
}

button {
    color: inherit;
}

::selection {
    color: #fff;
    background: var(--accent);
}

.skip-link {
    position: fixed;
    z-index: 2000;
    top: 10px;
    left: 10px;
    padding: 10px 14px;
    color: #fff;
    background: var(--accent);
    border-radius: 10px;
    transform: translateY(-150%);
    transition: transform 180ms ease;
}

.skip-link:focus {
    transform: translateY(0);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 12px;
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.arabic-text,
.prayer-name-arabic {
    font-family: var(--font-arabic);
}
/* =========================================================================
   1. BISMILLAH TOP BANNER (GIGABYTE RGB HARDWARE EDITION)
   ========================================================================= */
.bismillah-banner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 0.85rem 1.25rem;
    margin-bottom: 1rem;
    text-align: center;
    overflow: hidden;
    border-radius: 16px;
    /* Light Mode: Subtle Aorus amber tint background */
    background: linear-gradient(
        135deg,
        rgba(255, 113, 0, 0.05) 0%,
        rgba(255, 113, 0, 0.02) 50%,
        rgba(255, 113, 0, 0.05) 100%
    );
    border: 1px solid rgba(255, 113, 0, 0.25);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    animation: bismillahBannerIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* Subtle laser sheen passing across the container hardware housing */
.bismillah-banner::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        110deg,
        transparent 25%,
        rgba(255, 255, 255, 0.25) 50%,
        transparent 75%
    );
    transform: translateX(-100%);
    animation: bismillahSheen 7s ease-in-out infinite;
    pointer-events: none;
}

[data-appearance="dark"] .bismillah-banner {
    /* Dark Mode: Deep stealth metal black background with amber glowing borders */
    background: linear-gradient(
        135deg,
        rgba(17, 19, 24, 0.85) 0%,
        rgba(25, 28, 36, 0.95) 100%
    );
    border: 1px solid rgba(255, 113, 0, 0.35);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

[data-appearance="dark"] .bismillah-banner::after {
    background: linear-gradient(
        110deg,
        transparent 25%,
        rgba(255, 113, 0, 0.12) 50%,
        transparent 75%
    );
}

/* Accent lighting channels flanking the text */
.bismillah-ornament {
    flex: 1;
    max-width: 90px;
    height: 2px; /* Made slightly cleaner */
    background: linear-gradient(90deg, transparent, #ff7100, transparent);
    transform-origin: center;
    animation: ornamentExpand 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.15s both;
}

/* Base text properties for both themes */
.bismillah-text {
    margin: 0;
    padding: 10px;
    font-family: "Harmattan", "Scheherazade New", "Traditional Arabic" !important;
    /*font-size: clamp(1.3rem, 2.6vw, 1.85rem);*/
    font-size: 2.5em !important;
    font-weight: 700;
    line-height: 1.6;
    letter-spacing: 0.02em;
    
    /* Default Style: Premium Aorus Metallic Orange Theme */
    background: linear-gradient(90deg, #ff5100 0%, #ff7100 50%, #ff9900 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    
    /* Comma-separated dynamic multi-animation setup */
    animation:
        bismillahTextReveal 1s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both,
        bismillahGradientFlow 6s linear infinite;
}

/* Dark Mode: Full Dynamic RGB Fusion Rainbow Cycle Wave Loop */
[data-appearance="dark"] .bismillah-text {
    padding: 10px;
    background: linear-gradient(
        90deg, 
        #ff7676 0%, 
        #fca366 20%, 
        #79e793 40%, 
        #7be2e2 60%, 
        #829bf8 80%, 
        #e08df1 100%,
        #ff0000 100% /* Added trailing anchor point to prevent snapping loops */
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
}

/* =========================================================================
   ANIMATIONS
   ========================================================================= */
@keyframes bismillahBannerIn {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes bismillahTextReveal {
    from {
        opacity: 0;
        letter-spacing: 0.08em;
        filter: blur(4px);
    }
    to {
        opacity: 1;
        letter-spacing: 0.02em;
        filter: blur(0);
    }
}

@keyframes ornamentExpand {
    from {
        opacity: 0;
        transform: scaleX(0);
    }
    to {
        opacity: 1;
        transform: scaleX(1);
    }
}

/* Smooth continuous hardware-accurate tracking flow */
@keyframes bismillahGradientFlow {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 200% 50%;
    }
}

@keyframes bismillahSheen {
    0%, 65% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* =========================================================================
   2. POWERED BY TECHDONGLE INC. FOOTER
   ========================================================================= */
.techdongle-footer {
    margin-top: 2.5rem;
    padding: 1.25rem 1rem 1.75rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.techdongle-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--text-muted, #6b7280);
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(16, 185, 129, 0.25);
    box-shadow: 0 6px 24px -6px rgba(16, 185, 129, 0.18);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    overflow: hidden;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.35s ease,
                border-color 0.35s ease;
}

[data-appearance="dark"] .techdongle-badge {
    color: #9ca3af;
    background: rgba(24, 24, 30, 0.68);
    border-color: rgba(52, 211, 153, 0.25);
    box-shadow: 0 8px 28px -6px rgba(0, 0, 0, 0.45);
}

.techdongle-badge:hover {
    transform: translateY(-2px);
    border-color: rgba(16, 185, 129, 0.55);
    box-shadow: 0 12px 30px -6px rgba(16, 185, 129, 0.32);
}

.techdongle-badge::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        115deg,
        transparent 20%,
        rgba(16, 185, 129, 0.16) 50%,
        transparent 80%
    );
    transform: translateX(-100%);
    animation: techdongleSweep 5s ease-in-out infinite;
    pointer-events: none;
}

.techdongle-pulse {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 10px #10b981;
    flex-shrink: 0;
}

.techdongle-pulse::after {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 1.5px solid #10b981;
    animation: techdongleRing 2.2s cubic-bezier(0.22, 1, 0.36, 1) infinite;
}

.techdongle-brand {
    font-weight: 700;
    letter-spacing: 0.03em;
    background: linear-gradient(90deg, #059669, #0284c7, #10b981, #059669);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: techdongleBrandFlow 4.5s linear infinite;
}

[data-appearance="dark"] .techdongle-brand {
    background: linear-gradient(90deg, #34d399, #38bdf8, #a7f3d0, #34d399);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
}

@keyframes techdongleRing {
    0% {
        transform: scale(0.7);
        opacity: 0.9;
    }
    100% {
        transform: scale(2.1);
        opacity: 0;
    }
}

@keyframes techdongleBrandFlow {
    to { background-position: 200% center; }
}

@keyframes techdongleSweep {
    0%, 60% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* =========================================================================
   3. MOBILE SECTION HEADER AUTO-HIDE (AFTER 3 SECONDS)
   ========================================================================= */
@media (max-width: 768px) {
    .bismillah-text { font-size: 1.2em !important; }
    .section-page-header {
        overflow: hidden;
        transform-origin: top center;
        transition:
            max-height 0.65s cubic-bezier(0.22, 1, 0.36, 1),
            opacity 0.45s cubic-bezier(0.22, 1, 0.36, 1),
            transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
            margin 0.65s cubic-bezier(0.22, 1, 0.36, 1),
            padding 0.65s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .section-page-header.is-auto-hidden {
        max-height: 0 !important;
        opacity: 0;
        transform: translateY(-14px) scale(0.97);
        margin-top: 0 !important;
        margin-bottom: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        pointer-events: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bismillah-banner,
    .bismillah-banner::after,
    .bismillah-ornament,
    .bismillah-text,
    .techdongle-badge::before,
    .techdongle-pulse::after,
    .techdongle-brand {
        animation: none !important;
    }
}