*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --gold: #c9a84c;
    --gold-light: #f0cc6e;
    --gold-dim: rgba(201, 168, 76, 0.15);
    --white: #f5f0e8;
    --bg: #07070f;
    --bg2: #0d0d1a;
    --font-heading: "Amiri", "Noto Naskh Arabic", serif;
    --font-body: "Cairo", "Noto Naskh Arabic", system-ui, sans-serif;
    --font-ui: "Cairo", "Noto Naskh Arabic", system-ui, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--white);
    font-family: var(--font-body);
    line-height: 1.7;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    min-height: 100vh;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

body::before {
    background:
        radial-gradient(
            circle at 15% 20%,
            rgba(201, 168, 76, 0.1),
            transparent 32%
        ),
        radial-gradient(
            circle at 85% 15%,
            rgba(201, 168, 76, 0.06),
            transparent 28%
        ),
        radial-gradient(
            circle at 50% 85%,
            rgba(201, 168, 76, 0.05),
            transparent 35%
        );
}

body::after {
    background-image:
        linear-gradient(rgba(245, 240, 232, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(245, 240, 232, 0.025) 1px, transparent 1px);
    background-size: 42px 42px;
    opacity: 0.2;
}

/* ── NAV ── */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 3rem;
    background: rgba(7, 7, 15, 0.7);
    backdrop-filter: blur(12px);
    border-bottom: 0.5px solid rgba(201, 168, 76, 0.1);
    animation: fadeDown 1s ease 0.5s both;
}

@keyframes fadeDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 22px;
    color: var(--gold);
    letter-spacing: 0.05em;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: rgba(245, 240, 232, 0.6);
    text-decoration: none;
    font-size: 14px;
    font-family: var(--font-ui);
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--gold);
}

/* ── STARS CANVAS ── */
#stars-canvas {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

/* ── HERO ── */
.hero {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5rem 2rem 3rem;
    text-align: center;
    overflow: hidden;
}

/* Big glowing ring behind the word */
.hero::before {
    content: "";
    position: absolute;
    width: clamp(620px, 50vw, 820px);
    height: clamp(620px, 50vw, 820px);
    border-radius: 50%;
    background: radial-gradient(
        circle,
        rgba(201, 168, 76, 0.08) 0%,
        transparent 70%
    );
    top: 50%;
    left: 50%;
    transform: translate(-50%, -60%);
    animation: ringPulse 6s ease-in-out infinite;
}

.hero::after {
    content: "";
    position: absolute;
    width: clamp(480px, 42vw, 700px);
    height: clamp(230px, 24vw, 360px);
    left: 50%;
    top: 54%;
    transform: translate(-50%, -50%);
    background: radial-gradient(
        circle,
        rgba(201, 168, 76, 0.16),
        transparent 72%
    );
    filter: blur(26px);
    z-index: 1;
    animation: auraShift 9s ease-in-out infinite;
}

@keyframes auraShift {
    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.55;
    }
    50% {
        transform: translate(-50%, -52%) scale(1.08);
        opacity: 0.9;
    }
}

@keyframes ringPulse {
    0%,
    100% {
        transform: translate(-50%, -60%) scale(1);
        opacity: 0.6;
    }
    50% {
        transform: translate(-50%, -60%) scale(1.15);
        opacity: 1;
    }
}

/* ── FLAGS ORBIT ── */
.orbit-container {
    position: absolute;
    width: clamp(520px, 42vw, 700px);
    aspect-ratio: 1;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -55%);
    animation: orbit-spin 40s linear infinite;
    filter: drop-shadow(0 20px 60px rgba(0, 0, 0, 0.55));
}

@keyframes orbit-spin {
    from {
        transform: translate(-50%, -55%) rotate(0deg);
    }
    to {
        transform: translate(-50%, -55%) rotate(360deg);
    }
}

.flag-dot {
    position: absolute;
    font-size: 42px;
    top: 50%;
    left: 50%;
    transform-origin: center;
    animation: counter-spin 40s linear infinite;
    filter: drop-shadow(0 0 6px rgba(201, 168, 76, 0.4));
}

@keyframes counter-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(-360deg);
    }
}

/* ── BIG WORD ANIMATION ── */
.big-word-wrap {
    position: relative;
    z-index: 2;
    margin-bottom: 1.5rem;
    animation: wordReveal 1.6s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both;
}

