/* Beranda — tema tosca */

.hm {
    --tosca-900: #06383b;
    --tosca-800: #0a5c60;
    --tosca-700: #0d7d81;
    --tosca-500: #17b3b8;
    --tosca-200: #bfe9e9;
    --tosca-100: #e3f5f5;
    --paper: #f6faf9;
    --ink: #0f2024;
    --ink-soft: #5c7276;

    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    color: var(--ink);
    background:
        radial-gradient(1100px 420px at 84% -6%, rgba(23, 179, 184, .12), transparent 60%),
        radial-gradient(900px 500px at -6% 38%, rgba(23, 179, 184, .08), transparent 55%),
        radial-gradient(circle at 1px 1px, rgba(6, 56, 59, .06) 1px, transparent 0) 0 0 / 22px 22px,
        var(--paper);
    padding-bottom: 80px;
}

.hm ::selection { background: var(--tosca-200); color: var(--tosca-900); }

.hm-wrap {
    width: min(1160px, 100% - 32px);
    margin-inline: auto;
}

.hm-hero { padding-top: 28px; }
.hm-section { padding-top: 64px; }

/* ---------- section heading ---------- */
.hm-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}
.hm-head h2 {
    margin: 0;
    font-size: clamp(21px, 2.8vw, 27px);
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--tosca-900);
}
.hm-head p {
    margin: 6px 0 0;
    font-size: 13.5px;
    color: var(--ink-soft);
}
.hm-link {
    flex: none;
    font-size: 13px;
    font-weight: 600;
    color: var(--tosca-700);
    text-decoration: none;
    padding-bottom: 2px;
    border-bottom: 1.5px solid var(--tosca-200);
    transition: border-color .2s ease, color .2s ease;
}
.hm-link:hover, .hm-link:focus-visible { border-color: var(--tosca-700); }

/* ---------- hero slider ---------- */
.hm-slider {
    position: relative;
    aspect-ratio: 21 / 9;
    border-radius: 24px;
    overflow: hidden;
    background: var(--tosca-900);
    box-shadow: 0 30px 60px -34px rgba(6, 56, 59, .55);
}
.hm-slide {
    position: absolute;
    inset: 0;
    display: block;
    opacity: 0;
    visibility: hidden;
    transition: opacity .55s ease;
    text-decoration: none;
}
.hm-slide.is-active { opacity: 1; visibility: visible; }
.hm-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }

.hm-slide-caption {
    position: absolute;
    inset: auto 0 0 0;
    padding: 88px 32px 30px;
    color: #fff;
    background: linear-gradient(to top, rgba(6, 30, 32, .92), rgba(6, 30, 32, .3) 58%, transparent);
}
.hm-slide-caption h3 {
    margin: 0 0 8px;
    font-size: clamp(19px, 3vw, 30px);
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.2;
    max-width: 22ch;
}
.hm-slide-caption p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    max-width: 52ch;
    color: rgba(255, 255, 255, .78);
}

.hm-dots {
    position: absolute;
    left: 32px;
    bottom: 26px;
    display: flex;
    gap: 6px;
    z-index: 2;
}
.hm-dot {
    width: 7px; height: 7px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .45);
    cursor: pointer;
    transition: width .25s ease, background .25s ease;
}
.hm-dot.is-active { width: 24px; background: var(--tosca-500); }

@media (max-width: 720px) {
    .hm-slider { aspect-ratio: 3 / 4; border-radius: 18px; }
    .hm-slide-caption { padding: 64px 20px 22px; }
    .hm-slide-caption p { display: none; }
    .hm-dots { left: 20px; bottom: 16px; }
}

/* ---------- badge strip: kartu terapung di bawah hero ---------- */
.hm-strip {
    margin-top: -34px;
    position: relative;
    z-index: 3;
}
.hm-badges {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 20px 40px -26px rgba(6, 56, 59, .35), 0 1px 2px rgba(6, 56, 59, .06);
}
.hm-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    border-right: 1px solid var(--tosca-100);
}
.hm-badge:last-child { border-right: none; }
.hm-badge-ic {
    flex: none;
    width: 36px; height: 36px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--tosca-100);
    color: var(--tosca-700);
    font-size: 16px;
}
.hm-badge-txt {
    font-size: 13px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--tosca-900);
}

