/*
Theme Name: GeneratePress Child - Pre D.El.Ed Portal
Theme URI: https://rajpredeled.in/
Description: Custom Official Pre D.El.Ed. (BSTC) 2026 Portal Child Theme for rajpredeled.in
Author: RajPreDeled Team
Author URI: https://rajpredeled.in/
Template: generatepress
Version: 1.3.0
*/

/* ==========================================================================
   GLOBAL COLOR VARIABLES (2026 MODERN CLEAN AESTHETIC)
   ========================================================================== */
:root {
    --brand-primary: #0b3355;
    --brand-navy: #09233b;
    --brand-accent: #851414;
    --brand-gold: #c28800;
    --bg-page: #f2f4f8;
    --bg-card: #ffffff;
    --text-main: #1f2937;
    --text-secondary: #4b5563;
    --text-muted: #6b7280;
    --border-subtle: #e5e7eb;
}

/* ==========================================================================
   1. HOMEPAGE PORTAL ISOLATION (Hides default theme header/footer on front page)
   ========================================================================== */
body.home .site-header,
body.home #site-navigation,
body.home .site-footer,
body.home .entry-header {
    display: none !important;
}

/* ==========================================================================
   2. GENERATEPRESS CLEAN NAVIGATION HEADER FOR SINGLE POSTS & PAGES
   ========================================================================== */
body:not(.home) .site-header {
    background: #ffffff !important;
    border-bottom: 1px solid var(--border-subtle) !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04) !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
}

body:not(.home) .site-header .inside-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    max-width: 1140px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
    height: 68px !important;
}

body:not(.home) .site-header .main-title a {
    color: var(--brand-primary) !important;
    font-size: 20px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    letter-spacing: -0.3px !important;
}

body:not(.home) .site-header .site-description {
    color: var(--text-muted) !important;
    font-size: 11.5px !important;
    margin: 2px 0 0 0 !important;
    display: block !important;
    font-weight: 500 !important;
}

/* CLEAN HORIZONTAL NAVIGATION (GENERATEPRESS STYLE) */
body:not(.home) #site-navigation {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

body:not(.home) #site-navigation .main-nav > ul {
    display: flex !important;
    align-items: center !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

body:not(.home) #site-navigation .main-nav > ul > li > a {
    color: var(--text-secondary) !important;
    font-size: 13.5px !important;
    font-weight: 600 !important;
    padding: 0 16px !important;
    line-height: 68px !important;
    white-space: nowrap !important;
    transition: color 0.15s ease, background-color 0.15s ease !important;
    text-decoration: none !important;
    position: relative !important;
}

body:not(.home) #site-navigation .main-nav > ul > li:hover > a {
    color: var(--brand-primary) !important;
    background-color: #f8fafc !important;
}

body:not(.home) #site-navigation .main-nav > ul > li.current-menu-item > a,
body:not(.home) #site-navigation .main-nav > ul > li.active > a {
    color: var(--brand-primary) !important;
    font-weight: 700 !important;
}

body:not(.home) #site-navigation .main-nav > ul > li.current-menu-item > a::after,
body:not(.home) #site-navigation .main-nav > ul > li.active > a::after {
    content: '' !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 3px !important;
    background-color: var(--brand-primary) !important;
}

/* ==========================================================================
   3. BREADCRUMBS DIRECTLY ABOVE POST TITLE (INSIDE ARTICLE)
   ========================================================================== */
.entry-breadcrumbs,
.rank-math-breadcrumb,
.yoast-breadcrumb,
.site-content .breadcrumbs {
    font-size: 12.5px !important;
    color: var(--text-muted) !important;
    margin-bottom: 14px !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    flex-wrap: wrap !important;
    line-height: 1.4 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
}

.entry-breadcrumbs a,
.rank-math-breadcrumb a,
.yoast-breadcrumb a {
    color: #4b5563 !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    transition: color 0.15s ease !important;
}

.entry-breadcrumbs a:hover,
.rank-math-breadcrumb a:hover,
.yoast-breadcrumb a:hover {
    color: var(--brand-primary) !important;
    text-decoration: underline !important;
}

.entry-breadcrumbs .sep,
.rank-math-breadcrumb .separator,
.yoast-breadcrumb .breadcrumb_separator {
    color: #9ca3af !important;
    font-size: 11px !important;
    user-select: none !important;
    margin: 0 2px !important;
}

