/* ============================================================
   style5.css — Site5 Theme: Pattern BG | Madrasha (Islamic)
   Deep green + gold, geometric accents, pattern background
   ============================================================ */

/* ---- CSS Variables ---- */
:root {
    --s5-green: #1b5e20;
    --s5-green-dark: #0d3b12;
    --s5-green-light: #e8f5e9;
    --s5-gold: #d4a017;
    --s5-gold-light: #fdf6e3;
    --s5-accent: #d4a017;
    --s5-text: #222;
    --s5-muted: #666;
    --s5-border: #c8c8c8;
}

/* ---- Body: tiled Islamic pattern background ---- */
body.s5-body {
    background-image: url('/assets/site/images/main-bg.jpg');
    background-repeat: repeat;
    background-color: #9e9e9e;
    font-family: 'Hind Siliguri', 'Noto Sans', Arial, sans-serif;
    font-size: 13px;
    color: var(--s5-text);
    margin: 0;
    padding: 20px 0;
    min-height: 100vh;
}

/* ---- Container: white box ---- */
.s5-container {
    background: #fff;
    padding: 0;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    max-width: 1200px;
}

/* ============================================================
   HEADER
   ============================================================ */

.s5-topbar {
    background: var(--s5-green-dark);
    color: rgba(255,255,255,0.9);
    font-size: 0.72rem;
    padding: 4px 0;
}

.s5-topbar-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.s5-topbar-item i {
    font-size: 0.65rem;
    opacity: 0.8;
}

/* Desktop School Header */
.s5-school-header {
    background: #fff;
    border-bottom: 3px solid var(--s5-green);
    padding: 0;
    position: relative;
}

.s5-logo {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--s5-green);
    flex-shrink: 0;
}

.s5-school-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--s5-green-dark);
    margin: 0 0 2px;
    line-height: 1.2;
}

.s5-school-tagline {
    font-size: 0.8rem;
    color: var(--s5-muted);
    font-style: italic;
    margin: 0 0 2px;
}

.s5-msg-btn {
    display: inline-block;
    background: var(--s5-green);
    color: #fff;
    font-size: 0.72rem;
    padding: 4px 10px;
    border: none;
    text-decoration: none;
    margin-bottom: 4px;
    transition: background 0.2s;
}

.s5-msg-btn:hover {
    background: var(--s5-green-dark);
    color: #fff;
}

/* Mobile Header */
.s5-mobile-header {
    background: var(--s5-green);
    color: #fff;
    text-align: center;
    padding: 10px 12px;
}

.s5-mobile-school-name {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 2px;
}

.s5-mobile-school-meta {
    font-size: 0.7rem;
    color: rgba(255,255,255,0.85);
    margin: 0 0 6px;
}

.s5-mobile-cta {
    display: inline-block;
    background: var(--s5-gold);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 4px 14px;
    text-decoration: none;
}

/* Notice Bar */
.s5-notice-bar {
    background: var(--s5-gold-light);
    border-bottom: 2px solid var(--s5-gold);
    padding: 4px 0;
    font-size: 0.75rem;
}

.s5-notice-label {
    background: var(--s5-gold);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 3px 8px;
    white-space: nowrap;
    flex-shrink: 0;
    margin-right: 8px;
}

.s5-notice-bar marquee a {
    color: var(--s5-text);
    text-decoration: none;
    margin-right: 20px;
}

.s5-notice-bar marquee a:hover {
    color: var(--s5-green);
}

/* Navbar */
.s5-navbar {
    background: var(--s5-green) !important;
    padding: 0;
}

.s5-navbar .navbar-nav .nav-link {
    color: rgba(255,255,255,0.92) !important;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 10px 12px;
    transition: background 0.2s;
}

.s5-navbar .navbar-nav .nav-link:hover,
.s5-navbar .navbar-nav .nav-link.active {
    background: var(--s5-green-dark);
    color: #fff !important;
}

.s5-navbar .navbar-toggler {
    border-color: rgba(255,255,255,0.5);
    padding: 4px 8px;
}

