
/*
Theme Name: Virgo Maria 2 Bawen
Theme URI: https://sdvirgomaria2bawen.com/
Author: Website SD Virgo Maria 2 Bawen
Description: Tema WordPress portal berita sekolah dengan tampilan biru-putih.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: virgo-maria-2-bawen
*/

:root {
    --vm-blue: #123f78;
    --vm-blue-dark: #0b2b55;
    --vm-blue-light: #eaf2fb;
    --vm-yellow: #f4c542;
    --vm-text: #202938;
    --vm-muted: #687386;
    --vm-border: #e2e8f0;
    --vm-bg: #f5f7fb;
    --vm-white: #fff;
    --vm-radius: 12px;
    --vm-shadow: 0 6px 22px rgba(18, 63, 120, .08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--vm-bg);
    color: var(--vm-text);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.65;
}

a {
    color: var(--vm-blue);
    text-decoration: none;
}

a:hover {
    color: #0a5eb5;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

button,
input {
    font: inherit;
}

.container {
    width: min(1180px, calc(100% - 32px));
    margin-inline: auto;
}

/* HEADER DAN IDENTITAS SEKOLAH */

.site-topline {
    padding: 6px 0;
    background: var(--vm-blue-dark);
    color: #fff;
    font-size: 13px;
}

.topline-inner {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.site-header {
    background: #fff;
    border-bottom: 1px solid var(--vm-border);
}

.brand-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 0;
}

.custom-logo-link img {
    width: auto;
    max-width: 100px;
    max-height: 82px;
}

.brand-placeholder {
    display: grid;
    place-items: center;
    width: 78px;
    height: 78px;
    border-radius: 12px;
    background: var(--vm-blue);
    color: #fff;
    font-size: 28px;
    font-weight: 800;
}

.site-title {
    margin: 0;
    color: var(--vm-blue-dark);
    font-size: clamp(22px, 3vw, 31px);
    font-weight: 800;
    line-height: 1.2;
}

.site-description {
    margin: 5px 0 0;
    color: var(--vm-muted);
    font-size: 14px;
}

/* NAVIGASI */

.nav-wrap {
    background: var(--vm-blue);
    color: #fff;
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.menu-toggle {
    display: none;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 8px;
    background: transparent;
    color: #fff;
}

.main-menu {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    list-style: none;
}

.main-menu li {
    position: relative;
}

.main-menu a {
    display: block;
    padding: 13px 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
}

.main-menu a:hover,
.main-menu .current-menu-item > a {
    background: var(--vm-blue-dark);
}

.main-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 20;
    display: none;
    min-width: 210px;
    margin: 0;
    padding: 4px 0;
    background: var(--vm-blue-dark);
    box-shadow: var(--vm-shadow);
    list-style: none;
}

.main-menu li:hover > .sub-menu,
.main-menu li:focus-within > .sub-menu {
    display: block;
}

.search-form {
    display: flex;
    gap: 5px;
    padding: 6px 0;
}

.search-form input[type="search"] {
    width: 145px;
    min-width: 0;
    padding: 8px;
    border: 0;
    border-radius: 6px;
}

.search-form button {
    padding: 8px 10px;
    border: 0;
    border-radius: 6px;
    background: var(--vm-yellow);
    color: #172033;
    font-weight: 700;
}

/* INFORMASI BERJALAN */

.ticker {
    padding: 9px 0;
    background: #fff;
    border-bottom: 1px solid var(--vm-border);
}

.ticker-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
}

.ticker-label {
    flex-shrink: 0;
    padding: 4px 9px;
    border-radius: 4px;
    background: var(--vm-yellow);
    color: #172033;
    font-weight: 800;
}

.ticker a {
    color: var(--vm-text);
}

.ticker-text {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* JUDUL BAGIAN */

.section {
    padding: 28px 0;
}

.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 18px;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--vm-blue);
}

.section-heading h2 {
    margin: 0;
    color: var(--vm-blue-dark);
    font-size: 23px;
    line-height: 1.25;
}

.section-heading a {
    font-size: 14px;
    font-weight: 700;
}

/* HEADLINE BERITA */

.headline-grid {
    display: grid;
    grid-template-columns: 1.65fr 1fr;
    gap: 18px;
}

.headline-main,
.headline-small,
.news-card,
.sidebar-box,
.content-box,
.profile-card,
.achievement-card {
    overflow: hidden;
    border: 1px solid var(--vm-border);
    border-radius: var(--vm-radius);
    background: #fff;
    box-shadow: var(--vm-shadow);
}

.headline-main {
    padding: 16px;
}

.category-label {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    background: var(--vm-blue-light);
    color: #0d5aa7;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.news-title {
    margin: 10px 0 8px;
    color: var(--vm-blue-dark);
    font-size: clamp(20px, 2.5vw, 30px);
    line-height: 1.28;
}

.news-title a {
    color: inherit;
}

.news-meta {
    margin-bottom: 12px;
    color: var(--vm-muted);
    font-size: 12px;
}

.headline-main .news-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    object-fit: cover;
}

