@font-face {
    font-family: "Fredoka";
    src: url("../fonts/fredoka-latin-wght.woff2") format("woff2");
    font-weight: 300 700; font-style: normal; font-display: swap;
}
:root {
    --nav-bg: #0b2350;
    --ink: #10203f;
    --paper: #fff8eb;
    --teal: #075860;
    --font-display: "Fredoka", "Baloo 2", "Nunito", system-ui, sans-serif;
    --muted: #445369;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font: 1rem/1.55 system-ui, -apple-system, "Segoe UI", sans-serif;
    overflow-wrap: anywhere;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
svg { width: 1.2em; height: 1.2em; flex: none; }
:focus-visible { outline: 3px solid #2d71ba; outline-offset: 4px; }
.container { width: min(1160px, calc(100% - 72px)); margin-inline: auto; }
.skip-link {
    position: fixed; z-index: 5; top: 1rem; left: 1rem;
    transform: translateY(-200%); padding: .65rem 1rem; background: #fff;
}
.skip-link:focus { transform: none; }

.hero { padding-top: 14px; background: linear-gradient(120deg, #fff1d7, var(--paper) 55%); }
.nav-wrap {
    position: relative; z-index: 3;
    display: flex; justify-content: space-between; align-items: center;
    min-height: 76px; gap: 1rem; padding: .6rem clamp(.75rem, 3vw, 2rem);
    border: 1px solid #ffffff1f; border-radius: 2.25rem 2.25rem 3.2rem 2.55rem / 2.25rem 2.25rem 1.65rem 2.55rem; background: var(--nav-bg);
    color: #fff; box-shadow: 0 12px 28px #0b235033;
}
.brand, .contact-brand { display: flex; align-items: center; gap: .7rem; line-height: 1.15; }
.brand img, .contact-brand img { width: 46px; height: 50px; flex: none; object-fit: contain; }
.brand img { filter: drop-shadow(0 2px 4px #00000040); }
.brand span { padding-left: .7rem; border-left: 1px solid #ffffff40; }
.brand strong { display: block; color: #fff; font-size: clamp(.92rem, 2.2vw, 1.35rem); font-weight: 850; }
.brand strong + strong { margin-top: .24rem; color: #ffcd54; font-size: .68rem; letter-spacing: .17em; }
nav { color: #fff; display: flex; flex-wrap: wrap; align-items: center; gap: .15rem clamp(.2rem, 1vw, .75rem); font-size: .91rem; font-weight: 680; }
nav a { border-radius: 2rem; padding: .54rem .72rem; }
nav a:hover { background: #ffffff1f; }
nav .active, nav .active:hover { background: var(--gold); color: #18233a; }
.menu-toggle {
    display: none; min-width: 44px; min-height: 44px; border: 0;
    border-radius: 50%; background: #ffffff1f; color: #fff; font: inherit; font-size: 1.2rem; cursor: pointer;
}
.hero-content {
    display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: clamp(1.25rem, 4vw, 4rem); align-items: center;
    padding-block: clamp(2rem, 3.8vw, 3.6rem) clamp(1.65rem, 3vw, 2.8rem);
}
.eyebrow { color: var(--teal); font-size: .74rem; font-weight: 800; letter-spacing: .13em; }
.hero h1 { margin-top: .55rem; line-height: 1.02; }
.hero h1 span {
    display: block; max-width: 15ch; color: var(--navy);
    font-size: clamp(2.15rem, 4.4vw, 4.2rem); font-weight: 880; letter-spacing: -.06em;
}
.hero h1 span::after, .section-title h2::after {
    content: ""; display: block; width: 32%; max-width: 126px; height: .25rem;
    margin-top: .64rem; background: var(--gold); border-radius: 100% 40% 85% 40%; transform: rotate(-3deg);
}
.hero h1 em { display: block; margin-top: .8rem; color: var(--teal); font-size: clamp(.95rem, 2vw, 1.35rem); font-style: normal; line-height: 1.25; }
.hero-copy p { max-width: 38ch; margin-top: .85rem; color: var(--muted); font-size: clamp(1rem, 1.4vw, 1.12rem); }
.hero-button, .maps-button {
    display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 46px;
    padding: .62rem 1.16rem; border-radius: 2rem; font-weight: 750;
}
.hero-button { margin-top: 1.15rem; color: #fff; background: var(--teal); }
.hero-button:hover { background: #073f49; }
.values { display: flex; flex-wrap: wrap; gap: .28rem .7rem; margin-top: 1rem; color: var(--teal); font-size: .68rem; font-weight: 750; }
.values span:not(:empty)::before { content: '•'; margin-right: .35em; }

.services-section, .details-section { padding-block: clamp(2rem, 4.6vw, 3.75rem); }
.section-title { margin-bottom: 1.32rem; }
.section-title h2, .principal h2 { font-size: clamp(1.65rem, 3.5vw, 2.85rem); line-height: 1.08; letter-spacing: -.045em; font-weight: 850; }
.section-title h2::after { width: 75px; background: #ef846c; }
.section-title p { margin-top: .75rem; color: var(--muted); }
.service-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.service-card {
    /* Warna gradasi per card: semua lolos kontras teks putih >= 4.5:1. */
    --c1: #1f5fbf; --c2: #0d3b8c; --card-fg: #fff; --card-icon: #fff;
    display: grid; grid-template-columns: auto minmax(0, 1fr); align-content: start;
    position: relative; isolation: isolate; overflow: hidden;
    gap: clamp(.7rem, 2vw, 1.15rem); min-height: 146px;
    border-radius: 20px; background: linear-gradient(145deg, var(--c1), var(--c2)); color: var(--card-fg); padding: clamp(1rem, 2.8vw, 1.55rem);
    box-shadow: 0 12px 24px color-mix(in srgb, var(--c2) 28%, transparent); transition: transform .2s ease, box-shadow .2s ease;
}
.service-card:hover { transform: translateY(-4px); box-shadow: 0 18px 32px color-mix(in srgb, var(--c2) 38%, transparent); }
.service-card:nth-child(10n + 1), .detail-card:nth-child(10n + 1) { --c1: #1f5fbf; --c2: #0d3b8c; } /* biru */
.service-card:nth-child(10n + 2), .detail-card:nth-child(10n + 2) { --c1: #7a35e0; --c2: #5221b0; } /* ungu */
.service-card:nth-child(10n + 3), .detail-card:nth-child(10n + 3) { --c1: #08714e; --c2: #055239; } /* hijau */
.service-card:nth-child(10n + 4), .detail-card:nth-child(10n + 4) { --c1: #2756d6; --c2: #1a3fb3; } /* biru royal */
.service-card:nth-child(10n + 5), .detail-card:nth-child(10n + 5) { --c1: #a9481a; --c2: #843510; } /* oranye */
.service-card:nth-child(10n + 6), .detail-card:nth-child(10n + 6) { --c1: #0d6f78; --c2: #08525a; } /* teal */
.service-card:nth-child(10n + 7), .detail-card:nth-child(10n + 7) { --c1: #b83d36; --c2: #962b26; } /* coral */
.service-card:nth-child(10n + 8), .detail-card:nth-child(10n + 8) { --c1: #7d3fb0; --c2: #5e2a8f; } /* violet */
.service-card:nth-child(10n + 9), .detail-card:nth-child(10n + 9) { --c1: #9b2430; --c2: #6e1520; } /* merah marun */
.service-card:nth-child(10n + 10), .detail-card:nth-child(10n + 10) { --c1: #226f3a; --c2: #18552b; } /* hijau hutan */
.service-icon {
    display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px;
    background: #ffffff26; border: 1px solid #ffffff33; color: var(--card-icon); font-size: 1.35rem;
}
.service-card h3 { font-size: clamp(1.15rem, 2vw, 1.6rem); letter-spacing: -.03em; line-height: 1.18; }
.service-card p { max-width: min(38ch, 100%); margin-block: .4rem .25rem; font-size: .94rem; }
.service-copy { text-align: left; min-width: 0; padding-left: clamp(.7rem, 1.6vw, 1rem); border-left: 2px solid color-mix(in srgb, var(--card-fg) 35%, transparent); }
.service-card a { color: inherit; display: inline-flex; gap: .55rem; align-items: center; min-height: 44px; font-weight: 760; }
.service-card a::after { content: ""; position: absolute; inset: 0; }
.service-card a:hover { text-decoration: underline; }
.service-card:focus-within { outline: 3px solid #2d71ba; outline-offset: 4px; }
.service-art {
    position: absolute; right: -.75rem; bottom: -2rem; z-index: -1;
    font-size: clamp(5rem, 12vw, 10rem); line-height: 1; opacity: .07;
    color: var(--card-fg); transform: rotate(-13deg); pointer-events: none;
}
.empty-state { padding: 1rem; border: 1px dashed #a6947a; border-radius: 12px; }
.principal {
    padding-block: clamp(2rem, 3.5vw, 3.2rem); color: var(--ink);
    background: #ceeee6; border-radius: 49% 5% 42% 5% / 9% 8% 9% 8%;
}
.principal-grid { display: grid; grid-template-columns: minmax(64px, 150px) minmax(0, 1fr); gap: clamp(1rem, 4vw, 3rem); align-items: center; }
.principal-photo img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 38% 18% 35% 18%; }
.photo-empty { text-align: center; color: var(--teal); font: 900 clamp(3.6rem, 11vw, 9rem)/.9 Georgia, serif; }
.message { margin-block: .72rem; max-width: 65ch; }
.signature strong, .signature span { display: block; }
.signature span { color: #394d54; font-size: .9rem; }
.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.detail-card {
    --c1: #1f5fbf; --c2: #0d3b8c; --d-bg: var(--c1); --d-icon: #fff; --d-mark: var(--c2);
    display: grid; grid-template-columns: minmax(110px, 26%) minmax(0, 1fr); min-width: 0; overflow: hidden;
    border: 1px solid #e3d6c2; border-top: 5px solid var(--d-bg); border-radius: 18px;
    background: #fff; box-shadow: 0 10px 24px #10203f12;
}
.detail-icon {
    position: relative; isolation: isolate; display: grid; place-items: center;
    min-height: 100%; padding: 1.5rem .75rem; background: linear-gradient(160deg, var(--c1), var(--c2)); color: var(--d-icon); font-size: 2.6rem;
}
.detail-icon::before {
    content: ""; position: absolute; z-index: -1; top: 50%; left: 50%;
    width: 86px; height: 86px; border: 2px solid color-mix(in srgb, var(--d-icon) 35%, transparent);
    border-radius: 18px; background: color-mix(in srgb, var(--d-icon) 8%, transparent);
    transform: translate(-50%, -50%) rotate(45deg);
}
.detail-card > div:last-child { min-width: 0; padding: clamp(1.1rem, 2.6vw, 1.75rem) clamp(1rem, 2.8vw, 2.25rem); }
.detail-card h3 { color: var(--navy); font-size: 1.3rem; line-height: 1.2; }
.detail-card p { margin-top: .55rem; color: #405a77; font-size: .98rem; line-height: 1.7; text-align: justify; hyphens: auto; }
.detail-card ul { display: flex; flex-wrap: wrap; gap: .45rem 1.25rem; margin: .9rem 0 0; padding: 0; list-style: none; color: var(--navy); font-size: .92rem; font-weight: 700; }
.detail-card li { display: flex; gap: .4rem; align-items: center; }
.detail-card li svg { color: var(--d-mark); }
.section-badge { display: flex; justify-content: center; margin-bottom: 2rem; }
.section-badge h2 {
    position: relative; isolation: isolate; overflow: hidden; display: inline-block; max-width: 100%;
    padding: .8rem clamp(1.75rem, 7vw, 6rem); border-left: 7px solid var(--gold); border-radius: 18px;
    background: linear-gradient(110deg, var(--nav-bg), #0f4c86 62%, #0a7fa8); color: #fff;
    box-shadow: 0 14px 28px #0b235033;
}
.section-badge h2::after {
    content: ""; position: absolute; z-index: -1; top: 0; right: 14%; bottom: 0;
    width: 70px; height: auto; max-width: none; margin: 0; border-radius: 0; transform: none;
    background: #ffffff1c; clip-path: polygon(55% 0, 100% 0, 45% 50%, 100% 100%, 55% 100%, 0 50%);
}
.contact-strip, footer { background: #064952; color: #fff; }
.contact-strip { border-radius: 47% 28% 0 0 / 19% 10% 0 0; }
.contact-inner { display: flex; flex-wrap: wrap; gap: .85rem 1.4rem; align-items: center; justify-content: space-between; padding-block: 1.65rem 1rem; }
.address, .socials { display: flex; align-items: center; gap: .5rem; }
.maps-button, .socials a { background: #e4f5ed; color: #093d47; }
.socials:empty { display: none; }
.socials a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; }
footer .container { padding-block: .85rem 1rem; border-top: 1px solid #ffffff42; color: #e0f3ed; font-size: .84rem; }

@media (max-width: 950px) {
    .container { width: calc(100% - 44px); }
    .service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .detail-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
    .nav-wrap { min-height: 65px; }
    .menu-toggle { display: grid; place-items: center; }
    nav {
        display: none; position: absolute; inset: calc(100% + 6px) 0 auto;
        padding: .5rem; border-radius: 16px; background: var(--nav-bg);
        box-shadow: 0 12px 22px #0b235040;
    }
    nav.open { display: grid; }
    nav a { min-height: 44px; }
    .hero-content, .service-grid { grid-template-columns: minmax(0, 1fr); }
    .hero-content { gap: 1.3rem; padding-block: 1.8rem 1rem; }
    .hero h1 span { max-width: 15ch; }
    .service-grid .service-card { grid-column: auto; min-height: 132px; }
}
@media (max-width: 450px) {
    .container { width: calc(100% - 32px); }
    .brand img { width: 36px; height: 40px; }
    .detail-card { grid-template-columns: minmax(0, 1fr); }
    .detail-icon { min-height: 0; padding-block: 1.9rem; font-size: 2rem; }
    .detail-icon::before { width: 62px; height: 62px; border-radius: 14px; }
    .detail-card p { text-align: left; }
    .principal-grid { grid-template-columns: minmax(35px, 65px) minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
}

/* Dekorasi card layanan dan ornamen footer. */
.service-card::before {
    content: ""; position: absolute; z-index: -1; inset: auto auto -60% -6%;
    width: 47%; aspect-ratio: 1; border-radius: 50%;
    background: #ffffff12; transform: rotate(-18deg) scaleY(.62); pointer-events: none;
}
.service-art { right: .25rem; bottom: -1.75rem; }
footer { position: relative; }
footer::after {
    content: ""; display: block; height: 13px;
    background: url("../images/ornamen-layanan-papua.png") center / auto 100% repeat-x;
    opacity: .55; pointer-events: none;
}

/* ===== Hero & tipografi mengikuti mockup Portal Layanan Digital SMP 9 ===== */
h1, h2, h3, .brand strong, .hero-button, nav { font-family: var(--font-display); font-synthesis: none; }
.brand strong { font-weight: 600; letter-spacing: .01em; }
.brand strong + strong { font-weight: 500; letter-spacing: .2em; }
nav { font-weight: 500; }
.section-title h2, .principal h2 { font-weight: 700; letter-spacing: -.01em; }
.hero { position: relative; isolation: isolate; overflow: hidden; }
.hero::before {
    content: ""; position: absolute; z-index: -1; left: -70px; bottom: 6px;
    width: clamp(150px, 20vw, 260px); height: clamp(70px, 8vw, 110px); opacity: .7; pointer-events: none;
    background: radial-gradient(circle at 32% 100%, #f39b80 0 46%, transparent 47%), radial-gradient(circle at 72% 100%, #f6b09a 0 38%, transparent 39%);
}
.hero::after {
    content: ""; position: absolute; z-index: 2; inset: auto 0 -1px; height: clamp(14px, 2.6vw, 36px);
    background: var(--paper); border-radius: 55% 40% 0 0 / 100% 85% 0 0; pointer-events: none;
}
.hero-content { grid-template-columns: minmax(0, 44%) minmax(0, 1fr); min-height: clamp(380px, 38vw, 520px); padding-block: clamp(1.5rem, 3vw, 2.6rem) clamp(2.4rem, 4vw, 3.6rem); }
.hero-copy { position: relative; z-index: 3; }
.hero h1 span { max-width: 14ch; font-weight: 700; letter-spacing: -.012em; line-height: 1.04; font-size: clamp(2.3rem, 4.6vw, 4.2rem); }
.hero h1 span::after { width: 58%; max-width: 230px; height: .32rem; margin-top: .55rem; border-radius: 100% 30% 100% 30%; }
.hero-copy p { max-width: 26ch; color: #22324d; font-size: clamp(1.05rem, 1.7vw, 1.4rem); line-height: 1.4; }
.hero-button { margin-top: 1.4rem; padding-inline: 1.4rem; font-size: 1.08rem; font-weight: 600; box-shadow: 0 8px 18px #07586033; }
.hero-visual {
    position: absolute; z-index: 1; top: 0; right: 0; bottom: 0; width: 60%; isolation: isolate; pointer-events: none;
}
.hero-visual::before {
    content: ""; position: absolute; z-index: -1; inset: 0 0 0 -1.4%;
    background: linear-gradient(170deg, #ffcd54, #f6b915 55%, #f2a50c);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M34 0H100V100H0C10 92 14 74 18 56C22 36 27 14 34 0Z'/%3E%3C/svg%3E") 0 0 / 100% 100% no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M34 0H100V100H0C10 92 14 74 18 56C22 36 27 14 34 0Z'/%3E%3C/svg%3E") 0 0 / 100% 100% no-repeat;
}
.hero-photo {
    width: 100%; height: 100%; object-fit: cover; object-position: 40% 50%;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M34 0H100V100H0C10 92 14 74 18 56C22 36 27 14 34 0Z'/%3E%3C/svg%3E") 0 0 / 100% 100% no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M34 0H100V100H0C10 92 14 74 18 56C22 36 27 14 34 0Z'/%3E%3C/svg%3E") 0 0 / 100% 100% no-repeat;
}
.hero-secondary { position: absolute; z-index: 2; right: 6%; bottom: 22%; width: min(22%, 150px); height: auto; max-height: 40%; object-fit: contain; filter: drop-shadow(0 3px 9px #10203f55); }
.hero-motif {
    position: absolute; z-index: 1; right: -3%; bottom: clamp(34px, 5vw, 72px); width: 56%; height: clamp(38px, 4.6vw, 62px);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='76' height='48' viewBox='0 0 76 48'%3E%3Crect width='76' height='48' fill='%23fff8eb'/%3E%3Cpath d='M0 3h76M0 45h76' stroke='%23e0674f' stroke-width='4'/%3E%3Cpath d='M6 39V10h26v23H14V18h10v8' fill='none' stroke='%23e0674f' stroke-width='4.2' stroke-linejoin='round'/%3E%3Cpath d='M56 9l15 15-15 15-15-15z' fill='none' stroke='%23075860' stroke-width='4.2' stroke-linejoin='round'/%3E%3Cpath d='M56 18l6 6-6 6-6-6z' fill='%23075860'/%3E%3C/svg%3E") left center / auto 100% repeat-x;
    transform: rotate(-9deg); transform-origin: right bottom; box-shadow: 0 -4px 14px #10203f26;
}
.services-section .section-title h2 {
    display: inline-block; padding-right: clamp(2rem, 4vw, 2.8rem);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cg fill='none' stroke='%23f6b915' stroke-width='4.5' stroke-linecap='round'%3E%3Cpath d='M8 20 13 5'/%3E%3Cpath d='M17 25 32 13'/%3E%3Cpath d='M19 35 35 33'/%3E%3C/g%3E%3C/svg%3E") right top / clamp(1.6rem, 3vw, 2.3rem) auto no-repeat;
}
.service-card h3, .detail-card h3 { font-weight: 600; letter-spacing: 0; }
@media (max-width: 950px) {
    .hero-content { grid-template-columns: minmax(0, 50%) minmax(0, 1fr); }
    .hero-visual { width: 56%; }
}
@media (max-width: 720px) {
    .hero-content { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-bottom: 0; }
    .hero-copy p { max-width: 30ch; }
    .hero-visual { position: relative; width: calc(100% + 44px); margin: .4rem -22px 0; aspect-ratio: 1.35; }
    .hero-visual::before { inset: -10px 0 0 0; -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M0 14C22 2 44 0 64 6S92 12 100 4V100H0Z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M0 14C22 2 44 0 64 6S92 12 100 4V100H0Z'/%3E%3C/svg%3E"); }
    .hero-photo { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M0 14C22 2 44 0 64 6S92 12 100 4V100H0Z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M0 14C22 2 44 0 64 6S92 12 100 4V100H0Z'/%3E%3C/svg%3E"); }
    .hero-motif { width: 72%; bottom: 22px; }
    .hero::before { display: none; }
}
@media (max-width: 450px) {
    .hero-visual { width: calc(100% + 32px); margin-inline: -16px; }
}

/* ===== Revisi 3: hero layar lebar, teks pembuka, judul kapital ===== */
.hero-content { grid-template-columns: minmax(0, 58%) minmax(0, 1fr); }
.hero-visual { left: max(36%, calc(50% - 60px)); width: auto; }
.eyebrow {
    display: inline-flex; align-items: center; gap: .7rem;
    font-family: var(--font-display); font-size: clamp(.95rem, 1.35vw, 1.25rem); font-weight: 600; letter-spacing: .16em;
}
.eyebrow::before { content: ""; width: 2.2rem; height: .3rem; flex: none; border-radius: 1rem; background: var(--gold); }
.hero h1 { margin-top: .7rem; }
.hero h1 span { max-width: 10.6em; text-transform: uppercase; letter-spacing: .005em; font-size: clamp(2.2rem, 4.2vw, 4.4rem); }
.hero h1 em { font-family: var(--font-display); font-weight: 600; }
.hero-copy p { max-width: 34ch; }
.brand strong:first-child { font-weight: 700; }

/* ===== Sambutan Kepala Sekolah - biru #2d6f9c + ornamen tifa emas ===== */
.principal {
    position: relative; isolation: isolate; overflow: hidden;
    padding-block: clamp(2.75rem, 6vw, 5rem); border-radius: 0; color: #fff;
    background:
        repeating-linear-gradient(45deg, #ffd54a0d 0 2px, transparent 2px 36px),
        repeating-linear-gradient(-45deg, #ffd54a0d 0 2px, transparent 2px 36px),
        radial-gradient(circle at 82% 25%, #3d8cc0 0, transparent 55%),
        linear-gradient(125deg, #1f4d70 0%, #2d6f9c 65%, #337ab0 100%);
    border-block: 4px solid var(--gold);
}
.principal::after {
    content: ""; position: absolute; z-index: -1; right: -180px; bottom: -330px;
    width: 560px; height: 560px; border-radius: 50%;
    border: 22px solid var(--gold); border-right-color: transparent; border-bottom-color: transparent;
    transform: rotate(15deg); opacity: .9; pointer-events: none;
}
.principal-tifa {
    position: absolute; z-index: -1; right: clamp(-3rem, calc((100vw - 1160px) / 2 - 8rem), 8rem); top: 50%;
    width: auto; height: 115%; color: #ffe49a; opacity: .32; transform: translateY(-50%) rotate(-8deg); pointer-events: none;
}
.principal-grid { position: relative; grid-template-columns: minmax(150px, 340px) minmax(0, 1fr); gap: clamp(1.5rem, 5vw, 4.5rem); }
.principal-photo { padding: 6px; border-radius: 26px; background: linear-gradient(145deg, #ffe27a, var(--gold) 50%, #d99a06); box-shadow: 0 18px 36px #0b23505c; }
.principal-photo img { aspect-ratio: .82; border-radius: 20px; }
.photo-empty {
    display: grid; place-items: center; aspect-ratio: .82; border-radius: 20px;
    background: linear-gradient(160deg, #2d6f9c, #1f4d70); color: var(--gold);
    font: 700 clamp(9rem, 17vw, 15rem)/1 Georgia, serif; padding-top: .35em;
}
.principal h2 { color: #fff; font-size: clamp(1.8rem, 3.8vw, 3.2rem); }
.principal h2::after {
    content: ""; display: block; width: 88px; height: .38rem; margin-top: .8rem;
    border-radius: 1rem; background: var(--gold);
}
.principal .message { margin-block: 1.1rem 1.4rem; max-width: 58ch; color: #ffffff; font-size: clamp(1rem, 1.35vw, 1.2rem); line-height: 1.8; }
.signature strong { color: #fff; font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; }
.signature span { margin-top: .2rem; color: #fff1bf; font-weight: 600; }
@media (max-width: 1100px) {
    .principal-tifa { opacity: .16; right: -3.5rem; }
}
@media (max-width: 1500px) {
    .principal::after { width: 400px; height: 400px; right: -190px; bottom: -280px; border-width: 18px; }
}
@media (max-width: 950px) {
    .hero-content { grid-template-columns: minmax(0, 54%) minmax(0, 1fr); }
    .hero-visual { left: 44%; }
}
@media (max-width: 720px) {
    .hero-content { grid-template-columns: minmax(0, 1fr); }
    .hero-visual { left: auto; width: calc(100% + 44px); }
    .principal-grid { grid-template-columns: minmax(0, 1fr); }
    .principal-photo { width: min(100%, 260px); }
    .principal-tifa { height: 70%; top: auto; bottom: -4%; right: -1rem; transform: rotate(-8deg); opacity: .14; }
    .principal::after { width: 220px; height: 220px; right: -120px; bottom: -175px; border-width: 12px; }
}
@media (max-width: 450px) {
    .hero-visual { width: calc(100% + 32px); }
    /* Ukuran dari admin bisa terlalu besar untuk layar HP. */
    .brand strong { font-size: clamp(.9rem, 4.4vw, 1.05rem) !important; }
    .brand strong + strong { font-size: clamp(.6rem, 2.9vw, .72rem) !important; letter-spacing: .14em; }
    .principal-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
    .service-card, .service-card:hover { transition: none; transform: none; }
}

/* ===== Revisi 6: latar body bermotif batik Papua (transparan) ===== */
body { background: var(--paper) url("../images/motif-batik-papua.svg") 0 0 / 220px 220px repeat fixed; }
.hero { background: linear-gradient(120deg, #fff1d7 0%, #fff1d7cc 30%, #fff8eb00 62%); }
.hero::after { background: var(--paper) url("../images/motif-batik-papua.svg") 0 0 / 220px 220px repeat fixed; }

/* ===== Revisi 6: footer navy, lebih ringkas, teks lebih besar ===== */
.contact-strip, footer { background: var(--nav-bg); color: #fff; }
.contact-strip { border-radius: 60% 40% 0 0 / 28px 20px 0 0; border-top: 4px solid var(--gold); }
.contact-inner { gap: .7rem 1.6rem; padding-block: 1.1rem .7rem; }
.contact-brand strong { font-family: var(--font-display); font-size: 1.15rem; font-weight: 600; line-height: 1.2; }
.contact-brand img { width: 44px; height: 48px; }
.address { font-size: 1.02rem; }
.address svg { color: var(--gold); }
.maps-button { min-height: 44px; padding: .5rem 1.15rem; background: #fff; color: var(--nav-bg); font-size: 1rem; font-weight: 700; }
.maps-button:hover { background: var(--gold); }
.socials a { width: 42px; height: 42px; background: #ffffff1f; color: #fff; border: 1px solid #ffffff33; }
.socials a:hover { background: var(--gold); color: var(--nav-bg); }
footer .container { padding-block: .6rem .7rem; border-top: 1px solid #ffffff2e; color: #dbe6f5; font-size: .98rem; }
footer::after { height: 8px; opacity: .35; }
@media (max-width: 720px) {
    .contact-inner { justify-content: flex-start; }
    .contact-strip { border-radius: 60% 40% 0 0 / 18px 14px 0 0; }
}

/* ===== Revisi 10: blok sambutan lebih ringkas, foto PNG transparan menyatu ===== */
.principal { padding-block: clamp(1.75rem, 3.6vw, 2.75rem); }
.principal-grid {
    grid-template-columns: minmax(150px, 250px) minmax(0, 1fr);
    gap: clamp(1.25rem, 4vw, 3.5rem); align-items: start;
}
/* Bingkai emas tipis; isi bingkai biru seperti latar blok agar PNG transparan menyatu. */
.principal-photo { padding: 4px; border-radius: 22px; }
.principal-photo img, .photo-empty { border-radius: 18px; }
.principal-photo img {
    width: 100%; aspect-ratio: 4 / 5; height: auto;
    object-fit: contain; object-position: center bottom;
    background:
        radial-gradient(ellipse 70% 55% at 50% 38%, #4f9bd0 0%, transparent 70%),
        linear-gradient(170deg, #3b84b8 0%, #2d6f9c 55%, #1f4d70 100%);
}
.photo-empty { aspect-ratio: 4 / 5; font-size: clamp(6rem, 10vw, 9rem); }
.principal-copy { padding-top: clamp(.25rem, 1.2vw, 1rem); }
.principal::after { width: 340px; height: 340px; right: -165px; bottom: -255px; border-width: 15px; }
.principal h2 { font-size: clamp(1.7rem, 3.2vw, 2.6rem); }
.principal h2::after { margin-top: .55rem; }
.principal .message { margin-block: .8rem 1rem; line-height: 1.7; }
@media (max-width: 720px) {
    .principal-grid { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
    .principal-photo { width: min(100%, 220px); }
    .principal-copy { padding-top: 0; }
    .principal::after { width: 220px; height: 220px; right: -120px; bottom: -175px; border-width: 12px; }
}

/* ===== Revisi 11: sambutan berlatar navy, teks memanjang, tifa lebih transparan ===== */
.principal {
    background:
        repeating-linear-gradient(45deg, #ffd54a0b 0 2px, transparent 2px 36px),
        repeating-linear-gradient(-45deg, #ffd54a0b 0 2px, transparent 2px 36px),
        radial-gradient(circle at 82% 25%, #1a4a85 0, transparent 55%),
        linear-gradient(125deg, #081a3d 0%, #0b2350 55%, #123a6b 100%);
}
.principal-tifa { color: #ffe49a; opacity: .11; height: 115%; max-height: 560px; }
.principal .message { max-width: none; }
.signature span { color: #ffd54a; }
.principal-photo img {
    background:
        radial-gradient(ellipse 70% 55% at 50% 38%, #2a5f9e 0%, transparent 70%),
        linear-gradient(170deg, #173f73 0%, #0f2d5a 55%, #0b2350 100%);
}
.photo-empty { background: linear-gradient(160deg, #123a6b, #0b2350); }
.principal-photo { box-shadow: 0 18px 36px #00000059; }
@media (max-width: 1100px) {
    .principal-tifa { opacity: .08; }
}
@media (min-width: 951px) {
    .principal .container { width: min(1400px, calc(100% - 72px)); }
}
