/*
 * deliveryduke.com styles. One file, served as is (not bundled), no external resources.
 * A game site in the manner of tycoon games: a full-bleed hero over the game world, a chunky logo,
 * ribbon headings, big rounded buttons with hard shadows. Colours and the display font (Baloo 2)
 * come from the game's own interface: night-navy panels, teal for "us", orange and coral for
 * actions. Mobile first: base rules target phones, min-width queries add columns.
 *
 * Pages link this file as /assets/site.css?v=<content hash>; the build computes the hash.
 */

/* The game's own typeface, cut down to Latin and Turkish letters (README.md, "Font"). */
@font-face {
  font-family: "Baloo 2";
  src: url("fonts/Baloo2-SemiBold.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #1a1d2e;
  --navy-soft: #262b40;
  --cream: #fbf6ea;
  --paper: #ffffff;
  --ink: #1a1d2e;
  --ink-soft: #545a70;
  --teal: #17a398;
  --teal-dark: #0d7a72;
  --teal-soft: #dcf3ef;
  --orange: #ffa41f;
  --coral: #ef5d58;
  --gold: #ffd23f;
  --orange-dark: #d97f00;
  --purple: #8b5cf6;
  --sky: #8fd6f2;
  --line: #e6dfcf;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 28px;

  --font-display: "Baloo 2", ui-rounded, "SF Pro Rounded", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --font-body: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans",
    "Helvetica Neue", Arial, sans-serif;

  color-scheme: light;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Section links must not land under the sticky header. */
  scroll-padding-top: 72px;
}

/* A column layout keeps the footer at the bottom of short pages such as the 404. */
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--font-body);
  overflow-wrap: break-word;
}

img,
svg {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

a {
  color: var(--teal-dark);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--ink);
}

:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  text-wrap: balance;
}

main {
  flex: 1 0 auto;
}

.wrap {
  width: 100%;
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: 20px;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 12px;
  z-index: 10;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--gold);
  color: var(--ink);
  font-weight: 700;
}

.skip-link:focus {
  top: 12px;
}

.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: var(--radius);
  background: var(--teal);
  box-shadow: 0 4px 0 var(--teal-dark);
  color: #fff;
  font: 600 1.1rem/1.2 var(--font-display);
  text-decoration: none;
}

.btn:hover {
  background: var(--teal-dark);
  color: #fff;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--navy);
  box-shadow: 0 3px 0 rgb(13 15 24 / 0.35);
  color: #fff;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-block: 10px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  color: #fff;
  font: 600 1.3rem/1 var(--font-display);
  text-decoration: none;
  white-space: nowrap;
}

.brand:hover {
  color: var(--gold);
}

.section-nav {
  display: none;
}

.section-nav ul,
.lang-switch ul {
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.section-nav a {
  display: block;
  padding: 7px 14px;
  border-radius: 999px;
  color: #e8eaf2;
  font: 600 1.05rem/1.2 var(--font-display);
  text-decoration: none;
}

.section-nav a:hover {
  background: var(--navy-soft);
  color: var(--gold);
}

.lang-switch ul {
  padding: 4px;
  border-radius: 999px;
  background: var(--navy-soft);
}

.lang-switch a,
.lang-switch .is-current {
  display: block;
  padding: 5px 12px;
  border-radius: 999px;
  color: #d5d8e4;
  font: 600 0.95rem/1.2 var(--font-display);
  text-decoration: none;
}

.lang-switch a:hover {
  color: #fff;
}

.lang-switch .is-current {
  background: var(--teal);
  color: #fff;
}

/* ---------- Ribbon headings ---------- */

/* A banner with folded ends, the genre's section heading. */
.ribbon {
  position: relative;
  display: table;
  margin: 0 auto 20px;
  padding: 8px 26px 6px;
  border-radius: 6px;
  background: var(--orange);
  box-shadow: 0 5px 0 var(--orange-dark);
  color: var(--navy);
  font: 600 clamp(1.5rem, 6vw, 2.2rem)/1.15 var(--font-display);
  text-align: center;
}

.ribbon::before,
.ribbon::after {
  content: "";
  position: absolute;
  top: 10px;
  z-index: -1;
  width: 34px;
  height: 100%;
  background: var(--orange-dark);
}

.ribbon::before {
  left: -18px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 40% 50%);
}

.ribbon::after {
  right: -18px;
  clip-path: polygon(0 0, 100% 0, 60% 50%, 100% 100%, 0 100%);
}