@keyframes wordReveal {
    from {
        opacity: 0;
        transform: scale(0.6) translateY(40px);
        filter: blur(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
        filter: blur(0);
    }
}

.big-word {
    font-family: var(--font-heading);
    font-size: clamp(120px, 12vw, 220px);
    font-weight: 700;
    color: #d1ab4e;

    line-height: 1;
    letter-spacing: 0.03em;
    text-shadow:
        0 0 30px rgba(201, 168, 76, 0.5),
        0 0 80px rgba(201, 168, 76, 0.2);
    animation: goldShimmer 4s ease-in-out infinite 2s;
}

@keyframes goldShimmer {
    0%,
    100% {
        text-shadow:
            0 0 30px rgba(201, 168, 76, 0.5),
            0 0 80px rgba(201, 168, 76, 0.2);
    }
    50% {
        text-shadow:
            0 0 50px rgba(201, 168, 76, 0.8),
            0 0 120px rgba(201, 168, 76, 0.4),
            0 0 200px rgba(201, 168, 76, 0.1);
    }
}

/* ── AYAH ── */
.ayah-block {
    position: relative;
    z-index: 2;
    animation: fadeUp 1s ease 1.2s both;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ayah-text {
    font-family: var(--font-heading);
    font-size: clamp(18px, 1.7vw, 27px);
    color: rgba(201, 168, 76, 0.85);
    line-height: 2;
    max-width: 760px;
    margin: 0 auto 0.4rem;
    text-shadow: 0 0 22px rgba(201, 168, 76, 0.16);
}

.ayah-ref {
    font-size: 14px;
    color: rgba(245, 240, 232, 0.3);
    letter-spacing: 0.1em;
}

/* ── SEPARATOR ── */
.gold-line {
    width: 220px;
    height: 0.5px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 2rem auto;
    animation: fadeUp 1s ease 1.5s both;
}

/* ── SUBTITLE ── */
.subtitle {
    font-family: var(--font-body);
    font-size: 18px;
    color: rgba(245, 240, 232, 1);
    max-width: 700px;
    line-height: 1.95;
    text-align: center;
    margin-top: clamp(2.8rem, 7vh, 5.8rem);
    position: relative;
    z-index: 3;
    animation: fadeUp 1s ease 1.7s both;
}

/* ── CTA BUTTONS ── */
.cta-row {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2.5rem;
    flex-wrap: wrap;
    animation: fadeUp 1s ease 2s both;
}

.btn {
    padding: 12px 32px;
    border-radius: 50px;
    font-family: var(--font-ui);
    font-size: 15px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--gold);
    color: #07070f;
    border: none;
    font-weight: 700;
}

.btn-primary:hover {
    background: var(--gold-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(201, 168, 76, 0.35);
}

.btn-outline {
    background: transparent;
    color: var(--gold);
    border: 0.5px solid rgba(201, 168, 76, 0.4);
}

.btn-outline:hover {
    border-color: var(--gold);
    background: rgba(201, 168, 76, 0.08);
    transform: translateY(-2px);
}

/* ── SCROLL INDICATOR ── */
.scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    animation: fadeUp 1s ease 2.5s both;
}

.scroll-hint span {
    font-size: 11px;
    color: rgba(245, 240, 232, 0.25);
    letter-spacing: 0.15em;
}

.scroll-arrow {
    width: 20px;
    height: 20px;
    border-right: 1px solid rgba(201, 168, 76, 0.4);
    border-bottom: 1px solid rgba(201, 168, 76, 0.4);
    transform: rotate(45deg);
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%,
    100% {
        transform: rotate(45deg) translateY(0);
    }
    50% {
        transform: rotate(45deg) translateY(6px);
    }
}

/* ── COUNTRIES SECTION ── */
.section {
    position: relative;
    z-index: 2;
    padding: 4rem 2rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(34px, 3.1vw, 52px);
    color: var(--gold);
    text-align: center;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 24px rgba(201, 168, 76, 0.22);
}

.section-title::after {
    content: "";
    display: block;
    width: 72px;
    height: 1px;
    margin: 0.9rem auto 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(201, 168, 76, 0.85),
        transparent
    );
}

.section-sub {
    font-family: var(--font-ui);
    font-size: 17px;
    color: rgba(245, 240, 232, 0.35);
    text-align: center;
    margin-bottom: 3rem;
}

