/* ═══════════════════════════════════════════════════════════
   ShepFlips — shepflips.com
   ═══════════════════════════════════════════════════════════ */

:root {
  --navy:      #16294a;
  --navy-deep: #0f1c30;
  --navy-soft: #24406b;
  --gold:      #b8922e;
  --gold-lt:   #c9a227;

  --ink:       #17202e;
  --body:      #43505f;
  --muted:     #78838f;

  --bg:        #ffffff;
  --bg-alt:    #f7f8fa;
  --line:      #e3e7ec;
  --line-soft: #eef1f4;

  --wrap:  1120px;
  --radius: 4px;

  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto,
          "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 92px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { color: var(--ink); line-height: 1.2; margin: 0; font-weight: 700; }
p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

a { color: var(--navy-soft); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--gold); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 28px; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--navy); color: #fff; padding: 12px 20px;
}
.skip:focus { left: 0; }

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

/* ── Header ─────────────────────────────────────────────── */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; min-height: 78px;
}

/* The logo carries the wordmark, so the header holds the image and nothing
   else. Height drives it and width follows the 2.7:1 lockup; the intrinsic
   width/height attributes on the img reserve the box before it decodes, so the
   nav does not jump on first paint. */
.wordmark { text-decoration: none; display: block; line-height: 0; }
.wordmark-logo { display: block; height: 46px; width: auto; }

