/*
 * Karya Search
 * A sibling of pes.the-karya.com: white and stone-grey grounds, near-black
 * ink, two-tone statements, square bordered panels, mono for small facts.
 * The panther (from aarya.the-karya.com) moves in ink at the top.
 */

:root {
  --bg: #ffffff;
  --stone: #f4f4f2;
  --ink: #121211;
  --body: #55544f;
  --dim: #8d8c86;
  --line: #e4e3df;
  --green: #1f7a3f;
  --red: #b3261e;
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --ease: cubic-bezier(0.25, 1, 0.5, 1);
  --gutter: 22px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
button, input, textarea { font: inherit; color: inherit; }
button { -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: 600px; margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: 0.01em; }
.dim { color: var(--dim); }

/* ---------- Nav ---------- */

.nav { position: relative; z-index: 3; background: var(--bg); border-bottom: 1px solid var(--line); }
.nav-row { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 19px; font-weight: 600; letter-spacing: -0.01em; text-decoration: none; }
.brand img { width: 38px; height: auto; }
.nav-btn { display: inline-flex; align-items: center; text-decoration: none; min-height: 38px; padding: 0 14px; background: var(--ink); color: #fff; border: 0; border-radius: 0; font-size: 14px; font-weight: 500; cursor: pointer; }

/* ---------- Type ---------- */

.statement {
  font-size: clamp(34px, 9.4vw, 52px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.statement span { display: inline; }
.statement-md { font-size: clamp(30px, 8vw, 42px); }
.statement-sm { font-size: clamp(24px, 6.2vw, 30px); letter-spacing: -0.025em; }
.lead { margin-top: 14px; font-size: 18px; color: var(--body); text-wrap: pretty; }
.kicker { font-size: 16px; color: var(--body); margin-bottom: 14px; }
.label { display: block; font-size: 15px; font-weight: 500; }
.opt { font-weight: 400; color: var(--dim); }
.note { color: var(--dim); }
.error { font-size: 15px; color: var(--red); }
.confirm { font-size: 16px; color: var(--green); }
.textlink { font-size: 16px; font-weight: 500; text-underline-offset: 4px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px; padding: 0 20px;
  border: 1px solid var(--ink); border-radius: 0;
  font-size: 18px; font-weight: 500; text-decoration: none; text-align: center;
  cursor: pointer; user-select: none;
  transition: background-color 120ms var(--ease), color 120ms var(--ease), transform 120ms var(--ease);
}
.btn:active { transform: scale(0.985); }
.btn-solid { background: var(--ink); color: #fff; }
.btn-solid:hover { background: #2a2a28; }
.btn-line { background: #fff; color: var(--ink); border-color: #cfcec9; }
.btn-line:hover { border-color: var(--ink); }
.btn[disabled] { opacity: 0.35; cursor: not-allowed; transform: none; }
.btn-block { width: 100%; }

/* ---------- Panels (the PES card) ---------- */

.panel { background: #fff; border: 1px solid var(--line); }
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 18px; border-bottom: 1px solid var(--line);
  font-size: 16px; color: var(--body);
}
.panel-head .mono { color: var(--dim); }
.panel-foot { border-top: 1px solid var(--line); }
.panel-note { padding: 14px 18px; font-size: 15px; color: var(--body); }

/* ---------- Hero: the black panther, moving, on white ---------- */

.hero { position: relative; overflow: hidden; background: #fff; color: var(--ink); padding-bottom: 44px; }
.panther {
  position: relative; height: 170px; overflow: hidden; pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
}
.panther video {
  position: absolute; right: -16%; top: -10%; width: 116%; height: 150%;
  object-fit: cover; object-position: 60% 40%;
  filter: grayscale(1) contrast(1.45) brightness(1.1);
  mix-blend-mode: multiply;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
}
.hero .wrap { position: relative; }
.hero .statement { margin-top: -16px; }

/* ---------- 1. Moments ---------- */

.test { margin-top: 26px; }
.moment {
  padding: 22px 18px 26px;
  min-height: 150px;
  font-size: clamp(22px, 6vw, 26px);
  font-weight: 500;
  line-height: 1.28;
  letter-spacing: -0.015em;
  text-wrap: pretty;
}
.moment.out { animation: out 140ms var(--ease) forwards; }
.moment.in { animation: in 240ms var(--ease) both; }
@keyframes out { to { opacity: 0; transform: translateY(-6px); } }
@keyframes in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.answers { display: grid; grid-template-columns: 1fr 1.25fr; }
.answers .btn { border: 0; min-height: 60px; }
.answers .btn-line { border-right: 1px solid var(--line); }
.answers .btn-line:hover { background: var(--stone); }
.skip {
  display: block; margin: 16px auto 0; padding: 8px;
  background: none; border: 0; font-size: 15px; color: var(--dim);
  text-decoration: underline; text-underline-offset: 4px; cursor: pointer;
}
.step { padding-bottom: 56px; }
.step:focus { outline: none; }

/* ---------- Reveal ---------- */

.scan { position: fixed; inset: 0; z-index: 40; background: #fff; }
.field { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.scan-eye {
  position: absolute; top: 2%; right: 0; left: auto;
  width: min(120vw, 680px); max-width: none;
  filter: grayscale(1) contrast(1.1);
  mix-blend-mode: multiply; pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 60%, transparent 100%);
  animation: fade 900ms var(--ease) both;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.scan-text { position: absolute; left: 50%; bottom: 12%; transform: translateX(-50%); padding: 6px 12px; background: #fff; color: var(--body); font-size: 15px; white-space: nowrap; }

/* ---------- 2. Result ---------- */

#step-result .statement, #step-done .statement { padding-top: 34px; }
.signup { margin-top: 26px; display: grid; gap: 8px; }
.signup .label { margin-top: 8px; }
.signup .btn { margin-top: 12px; }
input, textarea {
  width: 100%; min-height: 56px; padding: 12px 16px;
  background: #fff; border: 1px solid #cfcec9; border-radius: 0;
  font-size: 18px; appearance: none; -webkit-appearance: none;
  transition: border-color 120ms var(--ease);
}
textarea { resize: vertical; min-height: 96px; line-height: 1.45; }
input::placeholder, textarea::placeholder { color: var(--dim); }
input:focus, textarea:focus { outline: none; border-color: var(--ink); }
input[aria-invalid="true"] { border-color: var(--red); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.finds-panel { margin-top: 36px; }
.finds li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; padding: 18px; border-bottom: 1px solid var(--line); }
.finds li:last-child { border-bottom: 0; }
.tick { width: 18px; height: 18px; margin-top: 4px; color: var(--green); }
.find-moment { font-size: 15px; color: var(--dim); line-height: 1.4; }
.find-what { margin-top: 6px; font-size: 18px; font-weight: 500; line-height: 1.35; }
.trail { margin-top: 8px; color: var(--body); }

.share-box { margin-top: 30px; padding: 20px 18px; background: var(--stone); display: grid; gap: 14px; }
.share-q { font-size: 20px; font-weight: 500; letter-spacing: -0.01em; }

/* ---------- 3. Done ---------- */

.share-hero { margin-top: 24px; display: grid; gap: 12px; }
.share-preview { width: 64%; max-width: 270px; margin: 0 auto 6px; border: 1px solid var(--line); }
.extra { margin-top: 30px; padding-top: 22px; border-top: 1px solid var(--line); display: grid; gap: 12px; }
.chips { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.chip {
  min-height: 52px; padding: 0 14px;
  background: #fff; border: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); border-radius: 0;
  font-size: 16px; text-align: left; cursor: pointer;
  transition: background-color 120ms var(--ease), color 120ms var(--ease);
}
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; }

.booking { display: grid; gap: 12px; }
.days { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 2px; }
.days::-webkit-scrollbar { display: none; }
.day { flex: 0 0 auto; display: grid; gap: 2px; min-width: 64px; padding: 8px 10px; background: #fff; border: 1px solid #cfcec9; border-radius: 0; text-align: center; cursor: pointer; }
.day-w { font-family: var(--mono); font-size: 12px; color: var(--dim); }
.day-d { font-size: 22px; font-weight: 500; font-variant-numeric: tabular-nums; }
.day[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.day[aria-selected="true"] .day-w { color: rgb(255 255 255 / 0.7); }
.slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.slot { min-height: 50px; background: #fff; border: 1px solid #cfcec9; border-radius: 0; font-family: var(--mono); font-size: 15px; cursor: pointer; }
.slot[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.slots-msg { grid-column: 1 / -1; font-size: 15px; color: var(--dim); padding: 8px 0; }
.next { margin-top: 36px; }

/* ---------- Why relevance ---------- */

.band { padding: 56px 0; background: var(--stone); }
.band-white { background: #fff; border-top: 1px solid var(--line); }
.stack { margin-top: 26px; display: grid; gap: 10px; font-size: clamp(22px, 6vw, 28px); font-weight: 500; line-height: 1.22; letter-spacing: -0.02em; }
.versus { margin-top: 36px; background: #fff; border: 1px solid var(--line); }
.versus-q { padding: 16px 18px; border-bottom: 1px solid var(--line); font-size: 18px; font-weight: 500; }
.versus-cols { display: grid; grid-template-columns: 1fr 1fr; }
.vs { padding: 18px; display: grid; align-content: start; gap: 12px; }
.vs ul { display: grid; gap: 12px; }
.vs li { font-size: 16px; line-height: 1.3; }
.vs li .mono { display: block; margin-top: 2px; font-size: 12px; }
.vs-label { color: var(--dim); }
.vs-search li { color: var(--dim); }
.vs-foot { margin-top: 6px; font-size: 14px; }
.vs-search .vs-foot { color: var(--dim); }
.vs-karya { background: var(--ink); color: #fff; }
.vs-karya .vs-label, .vs-karya li .mono { color: rgb(255 255 255 / 0.6); }
.vs-karya li { opacity: 0; transform: translateY(6px); transition: opacity 400ms var(--ease), transform 400ms var(--ease); }
.versus.in .vs-karya li { opacity: 1; transform: none; }
.versus.in .vs-karya li:nth-child(2) { transition-delay: 250ms; }
.versus.in .vs-karya li:nth-child(3) { transition-delay: 500ms; }

/* ---------- Footer ---------- */

.foot { padding: 48px 0 56px; border-top: 1px solid var(--line); }
.foot .wrap { display: grid; gap: 18px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot-links a { font-size: 16px; color: var(--body); text-underline-offset: 4px; }

/* ---------- Share sheet ---------- */

.sheet { position: fixed; inset: 0; z-index: 45; background: rgb(18 18 17 / 0.35); display: flex; align-items: flex-end; justify-content: center; }
.sheet-inner { width: 100%; max-width: 600px; background: #fff; padding: 22px var(--gutter) calc(22px + env(safe-area-inset-bottom)); display: grid; gap: 10px; }

@media (min-width: 720px) {
  .panther { height: 240px; }
  .panther video { right: -2%; width: 78%; }
  .hero .statement { margin-top: -36px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .panther video { display: none; }
}



/* ---------- Night: black statement band with the eye, faint ---------- */

.night { position: relative; overflow: hidden; background: #000; color: #fff; padding: 72px 0 80px; }
.night .dim { color: #7d7c77; }
.night-eye { position: absolute; right: -12%; top: 26%; width: 96%; max-width: 620px; opacity: 0.09; pointer-events: none; }
.night .wrap { position: relative; }
.night-line { margin-top: 120px; font-size: clamp(22px, 6vw, 28px); letter-spacing: -0.015em; }
.night-words { margin-top: 22px; display: grid; gap: 8px; font-size: clamp(24px, 6.6vw, 30px); letter-spacing: -0.02em; color: #d9d8d3; }
.stack-lg { margin-top: 0; font-size: clamp(24px, 6.6vw, 32px); }
.ask-line { margin-top: 26px; }

