/* =========================================================================
   Hut24 Landing Page Styles
   Design system tokens, Amplitude type, components, responsive layout.
   Retheme everything from the :root tokens below.
   ========================================================================= */

/* ---- Fonts (self-contained, served from /fonts) ---- */
@font-face {
  font-family: "Amplitude";
  src: url("../fonts/Amplitude-Light.ttf") format("truetype");
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Amplitude";
  src: url("../fonts/Amplitude-Regular.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Amplitude";
  src: url("../fonts/Amplitude-Medium.ttf") format("truetype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Amplitude";
  src: url("../fonts/Amplitude-Bold.ttf") format("truetype");
  font-weight: 700; font-style: normal; font-display: swap;
}

/* ---- Design tokens ---- */
:root {
  /* Brand palette (sampled from logo) */
  --red: #C8402F;
  --red-600: #B23627;
  --blue: #2E82C4;
  --blue-600: #2670AC;

  /* Neutrals */
  --ink: #1E2127;
  --ink-soft: #5A6270;
  --bg: #FBFBF9;
  --bg-alt: #F2F3F0;
  --surface: #FFFFFF;
  --line: #E7E8E4;

  /* Effects */
  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 32px;
  --shadow-sm: 0 2px 8px rgba(30,33,39,.06);
  --shadow: 0 18px 50px -20px rgba(30,33,39,.22);
  --shadow-lg: 0 40px 90px -30px rgba(30,33,39,.30);

  /* Type scale */
  --font: "Amplitude", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Layout */
  --maxw: 1160px;
  --gutter: clamp(20px, 5vw, 48px);
  --nav-h: 135px;
}

/* ---- Reset / base ---- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font);
  font-weight: 400;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }

h1, h2, h3 { line-height: 1.08; letter-spacing: -0.02em; font-weight: 700; }
h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 4vw, 3rem); }
h3 { font-size: 1.25rem; letter-spacing: -0.01em; }

/* ---- Layout helpers ---- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding: clamp(64px, 10vw, 130px) 0; }
.section-head { max-width: 640px; margin-bottom: clamp(36px, 6vw, 64px); }
.eyebrow {
  display: inline-block; font-weight: 700; font-size: .8rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--red); margin-bottom: 14px;
}
.lead { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--ink-soft); margin-top: 18px; }
.center { text-align: center; margin-inline: auto; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font); font-weight: 700; font-size: .98rem;
  padding: 13px 24px; border-radius: 100px; border: 0; cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 8px 20px -8px rgba(200,64,47,.7); }
.btn-primary:hover { background: var(--red-600); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); transform: translateY(-2px); }

/* ---- Store badges ---- */
.badges { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.badge img { height: 54px; width: auto; }
.badge {
  border-radius: 12px; transition: transform .2s ease, box-shadow .2s ease;
  display: inline-block; box-shadow: var(--shadow-sm);
}
.badge:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

/* =========================================================================
   Navigation
   ========================================================================= */
.nav {
  position: sticky; top: 0; z-index: 50; height: var(--nav-h);
  display: flex; align-items: center;
  background: rgba(251,251,249,.72); backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid transparent; transition: border-color .3s ease, box-shadow .3s ease;
}
.nav.scrolled { border-color: var(--line); box-shadow: var(--shadow-sm); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; }

.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.brand img { height: 32px; }
.brand .wordmark { font-size: 1.45rem; letter-spacing: -.02em; }
.brand .wordmark .b { color: var(--blue); }
.brand .wordmark .r { color: var(--red); }

.logo-wrap {
  width: 120px;
  height: 120px;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}
.logo-wrap img {
  position: absolute;
  width: 142px;
  height: auto;
  top: -8px;
  left: -14px;
}
.logo-footer {
  filter: brightness(0) invert(1);
}

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a { color: var(--ink-soft); font-weight: 500; font-size: .96rem; transition: color .2s; }
.nav-links a:hover { color: var(--ink); }

.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer; padding: 8px;
  flex-direction: column; gap: 5px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; transition: .25s; }

/* =========================================================================
   Hero
   ========================================================================= */
.hero { position: relative; padding-top: clamp(40px, 8vw, 80px); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 50% at 85% 0%, rgba(46,130,196,.14), transparent 60%),
    radial-gradient(50% 45% at 5% 20%, rgba(200,64,47,.12), transparent 60%);
}
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(30px, 5vw, 70px); align-items: center; }
.hero-copy { max-width: 560px; }
.hero h1 { margin-bottom: 8px; }
.hero h1 .accent { color: var(--red); }
.hero .tagline { font-size: clamp(1.1rem, 2.2vw, 1.4rem); color: var(--ink-soft); margin: 18px 0 32px; }
.hero .badges { margin-bottom: 18px; }
.hero .microcopy { font-size: .9rem; color: var(--ink-soft); }
.hero .microcopy strong { color: var(--ink); }