.nav { display: flex; align-items: center; gap: 30px; }
.nav a {
  font-size: .84rem; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--body); text-decoration: none;
  transition: color .15s;
}
.nav a:hover { color: var(--navy); }
.nav a.is-active { color: var(--navy); }
.nav a.is-active::after {
  content: ""; display: block; height: 2px; margin-top: 5px;
  background: var(--gold);
}
.nav .nav-cta.is-active::after { display: none; }
.nav .nav-cta {
  background: var(--navy); color: #fff;
  padding: 11px 20px; border-radius: var(--radius); letter-spacing: .05em;
}
.nav .nav-cta:hover { background: var(--gold); color: #fff; }

.nav-toggle {
  display: none; width: 42px; height: 42px; padding: 10px;
  background: none; border: 1px solid var(--line); border-radius: var(--radius);
  cursor: pointer;
}
.nav-toggle span {
  display: block; height: 2px; background: var(--navy); border-radius: 2px;
  margin: 4px 0; transition: transform .2s, opacity .2s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

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

.hero { padding: 72px 0 88px; }
/* The home hero hands straight off to the deals board, so it gives up the
   bottom padding the board's own section-top already provides. */
.hero-tight { padding-bottom: 52px; }
.section-deals { padding-top: 56px; }

/* Interior pages: same voice as the hero, less air, no competing with the
   home page's opening. */
.page-hero { padding: 76px 0 64px; border-bottom: 1px solid var(--line); }
.page-hero h1 {
  font-size: clamp(2rem, 4.2vw, 2.9rem);
  letter-spacing: -.02em; margin-bottom: 20px;
}
.page-hero .lede { margin-bottom: 30px; }

.eyebrow {
  font-size: .72rem; font-weight: 700; letter-spacing: .19em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 22px;
}

.hero h1 {
  font-size: clamp(2.3rem, 5.4vw, 3.85rem);
  letter-spacing: -.02em; margin-bottom: 26px;
}
.hero h1 em { font-style: italic; color: var(--navy); }

.lede {
  font-size: 1.16rem; max-width: 64ch; color: var(--body);
  margin-bottom: 34px;
}

.cta-row { display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  display: inline-block; padding: 15px 30px;
  font-size: .87rem; font-weight: 700; letter-spacing: .07em;
  text-transform: uppercase; text-decoration: none;
  border-radius: var(--radius); border: 1.5px solid transparent;
  cursor: pointer; transition: background .15s, color .15s, border-color .15s;
  font-family: inherit;
}
.btn-primary { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-primary:hover { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); background: var(--bg-alt); }
.btn-block { width: 100%; }

/* ── Trust strip ────────────────────────────────────────── */

.trust-strip { background: var(--navy); color: #fff; }
.trust-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding-top: 30px; padding-bottom: 30px; gap: 24px;
}
.trust-grid div { display: flex; flex-direction: column; gap: 3px; }
.trust-grid strong { font-size: 1.06rem; color: var(--gold-lt); letter-spacing: .01em; }
.trust-grid span {
  font-size: .74rem; letter-spacing: .13em; text-transform: uppercase;
  color: rgba(255,255,255,.68);
}

/* ── Sections ───────────────────────────────────────────── */

.section { padding: 92px 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }

.section-title {
  font-size: .78rem; font-weight: 700; letter-spacing: .21em;
  text-transform: uppercase; color: var(--gold);
  padding-bottom: 16px; margin-bottom: 38px;
  border-bottom: 1px solid var(--line);
}
.section-alt .section-title { border-color: #dfe4ea; }

.section-lede { font-size: 1.06rem; max-width: 78ch; }

.two-col {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: start;
}

.prose { font-size: 1.03rem; }
.prose strong { color: var(--ink); }

/* ── Bio ────────────────────────────────────────────────── */

.bio {
  display: flex; align-items: center; gap: 22px;
  margin-bottom: 28px;
}
/* Fixed box with width AND height set: the intrinsic attributes on the img are
   the source's square, so without these the 560px file would blow out the
   column before the CSS applied. */
.bio-photo {
  flex: 0 0 auto; width: 190px; height: 190px;
  object-fit: cover; object-position: center top;
  border-radius: var(--radius);
  background: var(--bg-alt);
  border: 1px solid var(--line);
}
.bio-id { min-width: 0; }
.bio-name {
  margin: 0 0 3px; font-size: 1.14rem; font-weight: 700;
  color: var(--ink); letter-spacing: -.01em; line-height: 1.25;
}
.bio-role {
  margin: 0; font-size: .68rem; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; color: var(--gold);
}

/* ── Spec card ──────────────────────────────────────────── */

.spec-card {
  border: 1px solid var(--line); border-top: 3px solid var(--navy);
  border-radius: var(--radius); padding: 28px 30px; background: var(--bg-alt);
}
.spec-card h3 {
  font-size: .74rem; letter-spacing: .19em; text-transform: uppercase;
  color: var(--navy); margin-bottom: 20px;
}
.spec-card dl { margin: 0; }
.spec-card dt {
  font-size: .68rem; font-weight: 700; letter-spacing: .15em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 5px;
}
.spec-card dd {
  margin: 0 0 20px; font-size: .96rem; color: var(--ink); line-height: 1.5;
}
.spec-card dd:last-child { margin-bottom: 0; }

/* ── Steps ──────────────────────────────────────────────── */

.steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
}
.steps li {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px 24px 28px;
}
.section-alt .steps li { background: #fff; }
.step-num {
  display: block; font-size: 1.45rem; font-weight: 700;
  color: var(--gold); line-height: 1; margin-bottom: 14px;
}
.steps h4 { font-size: 1.02rem; margin-bottom: 7px; }
.steps p { font-size: .93rem; color: var(--muted); margin: 0; line-height: 1.55; }

/* ── Deals ──────────────────────────────────────────────── */

.deals-cta {
  margin-top: 34px;
  display: flex; align-items: center; justify-content: space-between; gap: 40px;
  background: var(--bg-alt); border: 1px solid var(--line);
  border-left: 3px solid var(--gold); border-radius: var(--radius);
  padding: 34px 36px;
}
.deals-cta h3 { font-size: 1.24rem; margin-bottom: 8px; }
.deals-cta p { font-size: 1rem; color: var(--body); margin: 0; max-width: 52ch; }
.deals-cta .btn { flex: 0 0 auto; }

.deals-note {
  margin-top: 18px; font-size: .87rem; color: var(--muted); max-width: 78ch;
}

/* The board itself — cards built by deals.js from the public JSON feed.
   Visibility is driven by :empty, not by [data-state]: an empty grid and an
   empty status line take themselves out of the flow, so no state can leave a
   stray gap behind. The link-out below stays visible in every state. */

.deals-status { margin: 34px 0 0; font-size: .95rem; color: var(--body); }
.deals-status:empty { display: none; }
.deals-retry { margin-top: 16px; }
/* `.btn` sets display:inline-block, which outranks the UA's `[hidden]{display:none}`
   on specificity — so the retry button would sit there in every state, including
   success, unless the attribute is honoured explicitly here. */
.deals-retry[hidden] { display: none; }

.deals-grid {
  margin-top: 34px;
  display: grid;
  /* auto-fill rather than a fixed 4: a card carries a photo, a price, an
     address and three figures, and four tracks at the 1120px wrap leave only
     ~245px each. */
  /* min() keeps a single 280px track from overflowing a phone narrower than
     that; without it the grid would push the page sideways. */
  grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
  gap: 20px;
}
.deals-grid:empty { display: none; }

.deal-card {
  display: block; text-decoration: none; color: inherit;
  border: 1px solid var(--line); border-left: 3px solid var(--navy);
  border-radius: var(--radius); background: var(--bg); overflow: hidden;
  transition: border-left-color .15s, transform .15s;
}
.deal-card:nth-child(2n) { border-left-color: var(--gold); }
.deal-card:hover { transform: translateY(-2px); }
.deal-card:focus-visible { outline: 2px solid var(--navy); outline-offset: 2px; }

.deal-shot {
  position: relative; line-height: 0;
  background: var(--bg-alt); border-bottom: 1px solid var(--line-soft);
}
.deal-shot img {
  display: block; width: 100%; height: auto;
  aspect-ratio: 3 / 2; object-fit: cover;
}
.deal-shot.is-empty {
  aspect-ratio: 3 / 2; display: flex; align-items: center; justify-content: center;
  line-height: 1.4; font-size: .66rem; font-weight: 700; letter-spacing: .15em;
  text-transform: uppercase; color: var(--muted);
}
.deal-price {
  position: absolute; left: 12px; bottom: 12px;
  background: var(--navy); color: #fff;
  font-size: .96rem; font-weight: 700; letter-spacing: -.01em; line-height: 1.25;
  padding: 6px 11px; border-radius: var(--radius);
  font-variant-numeric: tabular-nums;
}

.deal-body { padding: 22px 22px 20px; }
.deal-card h3 { font-size: 1.04rem; margin-bottom: 6px; line-height: 1.3; }
.deal-desc { font-size: .94rem; color: var(--body); margin-bottom: 10px; }
.deal-meta { font-size: .85rem; color: var(--muted); margin: 0 0 14px; }

.deal-figs {
  display: flex; flex-wrap: wrap; margin: 0 0 16px;
  border-top: 1px solid var(--line-soft);
}
/* min-width: 0 matters — without it a flex item refuses to shrink below its
   nowrap figure and a long number widens the whole card. */
.deal-figs > div { flex: 1 1 82px; min-width: 0; padding-top: 12px; }
.deal-figs dt {
  font-size: .62rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 3px;
}
.deal-figs dd {
  margin: 0; font-size: .95rem; font-weight: 700; color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.deal-figs dd.is-spread { color: var(--gold); }

.deal-more {
  display: block;
  font-size: .7rem; font-weight: 700; letter-spacing: .13em;
  text-transform: uppercase; color: var(--navy);
}
.deal-card:hover .deal-more { color: var(--gold); }

/* Loading placeholders, same silhouette as a real card so nothing shifts. */
.deal-skeleton {
  border: 1px solid var(--line); border-left: 3px solid var(--line);
  border-radius: var(--radius); background: var(--bg); overflow: hidden;
}
.deal-skeleton .sk-shot { aspect-ratio: 3 / 2; background: var(--bg-alt); }
.deal-skeleton .sk-body { padding: 22px; }
.deal-skeleton .sk-line {
  height: 12px; border-radius: 2px; background: var(--line-soft); margin-bottom: 10px;
}
.deal-skeleton .sk-line.short { width: 55%; margin-bottom: 0; }
@media (prefers-reduced-motion: no-preference) {
  .deal-skeleton .sk-shot, .deal-skeleton .sk-line {
    animation: sk-pulse 1.4s ease-in-out infinite;
  }
}
@keyframes sk-pulse { 0%, 100% { opacity: 1 } 50% { opacity: .55 } }

/* ── Features ───────────────────────────────────────────── */

.feature-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 34px 48px;
}
.feature h3 {
  font-size: 1.06rem; margin-bottom: 9px;
  padding-left: 15px; border-left: 3px solid var(--gold);
}
.feature p { font-size: .98rem; margin: 0; padding-left: 18px; }

/* ── Path cards ─────────────────────────────────────────── */

.path-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }

.path-card {
  display: flex; flex-direction: column;
  padding: 34px 34px 30px; text-decoration: none;
  background: var(--bg-alt); border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .15s, border-color .15s, background .15s;
}
.path-card:hover {
  transform: translateY(-3px); border-color: #d3d9e1; background: #fff;
}
.path-eyebrow {
  font-size: .66rem; font-weight: 700; letter-spacing: .17em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 14px;
}
.path-card h3 { font-size: 1.36rem; letter-spacing: -.01em; margin-bottom: 9px; }
.path-card p { font-size: 1rem; color: var(--body); margin-bottom: 22px; }
.path-more {
  margin-top: auto;
  font-size: .73rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--navy);
}
.path-card:hover .path-more { color: var(--gold); }

/* ── Principles ─────────────────────────────────────────── */

.principles { background: var(--navy-deep); color: #fff; }
.principles-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px;
  padding-top: 52px; padding-bottom: 52px;
}
.principles h3 {
  color: var(--gold-lt); font-size: .8rem; letter-spacing: .15em;
  text-transform: uppercase; margin-bottom: 8px;
}
.principles p { color: rgba(255,255,255,.72); font-size: .95rem; margin: 0; }

/* ── Contact ────────────────────────────────────────────── */

.contact-cols { grid-template-columns: .9fr 1.1fr; }

.contact-line {
  display: flex; gap: 16px; align-items: baseline;
  padding: 14px 0; margin: 0; border-bottom: 1px solid var(--line-soft);
  font-size: 1rem; color: var(--ink);
}
.contact-label {
  flex: 0 0 108px;
  font-size: .68rem; font-weight: 700; letter-spacing: .15em;
  text-transform: uppercase; color: var(--muted);
}

.form {
  background: var(--bg-alt); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 32px;
}
.field { margin-bottom: 18px; }
.field label {
  display: block; margin-bottom: 7px;
  font-size: .7rem; font-weight: 700; letter-spacing: .13em;
  text-transform: uppercase; color: var(--muted);
}
/* Paired short fields. Collapses to one column on the phone breakpoint. */
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px;
  font-family: inherit; font-size: .98rem; color: var(--ink);
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color .15s;
}
.field textarea { resize: vertical; line-height: 1.55; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--navy); outline: none;
  box-shadow: 0 0 0 3px rgba(22,41,74,.09);
}