.ribbon-sm {
  margin: 10px auto 0;
  padding: 5px 20px 3px;
  font-size: clamp(1rem, 4.2vw, 1.4rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ---------- Hero ---------- */

/* The game world itself is the backdrop: a screenshot with a sky-to-night wash over it. */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgb(23 163 152 / 0.72) 0%, rgb(26 29 46 / 0.78) 62%, var(--navy) 100%),
    url("shots/backdrop.webp") center 30% / cover no-repeat,
    var(--teal);
  color: #fff;
  text-align: center;
}

.hero-inner {
  padding-top: 40px;
}

.logo {
  margin: 0 0 18px;
  font-size: clamp(3.4rem, 17vw, 7.5rem);
  line-height: 0.82;
  text-transform: uppercase;
}

.logo-a,
.logo-b {
  display: block;
  -webkit-text-stroke: 0.09em var(--navy);
  paint-order: stroke fill;
  text-shadow: 0 0.09em 0 var(--navy);
}

.logo-b {
  color: var(--gold);
  font-size: 1.32em;
}

.tagline {
  margin: 0 auto 10px;
  color: var(--gold);
  font: 600 clamp(1.35rem, 5vw, 1.9rem)/1.2 var(--font-display);
  text-shadow: 0 2px 0 rgb(13 15 24 / 0.5);
  text-wrap: balance;
}

.hero-lead {
  max-width: 36em;
  margin: 0 auto 22px;
  color: #f1f3f8;
  text-wrap: pretty;
}

.stores {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}

.store {
  display: block;
  min-width: 168px;
  padding: 9px 20px 7px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 5px 0 #c9ccd8;
  color: var(--ink);
  text-align: left;
  text-decoration: none;
}

.store small {
  display: block;
  font-size: 0.75rem;
  line-height: 1.3;
}

.store strong {
  display: block;
  font: 600 1.3rem/1.15 var(--font-display);
}

a.store:hover {
  background: var(--gold);
  color: var(--ink);
}

.store.is-soon {
  background: var(--navy);
  box-shadow: 0 5px 0 #0d0f18;
  color: #fff;
}

.store.is-soon small {
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-status {
  margin: 0;
  color: #dfe3ee;
  font-size: 0.95rem;
}

/* A phone frame around a 9:16 screenshot. */
.phone {
  width: min(100%, 290px);
  margin-inline: auto;
  padding: 8px;
  border-radius: 36px;
  background: #0d0f18;
  box-shadow: 0 18px 40px rgb(13 15 24 / 0.3);
}

.phone img {
  width: 100%;
  border-radius: 28px;
}

/* Three phones fanned out; they sink below the bottom edge of the hero. */
.phones {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  height: 380px;
  margin-top: 32px;
}

.phones .phone {
  flex: none;
  width: 230px;
  margin: 0;
}

.phone-left,
.phone-right {
  display: none;
}

/* ---------- Stats ---------- */

.stats {
  background: var(--navy);
  border-top: 6px solid var(--orange);
  color: #fff;
}

.stats-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px 12px;
  margin: 0 auto;
  padding-block: 28px;
  list-style: none;
}

.stat {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
}

/* A medal. */
.stat strong {
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  border: 5px solid var(--gold);
  border-radius: 50%;
  background: #fff8ea;
  box-shadow: 0 0 0 4px var(--orange-dark), 0 6px 0 4px rgb(13 15 24 / 0.45);
  color: var(--orange-dark);
  font: 600 2.6rem/1 var(--font-display);
  padding-top: 0.12em;
}

.stat span {
  max-width: 11em;
  color: #e8eaf2;
  font: 600 1.05rem/1.2 var(--font-display);
}

/* ---------- Sections ---------- */

.section {
  padding-block: 56px;
}

.section .wrap {
  position: relative;
  z-index: 0;
}

.section-alt {
  background: #fff;
}

.section-lead {
  max-width: 34em;
  margin: 0 auto 32px;
  color: var(--ink-soft);
  font-size: 1.15rem;
  text-align: center;
  text-wrap: balance;
}

/* ---------- The path: four stops on a road ---------- */

.journey {
  position: relative;
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0 0 0 44px;
  list-style: none;
  counter-reset: step;
}

/* The road, with its dashed centre line. */
.journey::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 6px;
  width: 22px;
  border-radius: 11px;
  background:
    repeating-linear-gradient(180deg, #fff 0 12px, transparent 12px 26px) center / 3px 100% no-repeat,
    #565c73;
}

.journey-step {
  position: relative;
  padding: 18px 20px;
  border: 3px solid var(--navy);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 6px 0 var(--navy);
  counter-increment: step;
}