.entry-breadcrumbs .current,
.rank-math-breadcrumb .last,
.yoast-breadcrumb .breadcrumb_last {
    color: #111827 !important;
    font-weight: 600 !important;
}

/* ==========================================================================
   4. SINGLE POST ARTICLE CONTAINER & TYPOGRAPHY
   ========================================================================== */
body.single {
    background-color: var(--bg-page) !important;
}

body.single .site-main {
    max-width: 960px !important;
    margin: 22px auto 40px !important;
    padding: 0 5px !important;
}

@media (max-width: 640px) {
    body.single .site-main {
        margin: 7px auto 7px !important;
        padding: 0 5px !important;
    }
}

body.single .inside-article {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-subtle) !important;
    border-radius: 8px !important;
    padding: 36px 40px !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04) !important;
}

@media (max-width: 640px) {
    body.single .inside-article {
        padding: 20px 16px !important;
    }
}

/* SINGLE POST TITLE */
body.single .entry-title,
.post-title {
    font-size: 27px !important;
    font-weight: 800 !important;
    color: var(--brand-primary) !important;
    line-height: 1.32 !important;
    letter-spacing: -0.2px !important;
    margin: 0 0 12px 0 !important;
}

@media (max-width: 640px) {
    body.single .entry-title,
    .post-title {
        font-size: 21px !important;
    }
}

/* SINGLE POST META STRIP */
body.single .entry-meta,
.post-meta-strip {
    font-size: 13px !important;
    color: var(--text-muted) !important;
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    padding-bottom: 16px !important;
    border-bottom: 1px solid var(--border-subtle) !important;
    margin-bottom: 22px !important;
    flex-wrap: wrap !important;
}

body.single .entry-meta span,
.post-meta-strip span {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
}

body.single .entry-meta a,
.post-meta-strip a {
    color: var(--brand-primary) !important;
    text-decoration: none !important;
    font-weight: 700 !important;
}

body.single .entry-meta a:hover,
.post-meta-strip a:hover {
    color: var(--brand-accent) !important;
    text-decoration: underline !important;
}

/* HEADINGS H2, H3, H4 */
.entry-content h2 {
    font-size: 19px !important;
    font-weight: 800 !important;
    color: var(--brand-primary) !important;
    margin: 32px 0 16px 0 !important;
    padding: 10px 14px !important;
    background: #f8fafc !important;
    border-left: 4px solid var(--brand-primary) !important;
    border-radius: 0 6px 6px 0 !important;
    line-height: 1.4 !important;
}

.entry-content h2.maroon {
    border-left-color: var(--brand-accent) !important;
}

.entry-content h3 {
    font-size: 16px !important;
    font-weight: 700 !important;
    color: var(--brand-accent) !important;
    margin: 24px 0 10px 0 !important;
    line-height: 1.4 !important;
}

.entry-content h4 {
    font-size: 14.5px !important;
    font-weight: 700 !important;
    color: var(--brand-navy) !important;
    margin: 18px 0 8px 0 !important;
}

.entry-content p {
    font-size: 14.5px !important;
    line-height: 1.75 !important;
    color: #374151 !important;
    margin-bottom: 16px !important;
}

/* ==========================================================================
   5. OFFICIAL DATA TABLES STYLING (THEAD TH NAVY)
   ========================================================================== */
.entry-content table {
    width: 100% !important;
    border-collapse: collapse !important;
    margin: 20px 0 28px 0 !important;
    background: #ffffff !important;
    border-radius: 6px !important;
    overflow: hidden !important;
    border: 1px solid #cbd5e1 !important;
    font-size: 13.5px !important;
}

.entry-content table thead th,
.entry-content table th {
    background: var(--brand-primary) !important;
    color: #ffffff !important;
    padding: 12px 16px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-align: left !important;
    border-bottom: 2px solid var(--brand-gold) !important;
    border-right: 1px solid rgba(255, 255, 255, 0.12) !important;
    white-space: nowrap !important;
}

.entry-content table tbody td,
.entry-content table td {
    padding: 11px 16px !important;
    border-bottom: 1px solid #e5e7eb !important;
    border-right: 1px solid #f1f5f9 !important;
    color: var(--text-main) !important;
    vertical-align: middle !important;
    line-height: 1.5 !important;
}

.entry-content table tbody tr:nth-child(even) {
    background-color: #f9fafb !important;
}

.entry-content table tbody tr:hover {
    background-color: #f0f7ff !important;
}

