/* seneng.lol's look, shared by every page: colors, type, buttons, the EN | ID switch, dialogs, toasts.
   Each app links it before its own style.css. Fonts: Fredoka for headings, Nunito for everything else.
   Sunny cream and plum in light mode, a warm night in dark mode, and "sticker" shapes: thick
   rounded outlines with a solid drop underneath. */
:root {
  --bg: #FFF6E5;
  --bg-2: #FFE8C2;
  --card: #FFFFFF;
  --ink: #2E1A47;
  --ink-soft: #6B5A80;
  --edge: #2E1A47;          /* sticker outlines */
  --drop: #2E1A47;          /* the solid shadow under stickers */
  --sun: #FFC233;
  --sun-deep: #F59E0B;
  --coral: #FF6B5B;
  --mint: #22C39A;
  --sky: #3FA9F5;
  --pink: #FF8EBF;
  --grape: #7B5CFF;
  --on-color: #2E1A47;      /* text on sun, mint, pink and sky */
  --ray: rgba(255, 194, 51, .16);
  --display: "Fredoka", "Baloo 2", "Trebuchet MS", system-ui, sans-serif;
  --body: "Nunito", "Segoe UI", system-ui, sans-serif;
  --r: 22px;
  --r-sm: 14px;
  --line: 2.5px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1B1230;
    --bg-2: #261A40;
    --card: #2B1F48;
    --ink: #FFF1DC;
    --ink-soft: #BDAED6;
    --edge: #0F0820;
    --drop: #0B0618;
    --ray: rgba(255, 194, 51, .07);
    color-scheme: dark;
  }
}

[hidden] { display: none !important; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.5;
}
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.1; margin: 0; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 2px; }
a:hover { color: var(--coral); }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: 8px; }
button { font: inherit; color: inherit; }
/* A first visit waits briefly for the visitor's country before showing words (seneng-lang.js). */
.seneng-detecting [data-t] { visibility: hidden; }

/* ---------- the brand: a smiling sun and the name ---------- */
.brand {
  display: inline-flex;
  align-items: center;
  font-family: var(--display);
  font-weight: 700;
  font-size: 26px;
  letter-spacing: -.01em;
  text-decoration: none;
  color: var(--ink);
}
.brand:hover { color: var(--ink); }
.brand span { color: var(--coral); }
.brand .sun { width: 34px; height: 34px; flex: none; margin-right: 8px; }
.brand:hover .sun { animation: spin 1.6s ease-in-out; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 18px;
  line-height: 1;
  padding: 13px 22px;
  border: var(--line) solid var(--edge);
  border-radius: 999px;
  background: var(--sun);
  color: var(--on-color);
  box-shadow: 0 4px 0 var(--drop);
  cursor: pointer;
  text-decoration: none;
  transition: transform .08s, box-shadow .08s;
}
.btn:hover { color: var(--on-color); transform: translateY(-1px); box-shadow: 0 5px 0 var(--drop); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--drop); }
.btn:disabled { opacity: .55; cursor: default; transform: none; }
.btn.coral { background: var(--coral); color: #fff; }
.btn.mint { background: var(--mint); }
.btn.plain { background: var(--card); color: var(--ink); }
.link-btn {
  background: none;
  border: 0;
  padding: 6px 4px;
  color: var(--ink-soft);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 2px;
  cursor: pointer;
}
.link-btn:hover { color: var(--coral); }

/* A round, outlined icon or account button in a header. */
.pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px;
  min-width: 38px;
  padding: 4px 14px;
  border: var(--line) solid var(--edge);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-weight: 800;
  font-size: 15px;
  box-shadow: 0 3px 0 var(--drop);
  cursor: pointer;
  max-width: 11em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pill-btn.icon { padding: 0; width: 38px; }
.pill-btn svg { width: 19px; height: 19px; flex: none; }
.pill-btn:hover { background: var(--bg-2); }
.pill-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--drop); }

/* ---------- EN | ID ---------- */
.langs {
  display: inline-flex;
  border: var(--line) solid var(--edge);
  border-radius: 999px;
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 3px 0 var(--drop);
  flex: none;
}
.langs button {
  border: 0;
  background: none;
  padding: 6px 11px;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: .04em;
  color: var(--ink-soft);
  cursor: pointer;
}
.langs button[aria-pressed="true"] { background: var(--sun); color: var(--on-color); }

/* ---------- dialogs ---------- */
dialog.sheet {
  width: min(420px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 26px 24px 22px;
  border: var(--line) solid var(--edge);
  border-radius: var(--r);
  background: var(--card);
  color: var(--ink);
  box-shadow: 0 6px 0 var(--drop);
}
dialog.sheet::backdrop { background: rgba(30, 14, 50, .55); backdrop-filter: blur(2px); }
dialog.sheet[open] { animation: pop .22s cubic-bezier(.3, 1.5, .6, 1); }
@keyframes pop { from { transform: scale(.9); opacity: 0; } }
dialog.sheet h2 { font-size: 28px; margin: 0 34px 6px 0; overflow-wrap: anywhere; }
.sheet-sub { margin: 0 0 14px; color: var(--ink-soft); }
.sheet-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 10px; margin-top: 18px; }
.sheet-close { position: absolute; top: 14px; right: 14px; margin: 0; }
.x-btn {
  width: 34px; height: 34px;
  border: var(--line) solid var(--edge);
  border-radius: 50%;
  background: var(--bg);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.x-btn:hover { background: var(--bg-2); }

/* ---------- forms ---------- */
.field label { display: block; font-weight: 800; margin-bottom: 6px; }
.field input, .input {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--bg);
  border: var(--line) solid var(--edge);
  border-radius: var(--r-sm);
  padding: 11px 14px;
}
.field input:focus, .input:focus { outline: none; border-color: var(--sky); box-shadow: 0 0 0 4px color-mix(in srgb, var(--sky) 30%, transparent); }
.field-hint { margin: 6px 0 0; font-size: 14px; color: var(--ink-soft); }
.field-hint.error { color: var(--coral); font-weight: 700; }

/* ---------- toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(22px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%);
  z-index: 50;
  width: max-content;
  max-width: calc(100vw - 32px);
  padding: 11px 18px;
  border: var(--line) solid var(--edge);
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 700;
  box-shadow: 0 4px 0 var(--drop);
  animation: rise .25s ease-out;
}
@keyframes rise { from { transform: translate(-50%, 12px); opacity: 0; } }

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