/* Shared tokens: the palette comes from the costumes — black cloth, gold braid, red sash. */
:root {
  --kain: #1e1a17;        /* black costume cloth */
  --kain-2: #2b2521;      /* raised surface */
  --kain-3: #3a322c;      /* borders on dark */
  --emas: #e2b13c;        /* gold braid */
  --emas-dim: #a8822a;
  --selendang: #c8402b;   /* red sash */
  --kapas: #f3ebdd;       /* text on dark */
  --kabus: #b9ae9c;       /* secondary text */
  --radius-s: 6px;
  --radius-m: 14px;
  --font-display: "Gloock", Georgia, "Times New Roman", serif;
  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--kain);
  color: var(--kapas);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.55;
}
img, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
[hidden] { display: none !important; }
a { color: var(--emas); }
button { font: inherit; color: inherit; }

:focus-visible { outline: 3px solid var(--emas); outline-offset: 3px; border-radius: 4px; }

/* Gold braid: the zig-zag trim sewn onto Kadazan and Bajau costumes. */
.braid {
  height: 12px;
  background:
    linear-gradient(135deg, transparent 33%, var(--emas) 33% 45%, transparent 45%) 0 0 / 12px 12px repeat-x,
    linear-gradient(45deg, transparent 33%, var(--emas) 33% 45%, transparent 45%) 0 0 / 12px 12px repeat-x;
  opacity: .9;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  min-height: 48px; padding: .75em 1.35em;
  border-radius: 999px; border: 1.5px solid transparent;
  font-weight: 650; font-size: 1rem; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .1s;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--emas); color: #231a06; }
.btn-primary:hover { background: #ecc25a; }
.btn-ghost { border-color: var(--kain-3); color: var(--kapas); background: transparent; }
.btn-ghost:hover { border-color: var(--emas-dim); }
.btn svg { width: 1.2em; height: 1.2em; flex: none; }

.icon-btn {
  width: 48px; height: 48px; border-radius: 50%;
  display: inline-grid; place-items: center;
  background: rgba(30, 26, 23, .72); border: 1px solid rgba(243, 235, 221, .18);
  color: var(--kapas); cursor: pointer;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn[aria-pressed="false"] .on, .icon-btn[aria-pressed="true"] .off { display: none; }

.lang-switch { display: inline-flex; border: 1px solid var(--kain-3); border-radius: 999px; padding: 3px; background: rgba(30,26,23,.6); }
.lang-switch button {
  border: 0; background: transparent; min-width: 44px; min-height: 36px; border-radius: 999px;
  font-weight: 600; font-size: .875rem; cursor: pointer; color: var(--kabus);
}
.lang-switch button[aria-pressed="true"] { background: var(--kapas); color: var(--kain); }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

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