:root {
  color-scheme: light;
  --background: #ffffff;
  --surface: #fbfcfe;
  --surface-strong: #f4f7fb;
  --ink: #0d1117;
  --muted: #5b6472;
  --faint: #8a94a5;
  --line: #dce3ed;
  --line-strong: #c5d0dd;
  --shadow: 0 18px 55px rgba(11, 20, 34, 0.12);
  --soft-shadow: 0 10px 30px rgba(11, 20, 34, 0.08);
  --cyan: #06b6d4;
  --blue: #1f6feb;
  --green: #26a269;
  --orange: #f97316;
  --navy: #0d1642;
  --gold: #d7a94f;
  --radius: 8px;
  --max-width: 1160px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(90deg, rgba(13, 17, 23, 0.035) 1px, transparent 1px) 0 0 / 72px 72px,
    linear-gradient(180deg, rgba(13, 17, 23, 0.035) 1px, transparent 1px) 0 0 / 72px 72px,
    var(--background);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  min-width: 320px;
}

img,
svg {
  display: block;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 18px;
  top: 18px;
  z-index: 100;
  transform: translateY(-160%);
  background: var(--ink);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 700;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  width: min(var(--max-width), calc(100% - 32px));
  margin: 18px auto 0;
  min-height: 58px;
  padding: 8px 8px 8px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(197, 208, 221, 0.85);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 34px rgba(13, 17, 23, 0.08);
}

.brand-link,
.nav-links,
.hero-actions,
.link-row,
.title-row,
.site-footer {
  display: flex;
  align-items: center;
}

.brand-link {
  gap: 10px;
  min-width: 0;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 0.95rem;
}

.brand-link img {
  width: 40px;
  height: 40px;
  border-radius: 7px;
  object-fit: cover;
  border: 1px solid var(--line);
}

.nav-links {
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  min-height: 40px;
  padding: 10px 12px;
  border-radius: 7px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 750;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: var(--surface-strong);
  color: var(--ink);
}

main {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
}

.hero {
  min-height: min(540px, calc(100svh - 158px));
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.82fr);
  align-items: center;
  gap: clamp(34px, 6vw, 82px);
  padding: clamp(28px, 5vw, 58px) 0 clamp(20px, 4vw, 42px);
}

.hero-copy {
  max-width: 650px;
}

.hero-headshot {
  width: clamp(92px, 10vw, 118px);
  height: clamp(92px, 10vw, 118px);
  border-radius: var(--radius);
  object-fit: cover;
  border: 1px solid var(--line);
  box-shadow: var(--soft-shadow);
  margin-bottom: clamp(20px, 3vw, 30px);
}

h1,
h2,
h3,
p {
  margin-block: 0;
}

h1 {
  max-width: 13ch;
  font-size: clamp(3.75rem, 8.6vw, 6.35rem);
  line-height: 0.88;
  font-weight: 900;
  letter-spacing: 0;
}

.hero-copy > p {
  max-width: 570px;
  margin-top: 22px;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.8vw, 1.35rem);
  line-height: 1.55;
}