.visitors-counter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    margin: 0 auto 1.6rem;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    border: 0.5px solid rgba(201, 168, 76, 0.35);
    background: rgba(14, 14, 25, 0.58);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.22);
    width: fit-content;
}

.visitors-counter-label {
    font-family: var(--font-ui);
    font-size: 13px;
    color: rgba(245, 240, 232, 0.66);
}

.visitors-counter-value {
    font-family: var(--font-heading);
    font-size: 20px;
    color: var(--gold-light);
    line-height: 1;
    min-width: 2.5ch;
}

/* ── GUIDANCE SECTION ── */
.guidance-section {
    padding-top: 3.2rem;
}

.guidance-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.2rem;
    max-width: 1120px;
    margin: 0 auto;
}

.guidance-panel {
    background: linear-gradient(
        160deg,
        rgba(255, 255, 255, 0.04),
        rgba(255, 255, 255, 0.01)
    );
    border: 0.5px solid rgba(201, 168, 76, 0.22);
    border-radius: 18px;
    padding: 1.2rem;
    backdrop-filter: blur(6px);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.22);
}

.guidance-panel-title {
    font-family: var(--font-heading);
    font-size: clamp(24px, 2.1vw, 32px);
    color: var(--gold-light);
    margin-bottom: 0.9rem;
    text-align: center;
}

.guidance-list {
    display: grid;
    gap: 0.75rem;
}

.guidance-item {
    border: 0.5px solid rgba(201, 168, 76, 0.16);
    border-radius: 14px;
    background: rgba(8, 9, 20, 0.56);
    padding: 0.8rem 0.85rem;
}

.guidance-item-highlight {
    border-color: rgba(240, 204, 110, 0.5);
    box-shadow: 0 0 0 1px rgba(240, 204, 110, 0.16);
}

.guidance-item-directive {
    border-color: rgba(240, 204, 110, 0.38);
    background: linear-gradient(
        145deg,
        rgba(201, 168, 76, 0.12),
        rgba(8, 9, 20, 0.64)
    );
}

.guidance-item-head {
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 700;
    color: var(--gold-light);
    margin-bottom: 0.4rem;
}

.guidance-quote {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(19px, 1.85vw, 26px);
    line-height: 1.8;
    color: rgba(245, 240, 232, 0.94);
}

.guidance-ref {
    margin-top: 0.45rem;
    font-family: var(--font-ui);
    font-size: 12px;
    letter-spacing: 0.06em;
    color: rgba(245, 240, 232, 0.46);
}

.guidance-note {
    margin-top: 0.5rem;
    font-family: var(--font-ui);
    font-size: 12px;
    color: rgba(240, 204, 110, 0.9);
}

/* ── FIXED COUNTRIES SIDE PANEL (DESKTOP) ── */
body.with-fixed-countries {
    padding-right: min(38vw, 420px);
}

.section-countries-fixed {
    position: fixed;
    top: 12px;
    right: 12px;
    width: min(36vw, 390px);
    height: calc(100vh - 24px);
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1rem 0.9rem 1.2rem;
    border: 0.5px solid rgba(201, 168, 76, 0.3);
    border-radius: 18px;
    background: linear-gradient(
        160deg,
        rgba(10, 10, 20, 0.9),
        rgba(7, 7, 15, 0.86)
    );
    box-shadow:
        0 22px 52px rgba(0, 0, 0, 0.42),
        0 0 0 1px rgba(201, 168, 76, 0.06);
    backdrop-filter: blur(10px);
    z-index: 70;
}

.section-countries-fixed .section-title {
    font-size: clamp(26px, 2vw, 34px);
}

.section-countries-fixed .section-sub {
    font-size: 13px;
    margin-bottom: 0.9rem;
}

.section-countries-fixed .visitors-counter {
    margin-bottom: 1rem;
}

.section-countries-fixed .countries-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    max-width: none;
}

.section-countries-fixed .c-card {
    min-width: 0;
    max-width: none;
    min-height: 84px;
    width: 100%;
    padding: 10px 12px;
}

.section-countries-fixed .c-flag {
    font-size: 36px;
    line-height: 34px;
}

.section-countries-fixed .c-name {
    font-size: 20px;
}

.section-countries-fixed::-webkit-scrollbar {
    width: 9px;
}

.section-countries-fixed::-webkit-scrollbar-thumb {
    background: rgba(201, 168, 76, 0.38);
    border-radius: 999px;
}

