/*
|--------------------------------------------------------------------------
| FILE PATH:
| /home/mahaupsi/public_html/assets/public/css/home.css
|
| FILE PURPOSE:
| Clean, card-based public homepage for Maha Shikshan Awaaz.
|
| RESPONSIVE RULE:
| - Desktop : >= 1024px
| - Tablet  : 600px - 1023px
| - Mobile  : <= 599px
|
| IMPORTANT:
| - Flexbox only; no CSS Grid.
| - Exactly ONE Desktop, ONE Tablet and ONE Mobile responsive block.
| - All responsive blocks are together at the END of this file.
|--------------------------------------------------------------------------
*/


/* =========================================================
   WELCOME
   ========================================================= */

.home-welcome-section {
    padding: 28px 0 18px;
}

.home-welcome-card {
    box-sizing: border-box;
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    max-width: 1100px;
    margin: 0 auto;
    overflow: hidden;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.home-welcome-copy {
    box-sizing: border-box;
    flex: 1 1 auto;
    min-width: 0;
    padding: 26px 28px;
}

.home-welcome-kicker {
    margin-bottom: 6px;
    color: var(--color-primary);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.home-welcome-title {
    margin: 0;
    color: var(--text-primary);
    font-size: 2.35rem;
    font-weight: 900;
    line-height: 1.15;
}

.home-welcome-text {
    max-width: 660px;
    margin: 10px 0 0;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.65;
}

.home-welcome-tags {
    display: flex;
    flex-wrap: wrap;
    margin-top: 14px;
}

.home-welcome-tags span {
    margin: 0 7px 7px 0;
    padding: 6px 10px;
    background: var(--bg-surface-2);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 750;
}

.home-account-box {
    box-sizing: border-box;
    flex: 0 0 330px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 24px;
    background: rgba(37, 99, 235, 0.07);
    border-left: 1px solid var(--border-color);
}

.home-account-box strong {
    color: var(--text-primary);
    font-size: 1.05rem;
    font-weight: 900;
    line-height: 1.4;
}

.home-account-box > span {
    display: block;
    margin-top: 6px;
    color: var(--text-secondary);
    font-size: 0.86rem;
    line-height: 1.5;
}

.home-account-actions {
    margin-top: 14px;
}

.home-account-actions .btn {
    width: 100%;
    justify-content: center;
}

.home-account-login {
    display: block;
    margin-top: 9px;
    color: var(--color-primary);
    text-align: center;
    font-size: 0.82rem;
    font-weight: 750;
    text-decoration: none;
}

.home-account-login:hover,
.home-account-login:focus {
    text-decoration: underline;
}


/* =========================================================
   SECTION HEADING
   ========================================================= */

.home-sections-section {
    padding: 8px 0 16px;
}

.home-section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    max-width: 1100px;
    margin: 0 auto 14px;
}

.home-section-heading h2 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.35rem;
    font-weight: 900;
    line-height: 1.35;
}

.home-section-heading p {
    margin: 4px 0 0;
    color: var(--text-secondary);
    font-size: 0.88rem;
    line-height: 1.55;
}


/* =========================================================
   FEATURED REELS CARD - ALWAYS FIRST
   ========================================================= */

.home-featured-card {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto 14px;
    padding: 20px 22px;
    background:
        linear-gradient(
            135deg,
            rgba(220, 38, 38, 0.11),
            rgba(37, 99, 235, 0.06)
        ),
        var(--bg-surface);
    color: inherit;
    border: 1px solid rgba(220, 38, 38, 0.28);
    border-left: 5px solid #dc2626;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        border-color 0.18s ease;
}

.home-featured-card:hover,
.home-featured-card:focus {
    transform: translateY(-2px);
    border-color: rgba(220, 38, 38, 0.45);
    box-shadow: var(--shadow-md);
}

.home-featured-icon {
    flex: 0 0 64px;
    width: 64px;
    height: 64px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 18px;
    background: #dc2626;
    color: #ffffff;
    border-radius: 50%;
    font-size: 1.45rem;
    font-weight: 900;
    box-shadow: 0 8px 22px rgba(220, 38, 38, 0.20);
}