.entry-content table tfoot td,
.entry-content table tr.total-row td {
    font-weight: 800 !important;
    background-color: #eff6ff !important;
    color: var(--brand-navy) !important;
    border-top: 2px solid #cbd5e1 !important;
}

/* ==========================================================================
   6. CLEAN MINIMAL FOOTER
   ========================================================================== */
body:not(.home) .site-footer {
    background: #ffffff !important;
    border-top: 1px solid var(--border-subtle) !important;
    padding: 22px 0 !important;
    font-size: 12.5px !important;
    color: var(--text-muted) !important;
}

body:not(.home) .site-footer .inside-site-info {
    max-width: 1140px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
}

body:not(.home) .site-footer a {
    color: var(--text-secondary) !important;
    text-decoration: none !important;
    transition: color 0.15s ease !important;
}

body:not(.home) .site-footer a:hover {
    color: var(--brand-primary) !important;
}

/* ==========================================================================
   7. HOMEPAGE PORTAL FULL STYLING (GUTENBERG / PAGE EDITOR SUPPORT)
   ========================================================================== */
.portal-wrapper, .portal-container {
    max-width: 1140px;
    margin: 0 auto;
    background: #ffffff;
    border: 1px solid #cfd8dc;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Nirmala UI", Arial, sans-serif;
    font-size: 13px;
    line-height: 1.55;
    color: #1e293b;
    box-sizing: border-box;
}

.portal-wrapper *, .portal-container * {
    box-sizing: border-box;
}

/* WIPE OUT WORDPRESS AUTO-P AND BR */
.portal-wrapper br, .portal-container br,
.portal-wrapper p:empty, .portal-container p:empty {
    display: none !important;
}

