/* ===== BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:       #090c14;
  --surface:  #0f1320;
  --blue:     #0a84ff;
  --blue-dim: rgba(10,132,255,0.15);
  --red:      #ff453a;
  --gold:     #ffd60a;
  --green:    #30d158;
  --white:    #ffffff;
  --g1:       rgba(255,255,255,0.88);
  --g2:       rgba(255,255,255,0.55);
  --g3:       rgba(255,255,255,0.25);
  --g4:       rgba(255,255,255,0.07);
  --glass:    rgba(255,255,255,0.05);
  --glass-b:  rgba(255,255,255,0.09);
  --navy-d:   #060e24;
  --navy-m:   #0c1d4a;
  --r-card:   18px;
  --r-el:     11px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--white);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ===== TOPNAV ===== */
.topnav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 28px;
  background: rgba(9,12,20,0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,0.07);
  position: sticky; top: 0; z-index: 100;
}

.nav-left  { display: flex; align-items: center; gap: 14px; }
.nav-right { display: flex; gap: 10px; }

.nav-logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.nav-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--g1);
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--blue); color: #fff;
  border: none; border-radius: 10px;
  padding: 9px 18px;
  font-family: 'Inter', sans-serif; font-size: 0.84rem; font-weight: 600;
  cursor: pointer; transition: filter .15s, transform .1s;
}
.btn-primary:hover  { filter: brightness(1.13); }
.btn-primary:active { transform: scale(.97); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--glass); color: var(--g1);
  border: 1px solid var(--glass-b); border-radius: 10px;
  padding: 9px 18px;
  font-family: 'Inter', sans-serif; font-size: 0.84rem; font-weight: 500;
  cursor: pointer; transition: background .15s;
}
.btn-ghost:hover { background: rgba(255,255,255,0.1); }

/* ===== CAROUSEL ===== */
.carousel-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 0 60px;
  overflow-y: auto;
}

.carousel-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  width: 100%;
}

.carousel-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  width: 100%;
  padding: 0 20px;
}

.carousel-viewport {
  width: 210mm;
  max-width: calc(100vw - 120px);
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.carousel-slide {
  flex-shrink: 0;
  display: flex;
  justify-content: center;
}

.carousel-btn {
  flex-shrink: 0;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.14);
  color: var(--g1);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .18s, transform .12s;
  backdrop-filter: blur(10px);
}
.carousel-btn:hover  { background: rgba(255,255,255,0.16); transform: scale(1.05); }
.carousel-btn:active { transform: scale(0.95); }
.carousel-btn:disabled { opacity: 0.25; cursor: default; transform: none; }

.carousel-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.carousel-dots { display: flex; gap: 7px; align-items: center; }

.cdot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.22);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background .2s, transform .2s, width .2s;
}
.cdot.active {
  background: var(--blue);
  transform: scale(1.25);
  width: 20px;
  border-radius: 4px;
}
.cdot:hover:not(.active) { background: rgba(255,255,255,0.45); }

.carousel-counter {
  font-size: 0.73rem;
  color: var(--g3);
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* =============================================
   REPORT CARD
   ============================================= */
.report-card {
  width: 210mm;
  min-height: 297mm;
  max-width: calc(100vw - 140px);
  background: var(--surface) url('../../BG1.png') center center / cover no-repeat;
  border-radius: var(--r-card);
  border: 1px solid rgba(255,255,255,0.07);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.03) inset,
    0 28px 64px rgba(0,0,0,0.6),
    0 4px 16px rgba(0,0,0,0.35);
  transition: transform .22s ease, box-shadow .22s ease;
}
.report-card:hover {
  transform: translateY(-4px);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.05) inset,
    0 36px 72px rgba(0,0,0,0.65),
    0 6px 24px rgba(10,132,255,0.14);
}

.report-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(9, 12, 20, 0.80);
  z-index: 0;
  pointer-events: none;
  border-radius: var(--r-card);
}