.home-featured-content {
    flex: 1 1 auto;
    min-width: 0;
}

.home-featured-content h3 {
    margin: 5px 0 0;
    color: var(--text-primary);
    font-size: 1.55rem;
    font-weight: 950;
    line-height: 1.3;
}

.home-featured-content p {
    margin: 5px 0 0;
    color: var(--text-secondary);
    font-size: 0.94rem;
    line-height: 1.55;
}

.home-featured-action {
    flex: 0 0 auto;
    margin-left: 20px;
    color: #dc2626;
    font-size: 0.92rem;
    font-weight: 900;
    white-space: nowrap;
}


/* =========================================================
   BADGES
   ========================================================= */

.home-card-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-bottom: 6px;
    padding: 4px 8px;
    background: rgba(245, 158, 11, 0.12);
    color: #a16207;
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: var(--radius-pill);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.home-card-badge--live {
    margin-bottom: 0;
    background: rgba(220, 38, 38, 0.10);
    color: #b91c1c;
    border-color: rgba(220, 38, 38, 0.22);
}


/* =========================================================
   REGULAR CARDS
   ========================================================= */

.home-card-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1100px;
    margin: 0 auto;
}

.home-section-card {
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    min-width: 0;
    margin-bottom: 14px;
    padding: 18px;
    background: var(--bg-surface);
    color: inherit;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        border-color 0.18s ease;
}

.home-section-card:hover,
.home-section-card:focus {
    transform: translateY(-2px);
    border-color: rgba(59, 130, 246, 0.40);
    box-shadow: var(--shadow-md);
}

.home-section-card--soon {
    border-style: dashed;
}

.home-section-card--about {
    background:
        linear-gradient(
            135deg,
            rgba(37, 99, 235, 0.07),
            rgba(37, 99, 235, 0.02)
        ),
        var(--bg-surface);
}

.home-card-icon {
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    background: var(--bg-surface-2);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    font-size: 1.25rem;
}

.home-card-content {
    display: block;
    flex: 1 1 auto;
}

.home-card-content strong {
    display: block;
    color: var(--text-primary);
    font-size: 1.02rem;
    font-weight: 900;
    line-height: 1.4;
}

.home-card-content small {
    display: block;
    margin-top: 6px;
    color: var(--text-secondary);
    font-size: 0.86rem;
    line-height: 1.55;
}

.home-card-link {
    display: block;
    margin-top: 15px;
    color: var(--color-primary);
    font-size: 0.83rem;
    font-weight: 900;
}


/* =========================================================
   RETURN MESSAGE
   ========================================================= */

.home-return-section {
    padding: 2px 0 18px;
}

