/* ================================================================
   HOME — DAILY FACTS / FLIP CARDS
   Altayseer visual identity
   ================================================================ */

.home-daily-facts-section {
    position: relative;
    width: 100%;
    padding: 50px 0 72px;
    background: transparent;
}

.home-daily-facts-section .container {
    width: 100%;
    max-width: none !important;
    padding-inline: clamp(28px, 4vw, 72px);
}
.home-daily-facts-heading {
    margin-bottom: 26px;
}

.home-daily-facts-heading h2 {
    margin: 6px 0 8px;

    color: #182E56;

    font-size: clamp(1.8rem, 3vw, 2.5rem);
    line-height: 1.25;
}

.home-daily-facts-heading p {
    max-width: 680px;

    margin: 0;

    color: rgba(24, 46, 86, .70);
    line-height: 1.8;
}

/* ================================================================
   GRID
   ================================================================ */

.home-daily-facts-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(22px, 2vw, 34px);
    width: 100%;
    align-items: stretch;
}

.daily-fact-item {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* ================================================================
   FLIP CARD
   ================================================================ */

.daily-fact-flip-card {
    position: relative;
    width: 100%;
    min-height: 440px;
    perspective: 1200px;
    outline: none;
}

.daily-fact-flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 440px;
    transform-style: preserve-3d;
    transition: transform .65s cubic-bezier(.2, .7, .2, 1),
                filter .3s ease;
}

.daily-fact-flip-card:hover .daily-fact-flip-inner,
.daily-fact-flip-card:focus .daily-fact-flip-inner,
.daily-fact-flip-card.is-flipped .daily-fact-flip-inner {
    transform: rotateY(180deg);
}

[dir="rtl"] .daily-fact-flip-card:hover .daily-fact-flip-inner,
[dir="rtl"] .daily-fact-flip-card:focus .daily-fact-flip-inner,
[dir="rtl"] .daily-fact-flip-card.is-flipped .daily-fact-flip-inner {
    transform: rotateY(-180deg);
}

.daily-fact-face {
    position: absolute;
    inset: 0;

    display: flex;
    flex-direction: column;

    overflow: hidden;

    border-radius: 24px;

    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;

    box-shadow:
        0 20px 48px rgba(24, 46, 86, .14);
}

/* ================================================================
   FRONT
   ================================================================ */

.daily-fact-front {
    padding: 26px;

    background:
        radial-gradient(
            circle at 15% 10%,
            rgba(233, 97, 36, .16),
            transparent 34%
        ),
        linear-gradient(
            145deg,
            #182E56 0%,
            #1D427B 100%
        );

    border: 1px solid rgba(255, 255, 255, .12);

    color: #FFFFFF;
}

.daily-fact-front::before {
    content: "";

    position: absolute;
    inset-inline-end: -75px;
    bottom: -95px;

    width: 230px;
    height: 230px;

    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 50%;
}

.daily-fact-front::after {
    content: "";

    position: absolute;
    inset-inline-start: -55px;
    top: -70px;

    width: 180px;
    height: 180px;

    border: 1px solid rgba(233, 97, 36, .18);
    border-radius: 50%;
}

.daily-fact-front-top {
    position: relative;
    z-index: 2;

    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 14px;
}

.daily-fact-number {
    color: rgba(255, 255, 255, .55);

    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .14em;
}

.daily-fact-latest {
    padding: 6px 10px;

    border-radius: 999px;

    background: rgba(233, 97, 36, .16);
    border: 1px solid rgba(233, 97, 36, .35);

    color: #FF8A4C;

    font-size: .72rem;
    font-weight: 800;
}

.daily-fact-question-mark {
    position: relative;
    z-index: 2;

    width: 82px;
    height: 82px;

    margin: auto;

    display: grid;
    place-items: center;

    border-radius: 50%;

    background: #E96124;

    color: #FFFFFF;

    font-size: 2.9rem;
    font-weight: 900;
    line-height: 1;

    box-shadow:
        0 18px 34px rgba(0, 0, 0, .20);
}

.daily-fact-front-copy {
    position: relative;
    z-index: 2;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    width: 100%;
    gap: 8px;

    text-align: center;
}

.daily-fact-front-label {
  .daily-fact-front-label {
    color: #E96124;
    font-size: 1.65rem;
    font-weight: 900;
    line-height: 1.25;
    margin-bottom: 2px;
}
}

.daily-fact-title {
    width: 100%;
    max-width: 92%;

    margin: 0;

    color: #FFFFFF;

    font-size: clamp(1.1rem, 1.35vw, 1.35rem);
    font-weight: 750;
    line-height: 1.55;

    text-align: center;

    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;
}