/* Phone mockup */
.phone-stage { position: relative; display: flex; justify-content: center; }
.phone {
  position: relative; width: min(300px, 78vw); aspect-ratio: 300 / 610;
  background: #0e1116; border-radius: 44px; padding: 12px;
  box-shadow: var(--shadow-lg); rotate: 2.5deg;
  transition: rotate .5s ease, transform .5s ease;
}
.phone:hover { rotate: 0deg; transform: translateY(-6px); }
.phone::before {
  content: ""; position: absolute; top: 14px; left: 50%; transform: translateX(-50%);
  width: 110px; height: 22px; background: #0e1116; border-radius: 0 0 16px 16px; z-index: 3;
}
.phone-screen {
  width: 100%; height: 100%; border-radius: 33px; overflow: hidden;
  background: linear-gradient(160deg, #fff, var(--bg-alt));
  display: flex; flex-direction: column;
}
.scr-top { padding: 30px 18px 16px; background: linear-gradient(135deg, var(--red), #d6614f); color: #fff; }
.scr-top .h { font-weight: 700; font-size: 1.1rem; }
.scr-top .s { font-size: .78rem; opacity: .9; }
.scr-search {
  margin: 14px 12px -6px; background: #fff; border-radius: 12px; padding: 11px 14px;
  font-size: .8rem; color: var(--ink-soft); box-shadow: var(--shadow-sm); display: flex; gap: 8px; align-items: center;
}
.scr-list { padding: 14px 12px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.scr-card { background: #fff; border-radius: 14px; box-shadow: var(--shadow-sm); overflow: hidden; }
.scr-card .ph { height: 78px; background: linear-gradient(120deg, var(--blue), #5aa6dd); position: relative; }
.scr-card .ph .tag {
  position: absolute; top: 8px; left: 8px; background: rgba(255,255,255,.9); color: var(--red);
  font-size: .62rem; font-weight: 700; padding: 3px 8px; border-radius: 100px;
}
.scr-card .body { padding: 10px 12px; }
.scr-card .body .t { font-weight: 700; font-size: .82rem; }
.scr-card .body .m { font-size: .72rem; color: var(--ink-soft); }
.scr-card .body .p { font-weight: 700; color: var(--red); font-size: .9rem; margin-top: 4px; }

/* =========================================================================
   Logo strip / stats
   ========================================================================= */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.stats .wrap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding-block: 40px; text-align: center; }
.stat .n { font-size: clamp(1.8rem, 3.5vw, 2.6rem); font-weight: 700; letter-spacing: -.02em; }
.stat .n.r { color: var(--red); }
.stat .n.b { color: var(--blue); }
.stat .l { font-size: .85rem; color: var(--ink-soft); margin-top: 4px; }

/* =========================================================================
   Audience split cards
   ========================================================================= */
.audience .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.aud-card {
  position: relative; padding: clamp(28px, 4vw, 44px); border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  overflow: hidden; transition: transform .3s ease, box-shadow .3s ease;
}
.aud-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.aud-card::after {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 5px;
}
.aud-card.host::after { background: var(--red); }
.aud-card.rent::after { background: var(--blue); }
.aud-card .pill {
  display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 100px; margin-bottom: 18px;
}
.aud-card.host .pill { background: rgba(200,64,47,.1); color: var(--red); }
.aud-card.rent .pill { background: rgba(46,130,196,.1); color: var(--blue); }
.aud-card h3 { font-size: 1.5rem; margin-bottom: 10px; }
.aud-card p.desc { color: var(--ink-soft); margin-bottom: 20px; }
.aud-list li { display: flex; gap: 10px; padding: 7px 0; font-size: .96rem; }
.aud-list li svg { flex: none; margin-top: 3px; }

/* =========================================================================
   Feature grid
   ========================================================================= */
.features .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.feature {
  padding: 28px; border-radius: var(--radius); background: var(--surface);
  border: 1px solid var(--line); transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.feature:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: transparent; }
.feature .ico {
  width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center;
  margin-bottom: 18px; background: rgba(46,130,196,.1); color: var(--blue);
}
.feature:nth-child(odd) .ico { background: rgba(200,64,47,.1); color: var(--red); }
.feature h3 { margin-bottom: 8px; }
.feature p { color: var(--ink-soft); font-size: .95rem; }

/* =========================================================================
   How it works
   ========================================================================= */
.how { background: var(--bg-alt); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: step; }
.step { position: relative; padding-top: 18px; }
.step .num {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  font-weight: 700; color: #fff; background: var(--red); margin-bottom: 18px; font-size: 1.1rem;
}
.step:nth-child(2) .num { background: var(--blue); }
.step:nth-child(3) .num { background: var(--ink); }
.step h3 { margin-bottom: 8px; }
.step p { color: var(--ink-soft); font-size: .95rem; }

/* =========================================================================
   Safety
   ========================================================================= */
.safety .grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(30px, 5vw, 64px); align-items: center; }
.safety-list { display: grid; gap: 16px; }
.safety-item {
  display: flex; gap: 16px; padding: 20px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line);
}
.safety-item .ico {
  width: 44px; height: 44px; flex: none; border-radius: 12px; display: grid; place-items: center;
  background: rgba(46,130,196,.1); color: var(--blue);
}
.safety-item h3 { font-size: 1.05rem; margin-bottom: 4px; }
.safety-item p { font-size: .9rem; color: var(--ink-soft); }
.safety-visual {
  border-radius: var(--radius-lg); padding: 48px 36px; color: #fff; text-align: center;
  background: linear-gradient(150deg, var(--blue), var(--blue-600));
  box-shadow: var(--shadow);
}
.safety-visual .verified {
  width: 90px; height: 90px; margin: 0 auto 20px; border-radius: 50%;
  background: rgba(255,255,255,.16); display: grid; place-items: center;
}
.safety-visual h3 { color: #fff; font-size: 1.5rem; margin-bottom: 8px; }
.safety-visual p { opacity: .92; font-size: .95rem; }

/* =========================================================================
   Final CTA band
   ========================================================================= */
.cta-band { padding: clamp(56px, 8vw, 96px) 0; }
.cta-inner {
  border-radius: var(--radius-lg); padding: clamp(40px, 6vw, 72px) clamp(28px, 5vw, 64px);
  background: linear-gradient(135deg, var(--red), #a83122);
  color: #fff; text-align: center; position: relative; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.cta-inner::after {
  content: ""; position: absolute; right: -80px; bottom: -80px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(255,255,255,.15), transparent 70%);
}
.cta-inner h2 { color: #fff; }
.cta-inner p { opacity: .94; margin: 16px auto 30px; max-width: 520px; }
.cta-inner .badges { justify-content: center; }

/* =========================================================================
   Footer
   ========================================================================= */
.footer { background: var(--ink); color: #C5CAD3; padding: clamp(48px, 7vw, 80px) 0 32px; }
.footer .top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 30px; }
.footer .brand .wordmark { color: #fff; }
.footer .blurb { font-size: .9rem; margin-top: 14px; max-width: 280px; color: #97A0AD; }
.footer h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; }
.footer ul li { margin-bottom: 10px; }
.footer ul a { color: #97A0AD; font-size: .9rem; transition: color .2s; }
.footer ul a:hover { color: #fff; }
.footer .bottom {
  margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: .82rem; color: #7A8492;
}

/* =========================================================================
   Subpages (legal / content pages)
   ========================================================================= */
.page-hero { position: relative; padding: clamp(48px, 7vw, 88px) 0 clamp(32px, 5vw, 56px); overflow: hidden; }
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 50% at 85% 0%, rgba(46,130,196,.12), transparent 60%),
    radial-gradient(50% 45% at 5% 20%, rgba(200,64,47,.10), transparent 60%);
}
.page-hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin-bottom: 8px; }
.page-hero .updated { font-size: .9rem; color: var(--ink-soft); margin-top: 14px; }

.legal { max-width: 780px; padding-bottom: clamp(64px, 10vw, 120px); }
.legal section + section { margin-top: clamp(32px, 5vw, 48px); }
.legal h2 {
  font-size: 1.4rem; letter-spacing: -0.01em; margin-bottom: 12px;
  padding-top: 8px;
}
.legal h3 { font-size: 1.05rem; margin: 22px 0 8px; }
.legal p { color: var(--ink-soft); margin-bottom: 14px; }
.legal p strong { color: var(--ink); }
.legal ul { list-style: disc; padding-left: 22px; margin: 0 0 14px; }
.legal li { color: var(--ink-soft); margin-bottom: 8px; }
.legal li::marker { color: var(--red); }
.legal a { color: var(--blue); font-weight: 500; }
.legal a:hover { text-decoration: underline; }
.legal .callout {
  border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface);
  padding: 20px 24px; margin: 20px 0; box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--blue);
}
.legal .callout.warn { border-left-color: var(--red); }
.legal .callout p:last-child, .legal .callout ul:last-child { margin-bottom: 0; }

.legal .toc {
  border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius);
  padding: 24px 28px; margin-bottom: clamp(32px, 5vw, 48px); box-shadow: var(--shadow-sm);
}
.legal .toc h2 { font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: var(--red); margin-bottom: 12px; padding-top: 0; }
.legal .toc ol { list-style: none; padding: 0; margin: 0; columns: 2; column-gap: 28px; }
.legal .toc li { margin-bottom: 6px; font-size: .92rem; break-inside: avoid; }
.legal .toc a { color: var(--ink-soft); font-weight: 500; }
.legal .toc a:hover { color: var(--blue); }

.legal .tbl-wrap { overflow-x: auto; margin: 18px 0; border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); }
.legal table { width: 100%; border-collapse: collapse; font-size: .92rem; background: var(--surface); }
.legal th {
  text-align: left; font-size: .76rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink); background: var(--bg-alt);
}
.legal th, .legal td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal td { color: var(--ink-soft); }
.legal tr:last-child td { border-bottom: 0; }

@media (max-width: 640px) {
  .legal .toc ol { columns: 1; }
}

/* =========================================================================
   Scroll reveal
   ========================================================================= */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* =========================================================================
   Responsive
   ========================================================================= */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { margin-inline: auto; }
  .hero .badges, .hero .microcopy { justify-content: center; }
  .phone-stage { margin-top: 20px; }
  .audience .grid, .safety .grid { grid-template-columns: 1fr; }
  .features .grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; gap: 16px; }
  .stats .wrap { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .footer .top { grid-template-columns: 1fr 1fr; }

  .nav-links, .nav-cta .btn { display: none; }
  .nav-toggle { display: flex; }
  .nav.open .nav-links {
    display: flex; flex-direction: column; gap: 0;
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 8px var(--gutter) 16px;
  }
  .nav.open .nav-links a { padding: 14px 0; border-bottom: 1px solid var(--line); width: 100%; }
}

@media (max-width: 540px) {
  .features .grid { grid-template-columns: 1fr; }
  .footer .top { grid-template-columns: 1fr; gap: 24px; }
  .badge img { height: 48px; }
}