.hero-actions {
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 11px 15px;
  border: 1px solid transparent;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 800;
  line-height: 1;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

.button-dark {
  background: var(--ink);
  color: #ffffff;
  box-shadow: 0 10px 22px rgba(13, 17, 23, 0.16);
}

.button-light {
  background: #ffffff;
  color: var(--ink);
  border-color: var(--line-strong);
}

.button-icon {
  width: 18px;
  height: 18px;
}

.button-icon svg,
.external-icon::before {
  width: 100%;
  height: 100%;
}

.button-icon svg {
  fill: currentColor;
}

.external-icon {
  width: 14px;
  height: 14px;
  position: relative;
  flex: 0 0 auto;
}

.external-icon::before {
  content: "";
  display: block;
  background: currentColor;
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14 3h7v7h-2V6.41l-9.29 9.3-1.42-1.42 9.3-9.29H14V3ZM5 5h6v2H7v10h10v-4h2v6H5V5Z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hero-shelf {
  min-height: 470px;
  position: relative;
  display: grid;
  place-items: center;
}

.hero-shelf::before {
  content: "";
  position: absolute;
  inset: 18% 0 16% 10%;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(6, 182, 212, 0.12), transparent 40%),
    linear-gradient(315deg, rgba(249, 115, 22, 0.12), transparent 42%),
    #ffffff;
  border-radius: var(--radius);
  box-shadow: var(--soft-shadow);
  transform: rotate(-2deg);
}

.shelf-card {
  position: absolute;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid rgba(197, 208, 221, 0.9);
  background: #ffffff;
  box-shadow: var(--shadow);
}

.shelf-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shelf-card-tall {
  width: min(42%, 220px);
  aspect-ratio: 720 / 1280;
  left: 2%;
  top: 12%;
  transform: rotate(-7deg);
}

.shelf-card-square {
  width: min(56%, 310px);
  aspect-ratio: 1;
  right: 3%;
  top: 22%;
  transform: rotate(4deg);
  z-index: 2;
}

.shelf-card-offset {
  left: auto;
  right: 18%;
  top: auto;
  bottom: 6%;
  transform: rotate(7deg);
  z-index: 3;
}

.work-section {
  padding: clamp(54px, 8vw, 96px) 0;
  border-top: 1px solid var(--line);
}

.section-heading {
  display: grid;
  grid-template-columns: 70px minmax(0, 0.72fr) minmax(240px, 0.62fr);
  gap: 22px;
  align-items: end;
  margin-bottom: 28px;
}

.section-count {
  color: var(--faint);
  font-size: 0.8rem;
  font-weight: 850;
}

h2 {
  font-size: clamp(2.5rem, 7vw, 5.4rem);
  line-height: 0.92;
  font-weight: 900;
  letter-spacing: 0;
}

.section-heading > p:last-child {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.work-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 34px rgba(13, 17, 23, 0.06);
}

.app-card {
  min-height: 640px;
  display: grid;
  grid-template-rows: auto minmax(260px, 1fr);
}

.app-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: var(--accent, var(--cyan));
}

.work-copy {
  position: relative;
  z-index: 1;
  padding: clamp(20px, 3vw, 28px);
}

.title-row {
  gap: 13px;
  margin-bottom: 18px;
}

.title-row img {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  border: 1px solid var(--line);
  object-fit: cover;
  box-shadow: 0 8px 18px rgba(13, 17, 23, 0.12);
}

h3 {
  font-size: clamp(1.35rem, 2vw, 1.75rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 0;
}

.meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 760;
}

.work-copy > p:not(.meta) {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.62;
}

.link-row {
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 22px;
}

.media-link {
  align-self: end;
  width: min(76%, 265px);
  margin: 0 auto -60px;
  display: block;
  border-radius: 8px 8px 0 0;
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(13, 17, 23, 0.16);
  transform: translateY(0);
  transition: transform 220ms ease;
}

.media-link:hover,
.media-link:focus-visible {
  transform: translateY(-5px);
}

.media-link img {
  width: 100%;
  aspect-ratio: 720 / 1280;
  object-fit: cover;
}