.daily-fact-hint {
    margin-top: 3px;

    color: rgba(255, 255, 255, .60);

    font-size: .82rem;
    font-weight: 500;
}

.daily-fact-front-copy strong {
    color: #FFFFFF;

    font-size: 1.3rem;
    font-weight: 800;
}

.daily-fact-front-copy span {
    color: rgba(255, 255, 255, .72);
    font-size: .95rem;
    font-weight: 600;
}


.daily-fact-date {
    position: relative;
    z-index: 2;

    margin-top: 14px;

    color: rgba(255, 255, 255, .48);

    font-size: .78rem;
}


/* ================================================================
   BACK
   ================================================================ */

.daily-fact-back {
    padding: 30px;

    justify-content: center;

    background:
        linear-gradient(
            145deg,
            #FFFFFF 0%,
            #F6F8FC 100%
        );

    border: 1px solid rgba(29, 66, 123, .15);

    transform: rotateY(180deg);
}

[dir="rtl"] .daily-fact-back {
    transform: rotateY(-180deg);
}

.daily-fact-back-label {
    margin-bottom: 16px;

    color: #E96124;

    font-size: 1.55rem;
    font-weight: 900;
    line-height: 1.25;
}

.daily-fact-back p {
    position: relative;
    z-index: 2;

    margin: 0;

    color: #182E56;

    font-size: clamp(1rem, 1.4vw, 1.16rem);
    font-weight: 650;
    line-height: 1.9;

    white-space: pre-line;
    overflow-wrap: anywhere;
    word-break: normal;
}

.daily-fact-back-mark {
    position: absolute;
    inset-inline-end: 22px;
    bottom: 8px;

    color: rgba(29, 66, 123, .06);

    font-size: 8rem;
    font-weight: 900;
    line-height: 1;
}

/* ================================================================
   HOVER LIFT
   ================================================================ */

.daily-fact-flip-card:hover {
    z-index: 2;
}

.daily-fact-flip-card:hover .daily-fact-face {
    box-shadow:
        0 28px 64px rgba(24, 46, 86, .22);
}

/* ================================================================
   DARK MODE
   ================================================================ */

.home-daily-facts-heading h2 {
    margin: 6px 0 8px;
    color: #FFFFFF;
    font-size: clamp(2rem, 3vw, 2.8rem);
    line-height: 1.25;
}

.home-daily-facts-heading p {
    max-width: 720px;
    margin: 0;
    color: rgba(255, 255, 255, .72);
    line-height: 1.8;
}

html[data-theme="dark"] .daily-fact-front {
    background:
        radial-gradient(
            circle at 15% 10%,
            rgba(233, 97, 36, .18),
            transparent 34%
        ),
        linear-gradient(
            145deg,
            #111F3B 0%,
            #182E56 100%
        );
}

html[data-theme="dark"] .daily-fact-back {
    background:
        linear-gradient(
            145deg,
            #182E56 0%,
            #142746 100%
        );

    border-color: rgba(255, 255, 255, .12);
}

html[data-theme="dark"] .daily-fact-back p {
    color: #FFFFFF;
}

html[data-theme="dark"] .daily-fact-back-mark {
    color: rgba(255, 255, 255, .04);
}

/* ================================================================
   TABLET
   ================================================================ */

@media (max-width: 980px) {
    .home-daily-facts-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ================================================================
   MOBILE
   ================================================================ */

@media (max-width: 640px) {
    .home-daily-facts-section {
        padding: 24px 0 42px;
    }

    .home-daily-facts-heading {
        margin-bottom: 20px;
    }

    .home-daily-facts-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .daily-fact-flip-card,
    .daily-fact-flip-inner {
        min-height: 360px;
    }

    .daily-fact-front,
    .daily-fact-back {
        border-radius: 20px;
    }

    .daily-fact-front {
        padding: 24px;
    }

    .daily-fact-back {
        padding: 26px 24px;
    }

    .daily-fact-question-mark {
        width: 70px;
        height: 70px;

        font-size: 2.4rem;
    }

    .daily-fact-front-copy strong {
        font-size: 1.18rem;
    }

    .daily-fact-front-copy span {
        font-size: .8rem;
    }
}

/* ================================================================
   ACCESSIBILITY
   ================================================================ */

@media (prefers-reduced-motion: reduce) {
    .daily-fact-flip-inner {
        transition: none;
    }
}
/* Final override — Did You Know front title */
.daily-fact-front-copy .daily-fact-front-label {
    display: block;

    margin: 0 0 6px;

    color: #E96124 !important;

    font-size: clamp(1.7rem, 2vw, 2.1rem) !important;
    font-weight: 900 !important;
    line-height: 1.2;

    text-align: center;
}