/* odonthub.com shared styles: the homepage and every generated page (build_site.py) use this file. */

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* White site with dark sections (the episode and the ninja). Colors come from brand/BRAND.md. */
:root {
  --ink: #14161c;
  --cyan: #4caccc;
  --cyan-dark: #2b86a8;
  --orange: #f48c34;
  --bg: #ffffff;
  --soft: #f1f4f8;
  --heading: #14161c;
  --text: #2a2f3a;
  --muted: #5d6878;
  --line: rgba(20, 22, 28, 0.12);
  --link: #2b86a8;
  --wrap: 1120px;
}
.dark {
  --bg: #14161c;
  --heading: #ffffff;
  --text: #e8edf3;
  --muted: #a3afbf;
  --line: rgba(255, 255, 255, 0.1);
  --link: #4caccc;
  background: var(--bg);
  color: var(--text);
}

html {
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Saira', system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--link);
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 20px;
}

h1,
h2,
h3 {
  color: var(--heading);
  line-height: 1.1;
  font-weight: 800;
}
h1 {
  font-size: clamp(2.6rem, 7vw, 4.4rem);
  letter-spacing: -0.01em;
}
h2 {
  font-size: clamp(1.9rem, 4.5vw, 2.8rem);
  margin-bottom: 16px;
}
h3 {
  font-size: 1.25rem;
  font-weight: 700;
}

.lead {
  font-size: clamp(1.1rem, 2.4vw, 1.3rem);
}
.muted {
  color: var(--muted);
}
/* cyan like "hub" in the logo; the darker cyan the brand uses on light backgrounds */
.accent {
  color: var(--cyan-dark);
}

/* the orange blade cut under a heading, like the line under "hub" in the logo */
.cut {
  display: block;
  width: 120px;
  height: 8px;
  margin-top: 18px;
  background: var(--orange);
  transform: skewX(-30deg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.btn-primary {
  background: var(--orange);
  color: var(--ink);
}
.btn-primary:hover {
  background: #ffa24f;
}
.btn-ghost {
  color: var(--heading);
  border: 2px solid rgba(20, 22, 28, 0.2);
}
.btn-ghost:hover {
  border-color: var(--cyan-dark);
}
a:focus-visible,
.btn:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 3px;
}

/* header */
.site-header {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.site-header img {
  width: 200px;
}
.site-header .btn {
  min-height: 44px;
  padding: 0 20px;
  font-size: 0.95rem;
  white-space: nowrap;
}
@media (max-width: 420px) {
  .site-header img {
    width: 150px;
  }
  .site-header .btn {
    padding: 0 16px;
  }
}

section {
  padding: 72px 0;
}

/* hero */
.hero {
  padding: 56px 0 72px;
}
.hero .wrap {
  display: grid;
  gap: 40px;
  align-items: center;
}
.hero .lead {
  margin-top: 22px;
  max-width: 34ch;
}
.hero .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.hero figure {
  justify-self: center;
  width: min(100%, 460px);
}
.hero figure img {
  border-radius: 20px;
  box-shadow: 0 0 0 1px var(--line), 0 18px 40px rgba(20, 22, 28, 0.1);
}
@media (min-width: 900px) {
  .hero {
    padding: 72px 0 96px;
  }
  .hero .wrap {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
  }
}

/* episode (dark) */
.episode .wrap {
  display: grid;
  gap: 36px;
  align-items: start;
}
.episode video {
  justify-self: center;
  width: min(100%, 360px);
  border-radius: 16px;
  background: #000;
  box-shadow: 0 0 0 1px var(--line);
}
.episode .tag {
  color: var(--orange);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 8px;
}
.episode p + p {
  margin-top: 14px;
}
.note {
  margin-top: 26px;
  padding: 18px 20px;
  border-left: 4px solid var(--cyan);
  background: rgba(76, 172, 204, 0.1);
  border-radius: 0 12px 12px 0;
}
.note h3 {
  margin-bottom: 6px;
}
@media (min-width: 900px) {
  .episode .wrap {
    grid-template-columns: 360px 1fr;
    gap: 56px;
  }
  .episode video {
    justify-self: start;
  }
}

/* join */
.join .wrap {
  display: grid;
  gap: 36px;
  align-items: start;
}
.join .lead {
  color: var(--text);
}
.perks {
  list-style: none;
  margin-top: 24px;
  display: grid;
  gap: 18px;
}
.perks li {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 14px;
}
.perks svg {
  width: 28px;
  height: 28px;
  stroke: var(--cyan-dark);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  margin-top: 2px;
}
.perks strong {
  display: block;
  color: var(--heading);
}
@media (min-width: 900px) {
  .join .wrap {
    grid-template-columns: 1fr 1fr;
    gap: 56px;
  }
}

/* Brevo form as a dark card (its markup and field names are unchanged) */
.sib-form {
  background-color: transparent !important;
  padding: 0 !important;
  font-family: inherit !important;
}
#sib-container {
  background: var(--ink) !important;
  border: 0 !important;
  border-radius: 20px !important;
  max-width: 100% !important;
  padding: 28px 24px !important;
  box-shadow: 0 18px 40px rgba(20, 22, 28, 0.18);
}
#sib-container,
#sib-container * {
  font-family: 'Saira', system-ui, sans-serif !important;
}
#sib-container .sib-form-block,
#sib-container .sib-form-block p,
#sib-container .entry__label {
  color: #ffffff !important;
}
#sib-container .sib-text-form-block p {
  color: #c9d2de !important;
  line-height: 1.5;
}
#sib-container .input,
#sib-container input[type='text'] {
  color: var(--ink) !important;
  -webkit-text-fill-color: var(--ink) !important;
  background-color: #f4f6f9 !important;
  font-size: 16px !important;
  min-height: 48px;
  border-radius: 10px !important;
}
#sib-container input::placeholder {
  color: #7b8696;
  -webkit-text-fill-color: #7b8696;
}
#sib-container .sib-form-block__button {
  background-color: var(--orange) !important;
  color: var(--ink) !important;
  border-radius: 999px !important;
  min-height: 52px;
  font-size: 1.05rem !important;
}
#sib-container .sib-form-block__button:hover {
  background-color: #ffa24f !important;
}
.form-note {
  margin-top: 14px;
  font-size: 0.95rem;
}

