/* ============================================================
   OLIVER CROWE — style.css
   ============================================================ */

/* ---------- Reset & Base ----------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink:       #1a1a18;
  --ink-soft:  #5a5a55;
  --paper:     #f8f6f1;
  --rule:      #dedad2;
  --accent:    #2e4a3e;
  --accent-lt: #e8efe9;
  --serif:     'Cormorant Garamond', Georgia, serif;
  --sans:      'Inter', system-ui, sans-serif;
  --max-w:     1100px;
  --gutter:    clamp(1.25rem, 5vw, 3rem);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section-padded { padding-block: clamp(3rem, 8vw, 6rem); }

/* ---------- Header ----------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--ink);
}

.site-nav {
  display: flex;
  gap: 2rem;
}

.site-nav a {
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color 0.2s;
}

.site-nav a:hover {
  color: var(--ink);
  text-decoration: none;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--ink);
}

/* ---------- Hero ------------------------------------------- */
.hero {
  min-height: 82vh;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--rule);
  position: relative;
  overflow: hidden;
  background-image: url('../images/Nasa.jpg');
  background-size: cover;
  background-position: center 30%;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

.hero::before {
  content: '';
  position: absolute;
  left: var(--gutter);
  top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--accent) 30%, var(--accent) 70%, transparent);
  opacity: 0.25;
}

.hero-inner {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: calc(var(--gutter) + 1.5rem);
  padding-block: 4rem;
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  margin-bottom: 1.25rem;
}

.hero-headline {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(3.5rem, 10vw, 7rem);
  font-weight: 300;
  line-height: 1.05;
  color: white;
  margin-bottom: 1.75rem;
  text-shadow: 0 2px 20px rgba(0,0,0,0.8);
}

.hero-headline em {
  font-style: italic;
  color: rgba(255,255,255,0.9);
}

.hero-sub {
  font-size: clamp(0.95rem, 1.5vw, 1.1rem);
  color: rgba(255,255,255,0.85);
  font-family: 'Space Grotesk', sans-serif;
  max-width: 540px;
  line-height: 1.7;
}

/* ---------- Reading Section -------------------------------- */
.recently {
  background: var(--accent-lt);
  border-block: 1px solid var(--rule);
}

.section-label {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 400;
  margin-bottom: 0.5rem;
}

.recently-sub {
  font-size: 0.88rem;
  color: var(--ink-soft);
  margin-bottom: 2rem;
}

/* ---------- Book Shelf ------------------------------------ */
.book-shelf {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 2rem;
}

.book {
  display: flex;
  width: 120px;
  height: 160px;
  border-radius: 2px 6px 6px 2px;
  box-shadow: -4px 4px 12px rgba(0,0,0,0.2);
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
}

.book:hover {
  transform: translateY(-6px) rotate(1deg);
  box-shadow: -6px 10px 20px rgba(0,0,0,0.25);
  text-decoration: none;
}

.book-spine {
  width: 18px;
  background: var(--accent);
  border-radius: 2px 0 0 2px;
  flex-shrink: 0;
  opacity: 0.8;
}

.book-cover {
  flex: 1;
  background: var(--accent-lt);
  border: 1px solid var(--rule);
  border-left: none;
  border-radius: 0 6px 6px 0;
  padding: 0.75rem 0.6rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.book-cover .book-title {
  font-family: var(--serif);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
  margin-bottom: 0.35rem;
}

.book-cover .book-author {
  font-size: 0.68rem;
  color: var(--ink-soft);
}

/* ---------- Cards ------------------------------------------ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0;
}

.card {
  padding: 2.5rem;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.card:nth-child(1) { border-left: 1px solid var(--rule); }

@media (max-width: 780px) {
  .cards-grid { grid-template-columns: 1fr; }
  .card { border: none; border-bottom: 1px solid var(--rule); padding-inline: 0; }
  .card:nth-child(1) { border-left: none; }
}

.card-number {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.card h3 {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 400;
  margin-bottom: 0.85rem;
}

.card p {
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.card-link {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
  transition: opacity 0.2s;
}

.card-link:hover { opacity: 0.7; text-decoration: none; }

/* ---------- Footer ----------------------------------------- */
.site-footer {
  border-top: 1px solid var(--rule);
  padding-block: 2rem;
}

.footer-inner {
  display: flex;
  justify-content: center;
  font-size: 0.8rem;
  color: var(--ink-soft);
}

/* ---------- Inner Pages ------------------------------------ */
.page-hero {
  padding-block: 4rem 2rem;
  border-bottom: 1px solid var(--rule);
}

.page-hero h1 {
  font-family: var(--serif);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 300;
}

.page-hero .page-sub {
  font-size: 1rem;
  color: var(--ink-soft);
  max-width: 520px;
  margin-top: 0.75rem;
}

.page-content {
  padding-block: 3rem 5rem;
}

.page-content p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--ink);
  max-width: 660px;
  margin-bottom: 1.25rem;
}

/* ---------- Mobile Nav ------------------------------------- */
@media (max-width: 600px) {
  .site-nav { display: none; flex-direction: column; gap: 0; }
  .site-nav.open {
    display: flex;
    position: absolute;
    top: 56px;
    left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    padding: 1rem var(--gutter) 1.5rem;
  }
  .site-nav a { padding-block: 0.5rem; font-size: 0.9rem; }
  .nav-toggle { display: block; }
  .site-header { position: relative; }
  .hero-inner { padding-inline: var(--gutter); }
  .hero::before { display: none; }
}