/* ============================================================
   A Book of Colors — marketing page (gouliard.com/abookofcolors)

   A 1:1 port of the gouliardsoftware.com/abookofcolors page. The two
   pages are meant to stay IDENTICAL; the only difference here is the
   ABC subnav above the hero, which is NOT styled by this file (it keeps
   its existing .abc-subnav* rules in abookofcolors.css).

   Everything below is namespaced `abcp-` and scoped under `.abcp` so it
   cannot collide with the older `.abc-*` rules in abookofcolors.css —
   that file still serves the support and privacy templates and is left
   untouched deliberately. Do not rename these to `.abc-*`.

   Ported 2026-07-24. When the GS page changes, port the change here too.
   ============================================================ */

.abcp {
  /* Scoped tokens: the GS page's palette, so this page renders the same
     regardless of what main.css does. Names are deliberately local. */
  --abcp-bg:     #F5F0E8;
  --abcp-ink:    #111108;
  --abcp-muted:  #333333;
  --abcp-faint:  #8a8478;
  --abcp-rule:   #E0DAD0;
  --abcp-width:  672px;

  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.65;
  color: var(--abcp-ink);
  -webkit-font-smoothing: antialiased;
}

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

/* The column itself is already established by .abc-marketing (main.css's
   --container-w, 672px, + 32px gutters) — the same 608px content measure the
   GS page's .col-wide produces. So this is a pass-through; do NOT add padding
   here or the page ends up double-gutted and narrower than GS. */
.abcp-col {
  /* No width/padding on purpose: a block box auto-fills the measure, which
     also lets the negative margins in the media query widen it. */
}

/* --- Hero: centred stack (headline, lede, badge, phone below) --- */

.abcp-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 64px 0 72px;
}

.abcp-hero h1 {
  font-size: 34px;
  font-weight: 350;
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin: 0 0 20px;
}

.abcp-hero-desc {
  color: var(--abcp-muted);
  max-width: 52ch;
  margin: 0 auto 36px;
}

.abcp-badge {
  display: inline-block;
  transition: opacity 0.2s;
}

/* width:auto — the badge SVG's ratio is 2.99:1; a wider box letterboxes
   it and floats the black shape off-centre inside its own box. */
.abcp-badge img {
  height: 44px;
  width: auto;
  display: block;
}

.abcp-badge:hover {
  opacity: 0.8;
}

.abcp-hero-img {
  display: flex;
  justify-content: center;
  margin-top: 56px;
}

/* The hero phone sits alone on the centreline, so it runs larger than the
   in-section ones; radii scale with it to keep the corners proportional. */
.abcp-hero-img .abcp-phone {
  width: 280px;
  max-width: 100%;
  border-radius: 44px;
}

/* 38px inner radius is the iPhone's own display curve at this width (~14%);
   the hero clip has a matching matte baked in, so the two coincide. */
.abcp-hero-img .abcp-phone img,
.abcp-hero-img .abcp-phone video {
  border-radius: 38px;
}

/* --- Device frames --- */

.abcp-phone {
  border-radius: 32px;
  border: 6px solid #1a1a1a;
  overflow: hidden;
  background: #1a1a1a;
  width: 220px;
  flex-shrink: 0;
  box-shadow: 0 24px 60px rgba(17, 17, 8, 0.16), 0 6px 16px rgba(17, 17, 8, 0.08);
}

/* The child carries its own radius rather than leaning on the parent's
   overflow:hidden. Note the raw iOS captures bake in the DISPLAY's squircle
   corners: where a system view is dark (the keyboard), the app's cream shows
   outside that curve and reads as light slivers inside the bezel. A CSS
   radius is a circular arc and can't match a squircle, and the UI's own text
   sits only 30px from the frame edge so cropping clips real content. The
   hero clip instead has a #1a1a1a corner matte composited in at the SAME
   radius the CSS clips at. Any future clip needs the same treatment.
   object-fit:cover kills sub-pixel letterboxing from the ratio below. */
.abcp-phone img,
.abcp-phone video {
  width: 100%;
  height: auto;
  aspect-ratio: 1206 / 2622;
  object-fit: cover;
  border-radius: 26px;
  display: block;
}