@media (max-width: 1200px) {
    body.with-fixed-countries {
        padding-right: 0;
    }

    .section-countries-fixed {
        position: relative;
        top: auto;
        right: auto;
        width: auto;
        height: auto;
        overflow: visible;
        border: none;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        z-index: 2;
    }

    .section-countries-fixed .countries-grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        max-width: 980px;
        gap: 12px;
    }

    .section-countries-fixed .c-card {
        min-width: 112px;
        max-width: 160px;
        min-height: 118px;
        width: auto;
        padding: 14px 18px;
    }

    .section-countries-fixed .c-flag {
        font-size: 60px;
        line-height: 50px;
    }

    .section-countries-fixed .c-name {
        font-size: 18px;
    }
}

.countries-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    max-width: 980px;
    margin: 0 auto;
}

.c-card {
    background: linear-gradient(
        155deg,
        rgba(255, 255, 255, 0.045),
        rgba(255, 255, 255, 0.015)
    );
    border: 0.5px solid rgba(201, 168, 76, 0.15);
    border-radius: 14px;
    padding: 14px 18px;
    text-align: center;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    min-width: 112px;
    max-width: 160px;
    min-height: 118px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(7px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.c-card::before {
    content: "";
    position: absolute;
    inset: -32% -22%;
    background: linear-gradient(
        110deg,
        transparent 35%,
        rgba(255, 255, 255, 0.22) 50%,
        transparent 65%
    );
    transform: translateX(-120%) rotate(8deg);
    transition: transform 0.75s ease;
}

.c-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 14px;
    background: radial-gradient(
        circle at center,
        rgba(201, 168, 76, 0.12) 0%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.3s;
}

.c-card:hover::after,
.c-card.active::after {
    opacity: 1;
}

.c-card:hover,
.c-card.active {
    border-color: rgba(201, 168, 76, 0.55);
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 16px 46px rgba(201, 168, 76, 0.14),
        0 0 0 1px rgba(201, 168, 76, 0.1);
}

.c-card.active {
    z-index: 3;
}

.c-card:hover::before,
.c-card.active::before {
    transform: translateX(120%) rotate(8deg);
}

.c-card.palestine {
    border-color: rgba(201, 168, 76, 0.5);
    background: rgba(201, 168, 76, 0.06);
    order: -1;
}

.c-card.palestine:hover,
.c-card.palestine.active {
    box-shadow: 0 12px 50px rgba(201, 168, 76, 0.22);
}

.c-flag {
    font-size: 60px;
    display: block;
    margin-bottom: 5px;
    line-height: 50px;
}
.c-name {
    font-family: var(--font-ui);
    font-size: 18px;
    color: rgba(245, 240, 232, 0.7);
    display: block;
}

.c-message {
    display: block;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    margin-top: 0;
    padding-top: 0;
    border-top: 0 solid rgba(201, 168, 76, 0.2);
    font-family: var(--font-ui);
    font-size: 18px;
    line-height: 1.8;
    color: rgba(245, 240, 232, 0.82);
    transition:
        max-height 0.38s ease,
        opacity 0.28s ease,
        margin-top 0.3s ease,
        padding-top 0.3s ease,
        border-top-width 0.3s ease;
}

.c-card.active .c-message {
    max-height: 0;
    opacity: 0;
    margin-top: 0;
    padding-top: 0;
    border-top-width: 0;
}

.c-card.palestine .c-name {
    color: var(--gold);
    font-weight: 700;
}

.heartbeat {
    display: inline-block;
    color: var(--gold);
    animation: hb 1.2s ease-in-out infinite;
}

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

/* ── MESSAGE TOAST ── */
.msg-toast {
    position: fixed;
    top: 30%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: linear-gradient(
        150deg,
        rgba(30, 22, 8, 0.96),
        rgba(10, 10, 20, 0.96) 45%,
        rgba(20, 16, 8, 0.96)
    );
    border: 1px solid rgba(240, 204, 110, 0.8);
    border-radius: 20px;
    padding: 18px 26px;
    font-family: var(--font-body);
    font-size: clamp(18px, 2.2vw, 24px);
    font-weight: 600;
    line-height: 1.7;
    color: #fff5dc;
    opacity: 0;
    transition:
        opacity 0.28s ease,
        transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 9999;
    white-space: normal;
    width: min(92vw, 760px);
    text-align: center;
    letter-spacing: 0;
    direction: rtl;
    box-shadow:
        0 26px 70px rgba(0, 0, 0, 0.6),
        0 0 48px rgba(201, 168, 76, 0.38),
        inset 0 0 24px rgba(201, 168, 76, 0.12);
    backdrop-filter: blur(14px);
    pointer-events: none;
    text-shadow: 0 0 12px rgba(201, 168, 76, 0.35);
}

.msg-toast::before {
    content: "✦";
    display: inline-block;
    margin-inline: 10px;
    color: var(--gold-light);
    font-size: 0.9em;
    animation: toastSpark 1.3s ease-in-out infinite;
}

#toast {
    display: none;
}

.msg-toast.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    animation: toastZoomInOut 4.2s ease-in-out both;
}

