/*
 * Iceland Atlas — landing page styles
 *
 * Palette mirrors the mobile app: PAPER ground, INK type, INK2 secondary,
 * trail-green accent. Georgia throughout. The page is intentionally quiet
 * — a single full-bleed cover image, three small cards, no animations,
 * no chrome. Reads like the inside flap of a paperback field guide.
 */

:root {
  --paper:    #f4eed5;
  --paper-2:  #ebe2b8;     /* slightly darker for cards */
  --ink:      #1a0e04;
  --ink-2:    #4a2e10;
  --trail:    #1a5c2a;     /* same as the dashed trail line in the app */
  --max-w:    760px;       /* book-page measure for body text */
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink-2);
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  display: block;
}

/* ── Hero ───────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  width: 100%;
  height: 70vh;
  min-height: 360px;
  max-height: 720px;
  overflow: hidden;
  background: #000;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  /*
   * Slight darken so the title overlay reads white on top.  No
   * gradient overlay div — keeps the markup minimal.  The brightness
   * filter is hardware-accelerated so it doesn't tank scrolling.
   */
  filter: brightness(0.78);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  pointer-events: none;          /* image link wouldn't be there anyway */
}

.hero-overlay h1 {
  margin: 0;
  font-size: clamp(40px, 8vw, 96px);
  font-weight: 700;
  font-family: 'Georgia', serif;
  color: #f4eed5;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 18px rgba(0,0,0,0.55);
  line-height: 1;
}

.hero-overlay .tagline {
  margin: 14px 0 0;
  font-size: clamp(15px, 2.5vw, 22px);
  font-style: italic;
  color: rgba(244, 238, 213, 0.92);
  text-shadow: 0 1px 6px rgba(0,0,0,0.5);
  letter-spacing: 0.02em;
}

/* ── Intro prose ────────────────────────────────────────────────────── */

.intro {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 64px 24px 24px;
}

.intro .lede {
  font-size: 22px;
  line-height: 1.45;
  color: var(--ink);
  margin: 0 0 28px;
  font-weight: 400;
}

.intro p {
  margin: 0 0 16px;
}

/* ── Three feature cards ────────────────────────────────────────────── */

.cards {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 32px 24px 24px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 720px) {
  .cards {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }
}

.card {
  background: var(--paper-2);
  border-radius: 12px;
  padding: 18px 18px 16px;
  /* Inset shadow — no offset drop shadow, the card sits "carved into"
     the paper. Matches the modal aesthetic in the mobile app. */
  box-shadow:
    inset 0 0 0 1px rgba(74, 46, 16, 0.12),
    0 1px 3px rgba(74, 46, 16, 0.08);
}

.card h3 {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.01em;
}

.card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-2);
}

/* ── Quiet section ──────────────────────────────────────────────────── */

.quiet {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 48px 24px;
  text-align: center;
}

.quiet-line {
  font-style: italic;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.6;
  opacity: 0.8;
  margin: 0;
}

/* ── Footer ─────────────────────────────────────────────────────────── */

footer {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 32px 24px 64px;
  text-align: center;
  font-size: 13px;
  color: var(--ink-2);
  opacity: 0.7;
  border-top: 1px solid rgba(74, 46, 16, 0.15);
  margin-top: 24px;
}

footer p {
  margin: 0 0 6px;
}

footer .credits {
  font-size: 11px;
  opacity: 0.65;
}

footer a {
  color: var(--trail);
  text-decoration: none;
  border-bottom: 1px dotted rgba(26, 92, 42, 0.4);
}

footer a:hover {
  border-bottom-color: var(--trail);
}

/* ── Reduced-motion respect ─────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0s !important;
    transition-duration: 0s !important;
  }
}
