/* ═══════════════════════════════════════════
   HOME PAGE STYLES — index.html only
   Shared base styles: styles.css
═══════════════════════════════════════════ */

/* WIDER CONTAINER FOR LANDING */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* HEADER */
header {
  display: flex;
}

/* STICKY NAVIGATION */
.section-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
  padding: 0.8rem 0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.nav-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.nav-logo {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-size: 1.2rem;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.nav-logo span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links li {
  margin: 0;
}

.nav-link {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  border-radius: 30px;
  transition: all 0.2s ease;
  white-space: nowrap;
  font-family: "Source Sans Pro", sans-serif;
}

.nav-link:hover {
  background: var(--cream);
  color: var(--ink);
}

.nav-link.active {
  background: var(--ink);
  color: var(--paper);
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* Accounts for sticky nav */
}

/* SERIES INTRO */
.series-intro {
  text-align: center;
  margin-bottom: 3.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}
.series-intro .kicker {
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1rem;
  display: block;
}
.series-intro h2 {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-size: 2.6rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.series-intro p {
  max-width: 600px;
  margin: 0 auto;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.8;
}

/* PRINCIPLE STRIP */
.principle-strip {
  background: linear-gradient(135deg, var(--ink) 0%, #2a2a2a 100%);
  border-radius: 16px;
  padding: 2rem 2.5rem;
  color: var(--paper);
  display: flex;
  align-items: center;
  gap: 3rem;
  margin-bottom: 3rem;
  position: relative;
  overflow: hidden;
  flex-wrap: wrap;
}
.principle-strip::before {
  content: "CTAC";
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-family: "Fraunces", serif;
  font-size: 6rem;
  font-weight: 600;
  color: rgba(232, 200, 154, 0.05);
  pointer-events: none;
  line-height: 1;
}
.ps-quote {
  flex: 1;
  min-width: 220px;
}
.ps-quote blockquote {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.55;
  color: var(--paper);
}
.ps-quote blockquote + blockquote {
  margin-top: 1.2rem;
}
.ps-quote small {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.6rem;
  color: var(--muted);
}

/* SECTION STYLES */
.section-container {
  margin-bottom: 3rem;
  scroll-margin-top: 80px;
}

.section-header {
  display: flex;
  align-items: flex-start;
  gap: 1.2rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--border);
}

.section-number {
  background: var(--ink);
  color: var(--paper);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 0.4rem 0.8rem;
  border-radius: 3px;
  flex-shrink: 0;
  margin-top: 2px;
}

.section-header h3 {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-size: 1.8rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 0.3rem;
}

.section-header h3 span {
  color: var(--accent);
}

.section-description {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.6;
  max-width: 500px;
}

/* NOTES GRID */
.notes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.8rem;
  margin-bottom: 2rem;
  counter-reset: card;
}

/* NOTE CARD */
.note-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  position: relative;
  transition:
    transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1),
    border-color 0.25s;
}
.note-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  border-color: var(--ink);
}

