/* =====================================================================
   KENYA — gaya papan savana
   Merah Maasai + garis tribal hitam, angka diukir pada papan kayu,
   tabel riwayat bergaris tebal, jadwal berupa pita horizontal.
   Mobile-first; sudut tajam (0px).
   ===================================================================== */

.ke-page {
  --color-primary: #b91c1c;
  --color-accent: #1c1917;
  --color-bg: #faf6ef;
  --ke-wood: #3f2a1d;
  --ke-wood-dark: #2a1b12;
  --ke-line: #1c1917;
  --ke-muted: #6b5c4d;

  background: var(--color-bg);
  color: var(--color-accent);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin: -1.5rem -12px 0;
  padding-bottom: 48px;
}

.ke-container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px;
}

.ke-breadcrumb {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 16px 0;
  font-size: 12px;
  color: var(--ke-muted);
}

.ke-breadcrumb a { color: var(--color-primary); }
.ke-breadcrumb span { margin: 0 8px; }
.ke-breadcrumb strong { color: var(--color-accent); font-weight: 600; }

/* ---------------------------------------------------------------
   HERO — blok merah Maasai berbingkai garis tribal
   --------------------------------------------------------------- */
.ke-hero {
  position: relative;
  background: var(--color-primary);
  color: #fff;
  padding: 44px 16px 52px;
  margin-top: 14px;
  border-top: 10px solid var(--ke-line);
  border-bottom: 10px solid var(--ke-line);
  overflow: hidden;
}

/* Garis tribal vertikal pada kedua tepi hero */
.ke-hero::before,
.ke-hero::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 14px;
  background-image: repeating-linear-gradient(
    180deg,
    var(--ke-line) 0 14px,
    transparent 14px 28px
  );
}

.ke-hero::before { left: 0; }
.ke-hero::after { right: 0; }

/* Pattern perisai Maasai */
.ke-hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.06;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='90' height='90' viewBox='0 0 90 90'%3E%3Cg fill='none' stroke='%23000' stroke-width='3'%3E%3Cpath d='M45 8c14 8 22 18 22 32S56 72 45 82C34 72 23 54 23 40S31 16 45 8z'/%3E%3Cpath d='M45 8v74M23 40h44'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 90px 90px;
}

.ke-hero-inner {
  position: relative;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 14px;
  text-align: center;
}

.ke-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
}

.ke-kicker-mark {
  width: 26px;
  height: 3px;
  background: var(--ke-line);
}

.ke-h1 {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: clamp(26px, 6.4vw, 46px);
  line-height: 1.06;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  margin: 0 0 10px;
  text-shadow: 3px 3px 0 rgba(28, 25, 23, 0.55);
}

.ke-hero-date {
  margin: 0 0 26px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
}

/* ---------------------------------------------------------------
   PAPAN KAYU — angka hasil diukir
   --------------------------------------------------------------- */
.ke-board {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
  background: linear-gradient(180deg, var(--ke-wood) 0%, var(--ke-wood-dark) 100%);
  border: 5px solid var(--ke-line);
  box-shadow: 0 14px 0 rgba(28, 25, 23, 0.35);
  padding: 22px 18px;
}

/* Tekstur serat kayu horizontal */
.ke-board::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.4;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.05) 0 2px,
    transparent 2px 7px
  );
}

.ke-board-peg {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #d6c3a5;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.35);
}

.ke-board-peg-left { left: 10px; }
.ke-board-peg-right { right: 10px; }

.ke-board-face {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 14px;
}

.ke-digit {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: clamp(44px, 13vw, 86px);
  line-height: 1;
  color: #f8f4ec;
  /* Efek ukiran: bayangan gelap ke bawah + sorot tipis ke atas */
  text-shadow:
    0 2px 0 rgba(0, 0, 0, 0.55),
    0 -1px 0 rgba(255, 255, 255, 0.16);
  opacity: 0;
  transform: translateY(14px);
  animation: ke-carve 0.5s ease forwards;
}

.ke-digit-empty {
  color: #8b7663;
  text-shadow: none;
}

@keyframes ke-carve {
  to { opacity: 1; transform: translateY(0); }
}

.ke-hero-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 22px;
  margin: 22px 0 0;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.92);
}

.ke-hero-meta b {
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 10.5px;
  margin-right: 5px;
  color: rgba(255, 255, 255, 0.7);
}

/* ---------------------------------------------------------------
   SECTION UMUM
   --------------------------------------------------------------- */
.ke-desc {
  margin: 26px 0 0;
  font-size: 14px;
  color: var(--ke-muted);
}

.ke-section {
  margin-top: 42px;
}

.ke-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.ke-h2 {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: clamp(18px, 4.2vw, 24px);
  text-transform: uppercase;
  letter-spacing: 0.01em;
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 5px solid var(--ke-line);
  color: var(--color-accent);
}

.ke-section-head .ke-h2 {
  margin-bottom: 0;
  border-bottom: 0;
  padding-bottom: 0;
}