/* HEADER */
.portal-head, .portal-header {
    background: linear-gradient(90deg, #07233b 0%, #0e3b64 100%);
    color: #ffffff;
    padding: 14px 18px;
    border-bottom: 3px solid #c28800;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.head-brand, .header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.emblem-circle, .emblem-badge {
    width: 50px;
    height: 50px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #c28800;
    flex-shrink: 0;
}

.emblem-circle svg, .emblem-badge svg {
    width: 30px;
    height: 30px;
    fill: #851414;
}

.head-titles h1, .brand-text h1 {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.25;
    margin: 0;
}

.head-titles h2, .brand-text h2 {
    font-size: 12px;
    font-weight: 500;
    color: #fed7aa;
    margin: 2px 0 0;
}

.head-titles .dept, .brand-text .dept {
    font-size: 11px;
    color: #cbd5e1;
    margin-top: 2px;
}

/* TICKER */
.portal-ticker, .notice-ticker {
    display: flex;
    background: #fffbeb;
    border-bottom: 1px solid #fde68a;
    align-items: center;
    font-size: 12.5px;
    overflow: hidden;
    height: 36px;
}

.ticker-tag {
    background: #851414;
    color: #fff;
    padding: 0 12px;
    font-weight: 700;
    font-size: 11.5px;
    white-space: nowrap;
    height: 100%;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.ticker-marquee {
    white-space: nowrap;
    overflow: hidden;
    padding: 0 10px;
    color: #92400e;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.ticker-marquee span {
    display: inline-flex;
    animation: tickerScroll 26s linear infinite;
    white-space: nowrap;
    align-items: center;
}

.ticker-marquee a {
    color: #b45309;
    text-decoration: underline;
    margin-right: 35px;
    white-space: nowrap;
}

@keyframes tickerScroll {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* WORKSPACE */
.portal-workspace, .portal-body {
    display: flex;
    flex-direction: row;
    gap: 14px;
    padding: 14px 14px 6px;
}

.workspace-left, .portal-col-left {
    width: 320px;
    flex-shrink: 0;
}

.workspace-right, .portal-col-right {
    flex: 1;
    min-width: 0;
}

@media (max-width: 860px) {
    .portal-workspace, .portal-body {
        flex-direction: column;
        padding: 10px;
    }
    .workspace-left, .portal-col-left {
        width: 100%;
    }
}

.card-box, .panel {
    background: #ffffff;
    border: 1px solid #cfd8dc;
    margin-bottom: 14px;
}

.card-head, .panel-head {
    background: #0b3355;
    color: #ffffff;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 2px solid #c28800;
}

.card-head.maroon, .panel-head.maroon {
    background: #851414;
}

.action-list {
    display: flex;
    flex-direction: column;
}

.action-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    border-bottom: 1px solid #f1f5f9;
    color: #0f172a;
    font-weight: 600;
    font-size: 12.5px;
    text-decoration: none;
    transition: all 0.15s;
}

.action-item:hover {
    background: #eff6ff;
    color: #1d4ed8;
    padding-left: 15px;
}

/* GUIDELINES */
.guidelines-list {
    padding: 9px 12px;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.guide-item {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: 12px;
    line-height: 1.5;
    color: #334155;
    padding-bottom: 7px;
    border-bottom: 1px dashed #e2e8f0;
}

.guide-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.guide-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 1px;
}

.guide-icon.check {
    background: #dcfce7;
    color: #15803d;
    border: 1px solid #86efac;
}

.guide-text strong {
    color: #0b3355;
    display: inline;
}

/* TABLES */
.portal-table, .gov-table {
    width: 100%;
    border-collapse: collapse;
}

.portal-table th, .gov-table th {
    background: #f1f5f9;
    padding: 8px 10px;
    text-align: left;
    font-size: 12px;
    font-weight: 700;
    color: #334155;
    border-bottom: 2px solid #cfd8dc;
}

.portal-table td, .gov-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #edf2f7;
    font-size: 12px;
    vertical-align: middle;
}

.portal-table tr:hover, .gov-table tr:hover {
    background: #f8fafc;
}

.date-col, .date-badge {
    color: #64748b;
    font-weight: 600;
    font-size: 11.5px;
    white-space: nowrap;
}

.pdf-pill, .download-btn {
    background: #fff1f2;
    color: #851414;
    border: 1px solid #fecdd3;
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.pdf-pill:hover, .download-btn:hover {
    background: #ffe4e6;
}

/* TOPIC HUB */
.topic-hub, .topic-section {
    padding: 10px 14px 18px;
}

.hub-title, .topic-section-head {
    background: #0b3355;
    color: #ffffff;
    padding: 9px 14px;
    font-size: 13.5px;
    font-weight: 700;
    border-bottom: 2px solid #c28800;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hub-grid, .topic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 12px;
}

@media (max-width: 540px) {
    .hub-grid, .topic-grid {
        grid-template-columns: 1fr;
    }
}

.hub-card, .topic-card {
    background: #ffffff;
    border: 1px solid #cfd8dc;
    border-top: 3px solid #0b3355;
    padding: 14px 16px;
    text-decoration: none;
    color: #1e293b;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}

.hub-card:hover, .topic-card:hover {
    border-top-color: #851414;
    border-color: #94a3b8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.hub-card-top, .topic-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.icon, .topic-icon {
    font-size: 22px;
    line-height: 1;
}

.tag, .topic-tag {
    font-size: 10.5px;
    font-weight: 700;
    padding: 2px 7px;
    background: #f1f5f9;
    color: #475569;
    border-radius: 2px;
}

.hub-card h3, .topic-card h3 {
    font-size: 14px;
    font-weight: 700;
    color: #0b3355;
    margin: 4px 0 6px 0;
    line-height: 1.35;
}

.hub-card:hover h3, .topic-card:hover h3 {
    color: #851414;
}

.hub-card p, .topic-card p {
    font-size: 12px;
    color: #64748b;
    line-height: 1.5;
    margin: 0 0 12px 0;
    flex-grow: 1;
}

.hub-btn, .topic-btn {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    font-size: 11.5px;
    font-weight: 700;
    color: #851414;
    padding-top: 8px;
    border-top: 1px dashed #e2e8f0;
}

.hub-card:hover .hub-btn, .topic-card:hover .topic-btn {
    color: #1d4ed8;
}

/* FOOTER */
.portal-helpdesk {
    background: #f8fafc;
    border-top: 2px solid #0f4675;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 12px;
}

.help-contacts {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.gov-disclaimer {
    font-size: 11px;
    color: #64748b;
}

@media (max-width: 640px) {
    .portal-head, .portal-header {
        padding: 10px 12px;
    }
    .head-brand, .header-brand {
        gap: 10px;
    }
    .emblem-circle, .emblem-badge {
        width: 40px;
        height: 40px;
        border-width: 1.5px;
    }
    .emblem-circle svg, .emblem-badge svg {
        width: 24px;
        height: 24px;
    }
    .head-titles h1, .brand-text h1 {
        font-size: 15px;
    }
    .portal-ticker, .notice-ticker {
        height: 32px;
    }
    .ticker-tag {
        padding: 0 8px;
        font-size: 10.5px;
    }
}
