/* ============================================================
   Hue. — marketing site
   Shared styles. Editorial register, breath-paced.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght,SOFT@9..144,300..900,30..100&family=JetBrains+Mono:wght@400;500&family=Inter:wght@400;500;600&display=swap');

:root {
  --paper:        #f8f4ec;
  --paper-deep:   #f1ebde;
  --ink:          #1c1a17;
  --ink-soft:     #4a463f;
  --ink-faint:    #98928a;
  --rule:         #1c1a17;
  --rule-faint:   rgba(28, 26, 23, 0.12);
  --terracotta:   #b3532a;
  --olive:        #6f6e3d;
  --teal-deep:    #2a5d6e;

  --hue-purple-a:  #c084fc; --hue-purple-b:  #a855f7;
  --hue-blue-a:    #3b82f6; --hue-blue-b:    #2563eb;
  --hue-green-a:   #4ade80; --hue-green-b:   #22c55e;
  --hue-jasmine-a: #fde047; --hue-jasmine-b: #facc15;
  --hue-red-a:     #f87171; --hue-red-b:     #ef4444;
  --hue-orange-a:  #fb923c; --hue-orange-b:  #f97316;
  --hue-white-a:   #f3f4f6; --hue-white-b:   #d1d5db;
  --hue-black-a:   #334155; --hue-black-b:   #0f172a;
  --hue-teal-a:    #2dd4bf; --hue-teal-b:    #14b8a6;
  --hue-pink-a:    #f9a8d4; --hue-pink-b:    #f472b6;
  --hue-brown-a:   #a16207; --hue-brown-b:   #78350f;
  --hue-gray-a:    #9ca3af; --hue-gray-b:    #6b7280;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body:    'Inter', -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, monospace;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Subtle paper grain */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 25% 30%, rgba(28,26,23,0.014) 1px, transparent 1.5px),
    radial-gradient(circle at 75% 70%, rgba(28,26,23,0.014) 1px, transparent 1.5px);
  background-size: 7px 7px, 11px 11px;
  z-index: 1;
  opacity: 0.7;
}

main, header, footer { position: relative; z-index: 2; }

a { color: inherit; text-decoration: none; }

/* ===== nav ===== */
.nav {
  display: flex; justify-content: space-between; align-items: center;
  padding: 28px 56px;
  border-bottom: 1px solid var(--rule);
  position: sticky; top: 0; background: var(--paper);
  z-index: 100;
}
.nav .wm {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 28px;
  letter-spacing: -0.02em;
  font-variation-settings: "SOFT" 80;
}
.nav .wm em { color: var(--terracotta); font-style: italic; font-weight: 900; }
.nav ul {
  display: flex; gap: 36px;
  list-style: none; margin: 0; padding: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.nav ul a { color: var(--ink-soft); padding-bottom: 4px; transition: color 200ms ease; }
.nav ul a:hover { color: var(--ink); }
.nav ul a.on { color: var(--ink); border-bottom: 1px solid var(--terracotta); }

/* ===== layout ===== */
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 56px; }
.wrap-narrow { max-width: 760px; margin: 0 auto; padding: 0 56px; }

/* ===== type ===== */
h1.display {
  font-family: var(--font-display);
  font-weight: 300;
  font-variation-settings: "opsz" 144, "SOFT" 50;
  font-size: clamp(56px, 8vw, 128px);
  line-height: 0.96;
  letter-spacing: -0.035em;
  margin: 0;
  text-wrap: balance;
}
h1.display em {
  font-style: italic;
  color: var(--terracotta);
  font-weight: 400;
}
h2.display {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin: 0 0 32px;
  text-wrap: balance;
  font-variation-settings: "opsz" 96;
}
h2.display em { font-style: italic; color: var(--terracotta); }
h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 28px;
  letter-spacing: -0.015em;
  line-height: 1.18;
  margin: 0 0 16px;
  text-wrap: balance;
}
.lede {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.45;
  letter-spacing: -0.01em;
  text-wrap: pretty;
  font-variation-settings: "opsz" 36;
  color: var(--ink);
}
p { margin: 0 0 18px; text-wrap: pretty; }
.body-prose p { font-size: 18px; line-height: 1.7; max-width: 64ch; }
.body-prose p strong { color: var(--ink); font-weight: 600; }
.stamp {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--terracotta);
}
.stamp.olive { color: var(--olive); }
.stamp.faint { color: var(--ink-faint); }