/* Card top colour bands — semantic names */
.card-band {
  height: 6px;
}
.band-principles {
  background: linear-gradient(90deg, #c9a227, #e8c89a, #c0392b);
}
.band-history {
  background: linear-gradient(90deg, #c0392b, #e8c89a, #1a5276);
}
.band-language {
  background: linear-gradient(90deg, #1a5276, #7a5c00, #1a5276);
}
.band-exam {
  background: linear-gradient(90deg, #c0392b, #e8c89a, #c0392b);
}
.band-reasoning {
  background: linear-gradient(90deg, #1a5276, #2c7a4b, #1a5276);
}
.band-mechanism {
  background: linear-gradient(90deg, #2c7a4b, #1a5276, #2c7a4b);
}
.band-management {
  background: linear-gradient(90deg, #1a5276, #c0392b, #1a5276);
}
.band-path {
  background: linear-gradient(90deg, #c0392b, #1a5276, #c0392b);
}

/* Card header — counter increments here */
.card-head {
  background: var(--cream);
  padding: 1.6rem 1.8rem 1.4rem;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  counter-increment: card;
}
.card-head::after {
  content: counter(card, decimal-leading-zero);
  position: absolute;
  right: 1rem;
  bottom: -1rem;
  font-family: "Fraunces", serif;
  font-size: 5rem;
  font-weight: 600;
  color: rgba(26, 26, 26, 0.04);
  pointer-events: none;
  line-height: 1;
}
.card-head h3 {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-size: 1.55rem;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.card-head h3 span {
  color: var(--accent);
}
.card-subtitle {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.4rem;
  letter-spacing: 0.04em;
  line-height: 1.5;
}

/* Card body */
.card-body {
  padding: 1.4rem 1.8rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.card-description {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.75;
}

/* COMING SOON */
.coming-soon-label {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 3rem 0 1.2rem;
}
.coming-soon-label .cs-line {
  flex: 1;
  height: 1px;
  background: var(--border);
}
.coming-soon-label span {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}
.coming-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
.coming-card {
  background: var(--cream);
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 1.4rem;
  opacity: 0.65;
}
.coming-card h4 {
  font-family: "Fraunces", serif;
  font-weight: 300;
  font-size: 1rem;
  margin-bottom: 0.4rem;
  color: var(--ink);
}
.coming-card p {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.6;
}
.coming-badge {
  display: inline-block;
  margin-top: 0.8rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--cream);
  border: 1px solid var(--border);
  color: var(--muted);
  padding: 0.2rem 0.6rem;
  border-radius: 30px;
}

/* ===== RESPONSIVE STYLES ===== */

/* Tablets and small desktops */
@media (max-width: 900px) {
  .container {
    padding: 0 1.5rem;
  }

  .section-header h3 {
    font-size: 1.6rem;
  }

  .nav-container {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-links {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    -webkit-overflow-scrolling: touch;
  }

  .nav-links::-webkit-scrollbar {
    height: 3px;
  }

  .nav-links::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
  }
}

/* Mobile landscape and tablets portrait */
@media (max-width: 750px) {
  .container {
    padding: 0 1.2rem;
  }

  .notes-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

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

  .principle-strip {
    gap: 1rem;
    padding: 1.5rem;
  }

  /* Header adjustments */
  header h1 {
    font-size: 2.2rem;
    line-height: 1.2;
  }

  .hero-tagline {
    flex-direction: column;
    gap: 0.5rem;
    align-items: center;
  }

  .hero-tagline span {
    display: block;
    text-align: center;
  }

  /* Section headers */
  .section-header {
    flex-direction: column;
    gap: 0.5rem;
  }

  .section-header h3 {
    font-size: 1.5rem;
  }

  .section-number {
    align-self: flex-start;
  }

  .section-description {
    font-size: 0.75rem;
  }

  /* Cards */
  .card-head {
    padding: 1.2rem 1.4rem;
  }

  .card-head h3 {
    font-size: 1.3rem;
  }

  .card-head::after {
    font-size: 4rem;
    right: 0.5rem;
    bottom: -0.5rem;
  }

  .card-body {
    padding: 1.2rem 1.4rem;
  }

  .card-description {
    font-size: 0.8rem;
  }

  .card-subtitle {
    font-size: 0.7rem;
  }

  /* Principle strip */
  .ps-quote blockquote {
    font-size: 1rem;
  }

  .ps-quote small {
    font-size: 0.7rem;
  }

  .principle-strip::before {
    font-size: 4rem;
    right: 0.5rem;
  }

  /* Series intro */
  .series-intro h2 {
    font-size: 2rem;
  }

  .series-intro p {
    font-size: 0.8rem;
    padding: 0 1rem;
  }

  /* Coming soon */
  .coming-card {
    padding: 1.2rem;
  }

  .coming-card h4 {
    font-size: 0.95rem;
  }

  .coming-card p {
    font-size: 0.7rem;
  }

  .coming-soon-label span {
    font-size: 0.55rem;
  }
}

/* Small mobile devices */
@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  header h1 {
    font-size: 1.8rem;
  }

  header p {
    font-size: 0.9rem;
  }

  .hero-tagline span {
    font-size: 0.7rem;
  }

  .series-intro h2 {
    font-size: 1.6rem;
  }

  .series-intro .kicker {
    font-size: 0.55rem;
  }

  .section-header h3 {
    font-size: 1.3rem;
  }

  .section-number {
    font-size: 0.6rem;
    padding: 0.3rem 0.6rem;
  }

  .card-head {
    padding: 1rem 1.2rem;
  }

  .card-head h3 {
    font-size: 1.2rem;
  }

  .card-head::after {
    font-size: 3.5rem;
  }

  .card-body {
    padding: 1rem 1.2rem;
  }

  .card-description {
    font-size: 0.75rem;
    line-height: 1.6;
  }

  .card-subtitle {
    font-size: 0.65rem;
  }

  .principle-strip {
    padding: 1.2rem;
  }

  .ps-quote blockquote {
    font-size: 0.9rem;
  }

  .coming-card {
    padding: 1rem;
  }

  footer p {
    font-size: 0.7rem;
  }
}

/* Handle very small devices */
@media (max-width: 360px) {
  .card-head h3 {
    font-size: 1.1rem;
  }

  .card-head::after {
    font-size: 3rem;
  }

  .series-intro h2 {
    font-size: 1.4rem;
  }
}