.s5-navbar .navbar-toggler-icon {
    filter: invert(1);
}

.s5-navbar .dropdown-menu {
    border: 1px solid var(--s5-border);
    padding: 0;
    min-width: 200px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.s5-navbar .dropdown-item {
    font-size: 0.78rem;
    padding: 7px 14px;
    border-bottom: 1px solid #f0f0f0;
    color: var(--s5-text);
}

.s5-navbar .dropdown-item:last-child {
    border-bottom: none;
}

.s5-navbar .dropdown-item:hover {
    background: var(--s5-green-light);
    color: var(--s5-green-dark);
}

/* ============================================================
   CONTENT BOXES — with gold top accent
   ============================================================ */

.s5-box {
    border: 1px solid var(--s5-border);
    margin-bottom: 8px;
    background: #fff;
}

.s5-box-head {
    background: var(--s5-green);
    color: #fff;
    padding: 5px 10px;
    font-size: 0.8rem;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 3px solid var(--s5-gold);
}

.s5-box-head a,
.s5-box-viewall {
    color: rgba(255,255,255,0.85);
    font-size: 0.7rem;
    text-decoration: none;
}

.s5-box-head a:hover,
.s5-box-viewall:hover {
    color: #fff;
    text-decoration: underline;
}

/* ============================================================
   NOTICE LIST
   ============================================================ */

.s5-notice-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.s5-notice-list li {
    padding: 4px 8px;
    border-bottom: 1px dotted var(--s5-border);
    font-size: 0.78rem;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.s5-notice-list li:last-child {
    border-bottom: none;
}

.s5-notice-list li::before {
    content: '✦';
    color: var(--s5-gold);
    font-size: 0.55rem;
    margin-top: 3px;
    flex-shrink: 0;
}

.s5-notice-list li a {
    color: var(--s5-text);
    text-decoration: none;
    line-height: 1.4;
}

.s5-notice-list li a:hover {
    color: var(--s5-green);
}

/* ============================================================
   SLIDER
   ============================================================ */

.s5-slider-img {
    height: 280px;
    object-fit: cover;
    width: 100%;
    display: block;
}

.s5-slider-caption {
    background: rgba(0,0,0,0.5);
    padding: 6px 12px;
    bottom: 10px;
    left: 5%;
    right: 5%;
}

.s5-slider-caption h5 { font-size: 0.9rem; margin: 0; color: #fff; }
.s5-slider-caption p { font-size: 0.75rem; margin: 0; color: rgba(255,255,255,0.9); }

/* ============================================================
   SIDEBAR: MESSAGE BOX
   ============================================================ */

.s5-msg-photo {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border: 2px solid var(--s5-gold);
    flex-shrink: 0;
}

.s5-msg-name {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--s5-green-dark);
    margin: 0 0 1px;
}

.s5-msg-designation {
    font-size: 0.7rem;
    color: var(--s5-muted);
    margin: 0 0 4px;
}

.s5-msg-text {
    font-size: 0.72rem;
    color: var(--s5-text);
    margin: 0 0 4px;
    line-height: 1.4;
}

.s5-read-more {
    font-size: 0.7rem;
    color: var(--s5-green);
    text-decoration: none;
}

.s5-read-more:hover {
    text-decoration: underline;
}

/* ============================================================
   SIDEBAR: NOTICE TICKER
   ============================================================ */

.s5-sb-ticker {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.s5-sb-list {
    position: absolute;
    width: 100%;
    top: 0;
    list-style: none;
    padding: 4px;
    margin: 0;
}

.s5-sb-list li {
    padding: 4px 6px;
    border-bottom: 1px dotted var(--s5-border);
    font-size: 0.72rem;
}

.s5-sb-list li a {
    color: var(--s5-text);
    text-decoration: none;
    line-height: 1.4;
    display: block;
}

.s5-sb-list li a:hover {
    color: var(--s5-green);
}

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

.s5-visitor-wrap {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: var(--s5-border);
}

.s5-visitor-cell {
    background: #fff;
    text-align: center;
    padding: 12px 8px;
}

.s5-visitor-num {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--s5-green-dark);
    display: block;
}

.s5-visitor-label {
    font-size: 0.72rem;
    color: var(--s5-muted);
    display: block;
}

/* ============================================================
   STARS OF INSTITUTION
   ============================================================ */

.s5-stars-ticker-wrap {
    overflow: hidden;
    padding: 6px 4px;
}

.s5-stars-track {
    display: inline-flex;
    white-space: nowrap;
}

.s5-star-card {
    display: inline-block;
    width: 90px;
    text-align: center;
    padding: 4px;
}

.s5-star-card-photo {
    width: 52px;
    height: 52px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--s5-gold);
    display: block;
    margin: 0 auto 4px;
}

.s5-star-card-name {
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--s5-green-dark);
    margin: 0 0 1px;
    white-space: normal;
    line-height: 1.2;
}

