/* Light and dark palettes; the page follows the visitor's system setting. */
:root {
  color-scheme: light dark;
  --bg: #fcfcfb;
  --card: #ffffff;
  --text: #1f1f1d;
  --muted: #6f6f69;
  --faint: #9a9a93;
  --rule: #e4e4df;
  --accent: #18453b;       /* buttons, badges, dots */
  --accent-ink: #ffffff;
  --link: #18453b;         /* link text (needs more contrast than the accent in dark mode) */
  --max: 640px;
  /* MSU Spartan green for the outcome badges (exact brand color) */
  --msu-green: #18453b;
  /* starting height only — the script measures the tallest quote on load
     and overrides this, so you never have to tune it by hand */
  --card-h: 220px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141513;
    --card: #1c1e1b;
    --text: #e6e6e1;
    --muted: #9d9d96;
    --faint: #74746e;
    --rule: #2c2d2a;
    --accent: #7fb3a0;
    --accent-ink: #141513;
    --link: #7fb3a0;
    /* true Spartan green vanishes on a dark card; this stays visibly
       MSU-green with enough contrast */
    --msu-green: #2e8b57;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
/* NOTE: no overflow-x: hidden here. It was needed when the strip ran
   full-bleed, but it also silently disables position: sticky (the
   strip's dock-to-bottom behavior on desktop). Nothing overflows the
   column anymore, so it's gone. */

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 64px 24px 88px; }

p { margin: 0 0 20px; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 2px; }

.label {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 12px; font-weight: 600; letter-spacing: .09em;
  text-transform: uppercase; color: var(--faint);
  margin: 0 0 20px; text-align: center;
}

/* ===== proof band ===== */

.proof {
  margin: 52px 0;
  padding: 34px 0 30px;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

/* Desktop: the company strip is a bordered band right under the TLDR.
   Phones: it moves to the very top of the page (see the mobile block).
   The testimonials band sits further down, after the booking button. */
.proof.proof-strip {
  margin: 40px 0 0;
  padding: 26px 0 28px;
  border-bottom: none;   /* the testimonials band's top border is the divider */
}
.proof.proof-quotes { margin-top: 0; padding-top: 26px; }
/* --- company marquee (never pauses) --- */

.marquee {
  /* Scrollable (with the scrollbar hidden) so people can swipe/flick
     through the strip themselves; the script auto-scrolls it the rest
     of the time. `clip` would forbid scrolling entirely. */
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
  /* same width as the reading column — the strip used to run edge to
     edge, but the owner prefers it aligned with the text */
  padding-block: 4px;
}
.marquee::-webkit-scrollbar { display: none; }
/* NOTE: no edge fade here on purpose. A -webkit-mask-image freezes the
   strip on iOS (masked containers break child animation), and gradient
   overlays half-dim each name as it passes the edge, which reads as
   broken text color. Names simply slide off the screen edge instead. */
.marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  /* NOTE: the strip is deliberately NOT moved with a CSS animation or
     transform. The track is ~3200px wide — past the size iOS Safari will
     animate as a GPU layer — so on real iPhones a CSS marquee renders
     frozen (or blank). The script scrolls .marquee instead. */
}
.logo {
  display: flex; align-items: center; gap: 12px;
  flex: none; padding: 0 34px; white-space: nowrap;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 21px; font-weight: 650; letter-spacing: -.005em;
  color: var(--text);
}
.logo img {
  height: 30px; width: 30px;
  object-fit: contain; flex: none;
  border-radius: 5px;
}

/* --- testimonial carousel (never pauses) --- */

.carousel { margin-top: 38px; }
/* `clip` (with `hidden` as the older-browser fallback) means the browser
   can't scroll this box to reveal something inside it — which is what was
   yanking the page around. See also the scroll guard in the script. */
.viewport { overflow: hidden; overflow: clip; height: var(--card-h); }
.track {
  display: flex;
  height: 100%;
  /* fallback duration — the script overrides it with SLIDE_MS from config.js */
  transition: transform 1.15s cubic-bezier(.65, 0, .35, 1);
}
.slide { flex: 0 0 100%; height: 100%; padding: 3px 4px 5px; }

