/* ==========================================================================
   SIAP SMP — App stylesheet
   Source of truth: Figma "SIAP SMP" / Portal Dinas - Dashboard (node 13:511)
   Layout target: 390px mobile viewport (design width), centered on larger screens.

   Contents
   1. Design tokens
   2. Base
   3. Components
      3.1  Icon tile
      3.2  Card
      3.3  Section head
      3.4  Text link
      3.5  Role banner
      3.6  KPI cards
      3.7  Distribution
      3.8  Schools
      3.9  Filter panel & field
      3.10 Search field
      3.11 Select button
      3.12 Status chips
      3.13 Category chips
      3.14 Button
      3.15 Report list
      3.16 Profile
      3.17 App header
      3.18 Page canvas
      3.19 Bottom nav
      3.20 Case detail
      3.21 Login
      3.22 Home (Pelapor/Guru)
      3.23 Report form (Pelapor)
      3.24 Report inbox (Guru)
      3.25 Overlays
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design tokens
   -------------------------------------------------------------------------- */
:root {
    /* Surfaces & content */
    --bg: #f8f9ff;
    --surface: #ffffff;
    --surface-variant: #eff4ff;
    --surface-variant-soft: rgba(239, 244, 255, 0.5);
    --on-surface: #0b1c30;
    --on-surface-variant: #45464d;
    --on-surface-soft: #525254;

    /* Brand & accents */
    --primary: #4b41e1;
    --primary-soft: rgba(75, 65, 225, 0.15);
    --badge-blue: #d3e4fe;
    --badge-violet: #e8e7ff;
    --success: #6bd8cb;
    --ink: #000000;
    --divider: #e5e7eb;

    /* Icon tile surfaces */
    --tile-blue: #e5eeff;
    --tile-violet: #e2dfff;
    --tile-teal: rgba(12, 148, 136, 0.1);
    --tile-avatar-blue: #dce9ff;

    /* Report status ribbon */
    --status-alert-bg: #93000a;
    --status-berat-bg: #ffdad6;
    --status-berat-text: #93000a;
    --status-sedang-bg: rgba(242, 183, 106, 0.45);
    --status-sedang-text: #935403;

    /* Alert */
    --error: #ba1a1a;
    --error-container: rgba(255, 218, 214, 0.6);
    --on-error-container: #93000a;

    /* Category chart series */
    --chart-ringan: #aaa6a6;
    --chart-sedang: #f2b76a;
    --chart-berat: #f5515c;

    /* Login hero & trust banner */
    --login-banner-bg: #131b2e;
    --login-banner-text: #bec6e0;
    --login-notice-text: #cbdbf5;

    /* Solid form of --tile-teal — used for the upload progress label */
    --teal-ink: #0c9488;

    /* Overlay surfaces (Figma 30:8 / 30:60 / 30:167 / 30:222) */
    --tile-mint: #e6f4f1;

    /* Elevation */
    --shadow-card: 0 1px 1px rgba(0, 0, 0, 0.05);
    --shadow-header: 0 1px 8px rgba(0, 0, 0, 0.04);
    --shadow-nav: 0 -2px 12px rgba(0, 0, 0, 0.04);
    --shadow-raise: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);

    /* Shape */
    --radius-xs: 2px;
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Typography */
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

    /* Shell metrics */
    /* The original Figma canvas is 390px, but the application shell expands
       gracefully up to a readable desktop width. */
    --app-width: 1180px;
    --header-height: 64px;
    --nav-height: 64px;
    --nav-inset: 36px;
    --gutter: clamp(16px, 3vw, 32px);
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
p {
    margin: 0;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

button {
    margin: 0;
    padding: 0;
    font: inherit;
    color: inherit;
    background: none;
    border: 0;
    cursor: pointer;
}

a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   3.1 Icon tile — rounded surface holding a single icon
   Sizes: base 32px (radius 12), --sm 24px (radius 4), --square 32px (radius 4)
   -------------------------------------------------------------------------- */
.icon-tile {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-lg);
}

.icon-tile--sm {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
}

.icon-tile--square {
    border-radius: var(--radius-sm);
}

.icon-tile--dark {
    background: var(--ink);
}

.icon-tile--blue {
    background: var(--tile-blue);
}

.icon-tile--violet {
    background: var(--tile-violet);
}

.icon-tile--teal {
    background: var(--tile-teal);
}

a.icon-tile,
button.icon-tile {
    transition: opacity 0.15s ease, transform 0.12s ease;
}

a.icon-tile:hover,
button.icon-tile:hover {
    opacity: 0.85;
}

a.icon-tile:active,
button.icon-tile:active {
    transform: scale(0.94);
}

/* --------------------------------------------------------------------------
   3.2 Card — elevated white surface
   -------------------------------------------------------------------------- */
.card {
    padding: 16px;
    border-radius: var(--radius-md);
    background: var(--surface);
    box-shadow: var(--shadow-card);
}

.card--muted {
    background: var(--surface-variant);
}

/* --------------------------------------------------------------------------
   3.2b Metric tile — white figure box next to a label
   Used by the school cards and the Portal Guru summary (Figma 13:273).
   -------------------------------------------------------------------------- */
.metric-tile {
    display: flex;
    flex: 0 0 108.66px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    box-shadow: var(--shadow-card);
}

.metric-tile__value {
    font-size: 24px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.36px;
    text-align: center;
}

.metric-tile__label {
    padding-top: 6px;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
    text-align: center;
}

/* --------------------------------------------------------------------------
   3.3 Section head — title (+ subtitle) on the left, meta/action on the right
   -------------------------------------------------------------------------- */
.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.section-head__titles {
    display: flex;
    flex-direction: column;
}

/* The Figma source spaces the schools header slightly tighter than the
   distribution header; keep both values so each section matches the design. */
.section-head__titles--spaced {
    gap: 2.5px;
    padding-bottom: 1.5px;
}

.section-head__title {
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.4px;
}