.tech-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cdefs%3E%3Cpattern id='p' x='0' y='0' width='80' height='80' patternUnits='userSpaceOnUse'%3E%3Crect width='80' height='80' fill='none'/%3E%3Cline x1='0' y1='40' x2='30' y2='40' stroke='%2300c8ff' stroke-width='1'/%3E%3Cline x1='50' y1='40' x2='80' y2='40' stroke='%2300c8ff' stroke-width='1'/%3E%3Cline x1='40' y1='0' x2='40' y2='30' stroke='%2300c8ff' stroke-width='1'/%3E%3Cline x1='40' y1='50' x2='40' y2='80' stroke='%2300c8ff' stroke-width='1'/%3E%3Ccircle cx='40' cy='40' r='4' fill='none' stroke='%2300c8ff' stroke-width='1'/%3E%3Ccircle cx='40' cy='40' r='1.5' fill='%2300c8ff'/%3E%3Ccircle cx='0' cy='0' r='1.5' fill='%2300c8ff'/%3E%3Ccircle cx='80' cy='0' r='1.5' fill='%2300c8ff'/%3E%3Ccircle cx='0' cy='80' r='1.5' fill='%2300c8ff'/%3E%3Ccircle cx='80' cy='80' r='1.5' fill='%2300c8ff'/%3E%3Cline x1='0' y1='0' x2='15' y2='0' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='0' y1='0' x2='0' y2='15' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='80' y1='0' x2='65' y2='0' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='80' y1='0' x2='80' y2='15' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='0' y1='80' x2='15' y2='80' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='0' y1='80' x2='0' y2='65' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='80' y1='80' x2='65' y2='80' stroke='%2300c8ff' stroke-width='0.7'/%3E%3Cline x1='80' y1='80' x2='80' y2='65' stroke='%2300c8ff' stroke-width='0.7'/%3E%3C/pattern%3E%3C/defs%3E%3Crect width='80' height='80' fill='url(%23p)'/%3E%3C/svg%3E");
  background-repeat: repeat;
}

/* ── CARD HEADER ── */
.card-header {
  background: linear-gradient(135deg, #0b1c48 0%, #060e24 100%);
  padding: 11px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(10,132,255,0.2);
  position: relative;
  z-index: 1;
}

.header-logos { display: flex; align-items: center; gap: 10px; }

.logo-ustp-img {
  height: 46px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.header-org-name {
  font-size: 0.52rem;
  font-weight: 700;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  line-height: 1.65;
}

.header-right {
  text-align: right;
  font-size: 0.56rem;
  font-weight: 700;
  color: var(--blue);
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  white-space: nowrap;
}

/* ── FOTO 4R ── */
.photo-section-4r {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 6px 14px 3px;
  background: transparent;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.photo-4r {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0c1d4a, #1a3470);
  aspect-ratio: 16 / 7;
}

.photo-4r img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transition: transform .3s ease;
}
.report-card:hover .photo-4r img { transform: scale(1.03); }

/* gradient overlay on photo section */
.photo-section-4r::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 70%, rgba(6,14,36,0.65) 100%);
  pointer-events: none;
  z-index: 2;
}

.photo-4r-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: rgba(255,255,255,0.15);
  font-size: 1.8rem;
}
.photo-4r-placeholder span {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  color: rgba(255,255,255,0.12);
}

/* ── CARD BODY ── */
.card-body {
  padding: 14px 20px 10px;
  display: flex;
  flex-direction: column;
  flex: 1;
  position: relative;
  z-index: 1;
  overflow: visible;
}

.card-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.42rem;
  line-height: 1.2;
  color: var(--white);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(1.42rem * 1.2 * 3);
}

/* ── INFO PILLS ── */
.info-pills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-bottom: 7px;
}

.info-pill {
  background: var(--glass);
  border: 1px solid var(--glass-b);
  border-radius: var(--r-el);
  padding: 9px 12px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.info-pill.full { grid-column: 1 / -1; }

.ip-icon { font-size: 0.95rem; line-height: 1.5; flex-shrink: 0; }

.time-range-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
}

.time-block {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.time-sub-label {
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--g3);
}

.time-sub-value {
  font-size: 0.77rem;
  font-weight: 700;
  color: var(--g1);
  line-height: 1.2;
}

.time-arrow {
  font-size: 0.7rem;
  color: var(--blue);
  font-weight: 700;
  margin-top: 6px;
}

.ip-text { display: flex; flex-direction: column; gap: 1px; }

.ip-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--blue);
}

.ip-value {
  font-size: 0.77rem;
  font-weight: 600;
  color: var(--g1);
  line-height: 1.3;
}