.s5-star-card-uni {
    font-size: 0.62rem;
    color: var(--s5-muted);
    margin: 0;
    white-space: normal;
}

.s5-star-card-batch {
    font-size: 0.62rem;
    color: var(--s5-muted);
    margin: 0;
}

/* ============================================================
   GOOGLE MAP
   ============================================================ */

.s5-map-iframe {
    width: 100%;
    height: 220px;
    border: none;
    display: block;
}

/* ============================================================
   ABOUT TEXT
   ============================================================ */

.s5-about-text {
    font-size: 0.75rem;
    color: var(--s5-text);
    line-height: 1.6;
    padding: 8px;
    margin: 0;
}

/* ============================================================
   IMPORTANT LINKS
   ============================================================ */

.s5-imp-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.s5-imp-links li {
    padding: 4px 8px;
    border-bottom: 1px dotted var(--s5-border);
    font-size: 0.75rem;
}

.s5-imp-links li:last-child {
    border-bottom: none;
}

.s5-imp-links li::before {
    content: '☆';
    color: var(--s5-gold);
    margin-right: 5px;
}

.s5-imp-links li a {
    color: var(--s5-text);
    text-decoration: none;
}

.s5-imp-links li a:hover {
    color: var(--s5-green);
}

/* ============================================================
   HIGHLIGHT BUTTONS
   ============================================================ */

.s5-hbtn {
    display: inline-block;
    padding: 4px 14px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff !important;
    text-decoration: none;
    transition: opacity 0.2s;
}

.s5-hbtn:hover { opacity: 0.85; color: #fff !important; }

/* ============================================================
   PAGE HEADER
   ============================================================ */

.s5-page-header {
    background: var(--s5-green-dark);
    color: #fff;
    padding: 22px 12px 0;
    position: relative;
    overflow: hidden;
}

.s5-page-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
}

.s5-page-subtitle {
    color: rgba(255,255,255,0.85);
    font-size: 0.88rem;
}

.s5-page-header svg {
    display: block;
    width: 100%;
}

/* ============================================================
   FOOTER — dark green with gold accents
   ============================================================ */

.s5-footer {
    background: var(--s5-green-dark);
    color: rgba(255,255,255,0.8);
    padding: 20px 0 0;
    position: relative;
}

/* Decorative top border with Islamic pattern feel */
.s5-footer::before {
    content: '✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦ ✦';
    display: block;
    text-align: center;
    color: var(--s5-gold);
    font-size: 0.6rem;
    letter-spacing: 4px;
    padding: 4px 0;
    opacity: 0.6;
}

.s5-footer-heading {
    color: var(--s5-gold);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.s5-footer-text {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.75);
    line-height: 1.6;
}

.s5-footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.s5-footer-links li {
    margin-bottom: 5px;
}

.s5-footer-links li a {
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-size: 0.75rem;
}

.s5-footer-links li a:hover {
    color: var(--s5-gold);
}

.s5-footer-contact {
    list-style: none;
    padding: 0;
    margin: 0;
}

.s5-footer-contact li {
    display: flex;
    gap: 8px;
    margin-bottom: 7px;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.75);
    align-items: flex-start;
}