/* The stop marker on the road. */
.journey-step::before {
  content: counter(step);
  position: absolute;
  top: 14px;
  left: -49px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 3px solid var(--navy);
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  font: 600 1.2rem/1 var(--font-display);
  padding-top: 0.1em;
}

.journey-step:last-child {
  background: #fff5d6;
  border-color: var(--orange-dark);
  box-shadow: 0 6px 0 var(--orange-dark);
}

.journey-step:last-child::before {
  background: var(--gold);
  color: var(--navy);
}

.journey-step h3 {
  margin: 0 0 6px;
  font-size: 1.4rem;
}

.journey-step p {
  margin: 0;
  color: var(--ink-soft);
}

.ladder {
  margin-top: 40px;
  text-align: center;
}

.ladder h3 {
  margin: 0 0 12px;
  font-size: 1.25rem;
}

.ladder-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ladder-list li {
  padding: 5px 14px 3px;
  border-radius: 999px;
  background: var(--teal-soft);
  color: var(--teal-dark);
  font: 600 1.05rem/1.3 var(--font-display);
}

.ladder-list li:not(:last-child)::after {
  content: "›";
  margin-left: 10px;
  color: var(--ink-soft);
}

.ladder-list li:last-child {
  background: var(--gold);
  box-shadow: 0 3px 0 var(--orange-dark);
  color: var(--navy);
}

/* ---------- Features ---------- */

.features {
  display: grid;
  gap: 56px;
  margin: 32px 0 0;
  padding: 0;
  list-style: none;
}

.feature {
  display: grid;
  gap: 24px;
  align-items: center;
}

.feature-copy h3 {
  margin: 0 0 10px;
  font-size: clamp(1.6rem, 5.5vw, 2.1rem);
}

.feature-copy p {
  margin: 0 0 14px;
  color: var(--ink-soft);
}