/* ===== buttons ===== */
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 16px 22px;
  background: var(--ink); color: var(--paper);
  border-radius: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 1px solid var(--ink);
  transition: transform 240ms ease;
}
.btn:hover { transform: translateY(-1px); }
.btn .glyph {
  display: grid; place-items: center;
  width: 24px; height: 24px;
}
.btn .glyph svg { width: 100%; height: 100%; color: var(--paper); }
.btn .stack { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.05; gap: 2px; }
.btn .stack .small { font-size: 9px; opacity: 0.7; }
.btn.outline {
  background: transparent; color: var(--ink);
}
.btn.outline .glyph svg { color: var(--ink); }
.btn:hover { background: var(--terracotta); border-color: var(--terracotta); color: var(--paper); }
.btn:hover .glyph svg { color: var(--paper); }
.btn.outline:hover { background: var(--terracotta); border-color: var(--terracotta); color: var(--paper); }

/* ===== footer ===== */
footer {
  border-top: 1px solid var(--rule);
  padding: 60px 56px 40px;
  margin-top: 120px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  line-height: 1.85;
}
footer h4 {
  color: var(--terracotta);
  margin: 0 0 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
}
footer .col-brand {
  font-family: var(--font-display);
  font-size: 14px;
  text-transform: none;
  letter-spacing: -0.01em;
  color: var(--ink-soft);
  line-height: 1.55;
  max-width: 32ch;
}
footer .col-brand .wm {
  font-size: 28px; font-weight: 900;
  color: var(--ink);
  letter-spacing: -0.02em;
  display: block; margin-bottom: 12px;
}
footer .col-brand .wm em { color: var(--terracotta); font-style: italic; }
footer ul { list-style: none; margin: 0; padding: 0; }
footer ul a:hover { color: var(--ink); }

/* ===== generic spread ===== */
section.spread {
  padding: 100px 0;
  border-bottom: 1px solid var(--rule-faint);
}
section.spread:last-of-type { border-bottom: 0; }

/* ===== hue gradient util ===== */
.hue-purple { background: linear-gradient(135deg, var(--hue-purple-a), var(--hue-purple-b)); }
.hue-blue   { background: linear-gradient(135deg, var(--hue-blue-a),   var(--hue-blue-b)); }
.hue-green  { background: linear-gradient(135deg, var(--hue-green-a),  var(--hue-green-b)); }
.hue-jasmine{ background: linear-gradient(135deg, var(--hue-jasmine-a),var(--hue-jasmine-b)); }
.hue-red    { background: linear-gradient(135deg, var(--hue-red-a),    var(--hue-red-b)); }
.hue-orange { background: linear-gradient(135deg, var(--hue-orange-a), var(--hue-orange-b)); }
.hue-white  { background: linear-gradient(135deg, var(--hue-white-a),  var(--hue-white-b)); }
.hue-black  { background: linear-gradient(135deg, var(--hue-black-a),  var(--hue-black-b)); }
.hue-teal   { background: linear-gradient(135deg, var(--hue-teal-a),   var(--hue-teal-b)); }
.hue-pink   { background: linear-gradient(135deg, var(--hue-pink-a),   var(--hue-pink-b)); }
.hue-brown  { background: linear-gradient(135deg, var(--hue-brown-a),  var(--hue-brown-b)); }
.hue-gray   { background: linear-gradient(135deg, var(--hue-gray-a),   var(--hue-gray-b)); }

/* ===== phone mockup ===== */
.phone {
  width: 360px;
  aspect-ratio: 0.487;
  background: #0a0a0a;
  border-radius: 56px;
  padding: 14px;
  box-shadow:
    0 60px 120px -40px rgba(28,26,23,0.35),
    0 24px 48px -24px rgba(28,26,23,0.25),
    inset 0 0 0 2px #1a1a1a;
  position: relative;
  margin: 0 auto;
}
.phone .screen {
  width: 100%; height: 100%;
  background: var(--paper);
  border-radius: 44px;
  overflow: hidden;
  position: relative;
  display: flex; flex-direction: column;
}
.phone .island {
  position: absolute; top: 14px; left: 50%;
  transform: translateX(-50%);
  width: 96px; height: 28px;
  background: #0a0a0a;
  border-radius: 16px;
  z-index: 5;
}
.phone .status {
  display: flex; justify-content: space-between;
  padding: 14px 28px 0;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0;
  z-index: 4;
}