/* Screenshot frame: same recipe as .abcp-phone. The inner curve clips the
   screenshots' baked rounded corners, so no crop artifacts. */
.abcp-panel {
  width: 100%;
  max-width: 220px;
  padding: 6px;
  background: #1a1a1a;
  border-radius: 32px;
  box-shadow: 0 24px 60px rgba(17, 17, 8, 0.16), 0 6px 16px rgba(17, 17, 8, 0.08);
  display: block;
  height: auto;
}

/* --- Feature sections --- */

.abcp-sec {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 36px;
  padding: 64px 0;
  border-top: 1px solid var(--abcp-rule);
}

.abcp-sec--flip .abcp-sec-img {
  order: -1;
}

.abcp-sec-img {
  display: flex;
  justify-content: center;
}

.abcp-sec-img .abcp-phone,
.abcp-sec-img .abcp-panel {
  width: 205px;
}

.abcp-sec h2 {
  font-size: 22px;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.3;
  margin: 0 0 12px;
}

.abcp-sec p {
  color: var(--abcp-muted);
  max-width: 40ch;
  margin: 0;
}

.abcp-sec--full {
  display: block;
  text-align: center;
}

.abcp-sec--full h2 {
  max-width: 480px;
  margin: 0 auto 12px;
}

.abcp-sec--full p {
  max-width: 52ch;
  margin: 0 auto;
}

.abcp-sec--stack {
  display: block;
  text-align: center;
}

.abcp-sec--stack h2 {
  max-width: 520px;
  margin: 0 auto 12px;
}

.abcp-sec--stack p {
  max-width: 52ch;
  margin: 0 auto 40px;
}

/* Mac window + menu-bar popover composition: the raw window capture carries
   its own macOS chrome (no device frame), and the popover overhangs the
   window's top-right corner. */
.abcp-mac-hero {
  position: relative;
  max-width: 560px;
  margin: 0 auto;
}

.abcp-mac-hero .abcp-mac-shot {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 24px 60px rgba(17, 17, 8, 0.16), 0 6px 16px rgba(17, 17, 8, 0.08);
}

.abcp-mac-hero .abcp-mac-pop {
  position: absolute;
  top: -24px;
  right: -30px;
  width: 29%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 20px 48px rgba(17, 17, 8, 0.22), 0 4px 12px rgba(17, 17, 8, 0.12);
}

/* --- How it works --- */

.abcp-how {
  border-top: 1px solid var(--abcp-rule);
  padding: 72px 0 96px;
}

.abcp-how h2 {
  font-size: 22px;
  font-weight: 400;
  letter-spacing: -0.01em;
  margin: 0 0 32px;
  text-align: center;
}

.abcp-gesture-list {
  list-style: none;
  max-width: 520px;
  margin: 0 auto;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.abcp-gesture {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  color: var(--abcp-muted);
  line-height: 1.6;
}

.abcp-gesture-icon {
  flex: 0 0 24px;
  display: flex;
  justify-content: center;
}

.abcp-gesture-icon img {
  height: 15px;
  width: auto;
  display: block;
  margin-top: 4px;
}

.abcp-how-byline {
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--abcp-faint);
  margin-top: 44px;
}

/* --- Responsive --- */

@media (max-width: 720px) {
  .abcp-mac-hero .abcp-mac-pop {
    top: -14px;
    right: -8px;
  }

  /* GS uses 20px gutters at this width; .abc-marketing gives 32px. Pull the
     CONTENT back out by the 12px difference rather than changing
     .abc-marketing, which also positions the subnav (left as-is by design). */
  .abcp-col {
    margin-left: -12px;
    margin-right: -12px;
  }

  .abcp-hero {
    padding: 48px 0 56px;
  }

  .abcp-hero h1 {
    font-size: 30px;
  }

  .abcp-hero-img {
    margin-top: 40px;
  }

  .abcp-sec {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 56px 0;
  }

  .abcp-sec--flip .abcp-sec-img {
    order: 0;
  }

  .abcp-phone,
  .abcp-sec-img .abcp-phone {
    width: 215px;
  }

  .abcp-panel,
  .abcp-sec-img .abcp-panel {
    max-width: 215px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .abcp-badge {
    transition: none;
  }
}
