/* Tampilan landing page HSSE. Isi & gambar diatur lewat halaman Kelola. */
:root {
    --bg: #f4f7fb;
    --surface: #ffffff;
    --ink: #0f172a;
    --muted: #5b6577;
    --line: #e3e8f0;
    --brand-blue: #1f4e9d;
    --brand-red: #e3262b;
    --brand-green: #a4c639;
    --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .06);
    --shadow-hover: 0 2px 4px rgba(15, 23, 42, .06), 0 16px 40px rgba(15, 23, 42, .12);
}
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg: #0b1220;
        --surface: #121b2d;
        --ink: #e7ecf5;
        --muted: #98a3b8;
        --line: #23304a;
        --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
        --shadow-hover: 0 2px 4px rgba(0, 0, 0, .35), 0 16px 40px rgba(0, 0, 0, .4);
    }
}
:root[data-theme="dark"] {
    --bg: #0b1220;
    --surface: #121b2d;
    --ink: #e7ecf5;
    --muted: #98a3b8;
    --line: #23304a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
    --shadow-hover: 0 2px 4px rgba(0, 0, 0, .35), 0 16px 40px rgba(0, 0, 0, .4);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
    font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
a { color: inherit; }

/* ── Header ─────────────────────────────────────────────── */
.topbar {
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}
.topbar-inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.logo {
    height: 40px;
    width: auto;
    background: #fff;
    border-radius: 8px;
    padding: 2px 6px;
}
.topbar-title { font-weight: 700; font-size: 15px; }
.topbar-sub { font-size: 12px; color: var(--muted); }
.topbar-inner > div { min-width: 0; }

/* ── Hero ───────────────────────────────────────────────── */
.hero {
    position: relative;
    overflow: hidden;
    /* foto latar & lapisan diatur dari halaman Kelola (style di index.php) */
    background: linear-gradient(135deg, #12346f 0%, var(--brand-blue) 55%, #2a63c2 100%);
    color: #fff;
}
.hero::after {
    /* aksen tiga warna, mengikuti logo */
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--brand-blue) 0 33.3%, var(--brand-red) 33.3% 66.6%, var(--brand-green) 66.6% 100%);
}
.hero-inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 48px 16px 72px;
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}
.hero-text { min-width: 0; }
.eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .25);
    padding: 4px 10px;
    border-radius: 999px;
}
.hero h1 {
    font-size: clamp(28px, 5vw, 44px);
    line-height: 1.15;
    margin: 16px 0 12px;
    font-weight: 800;
    letter-spacing: -.01em;
}
.hero p {
    margin: 0;
    max-width: 620px;
    font-size: clamp(15px, 2.2vw, 17px);
    color: rgba(255, 255, 255, .85);
}
.hero-logo {
    width: 220px;
    height: 220px;
    flex: none;
    object-fit: contain;
    filter: drop-shadow(0 10px 24px rgba(0, 0, 0, .45));
}

/* ── Kartu divisi ───────────────────────────────────────── */
main {
    flex: 1;
    max-width: 1120px;
    width: 100%;
    margin: 0 auto;
    padding: 0 16px 48px;
}
.grid {
    margin-top: -32px;
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
}
.card {
    --accent: #64748b;
    --accent-soft: rgba(100, 116, 139, .12);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px;
    flex: 1 1 300px;
    max-width: 362px;
    box-shadow: var(--shadow);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card::before {
    content: "";
    position: absolute;
    left: 0; top: 0; right: 0;
    height: 4px;
    background: var(--accent);
}
a.card:hover, a.card:focus-visible {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
    border-color: var(--accent);
    outline: none;
}
.card.off { cursor: default; }
.card.off .card-icon { filter: grayscale(.6); opacity: .7; }

.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--accent-soft);
    color: var(--accent);
    flex: none;
}
.card-icon svg { width: 26px; height: 26px; }
.card-icon.logo { width: 60px; height: 60px; background: none; border-radius: 50%; }
.card-icon.logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
.badge {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 999px;
    white-space: nowrap;
}
.badge.aktif   { background: rgba(22, 163, 74, .12);  color: #15803d; }
.badge.dev     { background: rgba(217, 119, 6, .14);  color: #b45309; }
.badge.segera  { background: rgba(100, 116, 139, .14); color: var(--muted); }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .badge.aktif { color: #4ade80; }
    :root:not([data-theme="light"]) .badge.dev   { color: #fbbf24; }
}
:root[data-theme="dark"] .badge.aktif { color: #4ade80; }
:root[data-theme="dark"] .badge.dev   { color: #fbbf24; }

.card h2 { margin: 0; font-size: 19px; font-weight: 700; }
.card .letter { color: var(--accent); }
.card p { margin: 0; color: var(--muted); font-size: 14px; flex: 1; }
.card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px dashed var(--line);
    font-size: 13px;
}
.card-url {
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}
.card-cta { font-weight: 700; color: var(--accent); white-space: nowrap; }
.card.off .card-cta { color: var(--muted); font-weight: 600; }

.note {
    margin-top: 28px;
    font-size: 13px;
    color: var(--muted);
    text-align: center;
}

footer {
    border-top: 1px solid var(--line);
    background: var(--surface);
}
.foot-inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 16px;
    font-size: 12px;
    color: var(--muted);
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
    justify-content: space-between;
}

@media (max-width: 560px) {
    .hero-inner { padding: 28px 16px 60px; flex-direction: column-reverse; align-items: flex-start; gap: 12px; }
    .hero-logo { width: 104px; height: 104px; }
    .logo { height: 34px; }
}
@media (prefers-reduced-motion: reduce) {
    .card { transition: none; }
    a.card:hover { transform: none; }
}
.preview-bar{position:sticky;top:0;z-index:50;background:#f59e0b;color:#111;font:600 12px/1.4 system-ui,sans-serif;text-align:center;padding:4px 8px}
