/* Programming Practice Cycle */
:root {
  --green-950: #102f25;
  --green-900: #153f31;
  --green-700: #1f5b45;
  --green-100: #e7f1ec;
  --gold-500: #c99a2e;
  --gold-300: #f0d279;
  --gold-100: #faf3de;
  --blue-700: #285f9f;
  --blue-100: #e9f1fa;
  --plum-700: #73405f;
  --plum-100: #f6eaf1;
  --rust-700: #994835;
  --rust-100: #faece7;
  --ink: #1f2933;
  --muted: #5b6872;
  --paper: #fff;
  --soft: #f5f8f6;
  --line: #d8e2dc;
  --shadow: 0 20px 55px rgba(16, 47, 37, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--soft);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.62;
}
a { color: inherit; }
.skip-link {
  position: fixed;
  z-index: 1000;
  top: 10px;
  left: 10px;
  padding: 10px 14px;
  background: #fff;
  color: var(--green-950);
  border-radius: 8px;
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px max(22px, calc((100vw - 1200px) / 2));
  background: rgba(255, 255, 255, .94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  line-height: 1.08;
}
.brand-mark {
  display: grid;
  width: 47px;
  height: 47px;
  place-items: center;
  border-radius: 14px;
  background: var(--green-900);
  color: var(--gold-300);
  font-size: .93rem;
  font-weight: 900;
  box-shadow: 0 8px 22px rgba(16, 47, 37, .18);
}
.brand strong { display: block; font-size: 1rem; }
.brand small {
  display: block;
  margin-top: 5px;
  color: var(--green-700);
  font-size: .72rem;
  font-weight: 850;
  letter-spacing: .09em;
  text-transform: uppercase;
}
nav { display: flex; gap: 24px; }
nav a { color: var(--ink); font-size: .92rem; font-weight: 800; text-decoration: none; }
nav a:hover { color: var(--green-700); }

.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 60px;
  align-items: center;
  min-height: 630px;
  padding: 90px max(24px, calc((100vw - 1200px) / 2));
  background:
    radial-gradient(circle at 84% 15%, rgba(240, 210, 121, .22), transparent 24%),
    linear-gradient(138deg, var(--green-950), var(--green-700));
  color: #fff;
}
.hero::after {
  position: absolute;
  right: -100px;
  bottom: -190px;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 50%;
  content: "";
}
.hero-copy, .cycle-map { position: relative; z-index: 1; }
.eyebrow {
  margin: 0 0 10px;
  color: var(--gold-300);
  font-size: .8rem;
  font-weight: 900;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.eyebrow.dark { color: var(--green-700); }
h1 {
  max-width: 760px;
  margin: 0;
  letter-spacing: -.055em;
}
.hero-title-main, .hero-title-sub { display: block; }
.hero-title-main {
  white-space: nowrap;
  font-size: clamp(3.4rem, 7vw, 6.5rem);
  line-height: .9;
}
.hero-title-sub {
  margin-top: 12px;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1;
  letter-spacing: -.04em;
}
.hero-quote {
  max-width: 650px;
  margin: 22px 0 0;
  color: var(--gold-300);
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  line-height: 1.18;
  letter-spacing: -.02em;
}
.hero-lead { max-width: 750px; margin: 24px 0 0; color: rgba(255, 255, 255, .89); font-size: 1.16rem; }
.hero-actions, .start-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 19px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 850;
  text-decoration: none;
  transition: transform .18s ease, background .18s ease;
}
.button:hover { transform: translateY(-2px); }
.button.primary { background: var(--gold-500); color: #17231d; }
.button.primary:hover { background: #d8aa43; }
.button.secondary { border-color: rgba(255, 255, 255, .38); background: rgba(255, 255, 255, .08); color: #fff; }
.button.secondary:hover { background: rgba(255, 255, 255, .16); }
.button.light { background: #fff; color: var(--green-950); }

.cycle-map {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 9px 12px;
  align-items: center;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, .19);
  border-radius: 28px;
  background: rgba(255, 255, 255, .10);
  box-shadow: 0 28px 80px rgba(0, 0, 0, .20);
  backdrop-filter: blur(8px);
}
.map-step {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 0 13px;
  align-items: center;
  min-height: 82px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .94);
  color: var(--ink);
}
.map-step span {
  grid-row: 1 / 3;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  background: var(--green-100);
  color: var(--green-900);
  font-weight: 900;
}
.map-step strong { align-self: end; font-size: 1.12rem; }
.map-step small { align-self: start; color: var(--muted); }
.map-step.rebuild span { background: var(--gold-100); color: #78550c; }
.map-step.trace span { background: var(--blue-100); color: var(--blue-700); }
.map-step.code span { background: var(--plum-100); color: var(--plum-700); }
.map-arrow { color: var(--gold-300); font-size: 1.45rem; font-weight: 900; transform: rotate(90deg); }

.cycle-section, .research-section, .courses-section {
  padding: 90px max(24px, calc((100vw - 1200px) / 2));
  scroll-margin-top: 80px;
}
.section-heading { max-width: 880px; margin-bottom: 42px; }
h2 { margin: 0; font-size: clamp(2.2rem, 4vw, 3.5rem); line-height: 1.08; letter-spacing: -.04em; }
.section-heading > p:last-child { color: var(--muted); font-size: 1.08rem; }
.practice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.practice-card {
  --accent: var(--green-700);
  --tint: var(--green-100);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 460px;
  padding: 30px;
  border: 1px solid var(--line);
  border-top: 5px solid var(--accent);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 35px rgba(16, 47, 37, .07);
}
.practice-card::after {
  position: absolute;
  right: -50px;
  top: -60px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  background: var(--tint);
  content: "";
  opacity: .8;
}
.rebuild-card { --accent: var(--gold-500); --tint: var(--gold-100); }
.trace-card { --accent: var(--blue-700); --tint: var(--blue-100); }
.code-card { --accent: var(--plum-700); --tint: var(--plum-100); }
.card-topline { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.number {
  display: grid;
  width: 47px;
  height: 47px;
  place-items: center;
  border-radius: 14px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
}
.skill-label { color: var(--accent); font-size: .78rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.practice-card h3 { margin: 22px 0 7px; font-size: 2rem; letter-spacing: -.03em; }
.practice-card p { color: var(--muted); }
.practice-card ul { margin: 8px 0 24px; padding-left: 1.2rem; }
.practice-card li { margin: 6px 0; }
.card-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: auto;
  padding: 14px 17px;
  border-radius: 13px;
  background: var(--accent);
  color: #fff;
  font-weight: 850;
  text-decoration: none;
}
.card-button:hover span { transform: translateX(4px); }
.card-button span { transition: transform .18s ease; }
.code-note { margin-top: auto; padding: 15px 17px; border-radius: 13px; background: var(--tint); color: var(--ink) !important; }

.connection-section {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 64px;
  align-items: center;
  padding: 84px max(24px, calc((100vw - 1200px) / 2));
  background: var(--green-900);
  color: #fff;
}
.connection-copy h2 { max-width: 540px; }
.connection-copy > p:not(.eyebrow) { color: rgba(255, 255, 255, .78); }
.ai-rationale {
  margin-top: 28px;
  padding: 22px 24px;
  border: 1px solid rgba(240, 210, 121, .36);
  border-left: 5px solid var(--gold-300);
  border-radius: 16px;
  background: rgba(255, 255, 255, .08);
}
.ai-rationale-label {
  margin: 0 0 5px;
  color: var(--gold-300) !important;
  font-size: .76rem;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.ai-rationale h3 { margin: 0; font-size: 1.35rem; }
.ai-rationale p:last-child { margin-bottom: 0; color: rgba(255, 255, 255, .82); }
.connection-example { display: grid; gap: 10px; }
.connection-example p { margin: 0; padding: 17px 20px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 14px; background: rgba(255, 255, 255, .08); }
.connection-example span { display: inline-block; width: 88px; color: var(--gold-300); font-weight: 900; }

.research-section { background: #fff; }
.research-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.research-grid article { padding: 28px; border: 1px solid var(--line); border-radius: 20px; background: var(--soft); }
.research-number { color: var(--gold-500); font-size: .8rem; font-weight: 900; letter-spacing: .1em; }
.research-grid h3 { margin: 12px 0 10px; font-size: 1.35rem; }
.research-grid p { color: var(--muted); }
.research-grid a, .course-grid a { color: var(--green-700); font-weight: 850; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.research-caution { margin: 28px 0 0; padding: 18px 21px; border-left: 4px solid var(--gold-500); background: var(--gold-100); }

.course-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.course-grid article { padding: 34px; border-radius: 23px; background: #fff; box-shadow: var(--shadow); }
.course-grid h3 { margin: 7px 0; font-size: 1.75rem; }
.course-grid p:not(.course-tag) { color: var(--muted); }
.course-tag { margin: 0; color: var(--green-700); font-size: .78rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }

.start-section { padding: 72px 24px; text-align: center; background: linear-gradient(135deg, var(--plum-700), var(--rust-700)); color: #fff; }
.start-section h2 { max-width: 780px; margin: 0 auto; }
.start-section .start-actions { justify-content: center; }
footer { display: flex; justify-content: space-between; gap: 24px; padding: 28px max(24px, calc((100vw - 1200px) / 2)); background: var(--green-950); color: rgba(255, 255, 255, .75); font-size: .9rem; }
footer p { margin: 0; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .cycle-map { max-width: 600px; }
  .research-grid { grid-template-columns: 1fr; }
  .connection-section { grid-template-columns: 1fr; gap: 34px; }
}

@media (max-width: 680px) {
  .site-header { align-items: flex-start; }
  .site-header nav { display: none; }
  .hero { padding-top: 70px; padding-bottom: 70px; }
  .practice-grid, .course-grid { grid-template-columns: 1fr; }
  .practice-card { min-height: auto; }
  .cycle-section, .research-section, .courses-section { padding-top: 68px; padding-bottom: 68px; }
  footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