@keyframes toastSpark {
    0%,
    100% {
        opacity: 0.45;
        transform: scale(0.9);
    }
    50% {
        opacity: 1;
        transform: scale(1.2);
    }
}

@keyframes toastZoomInOut {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.78);
    }
    14% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.04);
    }
    80% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0.92;
        transform: translate(-50%, -50%) scale(0.9);
    }
}

/* ── FOOTER STRIP ── */
.footer-strip {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 2rem;
    border-top: 0.5px solid rgba(201, 168, 76, 1);
    font-size: 18px;
    color: rgba(245, 240, 232, 0.2);
    font-family: var(--font-ui);
    background: linear-gradient(
        180deg,
        rgba(7, 7, 15, 0),
        rgba(10, 10, 22, 0.65)
    );
}

.copyright {
    margin-top: 0.35rem;
    font-size: 13px;
    letter-spacing: 0.04em;
    color: rgba(245, 240, 232, 0.46);
}

.copyright a {
    color: rgba(201, 168, 76, 0.5);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-nav {
    display: flex;
    gap: 2rem;
    justify-content: center;
    margin-bottom: 1rem;
}

.footer-nav a {
    color: rgba(201, 168, 76, 0.5);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

@media (max-width: 1024px) {
    .hero {
        padding-top: 4.5rem;
    }

    .hero::before {
        width: min(72vw, 520px);
        height: min(72vw, 520px);
    }

    .hero::after {
        width: min(70vw, 480px);
        height: min(32vw, 230px);
    }

    .orbit-container {
        width: min(88vw, 520px);
    }

    .big-word {
        font-size: clamp(72px, 20vw, 150px);
    }

    .ayah-text {
        font-size: clamp(14px, 2.5vw, 20px);
    }

    .subtitle {
        font-size: 15px;
        max-width: 540px;
        margin-top: 2.2rem;
    }

    .ayah-text {
        max-width: 80vw;
    }

    .section {
        padding: 4rem 1.4rem;
    }

    .guidance-columns {
        grid-template-columns: 1fr;
        max-width: 840px;
    }
}

@media (min-width: 1440px) {
    .hero {
        padding-top: 6.2rem;
    }

    .subtitle {
        max-width: 780px;
    }

    .countries-grid {
        max-width: 1080px;
    }
}

@media (max-width: 768px) {
    .hero {
        min-height: 78vh;
        justify-content: center;
        padding: 3.2rem 0.95rem 1.2rem;
    }

    .hero::before {
        width: min(84vw, 390px);
        height: min(84vw, 390px);
        transform: translate(-50%, -54%);
    }

    .hero::after {
        width: min(88vw, 360px);
        height: min(40vw, 180px);
        top: 44%;
    }

    .orbit-container {
        width: min(78vw, 340px);
        top: 34%;
        transform: translate(-50%, -50%);
    }

    @keyframes orbit-spin {
        from {
            transform: translate(-50%, -50%) rotate(0deg);
        }
        to {
            transform: translate(-50%, -50%) rotate(360deg);
        }
    }

    .flag-dot {
        font-size: 17px;
    }

    .big-word-wrap {
        margin-top: 4.6rem;
        margin-bottom: 0.65rem;
    }

    .big-word {
        font-size: clamp(56px, 17.6vw, 94px);
        letter-spacing: 0.02em;
    }

    .ayah-block {
        width: min(95vw, 580px);
        padding: 0 0.2rem;
    }

    .ayah-text {
        font-size: clamp(14px, 3.8vw, 18px);
        line-height: 2;
        max-width: 92vw;
        padding: 0.55rem 0.35rem;
        background: rgba(10, 10, 20, 0.34);
        border-radius: 12px;
    }

    .ayah-ref {
        margin-top: 0.35rem;
        font-size: 12px;
        letter-spacing: 0.06em;
    }

    .subtitle {
        font-size: 14px;
        line-height: 1.8;
        max-width: 92vw;
        margin-top: 1.4rem;
    }

    .gold-line {
        width: min(46vw, 150px);
        margin: 0.75rem auto 0.6rem;
    }

    .cta-row {
        margin-top: 1.8rem;
    }

    .btn {
        width: 100%;
        justify-content: center;
        max-width: 300px;
    }

    .section {
        padding: 3.4rem 1rem;
    }

    .guidance-section {
        padding-top: 2.6rem;
    }

    .guidance-panel {
        padding: 0.95rem;
    }

    .guidance-panel-title {
        font-size: clamp(22px, 6.2vw, 30px);
    }

    .guidance-item {
        padding: 0.75rem;
    }

    .guidance-quote {
        font-size: clamp(17px, 5.1vw, 22px);
    }

    .guidance-ref,
    .guidance-note,
    .guidance-item-head {
        font-size: 12px;
    }

    .section-sub {
        margin-bottom: 2rem;
    }

    .visitors-counter {
        margin-bottom: 1.2rem;
        padding: 0.4rem 0.75rem;
    }

    .visitors-counter-label {
        font-size: 12px;
    }

    .visitors-counter-value {
        font-size: 18px;
    }

    .countries-grid {
        gap: 10px;
    }

    .c-card {
        flex: 1 1 calc(50% - 10px);
        min-width: 132px;
        max-width: 175px;
        padding: 12px;
        backdrop-filter: blur(5px);
    }

    .c-card.active {
        min-width: 132px;
        max-width: 175px;
    }

    .c-card.active .c-message {
        max-height: 0;
    }

    .msg-toast {
        top: 50%;
        left: 50%;
        width: min(92vw, 620px);
        padding: 14px 16px;
        font-size: 14px;
        max-width: 92vw;
    }

    .footer-strip {
        padding: 1.4rem 1rem;
        font-size: 12px;
    }

    .copyright {
        font-size: 11px;
    }

    .scroll-hint {
        bottom: 1.2rem;
    }
}

@media (max-width: 480px) {
    .hero {
        min-height: 72vh;
        padding-top: 2.9rem;
        padding-bottom: 1rem;
    }

    .hero::before {
        width: min(90vw, 330px);
        height: min(90vw, 330px);
        transform: translate(-50%, -53%);
    }

    .hero::after {
        width: min(94vw, 300px);
        height: min(40vw, 150px);
        top: 43%;
    }

    .orbit-container {
        width: min(80vw, 290px);
        top: 57%;
        transform: translate(-50%, -50%);
    }

    @keyframes orbit-spin {
        from {
            transform: translate(-50%, -50%) rotate(0deg);
        }
        to {
            transform: translate(-50%, -50%) rotate(360deg);
        }
    }

    .flag-dot {
        font-size: 14px;
    }

    .big-word {
        font-size: clamp(44px, 20vw, 72px);
    }

    .big-word-wrap {
        margin-top: 4rem;
        margin-bottom: 0.45rem;
    }

    .ayah-text {
        line-height: 1.9;
        font-size: clamp(13px, 4vw, 16px);
        padding: 0.5rem 0.3rem;
    }

    .ayah-ref {
        font-size: 11px;
    }

    .section-title {
        font-size: clamp(22px, 7vw, 30px);
    }

    .section-sub {
        font-size: 12px;
    }

    .countries-grid {
        gap: 8px;
    }

    .c-card {
        flex: 1 1 calc(50% - 8px);
        min-width: 126px;
        max-width: 100%;
        border-radius: 12px;
    }

    .c-card.active {
        min-width: 126px;
    }

    .c-flag {
        font-size: 26px;
    }

    .c-name {
        font-size: 12px;
    }

    .scroll-hint span {
        font-size: 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero::before,
    .hero::after,
    .big-word,
    .flag-dot,
    .orbit-container,
    .heartbeat,
    .scroll-arrow {
        animation: none !important;
    }
}

.footer-nav a:hover {
    color: var(--gold);
}