/* phone screen — home */
.app-home {
  flex: 1;
  display: flex; flex-direction: column;
  align-items: center;
  padding: 56px 24px 28px;
  position: relative;
  background: linear-gradient(180deg, #faf6ec 0%, #f4ecd8 100%);
}
.app-home .greet {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: 20px;
  font-variation-settings: "opsz" 24;
  text-align: center;
  margin-bottom: 6px;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.app-home .greet em { font-style: italic; color: var(--terracotta); font-weight: 400; }
.app-home .when {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-faint);
  margin-bottom: 36px;
}
.app-home .ring-wrap {
  position: relative;
  width: 220px; height: 220px;
  display: grid; place-items: center;
  margin-bottom: 28px;
}
.app-home .halo {
  position: absolute;
  width: 100%; height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(168,85,247,0.32), transparent 65%);
  filter: blur(18px);
  animation: breathe 8s var(--ease, cubic-bezier(0.4,0,0.2,1)) infinite;
}
.app-home .core {
  width: 168px; height: 168px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--hue-purple-a), var(--hue-purple-b));
  box-shadow:
    0 24px 56px -16px rgba(168,85,247,0.55),
    inset 0 2px 0 rgba(255,255,255,0.35);
  display: grid; place-items: center;
  animation: breathe 8s ease-in-out infinite;
  position: relative;
}
.app-home .core .icon-wrap { width: 64px; height: 64px; color: white; opacity: 0.9; }
.app-home .core .icon-wrap svg { width: 100%; height: 100%; }
.app-home .label {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 28px;
  letter-spacing: -0.015em;
  margin-bottom: 4px;
}
.app-home .sub {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-soft);
  margin-bottom: auto;
}
.app-home .nav-bar {
  display: flex; justify-content: space-around;
  width: 100%;
  padding: 14px 0 8px;
  border-top: 1px solid rgba(28,26,23,0.08);
  margin-top: 16px;
}
.app-home .nav-bar .item {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  color: var(--ink-faint);
}
.app-home .nav-bar .item.on { color: var(--terracotta); }
.app-home .nav-bar svg { width: 22px; height: 22px; }

@keyframes breathe {
  0%, 100% { transform: scale(0.96); opacity: 0.9; }
  50%      { transform: scale(1.03); opacity: 1; }
}

/* phone screen variants used in showcase */
.app-checkin {
  flex: 1;
  background: linear-gradient(180deg, var(--hue-blue-a) 0%, var(--hue-blue-b) 100%);
  display: flex; flex-direction: column;
  padding: 56px 24px 24px;
  color: white;
}
.app-checkin .top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 28px; }
.app-checkin .arrow { width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,0.18); display:grid; place-items:center; font-size:14px; }
.app-checkin .pill { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 24px; background: rgba(0,0,0,0.18); font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; }
.app-checkin .pill svg { width: 18px; height: 18px; }
.app-checkin h4 {
  font-family: var(--font-display); font-weight: 400;
  font-size: 32px; line-height: 1.1; letter-spacing: -0.02em;
  margin: 12px 0 14px;
  font-variation-settings: "opsz" 48;
}
.app-checkin h4 em { font-style: italic; }
.app-checkin .desc { font-size: 13px; line-height: 1.55; opacity: 0.9; margin-bottom: auto; }
.app-checkin .vivid-row {
  display: grid; grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 22px;
}
.app-checkin .vivid-row .step {
  aspect-ratio: 1; border-radius: 50%;
  background: rgba(255,255,255,0.18);
  display: grid; place-items: center;
  font-family: var(--font-mono); font-size: 12px;
}
.app-checkin .vivid-row .step.on { background: white; color: var(--hue-blue-b); font-weight: 600; }
.app-checkin .hold-hint { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.7; text-align: center; }

/* spectrum (constellation) */
.app-spec {
  flex: 1;
  background: var(--paper);
  display: flex; flex-direction: column;
  padding: 56px 20px 20px;
  position: relative;
}
.app-spec .hed {
  font-family: var(--font-display);
  font-size: 24px; font-weight: 400; letter-spacing: -0.02em;
  margin: 8px 0 4px;
}
.app-spec .quiet {
  font-family: var(--font-display); font-style: italic;
  font-size: 13px; line-height: 1.4;
  color: var(--ink-soft);
  margin-bottom: 14px;
  text-wrap: pretty;
}
.app-spec .canvas {
  flex: 1;
  position: relative;
  background: linear-gradient(180deg, #faf6ec, #f1ebde);
  border-radius: 16px;
  overflow: hidden;
}
.app-spec .star {
  position: absolute;
  border-radius: 50%;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.4), 0 6px 16px -8px rgba(28,26,23,0.18);
  animation: twinkle 6s ease-in-out infinite;
}
.app-spec .star.dim {
  background: transparent; border: 1.5px solid var(--ink-faint); opacity: 0.5; box-shadow: none;
}
@keyframes twinkle {
  0%, 100% { opacity: 0.85; }
  50% { opacity: 1; }
}
.app-spec .ann-band {
  display: flex; gap: 4px; margin-top: 12px;
  height: 8px;
}
.app-spec .ann-band .day {
  flex: 1; height: 8px; background: rgba(28,26,23,0.06); border-radius: 1px;
}
.app-spec .ann-band .day.tag { background: var(--terracotta); }

/* responsive */
@media (max-width: 880px) {
  .nav { padding: 20px 28px; }
  .nav ul { gap: 20px; font-size: 11px; }
  .wrap, .wrap-narrow { padding: 0 28px; }
  footer { grid-template-columns: 1fr 1fr; padding: 40px 28px; }
  section.spread { padding: 60px 0; }
}
