/* Upper GI Endoscopy course page (course-git.html, course-git-ar.html). Builds on course.css.
   Every rule is scoped to body[data-course="git"], so nothing here leaks into other pages that
   share the stylesheet's cache (the blog, the dashboard). Logical properties (inline-start/end)
   keep the Arabic page mirrored without a second set of rules. */
body[data-course="git"] { --c: var(--drape); }
body[data-course="git"] .git-lang { font-size: 15px; text-underline-offset: 3px; color: var(--muted); }
body[data-course="git"] .git-split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 900px) { body[data-course="git"] .git-split { grid-template-columns: minmax(0, 1fr); } }
body[data-course="git"] .git-points, body[data-course="git"] .git-creds { list-style: none; margin: 22px 0 0; padding: 0; }
body[data-course="git"] .git-points li, body[data-course="git"] .git-creds li { position: relative; padding: 12px 0; padding-inline-start: 30px; border-top: 1px solid var(--line); }
body[data-course="git"] .git-points li::before, body[data-course="git"] .git-creds li::before { content: ""; position: absolute; inset-inline-start: 4px; top: 21px; width: 12px; height: 7px; border: 2px solid var(--c); border-top: 0; border-right: 0; transform: rotate(-45deg); }

/* Hero: the cohort's state, and the stats the server fills */
body[data-course="git"] .git-state { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 22px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--r-m); background: var(--card); color: var(--ink-2); font-size: 15px; max-width: 52ch; }
body[data-course="git"] .git-state[hidden] { display: none; }
body[data-course="git"] .git-state b { color: var(--ink); font-weight: 600; }
body[data-course="git"] .git-dot { flex: none; width: 10px; height: 10px; margin-top: .55em; border-radius: 50%; background: var(--ok); }
body[data-course="git"] .git-state.is-waitlist .git-dot { background: var(--warn); }
body[data-course="git"] .git-state.is-closed .git-dot { background: var(--muted); }
body[data-course="git"] .c-stats [hidden] { display: none; }
body[data-course="git"] .c-stats b { white-space: nowrap; }
@media (max-width: 520px) {
  body[data-course="git"] .c-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body[data-course="git"] .c-stats div:nth-child(n+3) { border-top: 1px solid var(--line); }
  body[data-course="git"] .c-stats div:nth-child(odd) { border-left: 0; padding-left: 0; }
  [dir="rtl"] body[data-course="git"] .c-stats div:nth-child(odd) { border-right: 0; padding-right: 0; }
}

