/* Harrif landing pages. Palette: CLAUDE.md 9.2. */
:root {
  --nile: #0E5E6F;
  --nile-deep: #0A3F4B;
  --sand: #F3E3C3;
  --papyrus: #FFF8EC;
  --brick: #B5532E;
  --gold: #D9A441;
  --ink: #1B1B1B;
  --success: #3E8E5A;

  --bg: var(--papyrus);
  --card: #FFFDF8;
  --text: var(--ink);
  --muted: #5f5a50;
  --accent: var(--nile);
  --line: rgba(14, 94, 111, 0.16);
  --pattern: rgba(181, 83, 46, 0.07);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: var(--nile-deep);
    --card: #0d4a58;
    --text: var(--sand);
    --muted: #cbbd9f;
    --accent: var(--gold);
    --line: rgba(243, 227, 195, 0.18);
    --pattern: rgba(217, 164, 65, 0.08);
  }
}

* { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; }

body {
  font-family: 'Cairo', system-ui, sans-serif;
  color: var(--text);
  background-color: var(--bg);
  /* an eight-point star lattice, kept quiet */
  background-image:
    radial-gradient(circle at 50% 0%, rgba(217, 164, 65, 0.18), transparent 55%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='56' viewBox='0 0 56 56'%3E%3Cg fill='none' stroke='%23B5532E' stroke-opacity='0.09' stroke-width='1'%3E%3Cpath d='M28 6l6 16 16 6-16 6-6 16-6-16-16-6 16-6z'/%3E%3Crect x='18' y='18' width='20' height='20' transform='rotate(45 28 28)'/%3E%3C/g%3E%3C/svg%3E");
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px calc(24px + env(safe-area-inset-bottom));
  -webkit-font-smoothing: antialiased;
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 28px 22px 22px;
  text-align: center;
  box-shadow: 0 18px 50px -24px rgba(10, 63, 75, 0.45);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 6px;
  background: linear-gradient(90deg, var(--brick), var(--gold), var(--nile));
}

.brand { margin-bottom: 14px; }
.logo {
  font-family: 'Lalezar', 'Cairo', sans-serif;
  font-size: 44px;
  line-height: 1;
  color: var(--accent);
  letter-spacing: 0;
}

.badge {
  display: inline-block;
  font-weight: 700;
  font-size: 14px;
  padding: 4px 14px;
  border-radius: 999px;
  background: var(--sand);
  color: var(--brick);
  margin-bottom: 10px;
}
@media (prefers-color-scheme: dark) { .badge { background: rgba(243, 227, 195, 0.12); color: var(--gold); } }

h1 {
  font-family: 'Lalezar', 'Cairo', sans-serif;
  font-weight: 400;
  font-size: 30px;
  line-height: 1.35;
  margin: 4px 0 6px;
}

.sub { margin: 0 0 20px; color: var(--muted); font-size: 16px; line-height: 1.7; }

.code {
  all: unset;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  margin: 0 auto 18px;
  padding: 12px 18px 10px;
  border: 2px dashed var(--gold);
  border-radius: 18px;
  min-width: 220px;
  transition: border-color 0.2s, background 0.2s;
}
.code:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.code.ok { border-color: var(--success); background: rgba(62, 142, 90, 0.08); }
.code-label { font-size: 12px; color: var(--muted); }
.code-value {
  font-family: 'Lalezar', 'Cairo', monospace;
  font-size: 36px;
  letter-spacing: 6px;
  direction: ltr;
  color: var(--text);
}
.code-hint { font-size: 12px; color: var(--muted); }
.code.ok .code-hint { color: var(--success); font-weight: 700; }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  border-radius: 16px;
  font-weight: 700;
  font-size: 17px;
  text-decoration: none;
  transition: transform 0.08s ease, filter 0.2s;
}
.btn:active { transform: scale(0.98); }
.btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.primary {
  background: var(--nile);
  color: var(--papyrus);
  font-family: 'Lalezar', 'Cairo', sans-serif;
  font-weight: 400;
  font-size: 22px;
  box-shadow: 0 8px 0 -2px var(--nile-deep);
  margin-bottom: 14px;
}
@media (prefers-color-scheme: dark) { .primary { background: var(--gold); color: var(--nile-deep); box-shadow: 0 8px 0 -2px #a87b2c; } }

.stores { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.store {
  border: 1.5px solid var(--line);
  color: var(--text);
  font-size: 15px;
  direction: ltr;
  min-height: 48px;
}
.store svg { width: 18px; height: 18px; fill: currentColor; }
.store.dim { opacity: 0.55; }

.note { margin: 16px 4px 0; font-size: 13px; color: var(--muted); line-height: 1.7; }

.missing .code, .missing .primary { display: none; }

.home .tagline { font-size: 18px; margin: 6px 0 22px; color: var(--muted); }
.home .modes { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 8px; text-align: right; }
.home .modes li { background: rgba(243, 227, 195, 0.45); border-radius: 14px; padding: 10px 14px; line-height: 1.6; }
@media (prefers-color-scheme: dark) { .home .modes li { background: rgba(243, 227, 195, 0.08); } }
.home .modes b { font-family: 'Lalezar', 'Cairo', sans-serif; font-weight: 400; color: var(--brick); font-size: 18px; }
@media (prefers-color-scheme: dark) { .home .modes b { color: var(--gold); } }

@media (max-width: 360px) {
  h1 { font-size: 26px; }
  .code-value { font-size: 30px; letter-spacing: 4px; }
  .stores { grid-template-columns: 1fr; }
}