.quote {
  height: 100%; margin: 0;
  display: flex; flex-direction: column;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 11px;
  padding: 18px 20px;
}
.quote p {
  margin: 0; flex: 1 1 auto; min-height: 0; overflow: hidden;
  font-size: 15.5px; line-height: 1.55;
}

.attrib {
  flex: none;
  margin-top: 13px; padding-top: 12px;
  border-top: 1px solid var(--rule);
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 12.5px; color: var(--muted);
}
.li-link {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 4px 10px 4px 8px;
  border: 1px solid var(--rule); border-radius: 999px;
  font-weight: 650; line-height: 1;
  color: var(--text); text-decoration: none;
  transition: border-color .15s, background .15s;
}
.li-link:hover { border-color: var(--faint); background: var(--bg); }
.li-link svg { width: 12px; height: 12px; fill: #0a66c2; flex: none; }
@media (prefers-color-scheme: dark) { .li-link svg { fill: #6ca9e8; } }
.who { color: var(--muted); }

/* outcome badge (New Grad / Internship / Job Hopped), pushed to the
   card's bottom-right corner. Defaults to green; per-person override
   comes from config.js */
.tag {
  margin-left: auto;
  font-weight: 650;
  color: var(--msu-green);
}

.controls {
  display: flex; align-items: center; justify-content: center;
  gap: 14px; margin-top: 18px;
}
.arrow {
  background: none; border: 1px solid var(--rule); color: var(--muted);
  width: 30px; height: 30px; border-radius: 50%;
  cursor: pointer; font-size: 15px; line-height: 1;
  display: flex; align-items: center; justify-content: center; padding: 0;
}
.arrow:hover { color: var(--text); border-color: var(--faint); }
.dots { display: flex; gap: 7px; }
.dot {
  width: 6px; height: 6px; border-radius: 50%; padding: 0;
  background: var(--rule); border: none; cursor: pointer;
  transition: background .3s;
}
.dot[aria-selected="true"] { background: var(--accent); }

/* small italic note under the testimonial carousel */
.carousel-note {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 13px;
  font-style: italic;
  color: var(--faint);
  text-align: left;
  margin: 18px 0 0;
}

/* ===== booking ===== */

.book-btn {
  display: inline-block;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 16px; font-weight: 600;
  background: var(--accent); color: var(--accent-ink);
  padding: 13px 26px; border-radius: 7px; text-decoration: none;
}
.book-btn:hover { opacity: .9; }
.cta { margin: 4px 0 0; }
.cta-bottom { margin-top: 8px; }

/* ===== intake form (/submitform) ===== */

.intake { margin-top: 34px; }

.field { margin-bottom: 22px; }

.field label {
  display: block;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 12px; font-weight: 600; letter-spacing: .09em;
  text-transform: uppercase; color: var(--faint);
  margin-bottom: 8px;
}
.field .hint { text-transform: none; letter-spacing: 0; font-weight: 500; }

.field input[type="text"],
.field input[type="email"],
.field input[type="url"],
.field textarea {
  width: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 16px;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 7px;
  padding: 11px 13px;
  transition: border-color .15s;
}
.field textarea { resize: vertical; line-height: 1.5; }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.field input::placeholder,
.field textarea::placeholder { color: var(--faint); }

.field input[type="file"] {
  display: block; width: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 14px; color: var(--muted);
}
.field input[type="file"]::file-selector-button {
  font-family: inherit; font-size: 14px; font-weight: 600;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 7px 14px;
  margin-right: 12px;
  cursor: pointer;
}
.field input[type="file"]::file-selector-button:hover { border-color: var(--faint); }

.book-btn { border: none; cursor: pointer; }

/* star rating picker on /feedback */
.stars { display: flex; gap: 6px; }
.star {
  background: none; border: none; padding: 2px;
  font-size: 30px; line-height: 1;
  color: var(--rule);
  cursor: pointer;
  transition: color .12s, transform .12s;
}
.star.lit { color: var(--accent); }
.star:hover { transform: scale(1.12); }
.star:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.form-status {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 14px; color: var(--muted);
  margin: 14px 0 0; min-height: 1.4em;
}
.form-status.error { color: #c0392b; }
@media (prefers-color-scheme: dark) { .form-status.error { color: #e07a6d; } }

.form-done {
  font-size: 19px;
  margin: 28px 0 0;
}

footer {
  margin-top: 38px; padding-top: 22px; border-top: 1px solid var(--rule);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 14px; color: var(--muted);
  /* flex centers the icons on the text line instead of leaving them
     to baseline-align at different heights */
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 7px;
}

/* "Software Engineer" on desktop, "SWE" on phones so the footer stays
   on one tidy line */
.role-short { display: none; }

/* LinkedIn / Gmail app-style tile icons in the footer — identical
   rounded squares, so they always sit level with each other */
.footer-icon { display: inline-flex; align-items: center; text-decoration: none; }
.footer-icon svg { display: block; width: 20px; height: 20px; }
/* hairline around Gmail's white tile so it has an edge on the light theme */
.footer-icon.gm svg rect { stroke: var(--rule); stroke-width: 1; }
/* GitHub: octocat on an ink tile, inverting with the theme */
.footer-icon.gh svg rect { fill: var(--text); }
.footer-icon.gh svg path { fill: var(--bg); }
.footer-icon:hover svg { opacity: .8; }

@media (prefers-reduced-motion: reduce) {
  .marquee-track {
    flex-wrap: wrap; justify-content: center;
    width: 100%; row-gap: 16px;
  }
  /* The list is rendered twice so the scroll can loop seamlessly. With the
     animation off there's no loop, so the second copy would just show every
     company a second time. Hide it. */
  .logo[aria-hidden="true"] { display: none; }
  .track { transition: none; }
}

/* On laptop screens, tighten the vertical rhythm so the intro paragraphs
   AND the company strip fit in the first viewport together. Same document
   order — nothing moves, the page just breathes a little less up top. */
@media (min-width: 768px) {
  .wrap { padding-top: 36px; }
  p { margin-bottom: 15px; }
  .proof {
    margin: 30px 0 44px;
    padding: 24px 0 28px;
  }
  .proof > .label { margin-bottom: 14px; }
  .carousel { margin-top: 30px; }
  .proof.proof-strip { margin: 36px 0 0; padding: 24px 0 22px; }
}

/* Shorter laptop windows get a compact rhythm so the strip lands as
   close to the first screen as the text length allows. The strip always
   stays BELOW the text on desktop — on very short windows it may sit
   past the fold, and that's accepted. */
@media (min-width: 768px) and (max-height: 969px) {
  body { font-size: 17px; }
  .wrap { padding-top: 22px; }
  p { margin-bottom: 12px; }
  .proof {
    margin-top: 20px;
    padding-top: 16px;
  }
  .proof > .label { margin-bottom: 12px; }
}

@media (max-width: 600px) {
  :root { --card-h: 250px; }
  .wrap { padding: 22px 20px 64px; }
  body { font-size: 16.5px; line-height: 1.55; }
  p { margin-bottom: 16px; }


  .role-long { display: none; }
  .role-short { display: inline; }

  /* company strip stays at the very top of the page on phones */
  .wrap { display: flex; flex-direction: column; }
  .proof.proof-strip {
    order: -1;
    border-top: none;
    border-bottom: 1px solid var(--rule);   /* text follows it here, so it needs its own line */
    margin: 0 0 22px;
    padding: 0 0 16px;
  }
  .proof.proof-quotes { margin-top: 44px; }
  .proof-strip .label { margin-bottom: 14px; }
  .logo { font-size: 17px; padding: 0 22px; gap: 10px; }
  .logo img { height: 24px; width: 24px; }
  .quote { padding: 17px 18px; }
  .quote p { font-size: 15px; }

  /* On narrow cards the attribution items wrap unpredictably (the alum
     badge could land on its own line under the title). Lock it to two
     lines: LinkedIn pill on the first, role-at-company on the left and
     the alum badge on the right of the second. */
  .attrib {
    display: grid;
    grid-template-columns: 1fr auto;
    row-gap: 7px;
    align-items: center;
  }
  .li-link { grid-column: 1 / -1; justify-self: start; }
  .tag { margin-left: 0; justify-self: end; }
}