/* Filter */
.ke-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ke-filter select {
  height: 40px;
  padding: 0 12px;
  border: 3px solid var(--ke-line);
  border-radius: 0;
  background: #fff;
  color: var(--color-accent);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
}

.ke-filter select:focus {
  outline: 3px solid var(--color-primary);
  outline-offset: 1px;
}

.ke-btn {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 18px;
  border: 3px solid var(--ke-line);
  background: var(--color-primary);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}

.ke-btn:hover {
  background: #991b1b;
  color: #fff;
  transform: translateY(-2px);
}

.ke-btn-ghost {
  background: transparent;
  color: var(--color-accent);
}

.ke-btn-ghost:hover {
  background: var(--ke-line);
  color: #fff;
}

/* ---------------------------------------------------------------
   TABEL RIWAYAT — garis tebal hitam, header merah
   --------------------------------------------------------------- */
.ke-table-wrap {
  overflow-x: auto;
  border: 4px solid var(--ke-line);
  background: #fff;
}

.ke-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.ke-table thead th {
  background: var(--color-primary);
  color: #fff;
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: left;
  padding: 13px 14px;
  border-bottom: 4px solid var(--ke-line);
  white-space: nowrap;
}

.ke-table tbody td {
  padding: 13px 14px;
  border-bottom: 2px solid var(--ke-line);
  vertical-align: middle;
}

.ke-table tbody tr:last-child td {
  border-bottom: 0;
}

.ke-table tbody tr:nth-child(even) {
  background: #f4ece0;
}

.ke-result {
  display: inline-block;
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: 17px;
  letter-spacing: 0.18em;
  color: var(--color-primary);
}

.ke-muted { color: var(--ke-muted); font-size: 12.5px; }
.ke-nowrap { white-space: nowrap; }

/* Empty state */
.ke-empty {
  border: 4px dashed var(--ke-line);
  background: #fff;
  padding: 40px 20px;
  text-align: center;
}

.ke-empty-mark {
  display: inline-block;
  width: 46px;
  height: 56px;
  background: var(--color-primary);
  clip-path: polygon(50% 0, 100% 26%, 100% 74%, 50% 100%, 0 74%, 0 26%);
  margin-bottom: 14px;
}

.ke-empty h3 {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: 17px;
  text-transform: uppercase;
  margin: 0 0 6px;
}

.ke-empty p {
  margin: 0;
  font-size: 13.5px;
  color: var(--ke-muted);
}

/* Pagination bawaan aplikasi disesuaikan ke gaya Kenya */
.ke-pagination {
  margin-top: 14px;
  font-size: 13px;
  color: var(--ke-muted);
}

.ke-pagination .page-link {
  border-radius: 0;
  border: 2px solid var(--ke-line);
  color: var(--color-accent);
  font-weight: 700;
}

.ke-pagination .page-item.active .page-link {
  background: var(--color-primary);
  border-color: var(--ke-line);
  color: #fff;
}

.ke-pagination .page-item.disabled .page-link {
  border-color: #c9bdaf;
  color: #b3a89c;
}

/* ---------------------------------------------------------------
   JADWAL — tiga banner pita horizontal
   --------------------------------------------------------------- */
.ke-ribbons {
  display: grid;
  gap: 14px;
}

.ke-ribbon {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 18px;
  background: var(--ke-line);
  color: #fff;
  padding: 16px 22px 16px 26px;
  /* Ujung kanan pita bertakik */
  clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 50%, calc(100% - 22px) 100%, 0 100%);
}

.ke-ribbon::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8px;
  background: var(--color-primary);
}

.ke-ribbon-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  flex: 0 0 130px;
}

.ke-ribbon-value {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-size: 19px;
  letter-spacing: 0.02em;
}

.ke-ribbon-note {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-left: auto;
  padding-right: 18px;
}

.ke-note {
  margin: 18px 0 0;
  font-size: 13px;
  color: var(--ke-muted);
}

.ke-note a {
  color: var(--color-primary);
  font-weight: 600;
}

/* ---------------------------------------------------------------
   RESPONSIF
   --------------------------------------------------------------- */
@media (max-width: 767.98px) {
  .ke-hide-md { display: none; }
}

@media (max-width: 575.98px) {
  .ke-hide-sm { display: none; }

  .ke-hero {
    padding: 30px 10px 36px;
    border-width: 6px;
  }

  .ke-hero::before,
  .ke-hero::after { width: 8px; }

  .ke-board {
    padding: 16px 12px;
    border-width: 4px;
    box-shadow: 0 9px 0 rgba(28, 25, 23, 0.35);
  }

  .ke-board-face { gap: 4px 8px; }
  .ke-board-peg { display: none; }

  .ke-section { margin-top: 30px; }

  .ke-ribbon {
    padding: 13px 18px 13px 20px;
    clip-path: none;
  }

  .ke-ribbon-label { flex: 1 0 100%; }
  .ke-ribbon-note { margin-left: 0; padding-right: 0; flex: 1 0 100%; }
}

@media (min-width: 768px) {
  .ke-page { margin-left: -24px; margin-right: -24px; }
}

@media (prefers-reduced-motion: reduce) {
  .ke-digit {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