.news-excerpt {
    margin: 12px 0;
    color: #4b5563;
    font-size: 15px;
}

.read-more {
    display: inline-block;
    font-size: 13px;
    font-weight: 800;
}

.headline-side {
    display: grid;
    gap: 18px;
}

.headline-small {
    padding: 13px;
}

.headline-small .news-title {
    margin: 8px 0;
    font-size: 18px;
}

.headline-small .news-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 7px;
    object-fit: cover;
}

/* BERITA TERBARU DAN SIDEBAR */

.news-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
    align-items: start;
    gap: 22px;
}

.news-list {
    display: grid;
    gap: 15px;
}

.news-card {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 16px;
    padding: 14px;
}

.news-card .news-image {
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 7px;
    object-fit: cover;
}

.news-card .news-title {
    margin: 7px 0;
    font-size: 20px;
}

.news-card .news-excerpt {
    margin: 6px 0;
}

.sidebar {
    display: grid;
    gap: 18px;
}

.sidebar-box {
    padding: 16px;
}

.sidebar-box h3 {
    margin: 0 0 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--vm-yellow);
    color: var(--vm-blue-dark);
    font-size: 18px;
}

.sidebar-list {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sidebar-list li {
    padding-bottom: 10px;
    border-bottom: 1px solid var(--vm-border);
}

.sidebar-list li:last-child {
    padding-bottom: 0;
    border: 0;
}

.sidebar-list a {
    color: var(--vm-text);
    font-weight: 700;
}

.sidebar-list small {
    display: block;
    color: var(--vm-muted);
    font-weight: 400;
}

/* PRESTASI DAN KARTU PROFIL */

.card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.grid-news {
    padding: 13px;
    border: 1px solid var(--vm-border);
    border-radius: var(--vm-radius);
    background: #fff;
    box-shadow: var(--vm-shadow);
}

.grid-news .news-title {
    font-size: 18px;
}

.grid-news .news-image {
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 7px;
    object-fit: cover;
}

.profile-card,
.achievement-card {
    padding: 15px;
}

.profile-card img,
.achievement-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    margin: 12px 0;
    border-radius: 8px;
    object-fit: cover;
}

.profile-card h3,
.achievement-card h3 {
    margin: 8px 0;
    color: var(--vm-blue-dark);
    font-size: 18px;
}

.profile-group {
    margin-bottom: 28px;
}

.profile-group h2 {
    padding-left: 12px;
    border-left: 5px solid var(--vm-yellow);
    color: var(--vm-blue-dark);
}

/* HALAMAN DAN ARTIKEL */

.page-header {
    margin-bottom: 20px;
    padding: 22px;
    border: 1px solid var(--vm-border);
    border-radius: var(--vm-radius);
    background: #fff;
}

.page-title {
    margin: 0;
    color: var(--vm-blue-dark);
    font-size: clamp(26px, 3vw, 36px);
    line-height: 1.25;
}

.breadcrumbs {
    margin-bottom: 8px;
    color: var(--vm-muted);
    font-size: 12px;
}

.article {
    padding: clamp(18px, 3vw, 32px);
    border: 1px solid var(--vm-border);
    border-radius: var(--vm-radius);
    background: #fff;
}

.article .page-title {
    margin: 10px 0;
}

.article-featured {
    width: 100%;
    max-height: 600px;
    margin: 18px 0;
    border-radius: 9px;
    background: #f1f5f9;
    object-fit: contain;
}

.article-content {
    font-size: 17px;
    line-height: 1.85;
}

.article-content h2,
.article-content h3 {
    color: var(--vm-blue-dark);
}

.article-content figure {
    margin: 20px 0;
}

.article-content figcaption {
    color: var(--vm-muted);
    font-size: 13px;
}

/* PAGINASI DAN PESAN KOSONG */

.pagination,
.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin: 22px 0;
}

.page-numbers {
    padding: 7px 12px;
    border: 1px solid var(--vm-border);
    border-radius: 6px;
    background: #fff;
}

.page-numbers.current {
    background: var(--vm-blue);
    color: #fff;
}

.empty-state {
    padding: 22px;
    border: 1px dashed #b8c7da;
    border-radius: 10px;
    background: #fff;
    color: var(--vm-muted);
}

/* FOOTER */

.site-footer {
    margin-top: 35px;
    padding: 30px 0 16px;
    background: var(--vm-blue-dark);
    color: #dce7f7;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 25px;
}

.site-footer h3 {
    margin-top: 0;
    color: #fff;
}

.site-footer a {
    color: #fff;
}

.footer-bottom {
    margin-top: 22px;
    padding-top: 13px;
    border-top: 1px solid rgba(255, 255, 255, .18);
    font-size: 13px;
}

.button-link {
    display: inline-block;
    padding: 9px 14px;
    border-radius: 6px;
    background: var(--vm-blue);
    color: #fff !important;
    font-weight: 700;
}

.button-link:hover {
    background: var(--vm-blue-dark);
}

/* PENGUMUMAN */

.notice-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.notice-list li {
    padding: 13px 0;
    border-bottom: 1px solid var(--vm-border);
}