/* ninja (dark) */
.ninja .wrap {
  max-width: 760px;
}
.ninja p + p {
  margin-top: 14px;
}

/* FAQ */
.faq .wrap {
  max-width: 860px;
}
.faq details {
  border-bottom: 1px solid var(--line);
}
.faq details:first-of-type {
  border-top: 1px solid var(--line);
}
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 20px 40px 20px 0;
  position: relative;
  color: var(--heading);
  font-weight: 700;
  font-size: 1.12rem;
  line-height: 1.35;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '+';
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--orange);
  font-size: 1.6rem;
  font-weight: 600;
}
.faq details[open] summary::after {
  content: '–';
}
.faq details p {
  padding: 0 0 22px;
}

/* footer */
footer {
  padding: 40px 0 56px;
  background: var(--soft);
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
}
footer .wrap {
  display: grid;
  gap: 18px;
}
footer img {
  width: 160px;
}
footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}
footer nav a {
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
footer a:hover {
  color: var(--cyan-dark);
}

/* header link to the episodes (hidden on narrow phones: the episode section links there too) */
.header-actions {
  display: flex;
  align-items: center;
  gap: 22px;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--heading);
  font-weight: 600;
  text-decoration: none;
}
.nav-link:hover {
  color: var(--cyan-dark);
}
@media (max-width: 600px) {
  .nav-link {
    display: none;
  }
}

.ep-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 22px;
}
.ep-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
}

/* breadcrumb */
.crumbs {
  font-size: 0.95rem;
  color: var(--muted);
  margin-bottom: 22px;
}
.crumbs a {
  color: var(--muted);
}