.home-return-card {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto;
    padding: 13px 16px;
    background: var(--bg-surface-2);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.home-return-icon {
    flex: 0 0 auto;
    margin-right: 12px;
    color: var(--color-primary);
    font-size: 1.25rem;
}

.home-return-card strong,
.home-return-card span {
    display: block;
}

.home-return-card strong {
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 850;
    line-height: 1.45;
}

.home-return-card span {
    margin-top: 2px;
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.45;
}


/* =========================================================
   TINY VISITOR COUNTER
   ========================================================= */

.home-visitor-counter-wrap {
    display: flex;
    justify-content: center;
    padding: 0 0 22px;
}

.home-visitor-counter {
    display: inline-flex;
    align-items: center;
    padding: 7px 10px 7px 13px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    color: var(--text-secondary);
    font-size: 0.76rem;
    font-weight: 700;
}

.home-visitor-counter strong {
    min-width: 28px;
    margin-left: 8px;
    padding: 4px 8px;
    background: var(--color-primary-soft);
    color: var(--color-primary);
    border-radius: var(--radius-pill);
    text-align: center;
    font-size: 0.8rem;
    font-weight: 900;
}


/* =========================================================
   DARK THEME
   ========================================================= */

:root[data-theme="dark"] .home-account-box {
    background: rgba(59, 130, 246, 0.10);
}

:root[data-theme="dark"] .home-featured-card {
    background:
        linear-gradient(
            135deg,
            rgba(220, 38, 38, 0.14),
            rgba(59, 130, 246, 0.08)
        ),
        var(--bg-surface);
    border-color: rgba(248, 113, 113, 0.30);
    border-left-color: #ef4444;
}

:root[data-theme="dark"] .home-card-badge--live {
    color: #fca5a5;
    background: rgba(220, 38, 38, 0.14);
    border-color: rgba(248, 113, 113, 0.24);
}

:root[data-theme="dark"] .home-card-badge {
    color: #fcd34d;
    background: rgba(245, 158, 11, 0.11);
    border-color: rgba(245, 158, 11, 0.23);
}


/* =========================================================
   DESKTOP
   >= 1024px
   ========================================================= */

@media (min-width: 1024px) {

    .home-section-card {
        width: 32.35%;
    }

}


/* =========================================================
   TABLET
   600px - 1023px
   ========================================================= */

@media (min-width: 600px) and (max-width: 1023px) {

    .home-welcome-card {
        display: block;
    }

    .home-account-box {
        display: block;
        border-top: 1px solid var(--border-color);
        border-left: 0;
    }

    .home-account-actions {
        max-width: 360px;
    }

    .home-section-card {
        width: 49%;
    }

    .home-section-card--about {
        width: 100%;
    }

}


/* =========================================================
   MOBILE
   <= 599px
   ========================================================= */

@media (max-width: 599px) {

    .home-welcome-section {
        padding: 14px 0 10px;
    }

    .home-welcome-card {
        display: block;
    }

    .home-welcome-copy {
        padding: 18px 16px 15px;
    }

    .home-welcome-kicker {
        font-size: 0.72rem;
    }

    .home-welcome-title {
        font-size: 1.72rem;
    }

    .home-welcome-text {
        margin-top: 7px;
        font-size: 0.91rem;
        line-height: 1.55;
    }

    .home-welcome-tags {
        margin-top: 10px;
    }

    .home-welcome-tags span {
        padding: 5px 8px;
        font-size: 0.7rem;
    }

    .home-account-box {
        display: block;
        padding: 15px 16px;
        border-top: 1px solid var(--border-color);
        border-left: 0;
    }

    .home-account-box strong {
        font-size: 0.96rem;
    }

    .home-account-box > span {
        font-size: 0.8rem;
    }

    .home-sections-section {
        padding-top: 4px;
    }

    .home-section-heading {
        margin-bottom: 10px;
    }

    .home-section-heading h2 {
        font-size: 1.15rem;
    }

    .home-section-heading p {
        font-size: 0.8rem;
    }

    .home-featured-card {
        align-items: flex-start;
        padding: 15px;
    }

    .home-featured-icon {
        flex-basis: 48px;
        width: 48px;
        height: 48px;
        margin-right: 12px;
        font-size: 1.05rem;
    }

    .home-featured-content h3 {
        font-size: 1.22rem;
    }

    .home-featured-content p {
        font-size: 0.82rem;
    }

    .home-featured-action {
        display: none;
    }

    .home-card-list {
        display: block;
    }

    .home-section-card,
    .home-section-card--about {
        width: 100%;
        margin-bottom: 10px;
        padding: 15px;
    }

    .home-card-icon {
        width: 42px;
        height: 42px;
        margin-bottom: 10px;
    }

    .home-card-content strong {
        font-size: 0.96rem;
    }

    .home-card-content small {
        font-size: 0.8rem;
    }

    .home-card-link {
        margin-top: 11px;
    }

    .home-return-card {
        align-items: flex-start;
        padding: 12px;
    }

    .home-return-card strong {
        font-size: 0.84rem;
    }

    .home-return-card span {
        font-size: 0.75rem;
    }

}