@media (max-width: 860px) {
    .hm-strip { margin-top: -22px; }
    .hm-badges {
        grid-template-columns: repeat(2, 1fr);
        border-radius: 16px;
    }
    .hm-badge {
        padding: 14px 16px;
        border-right: 1px solid var(--tosca-100);
    }
    .hm-badge:nth-child(2n) { border-right: none; }
    .hm-badge:nth-child(1), .hm-badge:nth-child(2) { border-bottom: 1px solid var(--tosca-100); }
    .hm-badge-txt { font-size: 12px; }
}

/* ---------- program: badge kecil ---------- */
.hm-badgegrid {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}
.hm-chip {
    position: relative;
    display: block;
    flex: 0 0 auto;
    width: 208px;
    aspect-ratio: 2 / 1;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 10px 22px -16px rgba(6, 56, 59, .4), 0 1px 2px rgba(6, 56, 59, .06);
    transition: transform .2s ease, box-shadow .2s ease;
}
.hm-chip:hover, .hm-chip:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 16px 28px -16px rgba(6, 56, 59, .5), 0 1px 2px rgba(6, 56, 59, .06);
}
.hm-chip img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.hm-chip::after {
    content: '';
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 0 1px rgba(6, 56, 59, .08);
    border-radius: inherit;
    pointer-events: none;
}
.hm-chip-fallback {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 4px;
    width: 100%;
    height: 100%;
    padding: 12px;
    background: var(--accent, var(--tosca-700));
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;
}
.hm-chip-fallback em {
    font-style: normal;
    font-size: 18px;
    font-weight: 800;
    opacity: .5;
}

@media (max-width: 720px) {
    .hm-chip { width: 44%; }
}

/* ---------- angka: guru / siswa / testimoni ---------- */
.hm-stats-section { padding-bottom: 8px; }
.hm-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.hm-stat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 24px 22px;
    background: #fff;
    border-radius: 18px;
    border-top: 3px solid var(--tosca-500);
    box-shadow: 0 1px 2px rgba(6, 56, 59, .05);
}
.hm-stat-ic {
    width: 38px; height: 38px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--tosca-100);
    color: var(--tosca-700);
    font-size: 17px;
    margin-bottom: 4px;
}
.hm-stat-num {
    font-size: clamp(26px, 3.6vw, 34px);
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--tosca-900);
}
.hm-stat-label {
    font-size: 13px;
    color: var(--ink-soft);
    font-weight: 600;
}

@media (max-width: 720px) {
    .hm-stats { grid-template-columns: 1fr; }
}

/* ---------- berita: kartu artikel ---------- */
.hm-news {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.hm-news-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 16px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 2px rgba(6, 56, 59, .05);
    transition: transform .2s ease, box-shadow .2s ease;
}
.hm-news-card:hover, .hm-news-card:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 16px 30px -20px rgba(6, 56, 59, .45);
}
.hm-news-media {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--tosca-100);
}
.hm-news-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .4s ease;
}
.hm-news-card:hover .hm-news-media img { transform: scale(1.05); }
.hm-news-body { padding: 16px 18px 18px; }
.hm-news-date {
    display: block;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--tosca-700);
    margin-bottom: 6px;
}
.hm-news-body h3 {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    color: var(--tosca-900);
    letter-spacing: -.01em;
}
.hm-news-body p {
    margin: 0;
    font-size: 12.5px;
    line-height: 1.55;
    color: var(--ink-soft);
}

@media (max-width: 860px) {
    .hm-news { grid-template-columns: repeat(2, 1fr); gap: 14px; }
}
@media (max-width: 560px) {
    .hm-news { grid-template-columns: 1fr; }
}

/* ---------- galeri: mosaik ---------- */
.hm-mosaic {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 150px;
    gap: 14px;
}
.hm-tile {
    position: relative;
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    background: var(--tosca-100);
}
.hm-tile:first-child { grid-column: span 2; grid-row: span 2; }
.hm-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .45s cubic-bezier(.2, .7, .2, 1);
}
.hm-tile:hover img { transform: scale(1.06); }
.hm-tile figcaption {
    position: absolute;
    left: 12px; bottom: 12px;
    font-size: 11px;
    font-weight: 700;
    color: var(--tosca-900);
    background: rgba(255, 255, 255, .94);
    padding: 5px 11px;
    border-radius: 999px;
}
@media (max-width: 860px) {
    .hm-mosaic { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 130px; }
}

/* ---------- a11y ---------- */
.hm a:focus-visible, .hm button:focus-visible {
    outline: 2px solid var(--tosca-500);
    outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
    .hm *, .hm *::before, .hm *::after {
        transition-duration: .01ms !important;
    }
}