.s5-footer-contact li i {
    color: var(--s5-gold);
    margin-top: 2px;
    flex-shrink: 0;
}

.s5-social-icons {
    display: flex;
    gap: 8px;
}

.s5-social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: rgba(255,255,255,0.15);
    color: #fff;
    font-size: 0.75rem;
    text-decoration: none;
    transition: background 0.2s;
}

.s5-social-icons a:hover {
    background: var(--s5-gold);
    color: #fff;
}

.s5-footer-hr {
    border-color: rgba(255,255,255,0.15);
    margin: 16px 0 0;
}

.s5-footer-bottom {
    background: rgba(0,0,0,0.2);
    padding: 8px 12px;
}

.s5-footer-copy {
    font-size: 0.72rem;
    color: rgba(255,255,255,0.65);
    margin: 0;
}

.s5-footer-copy a {
    color: var(--s5-gold);
    text-decoration: none;
}

.s5-footer-copy a:hover {
    text-decoration: underline;
}

/* ============================================================
   INNER PAGES
   ============================================================ */

.s5-inner-page { min-height: 60vh; padding: 12px 0 24px; }
.s5-card { background: #fff; border: 1px solid var(--s5-border); margin-bottom: 12px; overflow: hidden; }
.s5-card-header { background: var(--s5-green); color: #fff; padding: 7px 12px; font-weight: 700; font-size: 0.82rem; border-top: 3px solid var(--s5-gold); }
.s5-card-body { padding: 14px; }
.s5-card-footer { padding: 10px 14px; border-top: 1px solid var(--s5-border); background: #fafafa; }
.s5-page-section-header { border-left: 4px solid var(--s5-gold); padding: 5px 10px; background: var(--s5-green-light); margin-bottom: 14px; }
.s5-page-section-header h4 { margin: 0; font-size: 0.95rem; font-weight: 700; color: var(--s5-green-dark); }
.s5-content-body { font-size: 0.9rem; line-height: 1.7; }
.s5-content-body img { max-width: 100%; height: auto; }
.s5-content-body table { width: 100%; overflow-x: auto; display: block; }
.s5-content-body iframe { max-width: 100%; }
.s5-badge { display: inline-block; padding: 2px 8px; font-size: 0.72rem; font-weight: 600; background: var(--s5-gold-light); color: var(--s5-green-dark); border: 1px solid var(--s5-gold); }
.s5-notice-item-row { background: #fff; border: 1px solid var(--s5-border); padding: 10px 12px; margin-bottom: 8px; border-left: 3px solid var(--s5-gold); transition: transform 0.2s; }
.s5-notice-item-row:hover { transform: translateX(3px); }
.s5-notice-title { font-weight: 600; color: var(--s5-green-dark); font-size: 0.88rem; margin-bottom: 3px; }
.s5-notice-meta { font-size: 0.75rem; color: var(--s5-muted); }
.s5-event-list-item { background: #fff; border: 1px solid var(--s5-border); padding: 12px; margin-bottom: 10px; display: flex; gap: 12px; align-items: flex-start; transition: transform 0.2s; }
.s5-event-list-item:hover { transform: translateX(3px); }
.s5-event-list-date { background: var(--s5-green); color: #fff; min-width: 46px; height: 46px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; }
.s5-event-list-day { font-size: 1rem; }
.s5-event-list-mon { font-size: 0.62rem; text-transform: uppercase; }
.s5-faculty-card { background: #fff; border: 1px solid var(--s5-border); overflow: hidden; transition: transform 0.2s; margin-bottom: 14px; }
.s5-faculty-card:hover { transform: translateY(-3px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.s5-faculty-img { width: 100%; height: 200px; object-fit: cover; }
.s5-faculty-body { padding: 10px; }
.s5-faculty-name { font-size: 0.88rem; font-weight: 700; color: var(--s5-green-dark); margin-bottom: 2px; }
.s5-faculty-designation { font-size: 0.75rem; color: var(--s5-muted); }
.s5-dept-card { background: #fff; border: 1px solid var(--s5-border); border-top: 3px solid var(--s5-gold); padding: 16px; text-align: center; cursor: pointer; transition: transform 0.2s; margin-bottom: 14px; }
.s5-dept-card:hover { transform: translateY(-3px); background: var(--s5-green-light); }
.s5-gallery-album-card { background: #fff; border: 1px solid var(--s5-border); overflow: hidden; transition: transform 0.2s; margin-bottom: 14px; }
.s5-gallery-album-card:hover { transform: translateY(-3px); }
.s5-gallery-album-img { width: 100%; height: 160px; object-fit: cover; }
.s5-gallery-album-body { padding: 10px; }
.s5-gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; }
.s5-gallery-item { position: relative; padding-bottom: 100%; overflow: hidden; }
.s5-gallery-item img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.s5-gallery-overlay { position: absolute; inset: 0; background: rgba(13,59,18,0.6); display: flex; align-items: center; justify-content: center; color: #fff; opacity: 0; transition: opacity 0.3s; }
.s5-gallery-item:hover .s5-gallery-overlay { opacity: 1; }
.s5-search-filter-box { background: #fff; border: 1px solid var(--s5-border); padding: 14px; margin-bottom: 16px; }
.s5-profile-img { max-width: 180px; width: 100%; border: 3px solid var(--s5-gold); }
.s5-contact-info-box { background: var(--s5-green-light); padding: 16px; border-left: 4px solid var(--s5-gold); }
.s5-contact-info-item { display: flex; gap: 10px; margin-bottom: 12px; align-items: flex-start; }
.s5-contact-info-icon { width: 32px; height: 32px; background: var(--s5-green); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.78rem; }

/* Primary button */
.s5-btn-primary {
    background: var(--s5-green);
    color: #fff !important;
    border: none;
    padding: 5px 14px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
    transition: background 0.2s;
}
.s5-btn-primary:hover { background: var(--s5-green-dark); color: #fff !important; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 991.98px) {
    body.s5-body { padding: 0; }
    .s5-container { box-shadow: none; }
}

@media (max-width: 575.98px) {
    .s5-slider-img { height: 180px; }
    .s5-gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   SALAH TIMETABLE
   ============================================================ */

.s5-salah-table {
    padding: 8px;
}

.s5-salah-table table {
    width: 100%;
    border-collapse: collapse;
}

.s5-salah-table table tr {
    border-bottom: 1px dotted var(--s5-border);
}

.s5-salah-table table tr:last-child {
    border-bottom: none;
}

.s5-salah-table table td {
    padding: 6px 8px;
    font-size: 0.78rem;
}

.s5-salah-table table td:first-child {
    color: var(--s5-green-dark);
    font-weight: 600;
}

.s5-salah-table table td:first-child i {
    color: var(--s5-gold);
    margin-right: 6px;
    font-size: 0.7rem;
}

.s5-salah-table table td:last-child {
    text-align: right;
    font-weight: 700;
    color: var(--s5-green);
}

.s5-salah-location {
    text-align: center;
    font-size: 0.8rem;
    color: var(--s5-muted);
    margin: 6px 0 0;
    padding-top: 6px;
    border-top: 1px solid var(--s5-border);
}

/* Salah Clock */
.s5-salah-clock {
    text-align: center;
    padding: 10px 8px 6px;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--s5-green-dark);
    border-bottom: 1px dotted var(--s5-border);
    margin-bottom: 4px;
}

.s5-salah-clock i {
    color: var(--s5-gold);
    margin-right: 4px;
}

/* Salah Division Select */
.s5-salah-offsets {
    padding: 6px 8px;
    border-top: 1px dotted var(--s5-border);
    margin-top: 4px;
    text-align: center;
}

.s5-salah-select {
    font-size: 0.72rem;
    padding: 3px 8px;
    border: 1px solid var(--s5-border);
    border-radius: 3px;
    background: var(--s5-green-light);
    color: var(--s5-green-dark);
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    max-width: 160px;
}

.s5-salah-select:focus {
    outline: none;
    border-color: var(--s5-gold);
}