/* Stations bench */
body[data-course="git"] .git-route { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: clamp(20px, 4vw, 48px); align-items: center; }
body[data-course="git"] .git-route[hidden] { display: none; }
@media (max-width: 760px) { body[data-course="git"] .git-route { grid-template-columns: minmax(0, 1fr); } body[data-course="git"] .git-route svg { max-width: 260px; margin: 0 auto; } }
body[data-course="git"] .git-route svg { width: 100%; height: auto; }
body[data-course="git"] .git-route .tube { fill: none; stroke: #3A2738; stroke-width: 28; stroke-linecap: round; stroke-linejoin: round; }
body[data-course="git"] .git-route .tube-in { fill: none; stroke: #5A3D57; stroke-width: 2; stroke-dasharray: 4 7; }
body[data-course="git"] .git-route .organ { fill: #3A2738; stroke: #5A3D57; stroke-width: 2; }
body[data-course="git"] .git-route .st { cursor: pointer; outline: none; }
/* The transparent .hit circle is the touch target (44 units across, about 29px at the narrowest layout). */
body[data-course="git"] .git-route .st .hit { fill: transparent; }
body[data-course="git"] .git-route .st .dot { fill: var(--theatre); stroke: var(--monitor); stroke-width: 2; transition: fill .25s, r .25s; }
body[data-course="git"] .git-route .st .ring { fill: none; stroke: #fff; stroke-width: 3; opacity: 0; pointer-events: none; }
body[data-course="git"] .git-route .st text { fill: var(--monitor); font-family: var(--f-mono); font-size: 12px; text-anchor: middle; dominant-baseline: central; pointer-events: none; }
body[data-course="git"] .git-route .st:hover .dot { stroke-width: 3; }
body[data-course="git"] .git-route .st[aria-pressed="true"] .dot { fill: var(--monitor); r: 15px; }
body[data-course="git"] .git-route .st[aria-pressed="true"] text { fill: var(--theatre); }
body[data-course="git"] .git-route .st:focus-visible .ring { opacity: 1; }
body[data-course="git"] .git-panel h3 { font-size: clamp(26px, 2.6vw, 36px); color: #F4EAF1; margin: 6px 0 14px; }
body[data-course="git"] .git-panel p { color: #CDBBC9; margin: 0 0 12px; max-width: 52ch; }
body[data-course="git"] .git-step { color: var(--monitor); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin: 0; }
body[data-course="git"] .git-miss { padding: 12px 14px; border-inline-start: 3px solid var(--monitor); background: rgba(231, 179, 221, .06); border-radius: var(--r-s); }
body[data-course="git"] .git-miss b { color: #F4EAF1; font-weight: 600; }
body[data-course="git"] .git-nav { display: flex; gap: 8px; margin-top: 18px; }
body[data-course="git"] .git-nav button { border: 1px solid var(--theatre-line); background: transparent; color: #E9DEE6; border-radius: 999px; padding: 0 20px; min-height: 44px; cursor: pointer; font-size: 14px; }
body[data-course="git"] .git-nav button:hover { border-color: var(--monitor); }
body[data-course="git"] .git-nav button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
body[data-course="git"] .git-count { font-family: var(--f-mono); font-size: 11px; color: #AE9AAB; }
/* The plain-text stations: what a reader without JavaScript sees (git.js hides it once the diagram is built). */
body[data-course="git"] .git-stations { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(20px, 4vw, 48px); counter-reset: st; }
body[data-course="git"] .git-stations[hidden] { display: none; }
body[data-course="git"] .git-stations li { counter-increment: st; padding: 16px 0; border-top: 1px solid var(--theatre-line); }
body[data-course="git"] .git-stations li::before { content: counter(st); font-family: var(--f-mono); font-size: 11px; color: var(--monitor); }
html[lang="ar"] body[data-course="git"] .git-stations li::before { content: counter(st, arabic-indic); }
body[data-course="git"] .git-stations h3 { font-size: 22px; color: #F4EAF1; margin: 6px 0 8px; }
body[data-course="git"] .git-stations p { color: #CDBBC9; font-size: 15px; margin: 0 0 10px; }
body[data-course="git"] .git-stations .git-miss b { display: inline; }
@media (max-width: 760px) { body[data-course="git"] .git-stations { grid-template-columns: minmax(0, 1fr); } }

/* Programme and session steps */
body[data-course="git"] .git-learn { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--ink); counter-reset: learn; }
body[data-course="git"] .git-learn li { counter-increment: learn; padding: 24px 0 28px; padding-inline: 0 24px; border-bottom: 1px solid var(--line); }
body[data-course="git"] .git-learn li:not(:nth-child(3n+1)) { padding-inline-start: 24px; border-inline-start: 1px solid var(--line); }
body[data-course="git"] .git-learn li::before { content: counter(learn, decimal-leading-zero); font-family: var(--f-mono); font-size: 11px; color: var(--c); }
html[lang="ar"] body[data-course="git"] .git-learn li::before { content: counter(learn, arabic-indic); }
body[data-course="git"] .git-learn h3 { font-size: clamp(21px, 1.8vw, 25px); margin: 10px 0 8px; }
body[data-course="git"] .git-learn p { color: var(--muted); font-size: 15px; margin: 0; }
@media (max-width: 900px) {
  body[data-course="git"] .git-learn { grid-template-columns: 1fr 1fr; }
  body[data-course="git"] .git-learn li:not(:nth-child(3n+1)) { padding-inline-start: 0; border-inline-start: 0; }
  body[data-course="git"] .git-learn li:nth-child(2n) { padding-inline-start: 20px; border-inline-start: 1px solid var(--line); }
}
@media (max-width: 560px) { body[data-course="git"] .git-learn { grid-template-columns: 1fr; } body[data-course="git"] .git-learn li:nth-child(2n) { padding-inline-start: 0; border-inline-start: 0; } }
body[data-course="git"] .git-steps { list-style: none; margin: 0; padding: 0; grid-template-columns: repeat(5, 1fr); }
body[data-course="git"] .git-steps li { padding: 22px 0 0; padding-inline-end: 22px; }
body[data-course="git"] .git-steps li + li { padding-inline-start: 22px; border-inline-start: 1px solid var(--line); }
body[data-course="git"] .git-steps b { font-family: var(--f-display); font-weight: 400; font-size: 22px; display: block; line-height: 1.2; margin-bottom: 8px; }
body[data-course="git"] .git-steps p { color: var(--muted); font-size: 15px; margin: 0; }
@media (max-width: 1000px) { body[data-course="git"] .git-steps { grid-template-columns: 1fr 1fr; row-gap: 24px; } body[data-course="git"] .git-steps li:nth-child(odd) { border-inline-start: 0; padding-inline-start: 0; } }
@media (max-width: 520px) { body[data-course="git"] .git-steps { grid-template-columns: 1fr; } body[data-course="git"] .git-steps li { border-inline-start: 0 !important; padding-inline-start: 0 !important; } }

/* Instructor */
body[data-course="git"] .git-fac { align-items: start; }
body[data-course="git"] .git-portrait { width: 100%; max-width: 180px; aspect-ratio: 1; object-fit: cover; border-radius: 50%; }
body[data-course="git"] .git-role { font-family: var(--f-display); font-style: italic; font-size: 19px; color: var(--ink-2); margin: 6px 0 14px; }

/* Venue and certificate (rendered only when the cohort record has them) */
body[data-course="git"] .git-pre { white-space: pre-line; margin: 0; max-width: 64ch; }

/* Booking */
body[data-course="git"] #book .git-split { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); }
@media (max-width: 900px) { body[data-course="git"] #book .git-split { grid-template-columns: minmax(0, 1fr); } }
body[data-course="git"] .git-facts { margin: 26px 0 0; }
body[data-course="git"] .git-facts div { display: grid; grid-template-columns: minmax(96px, 8.5rem) minmax(0, 1fr); gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
body[data-course="git"] .git-facts div[hidden] { display: none; }
body[data-course="git"] .git-facts dt { font-family: var(--f-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-top: 4px; }
body[data-course="git"] .git-facts dd { margin: 0; }
body[data-course="git"] .git-how { list-style: none; margin: 22px 0 0; padding: 0; }
body[data-course="git"] .git-how li { padding: 14px 0; border-top: 1px solid var(--line); }
body[data-course="git"] .git-how b { font-family: var(--f-display); font-weight: 400; font-size: 21px; }
body[data-course="git"] .git-how p { color: var(--muted); font-size: 15px; margin: 4px 0 0; }
body[data-course="git"] .git-how a { color: inherit; text-underline-offset: 3px; }
body[data-course="git"] .git-side { display: grid; gap: 16px; min-width: 0; }
body[data-course="git"] .git-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-l); padding: clamp(20px, 3vw, 32px); min-width: 0; }
body[data-course="git"] .git-card[hidden] { display: none; }
body[data-course="git"] .git-card h3 { font-size: clamp(24px, 2.4vw, 30px); margin: 0 0 8px; }
body[data-course="git"] .git-card > .hint { color: var(--muted); font-size: 14px; margin: 0 0 18px; max-width: 60ch; }
body[data-course="git"] .git-form { max-width: none; gap: 14px; }
body[data-course="git"] .git-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
@media (max-width: 600px) { body[data-course="git"] .git-grid { grid-template-columns: minmax(0, 1fr); } }
body[data-course="git"] .git-field { display: grid; gap: 6px; align-content: start; min-width: 0; }
body[data-course="git"] .git-field .opt { color: var(--muted); font-weight: 400; }
body[data-course="git"] .git-field .check a { color: inherit; text-underline-offset: 3px; }
body[data-course="git"] .git-form .btn { justify-self: start; min-height: 48px; }
body[data-course="git"] .git-form .btn span[hidden] { display: none; }
body[data-course="git"] .git-hp { position: absolute; inline-size: 1px; block-size: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
body[data-course="git"] .git-done { display: grid; gap: 12px; outline: none; }
body[data-course="git"] .git-done:focus-visible { outline: 2px solid var(--c); outline-offset: 6px; border-radius: var(--r-s); }
body[data-course="git"] .git-done[hidden] { display: none; }
body[data-course="git"] .git-done h3 { margin: 0; }
body[data-course="git"] .git-done p { margin: 0; color: var(--ink-2); }
body[data-course="git"] .git-done ol { margin: 0; padding-inline-start: 22px; color: var(--ink-2); display: grid; gap: 6px; }
body[data-course="git"] .git-ref { display: inline-block; font-family: var(--f-mono); font-size: 22px; letter-spacing: .08em; direction: ltr; unicode-bidi: isolate; padding: 8px 14px; border: 1px dashed var(--c); border-radius: var(--r-s); color: var(--ink); }
body[data-course="git"] .git-done .c-actions { margin-top: 4px; }
body[data-course="git"] .git-ask { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-l); }
body[data-course="git"] .git-ask summary { cursor: pointer; min-height: 48px; display: flex; align-items: center; padding: 8px clamp(20px, 3vw, 32px); font-family: var(--f-display); font-size: 19px; list-style: none; }
body[data-course="git"] .git-ask summary::-webkit-details-marker { display: none; }
body[data-course="git"] .git-ask summary::after { content: "+"; margin-inline-start: auto; font-family: var(--f-mono); color: var(--c); }
body[data-course="git"] .git-ask[open] summary::after { content: "−"; }
body[data-course="git"] .git-ask > form, body[data-course="git"] .git-ask > .git-done, body[data-course="git"] .git-ask > noscript p { margin: 4px clamp(20px, 3vw, 32px) clamp(20px, 3vw, 32px); }
body[data-course="git"] .git-mailnote { margin: 0; font-size: 14px; color: var(--muted); }
body[data-course="git"] .git-mailnote a { color: inherit; text-underline-offset: 3px; }
body[data-course="git"] .git-card .notice { margin-top: 14px; }

/* FAQ and disclaimer */
body[data-course="git"] .git-faq details { border-top: 1px solid var(--line); }
body[data-course="git"] .git-faq details:last-child { border-bottom: 1px solid var(--line); }
body[data-course="git"] .git-faq summary { cursor: pointer; list-style: none; padding: 18px 0; padding-inline-end: 36px; position: relative; font-family: var(--f-display); font-size: clamp(19px, 1.7vw, 23px); }
body[data-course="git"] .git-faq summary::-webkit-details-marker { display: none; }
body[data-course="git"] .git-faq summary::after { content: "+"; position: absolute; inset-inline-end: 4px; top: 16px; font-family: var(--f-mono); font-size: 18px; color: var(--c); }
body[data-course="git"] .git-faq details[open] summary::after { content: "−"; }
body[data-course="git"] .git-faq details p { color: var(--ink-2); margin: 0 0 20px; max-width: 64ch; }
body[data-course="git"] .git-faq details p a { color: inherit; text-underline-offset: 3px; }
body[data-course="git"] .git-disc { font-size: 13px; color: var(--muted); max-width: 100ch; padding: 0 0 clamp(40px, 6vw, 72px); margin: 0; }

/* Arabic page: type, and the one course.css rule that is written with left/right */
html[lang="ar"] body[data-course="git"] { --f-display: "Noto Naskh Arabic", "Newsreader", serif; --f-body: "IBM Plex Sans Arabic", "Schibsted Grotesk", system-ui, sans-serif; line-height: 1.8; }
html[lang="ar"] body[data-course="git"] h1, html[lang="ar"] body[data-course="git"] h2, html[lang="ar"] body[data-course="git"] h3 { letter-spacing: 0; line-height: 1.35; }
html[lang="ar"] body[data-course="git"] .c-hero .kicker, html[lang="ar"] body[data-course="git"] .label, html[lang="ar"] body[data-course="git"] .git-facts dt, html[lang="ar"] body[data-course="git"] .c-stats span { letter-spacing: 0; text-transform: none; font-family: var(--f-body); font-size: 13px; }
html[lang="ar"] body[data-course="git"] .git-step, html[lang="ar"] body[data-course="git"] .git-count, html[lang="ar"] body[data-course="git"] .crumbs { font-family: var(--f-body); letter-spacing: 0; text-transform: none; }
[dir="rtl"] body[data-course="git"] .c-stats div + div { border-left: 0; padding-left: 0; border-right: 1px solid var(--line); padding-right: 18px; }
[dir="rtl"] body[data-course="git"] .crumbs, [dir="rtl"] body[data-course="git"] .c-actions { direction: rtl; }
[dir="rtl"] body[data-course="git"] input[dir="ltr"] { text-align: right; }
