/*
Theme Name: Ambedkar Sevak Samiti Portal
Theme URI: https://ambedkarsewaksamiti.org/
Author: livesk.in
Description: Responsive Hindi WordPress theme for Ambedkar Sevak Samiti with Fixed Hero Banner, Latest posts, Video section, Notice board and Social Share buttons.
Version: 5.0.3
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: ass-portal
*/

:root {
    --ass-blue: #123f86;
    --ass-blue-dark: #082653;
    --ass-blue-deep: #061b3b;
    --ass-gold: #f6bd32;
    --ass-red: #b4232f;
    --ass-text: #172033;
    --ass-muted: #687386;
    --ass-bg: #f4f7fb;
    --ass-border: #e3e9f2;
    --ass-white: #fff;
    --ass-radius: 18px;
    --ass-shadow: 0 12px 34px rgba(17, 38, 75, .09);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body {
    overflow-x: hidden !important;
    max-width: 100% !important;
    margin: 0;
    background: var(--ass-bg);
    color: var(--ass-text);
    font-family: "Mukta", "Noto Sans Devanagari", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.7;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ass-blue); text-decoration: none; }
a:hover { color: var(--ass-red); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

.ass-container { width: min(1200px, calc(100% - 32px)); margin-inline: auto; }

/* Topbar */
.ass-topbar { background: var(--ass-blue-deep); color: #e8efff; font-size: 13px; }
.ass-topbar-inner { min-height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ass-topbar a { color: #fff; }
.ass-topbar-right { display: flex; flex-wrap: wrap; gap: 16px; }

/* Header */
.ass-header { background: #fff; border-bottom: 4px solid var(--ass-gold); box-shadow: 0 5px 18px rgba(15, 35, 70, .05); }
.ass-header-inner { min-height: 124px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-block: 16px; }
.ass-brand { display: flex; align-items: center; gap: 17px; min-width: 0; }
.ass-logo, .custom-logo { width: 82px; height: 82px; object-fit: contain; flex: 0 0 auto; }
.ass-brand-copy { min-width: 0; }
.ass-jai-bhim { display: inline-block; padding: 2px 12px; border-radius: 999px; background: #fff0bf; color: #604300; font-size: 11px; font-weight: 800; letter-spacing: .04em; }
.ass-site-title { margin: 5px 0 2px; color: var(--ass-blue); font-size: clamp(21px, 2.5vw, 32px); line-height: 1.3; font-weight: 900; }
.ass-site-title a { color: inherit; }
.ass-reg { margin: 0; color: var(--ass-muted); font-size: 13px; }
.ass-president { margin: 3px 0 0; color: var(--ass-red); font-size: 14px; font-weight: 700; }
.ass-header-badge { padding: 9px 16px; background: var(--ass-red); color: #fff; border-radius: 999px; font-weight: 800; white-space: nowrap; }

/* Navigation & Mobile Menu */
.ass-nav { position: sticky; top: 0; z-index: 1000; background: var(--ass-blue); box-shadow: 0 8px 20px rgba(6, 27, 59, .15); }
.ass-nav-inner { display: flex; min-height: 56px; align-items: center; justify-content: space-between; gap: 16px; }
.ass-desktop-menu { display: flex; align-items: center; }
.ass-menu, .ass-menu ul { list-style: none; margin: 0; padding: 0; }
.ass-menu > ul, ul.ass-menu { display: flex; align-items: center; gap: 4px; }
.ass-menu li { position: relative; }
.ass-menu a { display: block; padding: 16px 13px; color: #fff; font-size: 14px; font-weight: 700; border-radius: 8px; }
.ass-menu a:hover, .ass-menu .current-menu-item > a, .ass-menu .current_page_item > a { background: rgba(255,255,255,.13); color: #ffdc7b; }
.ass-menu .sub-menu { display: none; position: absolute; top: 100%; left: 0; min-width: 220px; padding: 8px; background: #fff; border-radius: 12px; box-shadow: var(--ass-shadow); z-index: 9999; }
.ass-menu .sub-menu a { color: var(--ass-text); padding: 10px 12px; }
.ass-menu .sub-menu a:hover { background: #edf3ff; color: var(--ass-blue); }
.ass-menu li:hover > .sub-menu, .ass-menu li:focus-within > .sub-menu { display: block; }

.ass-register-link { display: inline-flex; align-items: center; justify-content: center; padding: 9px 13px; border-radius: 9px; background: var(--ass-red); color: #fff; font-size: 13px; font-weight: 800; white-space: nowrap; }
.ass-register-link:hover { background: #8e1721; color: #fff; }

.ass-menu-toggle { display: none; border: 1px solid rgba(255,255,255,.3); border-radius: 9px; padding: 7px 12px; color: #fff; background: transparent; cursor: pointer; font-size: 14px; font-weight: 700; }
.ass-mobile-menu { display: none; width: 100%; padding: 10px 16px; background: var(--ass-blue-deep); border-top: 1px solid rgba(255,255,255,0.1); }
.ass-mobile-menu.is-open { display: block !important; }
.ass-mobile-menu ul { list-style: none; margin: 0; padding: 0; }
.ass-mobile-menu li a { display: block; padding: 10px 12px; color: #fff; border-radius: 8px; font-weight: 700; border-bottom: 1px solid rgba(255,255,255,0.06); }
.ass-mobile-menu li a:hover { background: rgba(255,255,255,.12); color: #ffdc7b; }

@media (max-width: 900px) {
    .ass-desktop-menu { display: none !important; }
    .ass-menu-toggle { display: inline-flex !important; align-items: center; gap: 6px; }
    .ass-nav-inner { flex-wrap: wrap; padding-block: 8px; }
}

/* Fixed Hero Banner */
.ass-hero-banner {
    position: relative;
    display: block;
    width: min(1280px, calc(100% - 32px));
    height: clamp(270px, 38vw, 470px);
    margin: 24px auto 30px;
    overflow: hidden;
    border-radius: 22px;
    background: #082653;
}
.ass-hero-banner .ass-hero-img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center;
}
.ass-hero-banner .ass-slide-shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(90deg, rgba(4, 19, 43, 0.85), rgba(4, 19, 43, 0.15));
}
.ass-hero-banner .ass-slide-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    padding: clamp(20px, 5vw, 65px);
    color: #fff;
}
.ass-hero-banner .ass-slide-copy { width: 100%; max-width: 650px; }
.ass-hero-banner .ass-slide-content h2 { color: #fff; font-size: clamp(26px, 5vw, 50px); line-height: 1.3; }
.ass-hero-banner .ass-slide-content p { display: block; max-width: 100%; color: #fff; }

/* Newspaper Grid Layout */
.ass-news-portal-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
}
@media (min-width: 992px) {
    .ass-news-portal-grid {
        grid-template-columns: 2.2fr 1fr;
    }
}

.ass-top-news-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
@media (min-width: 768px) {
    .ass-top-news-split {
        grid-template-columns: 1.3fr 1fr;
    }
}

.ass-featured-news-big {
    background: #fff;
    border: 1px solid var(--ass-border);
    border-radius: 12px;
    overflow: hidden;
}
.ass-news-img-box {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #000;
}
.ass-news-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.ass-cat-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--ass-blue);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 4px 10px;
    text-transform: uppercase;
    z-index: 2;
}
.ass-featured-news-body { padding: 15px; }
.ass-news-meta { font-size: 11.5px; color: var(--ass-muted); font-weight: 700; margin-bottom: 6px; }
.ass-news-title-big { font-size: 18px; font-weight: 900; line-height: 1.4; margin: 0 0 8px; }
.ass-news-title-big a { color: var(--ass-blue-dark); }
.ass-news-excerpt { font-size: 13px; color: #475569; margin: 0; line-height: 1.6; }

/* Side Thumbnail List */
.ass-side-news-list, .ass-recent-news-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.ass-side-news-item {
    display: flex;
    gap: 12px;
    align-items: center;
    background: #fff;
    padding: 8px;
    border-radius: 8px;
    border: 1px solid var(--ass-border);
}
.ass-side-thumb {
    width: 80px;
    height: 65px;
    flex-shrink: 0;
    border-radius: 6px;
    overflow: hidden;
    background: #e2e8f0;
}
.ass-side-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ass-side-news-info { flex-grow: 1; }
.ass-side-news-title { font-size: 13px; font-weight: 800; line-height: 1.35; margin: 0; }
.ass-side-news-title a { color: var(--ass-blue); }

.ass-sidebar-box {
    background: #fff;
    border: 1px solid var(--ass-border);
    border-radius: 12px;
    padding: 15px;
}
.ass-sidebar-head {
    border-bottom: 2px solid var(--ass-border);
    margin-bottom: 15px;
    padding-bottom: 8px;
}
.ass-tab-active {
    color: var(--ass-red);
    font-weight: 900;
    font-size: 14px;
    border-bottom: 2px solid var(--ass-red);
    padding-bottom: 8px;
}

/* Notice Board */
.ass-notice-box { position: sticky; top: 78px; overflow: hidden; border: 1px solid var(--ass-border); border-top: 4px solid var(--ass-red); border-radius: 16px; background: #fff; box-shadow: var(--ass-shadow); }
.ass-notice-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 17px 18px; background: var(--ass-red); color: #fff; }
.ass-notice-head h2 { margin: 0; color: #fff; font-size: 21px; font-weight: 900; }
.ass-notice-list { max-height: 520px; overflow-y: auto; padding: 7px 17px 0; }
.ass-notice-item { padding: 14px 0; border-bottom: 1px solid #edf0f5; }
.ass-notice-date { display: inline-block; padding: 2px 8px; border-radius: 5px; background: #fff2c9; color: #765500; font-size: 11px; font-weight: 900; }
.ass-notice-item a { display: block; margin-top: 6px; color: #26364e; font-size: 14px; font-weight: 700; }
.ass-empty { padding: 20px; color: var(--ass-muted); text-align: center; font-size: 14px; }

/* Footer */
.ass-footer { margin-top: auto; background: var(--ass-blue-deep); color: #dbe6fb; }
.ass-footer-grid { display: grid; grid-template-columns: 1fr 1fr 1.1fr; gap: 34px; padding-block: 42px; }
.ass-footer h2, .ass-footer h3 { margin: 0 0 15px; padding-bottom: 10px; border-bottom: 1px solid rgba(255,255,255,.14); color: var(--ass-gold); font-size: 18px; font-weight: 900; }
.ass-footer p { margin: 0 0 10px; font-size: 14px; }
.ass-footer ul { margin: 0; padding: 0; list-style: none; }
.ass-footer li { margin-bottom: 8px; font-size: 14px; }
.ass-footer a { color: #eaf1ff; }
.ass-footer a:hover { color: var(--ass-gold); }
.ass-footer-card { padding: 18px; border: 1px solid rgba(255,255,255,.16); border-radius: 15px; background: rgba(255,255,255,.06); }
.ass-footer-bottom { padding: 15px 0; border-top: 1px solid rgba(255,255,255,.1); color: #afc0de; text-align: center; font-size: 12px; }

/* =====================================
   SINGLE POST PAGE FIXES & PADDING
===================================== */

.ass-single-wrapper {
    padding: 30px 0 50px;
    background: var(--ass-bg);
}

.ass-single-container {
    max-width: 900px !important;
    width: calc(100% - 32px) !important;
    margin: 0 auto !important;
}

.ass-single-article {
    background: #ffffff;
    border: 1px solid var(--ass-border);
    border-radius: 18px;
    box-shadow: var(--ass-shadow);
    overflow: hidden;
}

/* Single Header Fix */
.ass-single-article .ass-article-head {
    padding: 30px 24px 20px;
    background: linear-gradient(120deg, var(--ass-blue), var(--ass-blue-dark));
    color: #ffffff;
}

.ass-single-article .ass-article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #ffdf7e;
    font-weight: 700;
    margin-bottom: 10px;
}

.ass-meta-sep { opacity: 0.6; }

.ass-single-article .ass-article-title {
    margin: 0;
    color: #ffffff;
    font-size: clamp(22px, 3.5vw, 36px);
    line-height: 1.35;
    font-weight: 900;
}

/* Featured Image Fix */
.ass-single-article .ass-featured-image {
    width: 100%;
    max-height: 480px;
    overflow: hidden;
    background: #000;
}

.ass-single-article .ass-featured-image img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
    display: block;
}

/* Content Body Left-Right Padding Fix */
.ass-single-article .ass-entry-content {
    padding: 28px 24px;
    font-size: 17px;
    line-height: 1.85;
    color: #29364b;
    overflow-wrap: anywhere;
}

.ass-single-article .ass-entry-content p {
    margin-bottom: 1.2em;
}

.ass-single-article .ass-entry-content img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: 10px;
    margin: 15px auto;
    display: block;
}

.ass-single-article .ass-entry-content iframe,
.ass-single-article .ass-entry-content video {
    max-width: 100% !important;
    width: 100%;
    border-radius: 10px;
}

/* Tags & Footer Padding Fix */
.ass-post-tags-container {
    padding: 15px 24px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    border-top: 1px dashed var(--ass-border);
    font-size: 14px;
}

.ass-single-article .ass-article-foot {
    padding: 20px 24px;
    background: #f8faff;
    border-top: 1px solid var(--ass-border);
}

.ass-share-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ass-share-label {
    font-size: 14px;
    font-weight: 800;
    color: var(--ass-text);
}

.ass-share-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.ass-share-buttons a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 8px;
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
}

.ass-btn-wa { background: #25D366; }
.ass-btn-fb { background: #1877F2; }
.ass-btn-tw { background: #000000; }
.ass-btn-tg { background: #0088cc; }

/* Author Box Fix */
.ass-author-box {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    background: #f1f5f9;
    border-top: 2px solid var(--ass-gold);
}

.ass-author-avatar img {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--ass-blue);
}

.ass-author-details { flex: 1; }
.ass-author-role {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    background: #cbd5e1;
    color: var(--ass-blue-dark);
    padding: 2px 8px;
    border-radius: 4px;
}
.ass-author-name {
    margin: 4px 0 2px;
    font-size: 18px;
    font-weight: 900;
    color: var(--ass-blue-dark);
}
.ass-author-bio {
    margin: 0;
    font-size: 13px;
    color: var(--ass-muted);
}

/* Post Navigation Fix */
.ass-post-navigation {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.ass-nav-card {
    background: #fff;
    border: 1px solid var(--ass-border);
    border-radius: 12px;
    padding: 14px 18px;
}

.ass-nav-label { display: block; font-size: 12px; font-weight: 800; color: var(--ass-red); }
.ass-nav-title { font-size: 14px; font-weight: 700; color: var(--ass-blue); }
.ass-nav-next { text-align: right; }

@media (max-width: 600px) {
    .ass-single-article .ass-article-head,
    .ass-single-article .ass-entry-content,
    .ass-post-tags-container,
    .ass-single-article .ass-article-foot,
    .ass-author-box {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
    .ass-author-box {
        flex-direction: column;
        text-align: center;
    }
}

/* =====================================
   PHOTO GALLERY 4x6 GRID STYLING
===================================== */
.ass-gallery-4x6-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 Columns */
    gap: 16px;
    margin-top: 25px;
    margin-bottom: 25px;
}

.ass-gallery-thumb-box {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: 10px;
    overflow: hidden;
    background: #0f172a;
    border: 1px solid var(--ass-border);
    box-shadow: 0 3px 6px rgba(0,0,0,0.06);
}

.ass-gallery-thumb-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.ass-gallery-thumb-box:hover img {
    transform: scale(1.06);
}

.ass-thumb-overlay {
    position: absolute;
    inset: 0;
    background: rgba(18, 63, 134, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 18px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.ass-gallery-thumb-box:hover .ass-thumb-overlay {
    opacity: 1;
}

/* Responsive Breakpoints */
@media (max-width: 900px) {
    .ass-gallery-4x6-grid {
        grid-template-columns: repeat(3, 1fr); /* Tablets: 3 Columns */
    }
}

@media (max-width: 600px) {
    .ass-gallery-4x6-grid {
        grid-template-columns: repeat(2, 1fr); /* Mobile: 2 Columns */
        gap: 10px;
    }
}
/* =====================================
   GALLERY THUMBNAIL DISPLAY FIX
===================================== */
.ass-gallery-4x6-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 16px !important;
    margin-top: 25px !important;
    margin-bottom: 25px !important;
}

.ass-gallery-thumb-box {
    position: relative !important;
    width: 100% !important;
    aspect-ratio: 4 / 3 !important;
    border-radius: 10px !important;
    overflow: hidden !important;
    background: #0f172a !important;
    border: 1px solid var(--ass-border, #cbd5e1) !important;
    box-shadow: 0 3px 6px rgba(0,0,0,0.06) !important;
}

.ass-gallery-thumb-box a {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
}

.ass-gallery-thumb-box img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.ass-thumb-overlay {
    position: absolute !important;
    inset: 0 !important;
    background: rgba(18, 63, 134, 0.45) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #ffffff !important;
    font-size: 18px !important;
    opacity: 0 !important;
    transition: opacity 0.2s ease !important;
}

.ass-gallery-thumb-box:hover .ass-thumb-overlay {
    opacity: 1 !important;
}

/* Responsive for mobile */
@media (max-width: 768px) {
    .ass-gallery-4x6-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* =====================================
   SCROLLABLE NOTICE BOARD STYLING
===================================== */
.ass-notice-list-scroll {
    max-height: 380px; /* Apni zaroorat ke hisab se height kam ya zyada kar sakte hain */
    overflow-y: auto;  /* Scrollable banata hai */
    padding-right: 5px;
    scrollbar-width: thin; /* Firefox ke liye patla scrollbar */
}

/* Custom Scrollbar for Chrome/Edge */
.ass-notice-list-scroll::-webkit-scrollbar {
    width: 6px;
}
.ass-notice-list-scroll::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
.ass-notice-list-scroll::-webkit-scrollbar-thumb:hover {
    background: #0d47a1;
}