.hp { position: absolute; left: -9999px; }
.contact-intro { margin-bottom: 26px; }

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

.site-footer {
  background: var(--navy-deep); color: rgba(255,255,255,.6);
  padding: 44px 0; font-size: .84rem;
}
.footer-inner {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 40px;
}
/* Knockout version: the navy mark would disappear against the footer. */
.footer-logo { display: block; height: 38px; width: auto; margin: 0 0 12px; }
.footer-meta { margin: 0 0 16px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-nav a {
  color: rgba(255,255,255,.72); text-decoration: none;
  font-size: .78rem; font-weight: 600; letter-spacing: .09em; text-transform: uppercase;
}
.footer-nav a:hover { color: var(--gold-lt); }
.disclaimer { max-width: 54ch; text-align: right; margin: 0; line-height: 1.6; }

/* ── Responsive ─────────────────────────────────────────── */

@media (max-width: 960px) {
  .two-col, .contact-cols { grid-template-columns: 1fr; gap: 34px; }
  /* .deals-grid is deliberately absent. It sizes itself with auto-fill. */
  .steps, .principles-grid { grid-template-columns: repeat(2, 1fr); }
  .trust-grid { grid-template-columns: repeat(2, 1fr); gap: 22px 24px; }
  .feature-grid { gap: 30px 36px; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .wrap { padding: 0 20px; }
  html { scroll-padding-top: 80px; }
  .header-inner { min-height: 66px; }
  .wordmark-logo { height: 36px; }
  .footer-logo { height: 32px; }

  .nav-toggle { display: block; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 8px 20px 20px;
  }
  .nav.open { display: flex; }
  .nav a { padding: 14px 0; border-bottom: 1px solid var(--line-soft); }
  .nav .nav-cta { text-align: center; margin-top: 14px; border-bottom: 0; }

  .hero { padding: 46px 0 58px; }
  .hero-tight { padding-bottom: 34px; }
  .page-hero { padding: 54px 0 46px; }
  .section { padding: 62px 0; }
  .section-deals { padding-top: 40px; }
  .cta-row .btn { flex: 1 1 100%; text-align: center; }

  .feature-grid, .path-cards { grid-template-columns: 1fr; }
  .feature-grid { gap: 28px; }
  .path-card { padding: 28px 26px 24px; }

  .footer-inner { flex-direction: column; }
  .disclaimer { text-align: left; }

  .deals-cta { flex-direction: column; align-items: stretch; gap: 24px; padding: 28px 24px; }
  .deals-cta .btn { text-align: center; }
}

@media (max-width: 520px) {
  .steps, .principles-grid { grid-template-columns: 1fr; }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .form { padding: 24px 20px; }
  .field-row { grid-template-columns: 1fr; }
  .contact-line { flex-direction: column; gap: 3px; }
}

@media print {
  .site-header, .nav, .cta-row, .form { display: none; }
  .section { padding: 24px 0; }
}