.notice-list li:last-child {
    border-bottom: 0;
}

.notice-list h3 {
    margin: 0 0 5px;
    font-size: 18px;
}

.notice-list small {
    color: var(--vm-muted);
}

/* GALERI */

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.gallery-item {
    padding: 10px;
    border: 1px solid var(--vm-border);
    border-radius: 9px;
    background: #fff;
}

.gallery-item img {
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 6px;
    object-fit: cover;
}

.gallery-item h3 {
    margin: 9px 0 3px;
    font-size: 16px;
}

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* HERO FOTO HALAMAN DEPAN */

.vm2-home-hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    min-height: 560px;
    overflow: hidden;
    background-color: #173d6b;
    background-position: center;
    background-size: cover;
    color: #fff;
}

.vm2-home-hero-overlay {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(
        90deg,
        rgba(4, 18, 38, .82) 0%,
        rgba(4, 18, 38, .56) 48%,
        rgba(4, 18, 38, .12) 100%
    );
}

.vm2-home-hero-content {
    width: calc(100% - 80px);
    max-width: 1320px;
    margin-right: auto;
    margin-left: auto;
    padding: 70px 0;
    box-sizing: border-box;
}

.vm2-home-hero-eyebrow {
    margin: 0 0 14px;
    color: #e8effa;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .22em;
    text-transform: uppercase;
}

.vm2-home-hero-meta {
    margin: 0 0 12px;
    color: #e8effa;
    font-size: 12px;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.vm2-home-hero-title {
    max-width: 760px;
    margin: 0 0 18px;
    color: #fff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(35px, 5.2vw, 62px);
    font-weight: 500;
    line-height: 1.06;
    text-transform: uppercase;
}

.vm2-home-hero-title a {
    color: inherit;
}

.vm2-home-hero-description {
    max-width: 560px;
    margin: 0 0 26px;
    color: #f5f7fb;
    font-size: 16px;
    line-height: 1.8;
}

.vm2-home-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.vm2-home-button {
    display: inline-block;
    padding: 12px 22px;
    border: 1px solid #164c83;
    background: #164c83;
    color: #fff !important;
    font-size: 14px;
    font-weight: 700;
}

.vm2-home-button:hover {
    background: #0b2b55;
}

.vm2-home-button-outline {
    border-color: rgba(255, 255, 255, .8);
    background: transparent;
}

.vm2-home-news-section {
    padding-top: 32px;
}

/* TABLET */

@media (max-width: 900px) {
    .main-nav {
        display: block;
        padding: 8px 0;
    }

    .menu-toggle {
        display: inline-block;
        margin: 5px 0;
    }

    .main-menu {
        display: none;
        flex-direction: column;
        align-items: stretch;
    }

    .main-menu.is-open {
        display: flex;
    }

    .main-menu a {
        padding: 11px;
    }

    .main-menu .sub-menu {
        position: static;
        display: block;
        padding-left: 14px;
        box-shadow: none;
    }

    .search-form {
        padding: 8px 0;
    }

    .search-form input[type="search"] {
        width: 100%;
    }

    .headline-grid {
        grid-template-columns: 1fr 1fr;
    }

    .news-layout {
        grid-template-columns: minmax(0, 1.6fr) minmax(220px, 1fr);
    }

    .news-card {
        grid-template-columns: 160px minmax(0, 1fr);
    }

    .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* HP */

@media (max-width: 700px) {
    .vm2-home-hero {
        min-height: 460px;
        background-position: center;
    }

    .vm2-home-hero-content {
        width: calc(100% - 40px);
        padding: 48px 0;
    }

    .vm2-home-hero-title {
        font-size: clamp(31px, 9vw, 44px);
    }

    .vm2-home-hero-description {
        font-size: 14px;
    }
}

@media (max-width: 640px) {
    .container {
        width: min(100% - 22px, 1180px);
    }

    .brand-row {
        gap: 11px;
        padding: 13px 0;
    }

    .custom-logo-link img {
        max-width: 72px;
        max-height: 72px;
    }

    .brand-placeholder {
        width: 60px;
        height: 60px;
        font-size: 22px;
    }

    .site-title {
        font-size: 20px;
    }

    .site-description {
        font-size: 12px;
    }

    .topline-inner {
        font-size: 11px;
    }

    .headline-grid,
    .news-layout {
        grid-template-columns: 1fr;
    }

    .headline-side {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .headline-small {
        padding: 10px;
    }

    .headline-small .news-title {
        font-size: 15px;
    }

    .news-card {
        grid-template-columns: 1fr;
        gap: 9px;
        padding: 12px;
    }

    .news-card .news-image {
        aspect-ratio: 16 / 9;
    }

    .news-card .news-title {
        font-size: 19px;
    }

    .card-grid,
    .gallery-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .grid-news {
        padding: 10px;
    }

    .grid-news .news-title {
        font-size: 16px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 20px 0;
    }

    .section-heading h2 {
        font-size: 20px;
    }

    .article-content {
        font-size: 16px;
    }
}