.points {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.points li {
  position: relative;
  padding-left: 28px;
  font-weight: 600;
}

/* A coin. */
.points li::before {
  content: "";
  position: absolute;
  top: 0.32em;
  left: 2px;
  width: 15px;
  height: 15px;
  border: 3px solid var(--orange-dark);
  border-radius: 50%;
  background: var(--gold);
}

/* ---------- Rivals ---------- */

.section-night {
  background: var(--navy);
  color: #fff;
}

.section-night .section-lead {
  color: #d5d8e4;
}

.rivals {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rival {
  --rival: var(--coral);
  padding: 20px 22px;
  border-top: 10px solid var(--rival);
  border-radius: var(--radius);
  background: var(--navy-soft);
  box-shadow: 0 6px 0 #0d0f18;
}

.rival-okavo {
  --rival: #9aa3b8;
}

.rival-nimbo {
  --rival: var(--purple);
}

.rival-cheapride {
  --rival: var(--coral);
}

.rival-tag {
  margin: 0 0 2px;
  color: var(--rival);
  font: 600 0.95rem/1.3 var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rival h3 {
  margin: 0 0 8px;
  font-size: 2rem;
}

.rival p:last-child {
  margin: 0;
  color: #d5d8e4;
}

/* ---------- Promises ---------- */

.promises {
  background: var(--teal-soft);
}

.promise-list {
  display: grid;
  gap: 18px;
  margin: 32px 0 0;
  padding: 0;
  list-style: none;
}

.promise {
  padding: 22px;
  border: 3px solid var(--teal-dark);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 6px 0 var(--teal-dark);
}

.promise h3 {
  margin: 0 0 6px;
  font-size: 1.4rem;
}

.promise p {
  margin: 0;
  color: var(--ink-soft);
}

/* ---------- FAQ ---------- */

.faq {
  display: grid;
  gap: 12px;
  max-width: 44rem;
  margin: 32px auto 0;
}

.faq details {
  border: 3px solid var(--navy);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 5px 0 var(--navy);
}

.faq summary {
  padding: 14px 18px 12px;
  cursor: pointer;
  font: 600 1.2rem/1.3 var(--font-display);
}

.faq summary::marker {
  color: var(--orange-dark);
}

.faq p {
  margin: 0;
  padding: 0 18px 16px;
  color: var(--ink-soft);
}

/* ---------- Final call ---------- */

.cta {
  padding-block: 64px;
  background:
    linear-gradient(180deg, rgb(26 29 46 / 0.82), rgb(23 163 152 / 0.78)),
    url("shots/backdrop.webp") center 70% / cover no-repeat,
    var(--teal);
  color: #fff;
  text-align: center;
}

.cta h2 {
  margin: 0 0 8px;
  font-size: clamp(2rem, 8vw, 3.2rem);
  text-shadow: 0 4px 0 var(--navy);
}

.cta p {
  margin: 0 0 22px;
  font-size: 1.15rem;
}

.cta .stores {
  margin: 0;
}

/* ---------- Legal pages ---------- */

.legal {
  max-width: 46rem;
  margin-inline: auto;
  padding-block: 40px 64px;
}

.legal h1 {
  margin: 0 0 8px;
  font-size: clamp(2rem, 7vw, 2.8rem);
  font-weight: 600;
}

.legal h2 {
  margin: 36px 0 10px;
  font-size: 1.35rem;
  font-weight: 600;
  scroll-margin-top: 16px;
}

.legal .meta {
  margin: 0 0 20px;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.legal .lead {
  font-size: 1.15rem;
}

.legal li {
  margin-bottom: 6px;
}

.legal address {
  padding: 16px 20px;
  border-left: 4px solid var(--teal);
  border-radius: var(--radius-sm);
  background: var(--paper);
  font-style: normal;
}

.toc {
  margin-block: 24px;
  padding: 18px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.legal .toc h2 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.toc ol {
  margin: 0;
  padding-left: 1.4em;
}

.callout {
  margin-block: 20px;
  padding: 18px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.callout-mint {
  border-color: #b9e3dc;
  background: var(--teal-soft);
}

.legal .callout h2 {
  margin-top: 0;
}

.callout > :last-child {
  margin-bottom: 0;
}

.path {
  padding: 1px 7px;
  border-radius: 6px;
  background: var(--navy);
  color: #fff;
  font-size: 0.92em;
  font-weight: 600;
  white-space: nowrap;
}

/* A publisher detail that has not been added yet (src/data/publisher.ts). */
.placeholder {
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--gold);
  color: var(--ink);
  font-weight: 600;
}

.draft-note {
  max-width: 46rem;
  margin: 24px auto 0;
  padding: 12px 18px;
  border: 2px dashed var(--orange);
  border-radius: var(--radius);
  background: #fff5df;
  font-weight: 600;
}

/* ---------- 404 ---------- */

.notfound {
  padding-block: 72px;
  text-align: center;
}

.notfound .code {
  margin: 0;
  color: var(--teal);
  font: 600 clamp(4rem, 22vw, 8rem)/1 var(--font-display);
}

.notfound h1 {
  margin: 8px 0;
  font-size: 2rem;
}

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

.site-footer {
  background: var(--navy);
  color: #aab0c4;
  padding-block: 28px;
}

.footer-grid {
  display: grid;
  gap: 16px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a {
  color: #fff;
  font-weight: 600;
  text-decoration: none;
}

.footer-links a:hover,
.footer-links a[aria-current="page"] {
  color: var(--gold);
}

.footer-meta {
  margin: 0;
  font-size: 0.9rem;
}

/* ---------- Wider screens ---------- */

@media (min-width: 560px) {
  .phones {
    height: 420px;
  }

  .phones .phone {
    width: 250px;
  }

  .phone-left,
  .phone-right {
    display: block;
    margin-top: 44px !important;
    opacity: 0.96;
  }

  .phone-left {
    margin-right: -70px !important;
    transform: rotate(-7deg);
  }

  .phone-right {
    margin-left: -70px !important;
    transform: rotate(7deg);
  }

  .phone-center {
    z-index: 1;
  }

  .stats-list {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 860px) {
  .section-nav {
    display: block;
  }

  .hero-inner {
    padding-top: 56px;
  }

  .phones {
    height: 470px;
  }

  .phones .phone {
    width: 280px;
  }

  .section {
    padding-block: 80px;
  }

  /* The road turns sideways and the stops sit under it. */
  .journey {
    grid-template-columns: repeat(4, 1fr);
    padding: 58px 0 0;
  }

  .journey::before {
    top: 6px;
    right: 0;
    bottom: auto;
    left: 0;
    width: auto;
    height: 22px;
    background:
      repeating-linear-gradient(90deg, #fff 0 12px, transparent 12px 26px) center / 100% 3px no-repeat,
      #565c73;
  }

  .journey-step::before {
    top: -59px;
    left: 50%;
    margin-left: -18px;
  }

  .feature {
    grid-template-columns: 290px 1fr;
    gap: 64px;
    max-width: 880px;
    margin-inline: auto;
  }

  /* Every second feature puts the phone on the right. */
  .feature:nth-child(even) {
    grid-template-columns: 1fr 290px;
  }

  .feature:nth-child(even) .phone {
    order: 2;
  }

  .rivals,
  .promise-list {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr auto;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