/* ── PESERTA PILL ── */
.peserta-pill {
  background: var(--glass);
  border: 1px solid var(--glass-b);
  border-radius: var(--r-el);
  padding: 9px 12px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.peserta-pill .ip-text { gap: 4px; }

.peserta-jumlah {
  font-size: 0.77rem;
  font-weight: 700;
  color: var(--g1);
  line-height: 1.3;
}

.peserta-breakdown {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.pb-item {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--g2);
  display: flex;
  align-items: center;
  gap: 3px;
}
.pb-item .pb-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.pb-dot.murid     { background: #0a84ff; }
.pb-dot.guru      { background: #30d158; }
.pb-dot.jurulatih { background: #ff9f0a; }
.pb-item .pb-num  { font-weight: 700; color: var(--g1); }

/* ── PENERANGAN BOX ── */
.desc-box {
  background: rgba(10,132,255,0.06);
  border: 1.5px solid rgba(10,132,255,0.2);
  border-radius: var(--r-el);
  padding: 13px 15px;
  margin-top: 8px;
}

.desc-box-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 8px;
}

.desc-box-icon {
  width: 22px; height: 22px;
  background: rgba(10,132,255,0.18);
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.72rem;
  flex-shrink: 0;
}

.desc-box-lbl {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--blue);
}

.desc-divider {
  height: 1px;
  background: linear-gradient(90deg, rgba(10,132,255,0.35), transparent);
  margin-bottom: 9px;
}

.desc-text {
  font-size: 0.78rem;
  line-height: 1.65;
  color: var(--g1);
  white-space: pre-line;
  word-break: break-word;
  overflow-wrap: break-word;
  display: block;
  overflow: visible;
}

/* ── FOOTER ── */
.card-footer {
  background: linear-gradient(90deg, #060e24, #0c1d4a);
  border-top: 1px solid rgba(10,132,255,0.15);
  padding: 10px 17px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1;
}

.footer-left { display: flex; flex-direction: column; gap: 2px; }

.footer-brand {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
}

.footer-tags {
  font-size: 0.44rem;
  color: rgba(255,255,255,0.2);
  letter-spacing: 0.6px;
}

.footer-badges { display: flex; gap: 5px; }

.fbadge {
  width: 27px; height: 27px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.1);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.4rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.2;
  color: rgba(255,255,255,0.55);
  background: rgba(255,255,255,0.04);
}

/* delete btn */
.btn-delete {
  position: absolute;
  top: 10px; right: 10px;
  background: rgba(255,69,58,0.12);
  border: 1px solid rgba(255,69,58,0.22);
  color: var(--red);
  width: 30px; height: 30px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 20;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.78rem;
  backdrop-filter: blur(8px);
  transition: background .15s;
}
.btn-delete:hover { background: rgba(255,69,58,0.28); }

/* empty state */
.empty-state {
  text-align: center;
  padding: 110px 20px;
  color: var(--g3);
  width: 100%;
}
.empty-state .es-icon { font-size: 3.5rem; margin-bottom: 14px; }
.empty-state h2 { font-size: 1.25rem; font-weight: 600; color: var(--g2); margin-bottom: 6px; }
.empty-state p  { font-size: 0.84rem; }

/* =============================================
   MODAL
   ============================================= */
.modal-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; }

.modal {
  background: #131722;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 26px 28px;
  width: min(600px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 36px 80px rgba(0,0,0,0.65), 0 0 0 1px rgba(255,255,255,0.03) inset;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 22px;
}
.modal-header h2 { font-size: 1.15rem; font-weight: 700; }

.modal-close {
  background: var(--glass); border: 1px solid var(--glass-b);
  border-radius: 50%; width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  color: var(--g2); cursor: pointer; transition: background .15s;
}
.modal-close:hover { background: rgba(255,255,255,0.12); }

.field-section-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--blue);
  margin: 18px 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.field-section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(10,132,255,0.2);
}

.field-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }

.field-row   { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-bottom: 14px; }

label {
  font-size: 0.73rem;
  font-weight: 600;
  color: var(--g2);
}

input, textarea {
  width: 100%;
  padding: 10px 13px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--r-el);
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.87rem;
  outline: none;
  transition: border-color .15s, background .15s;
  -webkit-appearance: none;
}
input::placeholder, textarea::placeholder { color: rgba(255,255,255,0.22); }
input:focus, textarea:focus {
  border-color: var(--blue);
  background: rgba(10,132,255,0.08);
}
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator { filter: invert(0.55); cursor: pointer; }
input[type="number"] { text-align: center; }

textarea { resize: vertical; min-height: 95px; line-height: 1.6; }

/* 4R upload grid */
.photo-upload-grid-4r {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 18px;
}

.pus-4r { cursor: pointer; }

.pus-4r-inner {
  aspect-ratio: 3 / 2;
  border-radius: 10px;
  border: 2px dashed rgba(255,255,255,0.14);
  background: var(--glass);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--g3);
  overflow: hidden;
  transition: border-color .2s;
}
.pus-4r-inner span { font-size: 0.68rem; font-weight: 500; }
.pus-4r:hover .pus-4r-inner { border-color: var(--blue); }
.pus-4r-inner img { width: 100%; height: 100%; object-fit: cover; }

.form-actions {
  display: flex; gap: 10px;
  justify-content: flex-end;
  padding-top: 6px;
}

/* ===== PRINT ===== */
/* =============================================
   TABLE VIEW
   ============================================= */
.table-view {
  padding: 32px 28px 60px;
  min-height: calc(100vh - 56px);
}