/* episode page */
.ep-page h1 {
  font-size: clamp(2rem, 5vw, 3.1rem);
}
.ep-meta {
  margin-top: 14px;
  color: var(--muted);
  font-size: 1rem;
}
.topic {
  display: inline-block;
  margin-top: 16px;
  padding: 4px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.95rem;
  color: var(--text);
}
.prose .wrap {
  max-width: 860px;
}
.prose h2 {
  margin-top: 8px;
}
.prose h2 + p {
  margin-bottom: 18px;
}
.prose ul {
  padding-left: 22px;
  display: grid;
  gap: 10px;
}

/* the script, line by line */
.transcript {
  list-style: none;
  display: grid;
  gap: 14px;
  margin-top: 8px;
}
.transcript li {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.transcript .who {
  font-weight: 700;
  color: var(--cyan-dark);
}
@media (max-width: 520px) {
  .transcript li {
    grid-template-columns: 1fr;
    gap: 2px;
  }
}

/* clinical sheet */
.sheet-block + .sheet-block {
  margin-top: 40px;
}
.sources {
  font-size: 0.95rem;
}
.patient {
  margin-top: 40px;
  padding: 24px;
  border-radius: 16px;
  background: var(--soft);
  border-left: 6px solid var(--orange);
}
.patient p + p {
  margin-top: 10px;
}
.patient .btn {
  margin-top: 18px;
}
.reviewed {
  margin-top: 28px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* episode list */
.ep-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 28px;
  margin-top: 36px;
}
.ep-card a {
  display: block;
  color: inherit;
  text-decoration: none;
}
.ep-card img {
  border-radius: 14px;
  box-shadow: 0 0 0 1px var(--line);
  aspect-ratio: 9 / 16;
  object-fit: cover;
  width: 100%;
}
.ep-card .tag {
  margin-top: 14px;
  color: var(--orange);
  font-weight: 700;
  font-size: 0.95rem;
}
.ep-card h2 {
  font-size: 1.3rem;
  margin: 4px 0 6px;
}
.ep-card a:hover h2 {
  color: var(--cyan-dark);
}

/* join call to action at the end of generated pages */
.cta-band {
  text-align: center;
}
.cta-band .lead {
  margin: 0 auto 26px;
  max-width: 40ch;
}

/* the episode script, folded: a pill that opens it (no JavaScript, the browser's own details element) */
.script summary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 2px solid rgba(20, 22, 28, 0.2);
  color: var(--heading);
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.script summary::-webkit-details-marker {
  display: none;
}
.script summary::after {
  content: '+';
  color: var(--orange);
  font-size: 1.4rem;
  line-height: 1;
}
.script[open] summary::after {
  content: '–';
}
.script summary:hover {
  border-color: var(--cyan-dark);
}
.script .transcript {
  margin-top: 22px;
}

/* the episode article (written for everyone, reviewed by a dentist) */
.article .wrap {
  max-width: 800px;
}
.article h2 {
  font-size: clamp(1.8rem, 4.2vw, 2.5rem);
}
.article h3 {
  font-size: 1.4rem;
  margin: 40px 0 12px;
}
.article p + p {
  margin-top: 14px;
}
.article ul,
.article ol {
  padding-left: 22px;
  display: grid;
  gap: 10px;
  margin-top: 12px;
}
.byline {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 6px 0 22px;
}
.summary,
.dentist {
  margin-top: 32px;
  padding: 24px;
  border-radius: 16px;
  background: var(--soft);
}
.summary {
  border-left: 6px solid var(--orange);
}
.dentist {
  margin-top: 48px;
  border-left: 6px solid var(--cyan-dark);
}
.summary h3,
.dentist h3 {
  margin-top: 0;
}
.dentist h4 {
  margin-top: 22px;
  font-size: 1.05rem;
  color: var(--heading);
}
.summary .btn,
.dentist .btn {
  margin-top: 18px;
}
.dentist p {
  margin-top: 18px;
}
.article .sources {
  margin-top: 40px;
  font-size: 0.95rem;
}
.article .sources a {
  word-break: break-word;
}
.article {
  display: block;
  padding: 16px 0 72px;
}