.section-head__subtitle {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

.section-head__meta {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

/* --------------------------------------------------------------------------
   3.4 Text link — primary coloured label with a trailing icon
   -------------------------------------------------------------------------- */
.text-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--primary);
    text-decoration: none;
}

.text-link__label {
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.18px;
}

.text-link--medium .text-link__label {
    font-weight: 500;
}

.text-link--sm .text-link__label {
    font-size: 11px;
    line-height: 14px;
    letter-spacing: 0.22px;
}

.text-link:hover .text-link__label {
    text-decoration: underline;
}

/* --------------------------------------------------------------------------
   3.5 Role banner — current user role
   -------------------------------------------------------------------------- */
.role-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px;
    border-radius: var(--radius-md);
    background: var(--surface-variant);
    box-shadow: var(--shadow-card);
}

.role-banner__group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.role-banner__text {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

/* Two-line variant: role row on top, school name below (Figma 13:147). */
.role-banner__text--stacked {
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0;
}

.role-banner__row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.role-banner__subtitle {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

.role-banner__label {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
}

.role-banner__badge {
    padding: 2px 6px;
    border-radius: 12px;
    background: var(--badge-blue);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
}

/* --------------------------------------------------------------------------
   3.6 KPI cards — Ringkasan Metrik Laporan
   -------------------------------------------------------------------------- */
.kpi-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.kpi-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 132px;
}

.kpi-card__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.kpi-card__label {
    font-size: 11px;
    font-weight: 500;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.kpi-card__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.kpi-card__figure {
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.kpi-card__number {
    font-size: 24px;
    font-weight: 600;
    line-height: 32px;
    letter-spacing: -0.36px;
}

.kpi-card__unit {
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    color: var(--on-surface-variant);
}

.kpi-card__trend {
    display: flex;
    align-items: center;
    gap: 4px;
}

.kpi-card__delta-group {
    display: inline-flex;
    align-items: center;
}

.kpi-card__delta {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--error);
}

.kpi-card__trend-label,
.kpi-card__period {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.kpi-card__spacer {
    height: 28px;
}

/* Rincian laporan belum terselesaikan — subset, bukan duplikat angka utama. */
.kpi-card__breakdown {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 4px;
}

.kpi-card__breakdown-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.kpi-card__breakdown-dot {
    flex: 0 0 auto;
    width: 6px;
    height: 6px;
    border-radius: 12px;
    background: var(--on-surface-variant);
}

.kpi-card__breakdown-dot--sla {
    background: var(--error);
}

.kpi-card__breakdown-label {
    flex: 1 1 auto;
    min-width: 0;
}

.kpi-card__breakdown-count {
    flex: 0 0 auto;
    color: var(--on-surface);
}

/* --------------------------------------------------------------------------
   3.7 Distribution — Distribusi Kategori Kasus
   -------------------------------------------------------------------------- */
.distribution {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.distribution__bar-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.distribution__bar {
    display: flex;
    height: 12px;
    overflow: hidden;
    border-radius: 12px;
    background: var(--tile-blue);
}

.distribution__segment {
    height: 100%;
}

.distribution__segment--ringan {
    background: var(--chart-ringan);
}

.distribution__segment--sedang {
    background: var(--chart-sedang);
}

.distribution__segment--berat {
    background: var(--chart-berat);
}

.distribution__segment--selesai {
    background: var(--teal-ink);
}

.distribution__segment--belum-selesai {
    background: var(--error);
}

.distribution__legend {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.distribution__legend-item {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.distribution__rows {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.distribution__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 48px;
    padding: 8px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
}

.distribution__row-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.distribution__dot {
    width: 10px;
    height: 10px;
    border-radius: 12px;
}

.distribution__dot--ringan {
    background: var(--chart-ringan);
}

.distribution__dot--sedang {
    background: var(--chart-sedang);
}

.distribution__dot--berat {
    background: var(--chart-berat);
}

.distribution__dot--selesai {
    background: var(--teal-ink);
}

.distribution__dot--belum-selesai {
    background: var(--error);
}

.distribution__row-label {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
}

.distribution__row-value {
    display: flex;
    align-items: center;
    gap: 6px;
    padding-left: 4px;
}

.distribution__row-count {
    font-size: 12px;
    line-height: 16px;
}

.distribution__row-percent {
    font-size: 16px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.18px;
}

/* --------------------------------------------------------------------------
   3.8 Schools — Kasus Per Sekolah
   -------------------------------------------------------------------------- */
.schools {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.school-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.school-card__info {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    min-width: 0;
}

.school-card__meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
}

.school-card__name {
    max-width: 170px;
    overflow: hidden;
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.08px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.school-card__npsn {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 400;
    line-height: 16px;
    color: var(--on-surface-variant);
}

.school-card__detail {
    margin: 0;
    color: var(--on-surface-variant);
    font-size: 11px;
    line-height: 16px;
}

.school-card__detail--address {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.school-profile__principal {
    margin: 0;
    color: var(--on-surface-variant);
    font-size: 12px;
    line-height: 18px;
}

/* Title + search field card on the Sekolah page (Figma node 13:1198) */
.school-search {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* --------------------------------------------------------------------------
   3.9 Filter panel & field — search + dropdown + chips stack
   -------------------------------------------------------------------------- */
.filter-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.field__label {
    font-size: 11px;
    font-weight: 500;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

/* Label (+ optional counter or trailing link) above a control — shared by the
   Login form and the report form. Figma 13:1433 / 13:1467. */
.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-field__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.form-field__label {
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    color: var(--on-surface);
}

/* The mandatory marker: a bold red asterisk (Figma 13:1434). */
.form-field__required {
    font-weight: 700;
    color: var(--error);
}

.form-field__counter {
    color: var(--on-surface-variant);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 400;
    line-height: 16px;
}

/* --------------------------------------------------------------------------
   3.10 Search field — leading icon, input, trailing clear button
   -------------------------------------------------------------------------- */
.search-field {
    position: relative;
}

.search-field__input {
    width: 100%;
    height: 40px;
    padding: 0 36px 0 40px;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 400;
}

.search-field__input::placeholder {
    color: rgba(69, 70, 77, 0.7);
}

.search-field__input:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 0;
}

.search-field__input::-webkit-search-decoration,
.search-field__input::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
}

.search-field__icon {
    position: absolute;
    top: 50%;
    left: 14.5px;
    transform: translateY(-50%);
    pointer-events: none;
}

.search-field__clear {
    position: absolute;
    top: 50%;
    right: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 12px;
    transform: translateY(-50%);
    transition: background-color 0.15s ease;
}

.search-field__clear:hover {
    background: rgba(11, 28, 48, 0.06);
}

/* --------------------------------------------------------------------------
   3.11 Select button — dropdown-style control
   -------------------------------------------------------------------------- */
.select-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    transition: opacity 0.15s ease;
}

.select-button:hover {
    opacity: 0.85;
}

.select-button__value {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.select-button__text {
    overflow: hidden;
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.18px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.select-button--native {
    border: 0;
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 600;
}

.filter-submit {
    display: flex;
    align-self: flex-start;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    width: 100%;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    background: var(--ink);
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
}

.filter-submit:hover {
    opacity: 0.88;
}

/* --------------------------------------------------------------------------
   3.12 Status chips — horizontally scrollable status filter pills
   -------------------------------------------------------------------------- */
.status-filters {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 32px;
    overflow-x: auto;
    scrollbar-width: none;
}

.status-filters::-webkit-scrollbar {
    display: none;
}

.status-chip {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 4px;
    height: 26px;
    padding: 0 12px;
    border-radius: 12px;
    font-size: 11px;
    line-height: 14px;
    letter-spacing: 0.22px;
    white-space: nowrap;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.status-chip:hover {
    opacity: 0.85;
}

.status-chip--strong {
    background: var(--ink);
    color: #ffffff;
    font-weight: 600;
}

.status-chip--tonal {
    background: var(--surface-variant);
    color: var(--on-surface);
    font-weight: 500;
}

.status-chip__dot {
    width: 8px;
    height: 8px;
    border-radius: 12px;
}

.status-chip__dot--error {
    background: var(--error);
}

.status-chip__dot--success {
    background: var(--success);
}

/* --------------------------------------------------------------------------
   3.13 Category chips — secondary filter pills
   -------------------------------------------------------------------------- */
.category-filters {
    display: flex;
    align-items: center;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
}

.category-filters::-webkit-scrollbar {
    display: none;
}

.category-filters__label {
    flex: 0 0 auto;
    padding-right: 4px;
    font-size: 11px;
    font-weight: 500;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
    white-space: nowrap;
}

.category-chip {
    flex: 0 0 auto;
    padding: 4px 10px;
    border-radius: 6px;
    background: var(--surface-variant);
    color: var(--on-surface-variant);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    white-space: nowrap;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.category-chip:hover {
    opacity: 0.85;
}

.category-chip--active {
    background: var(--primary-soft);
    color: var(--primary);
}

/* --------------------------------------------------------------------------
   3.14 Button — equal-width action pair
   -------------------------------------------------------------------------- */
.button {
    display: flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    height: 40px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.18px;
    text-align: center;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.button:hover {
    opacity: 0.88;
}

.button--dark {
    /* Figma spaces the icon and its label apart and nudges the pair left of
       centre (gap 20.14 / padding 12 left, 26.14 right); rounded here. */
    gap: 20px;
    padding: 0 26px 0 12px;
    background: var(--ink);
    color: #ffffff;
    font-weight: 600;
}

.button--tonal {
    background: var(--surface-variant);
    color: var(--on-surface);
    font-weight: 500;
}

/* --------------------------------------------------------------------------
   3.15 Report list — laporan cards
   -------------------------------------------------------------------------- */
.reports {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.report {
    display: flex;
    flex-direction: column;
}

.report__status {
    display: flex;
    align-items: center;
    gap: 4px;
    height: 34px;
    padding: 2px 16px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    background: var(--surface-variant);
    color: var(--on-surface-variant);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
}

.report__status--alert {
    background: var(--status-alert-bg);
    color: #ffffff;
}

.report__status--berat {
    background: var(--status-berat-bg);
    color: var(--status-berat-text);
}

.report__status--ringan {
    background: rgba(170, 166, 166, 0.3);
    color: var(--on-surface);
}

.report__status--sedang {
    background: var(--status-sedang-bg);
    color: var(--status-sedang-text);
}

.report__body {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.report__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
}

.report__identity {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
}

/* SLA 2x24 jam: tiket belum dikategorikan lewat batas waktu. */
.report__sla {
    flex: 0 0 auto;
    padding: 2px 8px;
    border-radius: var(--radius-xs);
    background: var(--error-container);
    color: var(--on-error-container);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    white-space: nowrap;
}

.report__ticket {
    flex: 0 0 auto;
    padding: 2px 8px;
    border-radius: var(--radius-xs);
    background: var(--surface-variant);
    color: var(--primary);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
}

.report__school {
    flex: 0 0 107px;
    overflow: hidden;
    padding: 2px 6px;
    border-radius: 12px;
    background: var(--badge-blue);
    font-size: 11px;
    font-weight: 400;
    line-height: 14px;
    letter-spacing: 0.22px;
    text-align: right;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.report__content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.report__title {
    font-size: 16px;
    font-weight: 600;
    line-height: 22px;
    letter-spacing: -0.08px;
}

.report__date {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-soft);
}

/* Workflow progress is deliberately separate from the incident category ribbon. */
.report__progress {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.report__progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--on-surface-variant);
}

.report__progress--disetujui {
    color: var(--teal-ink);
}

.report__progress--disetujui .report__progress-dot {
    background: var(--teal-ink);
}

.report__progress--ditolak {
    color: var(--error);
}

.report__progress--ditolak .report__progress-dot {
    background: var(--error);
}

.report__excerpt {
    display: -webkit-box;
    overflow: hidden;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

/* Read-only cards (Guru) show the chronology in full — Figma 13:352 is 3 lines. */
.report__excerpt--full {
    display: block;
    overflow: visible;
}

.report__reporter {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant-soft);
}

.report__reporter-avatar {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 12px;
    background: var(--tile-avatar-blue);
}

.report__reporter-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.report__reporter-name {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
}

.report__reporter-note {
    overflow: hidden;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
    white-space: nowrap;
    text-overflow: ellipsis;
}

.report__actions {
    display: flex;
    gap: 8px;
}

/* Read-only card: one 32px action across the card (Figma 13:333) */
.report__actions--single {
    padding-top: 4px;
}

.report__open {
    display: flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    color: var(--on-surface);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.report__open:hover {
    opacity: 0.85;
}

.reports-footer {
    padding-top: 8px;
    text-align: center;
}

.reports-footer__text {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

.reports-empty {
    padding: 24px;
    border-radius: var(--radius-md);
    background: var(--surface);
    color: var(--on-surface-variant);
    font-size: 14px;
    text-align: center;
}

/* --------------------------------------------------------------------------
   3.16 Profile — Profil page cards
   -------------------------------------------------------------------------- */
.profile-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.profile-card__head {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.profile-card__avatar {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 28px;
    background: var(--primary);
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    line-height: normal;
}

.profile-card__info {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.profile-card__name {
    font-size: 16px;
    font-weight: 700;
    line-height: normal;
}

.profile-card__badge {
    align-self: flex-start;
    padding: 2px 8px;
    border-radius: 100px;
    background: var(--badge-violet);
    color: var(--primary);
    font-size: 11px;
    font-weight: 600;
    line-height: normal;
    white-space: nowrap;
}

.profile-card__id {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--on-surface-variant);
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 400;
    line-height: normal;
}

.card-title {
    font-size: 14px;
    font-weight: 700;
    line-height: normal;
}

/* Hairline between rows — Figma exports it as a 1px line asset (#E5E7EB) */
.divider {
    height: 0;
    border-top: 1px solid var(--divider);
}

.info-list,
.action-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    font-size: 13px;
    line-height: normal;
    white-space: nowrap;
}

.info-row__label {
    font-weight: 400;
    color: var(--on-surface-variant);
}

.info-row__value {
    font-weight: 500;
    color: var(--on-surface);
    text-align: right;
}

.action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 2px 0;
    font-size: 13px;
    line-height: normal;
    text-align: left;
}

.action-row__label {
    flex: 1 1 0;
    overflow: hidden;
    min-width: 0;
    font-weight: 500;
    color: var(--on-surface);
    white-space: nowrap;
    text-overflow: ellipsis;
}

.action-row__meta {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.action-row__value {
    font-weight: 400;
    color: var(--on-surface-variant);
    white-space: nowrap;
}

.switch {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    width: 40px;
    height: 20px;
}

.logout-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px;
    border: 1.5px solid var(--error);
    border-radius: var(--radius-md);
    background: var(--surface);
    color: var(--error);
    font-size: 14px;
    font-weight: 600;
    line-height: normal;
    transition: background-color 0.15s ease;
}

.logout-button:hover {
    background: rgba(186, 26, 26, 0.04);
}

.app-version {
    padding-top: 8px;
    color: var(--on-surface-variant);
    font-size: 11px;
    font-weight: 400;
    line-height: normal;
    text-align: center;
}

/* --------------------------------------------------------------------------
   3.17 App header — fixed glass bar
   -------------------------------------------------------------------------- */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 20;
    width: 100%;
    max-width: none;
    background: rgba(255, 255, 255, 0.8);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow-header);
}

.app-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
    max-width: var(--app-width);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.app-header__logout {
    display: flex;
    margin: 0;
}

.account-menu {
    position: relative;
}

.account-menu > summary {
    list-style: none;
}

.account-menu > summary::-webkit-details-marker {
    display: none;
}

.account-menu__panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: min(260px, calc(100vw - (var(--gutter) * 2)));
    padding: 16px;
    border-radius: var(--radius-md);
    background: var(--surface);
    box-shadow: var(--shadow-raise);
}

.account-menu__name {
    overflow: hidden;
    font-size: 14px;
    font-weight: 700;
    line-height: 20px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-menu__role {
    margin-bottom: 8px;
    color: var(--on-surface-variant);
    font-size: 12px;
    line-height: 18px;
}

.account-menu__logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 40px;
    border-radius: var(--radius-sm);
    background: var(--on-surface);
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
}

.app-nav__inner--trio {
    justify-content: space-around;
}

/* Detail pages: shorter bar with a back button and the page title */
.app-header--detail .app-header__inner {
    height: 56px;
}

.app-header__lead {
    display: flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
}

.app-header__title {
    overflow: hidden;
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.08px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.back-button {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    /* The touch target bleeds 8px into the gutter so the arrow lines up with
       the page rhythm (Figma 13:1174). */
    margin-left: -8px;
    border-radius: var(--radius-lg);
    transition: opacity 0.15s ease;
}

.back-button:hover {
    opacity: 0.85;
}

.brand {
    display: flex;
    align-items: center;
    gap: 6px;
}

.brand__name {
    font-size: 16px;
    font-weight: 600;
    line-height: 20px;
    letter-spacing: -0.08px;
}

/* --------------------------------------------------------------------------
   3.18 Page canvas
   -------------------------------------------------------------------------- */
.page {
    max-width: var(--app-width);
    min-height: 100vh;
    margin: 0 auto;
    padding: var(--header-height) 0 calc(96px + env(safe-area-inset-bottom));
}

.page__inner {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: var(--gutter);
}

/* --------------------------------------------------------------------------
   3.19 Bottom nav — fixed glass bar
   -------------------------------------------------------------------------- */
.app-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    z-index: 20;
    width: 100%;
    max-width: none;
    background: rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow-nav);
}

.app-nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    height: var(--nav-height);
    max-width: var(--app-width);
    margin: 0 auto;
    /* Figma 26:55 insets the four links well inside the bar (the page gutter
       is too tight for the nav), leaving room left and right of the row. */
    padding: 0 var(--nav-inset);
}

/* With only two links Figma instead centres them with equal space around each
   (link centres at 106 / 285 of 390 — Figma 13:406), so the row's own gap of
   24px must not eat into that space. */
.app-nav__inner--duo {
    gap: 0;
    padding: 0 var(--gutter);
    justify-content: space-around;
}

/* --------------------------------------------------------------------------
   4. Responsive layout
   The mobile composition remains the default. These rules progressively use
   extra space on tablets and desktop screens without changing the HTML flow.
   -------------------------------------------------------------------------- */
@media (max-width: 359px) {
    :root {
        --gutter: 12px;
        --nav-inset: 20px;
    }

    .card {
        padding: 12px;
    }

    .login-card,
    .home-card {
        padding: 16px;
    }

    .meta-grid,
    .form-row,
    .modal__actions {
        flex-direction: column;
    }

    .metric-tile {
        flex-basis: 92px;
    }
}

@media (min-width: 640px) {
    :root {
        --gutter: 24px;
        --nav-inset: 48px;
    }

    .page__inner {
        gap: 24px;
    }

    .card {
        padding: 20px;
    }

    .login-card,
    .home-card {
        padding: 28px;
    }

    .kpi-card {
        min-height: 150px;
    }

    .school-card__name {
        max-width: none;
    }
}

@media (min-width: 768px) {
    :root {
        --header-height: 72px;
        --nav-height: 72px;
        --gutter: 28px;
    }

    .app-header__inner,
    .app-nav__inner {
        padding-left: var(--gutter);
        padding-right: var(--gutter);
    }

    .app-nav__inner {
        justify-content: space-evenly;
    }

    .page {
        padding-bottom: calc(112px + env(safe-area-inset-bottom));
    }

    .page--login .page__inner,
    .page--report-form .page__inner,
    .page--case-detail .page__inner {
        max-width: 820px;
        margin: 0 auto;
    }

    .page--reporter-home .home-banner,
    .page--reporter-home .home-content {
        max-width: 820px;
        margin-right: auto;
        margin-left: auto;
    }

    .page--dashboard .page__inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        align-items: start;
    }

    .page--dashboard .role-banner,
    .page--dashboard .kpi-section,
    .page--dashboard .distribution,
    .page--dashboard .schools {
        grid-column: 1 / -1;
    }

    .page--dashboard .schools {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .page--dashboard .schools > .section-head {
        grid-column: 1 / -1;
    }

    .page--reports-page .filter-panel {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
        align-items: end;
        gap: 16px;
    }

    .page--reports-page .status-filters,
    .page--reports-page .category-filters {
        grid-column: 1 / -1;
        flex-wrap: wrap;
        height: auto;
        overflow: visible;
    }

    .page--reports-page .filter-submit {
        align-self: end;
        width: auto;
        white-space: nowrap;
    }

    .page--reports-page .reports,
    .page--detail-school .reports,
    .page--guru .reports {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }

    .page--schools-page .schools {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .page--profile .page__inner {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }

    .page--profile .profile-card:first-child,
    .page--profile #logout-form,
    .page--profile .app-version {
        grid-column: 1 / -1;
    }

    .guru-page__banner,
    .guru-page__summary,
    .guru-page__list {
        max-width: var(--app-width);
        margin-right: auto;
        margin-left: auto;
    }
}

@media (min-width: 1024px) {
    :root {
        --gutter: 32px;
    }

    .page--dashboard .kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .page--dashboard .distribution,
    .page--dashboard .schools {
        min-height: 100%;
    }


    .page--reporter-home .home-card {
        max-width: 760px;
    }

    .page--report-form .report-form {
        max-width: 820px;
    }
}

.nav-item {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-width: 44px;
    min-height: 44px;
    padding: 3px 0;
    text-decoration: none;
}

.nav-item__label {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
    white-space: nowrap;
}

.nav-item--active .nav-item__label {
    color: var(--primary);
}

.nav-item:hover .nav-item__label {
    color: var(--primary);
}

/* --------------------------------------------------------------------------
   3.20 Case detail — Kronologi + evidence block on Detail Kasus
   Figma: node 13:458.
   -------------------------------------------------------------------------- */
.case-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.case-section__head {
    display: flex;
    align-items: center;
    gap: 4px;
}

.case-section__title {
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.08px;
}

.case-section__body {
    display: flex;
    flex-direction: column;
    /* Figma 13:464 measures this heading-to-paragraph gap at 2.875px. */
    gap: 2.875px;
}

.case-section__heading {
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    letter-spacing: 0.14px;
}

.case-section__text {
    font-size: 14px;
    font-weight: 400;
    line-height: 22.75px;
    color: var(--on-surface-variant);
}

/* Attachment row + two preview thumbnails (Figma 13:469) */
.evidence {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 4px;
}

.evidence__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.evidence__label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
    letter-spacing: 0.18px;
}

.evidence__grid {
    display: flex;
    gap: 8px;
}

/* Figma renders the 159 x 119.25 slot as a fixed crop of the source photo
   (137.63% wide, vertically centred), which is exactly object-fit: cover. */
.evidence__item {
    position: relative;
    display: flex;
    flex: 1 1 0;
    align-items: flex-end;
    min-width: 0;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: var(--radius-sm);
    background: var(--tile-avatar-blue);
    text-decoration: none;
}

.evidence__image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.evidence__gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 50%);
}

.evidence__caption {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 4px;
}

.evidence__name {
    overflow: hidden;
    color: #ffffff;
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.evidence__meta {
    overflow: hidden;
    color: #eaf1ff;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* Tinted full-width download bar (Figma 13:494) */
.file-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--tile-avatar-blue);
    color: var(--on-surface);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    text-align: center;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.file-button:hover {
    opacity: 0.85;
}

.file-button__label {
    min-width: 0;
}

/* --------------------------------------------------------------------------
   3.21 Login — hero & trust banner, login form card, footer
   Figma: nodes 13:192 (banner), 13:204 (form card), 13:238 (footer).
   -------------------------------------------------------------------------- */
.login-banner {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
    padding: 24px;
    border-radius: var(--radius-md);
    background: var(--login-banner-bg);
    box-shadow: var(--shadow-raise);
}

.login-banner__title {
    font-size: 24px;
    font-weight: 600;
    line-height: 32px;
    letter-spacing: -0.36px;
    color: #ffffff;
}

.login-banner__text {
    padding-bottom: 12px;
    font-size: 12px;
    font-weight: 400;
    line-height: 19.5px;
    color: var(--login-banner-text);
}

.login-banner__notice {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
}

.login-banner__notice-text {
    /* Figma 13:200 reserves 26.75px on the right, which is what sets the
       notice copy's line breaks. */
    padding-right: 26.75px;
    font-size: 12px;
    font-weight: 400;
    line-height: 15px;
    color: var(--login-notice-text);
}

/* Decorative brand glow bleeding out of the banner's bottom-right corner */
.login-banner__glow {
    position: absolute;
    right: -24px;
    bottom: -24px;
    width: 128px;
    height: 128px;
    border-radius: var(--radius-lg);
    background: var(--primary-soft);
    filter: blur(20px);
}

.login-card {
    /* Figma 13:204 pads the card 24px (the shared .card default is 16px). */
    padding: 24px;
    /* Figma 13:203 keeps 24px under the card before the page footer. */
    margin-bottom: 24px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-input {
    position: relative;
}

.login-input__control {
    width: 100%;
    height: 44px;
    padding: 0 12px 0 40px;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 400;
}

.login-input__control::placeholder {
    color: rgba(69, 70, 77, 0.6);
}

.login-input__control:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 0;
}

/* Figma 13:223 measures the password field's padding symmetrically at 40px */
.login-input--password .login-input__control {
    padding-right: 40px;
}

.login-input__icon {
    position: absolute;
    top: 50%;
    left: 12px;
    display: flex;
    align-items: center;
    transform: translateY(-50%);
    pointer-events: none;
}

/* Figma 13:229 pads 12px on the top/right/bottom only, so the hit area is
   30.33 x 36.5 and the icon sits 12px in from the field's right edge. */
.login-input__toggle {
    position: absolute;
    top: 50%;
    right: 0;
    display: flex;
    align-items: center;
    padding: 12px 12px 12px 0;
    transform: translateY(-50%);
    transition: opacity 0.15s ease;
}

.login-input__toggle:hover {
    opacity: 0.7;
}

.login-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 48px;
    /* Figma 13:232 wraps the CTA in a 4px top padding. */
    margin-top: 4px;
    border-radius: var(--radius-sm);
    background: var(--ink);
    box-shadow: var(--shadow-card);
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    letter-spacing: 0.14px;
    transition: opacity 0.15s ease;
}

.login-submit:hover {
    opacity: 0.88;
}

.login-footer {
    padding: 0 var(--gutter) 24px;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
    text-align: center;
}

/* Keep the login content visually balanced on tall screens. The flex layout
   still allows normal scrolling when a short viewport cannot fit the form. */
.page--login {
    display: flex;
    flex-direction: column;
    min-height: 100svh;
}

.page--login .page__inner {
    flex: 1 0 auto;
    justify-content: center;
}

/* No error state exists in the design — this reuses the existing error tokens
   so a failed sign-in still reads as part of the system. */
.login-error {
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--error-container);
    color: var(--on-error-container);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
}

/* --------------------------------------------------------------------------
   3.22 Home — Pelapor/Guru home layout
   Figma: nodes 13:141 (role banner slot) and 13:155 (content stack).
   -------------------------------------------------------------------------- */
.home-banner {
    /* The banner hugs the header: 8px above, 16px below (Figma 13:141). */
    padding: 8px var(--gutter) 16px;
}

.home-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 0 var(--gutter);
}

.home-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
    /* Figma 13:156 pads the card 24px and lifts it 1px/2px. */
    padding: 24px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.home-card__intro {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.home-card__text {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

.home-card__actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 4px;
}

.home-card__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    background: var(--ink);
    box-shadow: var(--shadow-card);
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    letter-spacing: 0.14px;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.home-card__cta:hover {
    opacity: 0.88;
}

.home-card__note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

/* Ticket lookup panel on the Pelapor dashboard. */
.progress-check {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.progress-check__form {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.progress-check__controls {
    display: flex;
    gap: 8px;
}

.progress-check__input {
    flex: 1 1 auto;
    min-width: 0;
    height: 44px;
    padding: 0 12px;
}

.progress-check__button {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 44px;
    padding: 0 14px;
    border-radius: var(--radius-sm);
    background: var(--ink);
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    line-height: 16px;
}

.progress-check__button:hover {
    opacity: 0.88;
}

.progress-check__message {
    margin: 0;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    line-height: 18px;
}

.progress-check__message--error {
    background: var(--error-container);
    color: var(--on-error-container);
}

.progress-result {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    border-left: 4px solid var(--on-surface-variant);
}

.progress-result--disetujui {
    border-left-color: var(--teal-ink);
}

.progress-result--ditolak {
    border-left-color: var(--error);
}

.progress-result__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.progress-result__ticket,
.progress-result__status {
    padding: 3px 8px;
    border-radius: var(--radius-xs);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
}

.progress-result__ticket {
    background: var(--badge-blue);
    color: var(--primary);
    font-family: var(--font-mono);
}

.progress-result__status {
    background: var(--surface);
}

.progress-result--disetujui .progress-result__status {
    color: var(--teal-ink);
}

.progress-result--ditolak .progress-result__status {
    color: var(--error);
}

.progress-result__title {
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
}

.progress-result__note {
    color: var(--on-surface-variant);
    font-size: 12px;
    line-height: 18px;
}

@media (max-width: 480px) {
    .progress-check__controls {
        flex-direction: column;
    }

    .progress-check__button {
        width: 100%;
    }
}

/* --------------------------------------------------------------------------
   3.23 Report form — Formulir Laporan (Pelapor)
   Figma: nodes 13:1390 (safe banner), 13:1402/13:1426/13:1490 (sections),
   13:1526 (submit).
   -------------------------------------------------------------------------- */
.report-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Card wrapper for each form section (Figma 13:1402 / 13:1426 / 13:1490) */
.report-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Bagian 1 stacks its heading and metadata grid 8px apart. */
.report-section--tight {
    gap: 8px;
}

/* Section heading: a black accent bar plus the title (Figma 13:1427) */
.report-form__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

/* Bagian 2 & 3 hold their heading 4px further off the fields (Figma 13:1427,
   13:1491). Bagian 1's eyebrow row has no such padding. */
.report-form__head--roomy {
    padding-bottom: 4px;
}

.report-form__head-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.report-form__mark {
    flex: 0 0 auto;
    width: 6px;
    height: 16px;
    border-radius: 12px;
    background: var(--ink);
}

/* "Opsional" pill next to the section heading (Figma 13:1496) */
.form-tag {
    flex: 0 0 auto;
    padding: 2px 8px;
    border-radius: var(--radius-xs);
    background: var(--tile-avatar-blue);
    color: var(--on-surface-variant);
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    white-space: nowrap;
}

/* System-verified metadata banner (Figma 13:1390) */
.safe-banner {
    position: relative;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    overflow: hidden;
    padding: 16px;
    border-radius: var(--radius-md);
    background: var(--surface-variant);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.safe-banner__tile {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--badge-blue);
}

.safe-banner__text {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.safe-banner__desc {
    font-size: 12px;
    font-weight: 400;
    line-height: 19.5px;
    color: var(--on-surface-variant);
}

.safe-banner__glow {
    position: absolute;
    right: -24px;
    bottom: -23.5px;
    width: 96px;
    height: 96px;
    border-radius: var(--radius-lg);
    background: rgba(211, 228, 254, 0.4);
    filter: blur(12px);
}

/* Locked metadata card (Figma 13:1402) */
.report-form__eyebrow {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.55px;
    text-transform: uppercase;
    color: var(--on-surface-variant);
}

.report-form__readonly {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.meta-grid {
    display: flex;
    gap: 8px;
    padding-top: 4px;
}

.meta-block {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    padding: 8px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
}

.meta-block__label {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.meta-block__row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-block__value {
    overflow: hidden;
    color: var(--on-surface);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* Incident fields (Figma 13:1431 onwards) */
.form-row {
    display: flex;
    gap: 8px;
}

.form-row > * {
    flex: 1 1 0;
    min-width: 0;
}

.form-input {
    width: 100%;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 400;
}

.form-input:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 0;
}

.form-input::placeholder {
    color: rgba(69, 70, 77, 0.6);
}

/* Date field: icon at 12px, text starts at 38px (Figma 13:1435) */
.form-input--date {
    height: 44px;
    padding: 0 12px 0 38px;
}

/* Telephone input follows the same comfortable touch target as date/time. */
.form-input--phone {
    height: 44px;
    padding: 0 16px;
}

/* Judul Laporan: single line, clipped (Figma 13:1472) */
.form-input--title {
    padding: 10px 16px;
    line-height: 22px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.form-textarea {
    display: block;
    padding: 16px;
    line-height: 22.75px;
    /* Figma 13:1481 has no resize affordance; the field is a fixed 5 rows. */
    resize: none;
}

.form-control {
    position: relative;
}

.form-control__icon {
    position: absolute;
    top: 50%;
    left: 12px;
    display: flex;
    align-items: center;
    transform: translateY(-50%);
    pointer-events: none;
}

/* Perkiraan jam: icon and input share one 44px control (Figma 13:1452) */
.form-time {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 44px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
}

.form-time__input {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: none;
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 400;
}

.form-time__input:focus-visible {
    outline: none;
}

.form-note {
    display: flex;
    align-items: center;
    gap: 6px;
    padding-top: 8px;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

/* Bukti pendukung (Figma 13:1498) */
.dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px;
    border: 0;
    border-radius: var(--radius-md);
    background: var(--surface-variant);
    font-family: var(--font-sans);
    text-align: center;
}

.dropzone__tile {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 8px;
    border-radius: var(--radius-lg);
    background: var(--tile-avatar-blue);
    box-shadow: var(--shadow-card);
}

.dropzone__prompt {
    padding-bottom: 2px;
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.08px;
}

.dropzone__hint {
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
    color: var(--on-surface-variant);
}

.dropzone input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    clip-path: inset(50%);
}

.dropzone:focus-within {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.dropzone--selected {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.file-previews {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.file-preview__thumb {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-xs);
    object-fit: cover;
    cursor: zoom-in;
}

.file-preview__tile--document {
    color: var(--primary);
    font-size: 10px;
    font-weight: 700;
    text-align: center;
}

/* Uploaded file preview (Figma 13:1508) */
.file-preview {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px;
    border-radius: var(--radius-sm);
    background: var(--surface-variant);
}

.file-preview__tile {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-xs);
    background: var(--tile-avatar-blue);
}

.file-preview__info {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.file-preview__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.file-preview__name {
    overflow: hidden;
    padding-right: 8px;
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.file-preview__progress {
    flex: 0 0 auto;
    color: var(--teal-ink);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
}

.file-preview__bar {
    height: 6px;
    overflow: hidden;
    border-radius: 12px;
    background: var(--tile-avatar-blue);
}

.file-preview__bar-fill {
    height: 100%;
    border-radius: 12px;
    background: var(--primary);
}

.file-preview__meta {
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
    color: var(--on-surface-variant);
}

.file-preview__remove {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-lg);
    transition: background-color 0.15s ease;
}

.file-preview__remove:hover {
    background: rgba(11, 28, 48, 0.06);
}

/* Bottom action (Figma 13:1526) */
.form-actions {
    display: flex;
    padding-top: 8px;
}

.form-submit {
    display: flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 0;
    padding: 12px;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--ink);
    box-shadow: var(--shadow-raise);
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 16px;
    font-weight: 600;
    line-height: 24px;
    letter-spacing: -0.08px;
    transition: opacity 0.15s ease;
}

.form-submit:hover {
    opacity: 0.88;
}

/* --------------------------------------------------------------------------
   3.24 Report inbox — Portal Guru BK "Laporan Masuk"
   Figma: nodes 13:251 (banner slot), 13:265 (summary), 13:291 (list).
   -------------------------------------------------------------------------- */
.guru-page__banner {
    padding: 16px var(--gutter) 4px;
}

.guru-page__summary {
    padding: 8px var(--gutter);
}

.guru-page__list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 8px var(--gutter) 24px;
}

/* Tinted summary head joined to a white body, so they read as one card
   (Figma 13:266 + 13:279). */
.guru-summary {
    overflow: hidden;
    border-radius: var(--radius-md);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.guru-summary__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px;
    background: var(--surface-variant);
}

.guru-summary__text {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    padding: 0 5px;
}

.guru-summary__subtitle {
    font-size: 12px;
    font-weight: 400;
    line-height: 16px;
    color: var(--on-surface-variant);
}

.guru-summary__body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    /* 24px card padding plus the 4px the CTA group adds above itself
       (Figma 13:279 + 13:280). */
    padding: 28px 24px 24px;
    background: var(--surface);
}

/* Search + sort row above the inbox list (Figma 13:293) */
.guru-filters {
    display: flex;
    gap: 8px;
    align-items: center;
}

.guru-search {
    display: flex;
    flex: 1 1 0;
    gap: 8px;
    align-items: center;
    min-width: 0;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    box-shadow: var(--shadow-card);
}

.guru-search__input {
    width: 100%;
    min-width: 0;
    padding: 1px 0 2px;
    border: 0;
    background: none;
    color: var(--on-surface);
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 400;
    line-height: 15px;
}

.guru-search__input::placeholder {
    color: #76777d;
}

.guru-search__input:focus-visible {
    outline: none;
}

.guru-filters__sort {
    display: flex;
    flex: 0 0 auto;
    gap: 4px;
    align-items: center;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    box-shadow: var(--shadow-card);
    color: var(--on-surface);
    font-size: 12px;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 0.18px;
    transition: opacity 0.15s ease;
}

.guru-filters__sort:hover {
    opacity: 0.85;
}

/* Footer gains the page indicator on this page (Figma 13:1577) */
.reports-footer--paged {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.reports-pager {
    display: flex;
    gap: 4px;
    align-items: center;
    padding: 4px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    box-shadow: var(--shadow-card);
}

.reports-pager__page {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 32px;
    color: #76777d;
    font-size: 11px;
    font-weight: 600;
    line-height: 14px;
    letter-spacing: 0.22px;
}

/* --------------------------------------------------------------------------
   3.25 Overlays — modal (confirm / success) dan toast
   Figma: nodes 30:50, 30:102, 30:209 (modal) dan 30:263 (toast).
   -------------------------------------------------------------------------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(11, 28, 48, 0.35);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

/* `display: flex` above would otherwise win over the hidden attribute */
.modal[hidden] {
    display: none;
}

.modal__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
    max-width: 342px;
    padding: 24px;
    border-radius: var(--radius-xl);
    background: var(--surface);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.modal__icon {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 32px;
    background: var(--surface-variant);
}

.modal__icon--success {
    background: var(--tile-mint);
}

.modal__icon-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 24px;
    background: rgba(11, 28, 48, 0.08);
}

.modal__icon--success .modal__icon-inner {
    background: rgba(12, 148, 136, 0.14);
}

.modal__icon--accent .modal__icon-inner {
    background: rgba(75, 65, 225, 0.12);
}

.modal__text {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.modal__title {
    font-size: 18px;
    font-weight: 700;
    line-height: normal;
    color: var(--on-surface);
}

.modal__body {
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--on-surface-variant);
}

.modal__actions {
    display: flex;
    gap: 12px;
    width: 100%;
}

/* One action fills the row; two actions split it evenly (Figma 30:216).
   The outline variant draws its 1.5px ring inside so both variants stay 41px
   tall, as the design measures them. */
.modal__button {
    display: flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    min-width: 0;
    padding: 12px 24px;
    border: 0;
    border-radius: var(--radius-md);
    background: none;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 600;
    line-height: normal;
    text-align: center;
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.modal__button:hover {
    opacity: 0.88;
}

.modal__button--dark {
    background: var(--on-surface);
    color: #ffffff;
}

.modal__button--outline {
    box-shadow: inset 0 0 0 1.5px var(--badge-blue);
    color: var(--on-surface);
}

.modal__button--success {
    background: var(--teal-ink);
    color: #ffffff;
}

/* Toast — fixed just under the 64px header (Figma 30:263) */
.toast {
    position: fixed;
    top: 80px;
    left: 50%;
    z-index: 30;
    display: flex;
    gap: 12px;
    align-items: center;
    width: 358px;
    max-width: calc(100% - 32px);
    padding: 14px 16px;
    border-radius: var(--radius-lg);
    background: var(--on-surface);
    box-shadow: 0 8px 8px rgba(11, 28, 48, 0.25);
    transform: translateX(-50%);
}

.toast[hidden] {
    display: none;
}

.toast__icon {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 14px;
    background: rgba(12, 148, 136, 0.2);
}

.toast__text {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.toast__title {
    font-size: 13px;
    font-weight: 600;
    line-height: normal;
    color: #ffffff;
}

.toast__body {
    font-size: 12px;
    font-weight: 400;
    line-height: normal;
    color: rgba(255, 255, 255, 0.85);
}

.toast__close {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    transition: opacity 0.15s ease;
}

.toast__close:hover {
    opacity: 0.7;
}

/* --------------------------------------------------------------------------
   Preferences
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}