.tv-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.tv-topbar-left { display: flex; align-items: center; gap: 12px; }

.tv-heading {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--g1);
}

.tv-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--g3);
  background: var(--glass);
  border: 1px solid var(--glass-b);
  border-radius: 20px;
  padding: 3px 10px;
}

.tv-scroll {
  overflow-x: auto;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.07);
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  min-width: 900px;
}

.report-table thead th {
  background: #0b1c48;
  color: var(--blue);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 12px 14px;
  text-align: left;
  white-space: nowrap;
  border-bottom: 1px solid rgba(10,132,255,0.2);
}

.report-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: background .15s;
}
.report-table tbody tr:last-child { border-bottom: none; }
.report-table tbody tr:hover { background: rgba(255,255,255,0.03); }

.report-table td {
  padding: 12px 14px;
  color: var(--g1);
  vertical-align: top;
}

.td-no    { color: var(--g3); font-weight: 600; text-align: center; }
.td-title { font-weight: 600; max-width: 200px; }
.td-sm    { white-space: nowrap; color: var(--g2); font-size: 0.78rem; }
.td-num   { text-align: center; color: var(--g2); }
.td-desc  { max-width: 220px; color: var(--g2); font-size: 0.78rem; line-height: 1.5; white-space: pre-line; }
.td-actions { white-space: nowrap; }

.tv-btn {
  display: inline-flex; align-items: center; gap: 5px;
  border: none; border-radius: 7px;
  padding: 6px 11px;
  font-size: 0.73rem; font-weight: 600;
  cursor: pointer;
  transition: background .15s, transform .1s;
}
.tv-btn:active { transform: scale(.95); }

.tv-btn-edit {
  background: rgba(10,132,255,0.15);
  color: var(--blue);
  border: 1px solid rgba(10,132,255,0.25);
  margin-right: 6px;
}
.tv-btn-edit:hover { background: rgba(10,132,255,0.28); }

.tv-btn-del {
  background: rgba(255,69,58,0.1);
  color: var(--red);
  border: 1px solid rgba(255,69,58,0.2);
}
.tv-btn-del:hover { background: rgba(255,69,58,0.24); }

/* =============================================
   MOBILE
   ============================================= */
@media (max-width: 680px) {

  /* --- Topnav --- */
  .topnav { padding: 10px 12px; flex-direction: column; align-items: stretch; gap: 0; }
  .nav-left { display: flex; align-items: center; justify-content: space-between; width: 100%; margin-bottom: 8px; }
  .nav-logo-img { height: 34px; }
  .nav-title { font-size: 0.72rem; }
  .nav-right { display: flex; gap: 7px; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 2px; width: 100%; }
  .nav-right::-webkit-scrollbar { display: none; }
  .btn-ghost, .btn-primary { padding: 7px 12px; font-size: 0.74rem; white-space: nowrap; flex-shrink: 0; border-radius: 9px; }
  .btn-ghost svg, .btn-primary svg { width: 13px; height: 13px; }

  /* --- Carousel --- */
  .carousel-wrapper { padding: 16px 0 40px; }
  .carousel-row { gap: 6px; padding: 0 6px; }
  .carousel-btn { width: 30px; height: 30px; flex-shrink: 0; }
  .carousel-btn svg { width: 16px; height: 16px; }
  .carousel-viewport { max-width: calc(100vw - 60px) !important; }
  /* Slide aligns top-left so transform-origin works correctly */
  .carousel-slide { justify-content: flex-start; align-items: flex-start; }

  /* --- Modal --- */
  .modal-overlay { padding: 10px; align-items: flex-end; }
  .modal { padding: 18px 15px; border-radius: 18px 18px 10px 10px; max-height: 94vh; width: 100%; }
  .modal-header h2 { font-size: 1rem; }
  div.field-row[style] { grid-template-columns: 1fr !important; }
}

@media (max-width: 400px) {
  .nav-title { display: none; }
}

/* ===== PRINT ===== */
@page { size: A4 portrait; margin: 10mm; }

@media print {
  .topnav, .btn-delete, .modal-overlay,
  .carousel-btn, .carousel-footer { display: none !important; }

  body { background: #fff !important; }

  .carousel-viewport { overflow: visible !important; width: 100% !important; }
  .carousel-track {
    flex-direction: column !important;
    transform: none !important;
    gap: 0;
  }
  .carousel-slide { width: auto !important; min-width: 0 !important; display: block !important; }

  .report-card {
    width: 190mm;
    min-height: 277mm;
    box-shadow: none;
    border: 1px solid #ccc;
    break-after: page;
    border-radius: 4px;
    max-width: 100%;
  }
  .tech-bg { opacity: 0.02; }
}