.accent-audolio {
  --accent: linear-gradient(90deg, #10c7e8, #2445ff, #e04cf5);
}

.accent-airman {
  --accent: linear-gradient(90deg, #2563eb, #ef4444, #16a34a);
}

.accent-accountability {
  --accent: linear-gradient(90deg, #2f5cff, #ffb000, #20bf55);
}

.books-section {
  padding-bottom: clamp(58px, 8vw, 104px);
}

.book-card {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1fr);
  align-items: stretch;
  background:
    linear-gradient(135deg, rgba(13, 22, 66, 0.04), rgba(215, 169, 79, 0.1)),
    #ffffff;
}

.book-media {
  min-height: 520px;
  padding: clamp(20px, 4vw, 34px);
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 0.58fr);
  gap: 14px;
  align-items: center;
  background: var(--navy);
}

.book-media a {
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: 0 22px 45px rgba(0, 0, 0, 0.28);
  transition: transform 220ms ease;
}

.book-media a:hover,
.book-media a:focus-visible {
  transform: translateY(-4px);
}

.book-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-media a:first-child {
  aspect-ratio: 1;
}

.book-media a:last-child {
  aspect-ratio: 1080 / 1920;
}

.book-card .work-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.book-card h3 {
  font-size: clamp(2rem, 5vw, 4.8rem);
  line-height: 0.95;
}

.book-links {
  display: grid;
  gap: 9px;
  margin-top: 28px;
}

.book-links a {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
  font-weight: 820;
  box-shadow: 0 8px 18px rgba(13, 17, 23, 0.05);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.book-links a:hover,
.book-links a:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  box-shadow: 0 12px 25px rgba(13, 17, 23, 0.08);
}

.connect-section {
  margin-bottom: 22px;
  padding: clamp(28px, 5vw, 42px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(90deg, rgba(6, 182, 212, 0.1), transparent 40%),
    linear-gradient(270deg, rgba(38, 162, 105, 0.12), transparent 35%),
    #ffffff;
}

.connect-section h2 {
  font-size: clamp(2.3rem, 5vw, 4.2rem);
}

.connect-section p:not(.section-count) {
  margin-top: 8px;
  color: var(--muted);
}

.site-footer {
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 34px;
  justify-content: space-between;
  gap: 16px;
  color: var(--faint);
  font-size: 0.9rem;
  font-weight: 760;
}

@media (max-width: 960px) {
  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-top: 62px;
  }

  .hero-copy {
    max-width: 760px;
  }

  h1 {
    max-width: 12ch;
  }

  .hero-shelf {
    min-height: 430px;
  }

  .section-heading {
    grid-template-columns: 52px 1fr;
    align-items: start;
  }

  .section-heading > p:last-child {
    grid-column: 2;
  }

  .app-grid {
    grid-template-columns: 1fr;
  }

  .app-card {
    min-height: 500px;
    grid-template-columns: minmax(0, 1fr) minmax(190px, 0.52fr);
    grid-template-rows: auto;
  }

  .media-link {
    width: min(78%, 235px);
    margin: auto auto -42px;
  }

  .book-card {
    grid-template-columns: 1fr;
  }

  .book-media {
    min-height: auto;
  }
}

@media (max-width: 700px) {
  body {
    background-size: 52px 52px;
  }

  .site-header {
    width: calc(100% - 20px);
    margin-top: 10px;
    align-items: flex-start;
  }

  .brand-link span {
    display: none;
  }

  .nav-links a {
    min-height: 36px;
    padding: 8px 9px;
    font-size: 0.84rem;
  }

  main,
  .site-footer {
    width: calc(100% - 24px);
  }

  .hero {
    padding-top: 50px;
    gap: 28px;
  }

  .hero-copy > p {
    margin-top: 22px;
  }

  .hero-actions,
  .link-row {
    align-items: stretch;
  }

  .button {
    flex: 1 1 auto;
  }

  .hero-shelf {
    min-height: 350px;
  }

  .hero-shelf::before {
    inset: 14% 3% 14% 3%;
  }

  .shelf-card-tall {
    width: min(37%, 150px);
    left: 4%;
  }

  .shelf-card-square {
    width: min(54%, 220px);
  }

  .shelf-card-offset {
    right: 11%;
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .section-heading > p:last-child {
    grid-column: auto;
  }

  .app-card {
    min-height: 0;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
  }

  .media-link {
    width: min(66%, 230px);
    margin: 8px auto -54px;
  }

  .app-card {
    padding-bottom: 54px;
  }

  .work-copy {
    padding: 22px;
  }

  .book-media {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.56fr);
    padding: 18px;
  }

  .connect-section,
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 430px) {
  .nav-links {
    max-width: 230px;
  }

  .book-media {
    grid-template-columns: 1fr;
  }

  .book-media a:last-child {
    max-width: 58%;
    justify-self: end;
    margin-top: -34px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
