/* Shared finishing layer for the Session 1 visual system. */
.course-skip { position: fixed; top: -100px; left: 1rem; z-index: 100; padding: .7rem 1rem; border-radius: .6rem; background: var(--accent, #4f46e5); color: white; font-weight: 600; }
.course-skip:focus { top: .5rem; }
.course-path { background: var(--paper, #fff); border-bottom: 1px solid var(--line, #e2e8f0); }
.course-path-inner { max-width: 72rem; margin: auto; padding: .8rem 1rem; display: flex; align-items: center; flex-wrap: wrap; gap: .65rem 1.25rem; font: 500 .75rem/1.5 Inter, sans-serif; }
.course-map-link { color: var(--accent, #4f46e5); text-decoration: none; white-space: nowrap; }
.course-map-link:hover { text-decoration: underline; }
.course-guide-link { display: inline-flex; align-items: center; min-height: 40px; color: var(--accent, #4f46e5); text-decoration: underline; text-underline-offset: 3px; }
.course-phase { color: var(--muted, #475569); margin-right: auto; }
.course-switcher { display: flex; align-items: center; gap: .5rem; min-width: 0; max-width: 100%; }
.course-switcher label { color: var(--muted, #475569); }
.course-switcher select { width: min(22rem, 48vw); max-width: 100%; border: 1px solid var(--line, #e2e8f0); border-radius: .5rem; background: var(--card, #fff); color: var(--ink, #0f172a); padding: .5rem .6rem; min-height: 40px; font: inherit; }
.course-step { display: inline-flex; justify-content: center; align-items: center; width: 40px; height: 40px; flex: none; border: 1px solid var(--line, #e2e8f0); border-radius: .5rem; color: var(--accent, #4f46e5); font-size: 1.1rem; }
.course-step:hover { background: var(--accent-soft, #eef2ff); }
.course-memo { max-width: 72rem; margin: 2.5rem auto; padding: 0 1rem; }
.course-memo details { border: 1px solid var(--line, #e2e8f0); border-radius: 1rem; background: var(--card, #fff); }
.course-memo summary { cursor: pointer; padding: 1.25rem; color: var(--ink, #0f172a); font: 600 1.15rem/1.5 Fraunces, Georgia, serif; }
.course-memo-body { border-top: 1px solid var(--line, #e2e8f0); padding: 1.25rem; }
.course-memo-prompt { font-size: .95rem; line-height: 1.7; color: var(--ink, #0f172a); max-width: 56rem; }
.course-memo-hint, .course-memo-status { color: var(--muted, #475569); font-size: .75rem; line-height: 1.6; }
.course-memo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1.25rem; }
.course-memo label { display: block; font-size: .8rem; font-weight: 600; color: var(--ink, #0f172a); }
.course-memo textarea { display: block; resize: vertical; width: 100%; min-height: 9rem; margin-top: .5rem; padding: .75rem; border: 1px solid var(--line, #e2e8f0); border-radius: .6rem; background: var(--paper, #fff); color: var(--ink, #0f172a); font: 400 .875rem/1.6 Inter, sans-serif; }
.course-memo-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .65rem; margin-top: 1rem; }
.course-memo-actions button { border: 1px solid var(--line, #e2e8f0); border-radius: .5rem; min-height: 42px; padding: .6rem .85rem; font-size: .8rem; color: var(--ink, #0f172a); }
.course-memo-actions button:first-child { background: var(--accent, #4f46e5); color: #fff; border-color: transparent; }
.course-memo-status { margin-top: .75rem; min-height: 1.2em; }
html.dark .course-memo-actions button:first-child { background: #4f46e5; color: #fff; }
body :focus-visible { outline: 2px solid var(--accent, #4f46e5); outline-offset: 4px; }
#themeBtn, #drawerBtn, #drawerClose { flex-shrink: 0; min-width: 40px; min-height: 40px; }
#main-header .course-section-links { flex-shrink: 0; white-space: nowrap; }
#main-header.course-compact .course-section-links { display: none !important; }
#main-header.course-compact #drawerBtn { display: grid !important; }
section { scroll-margin-top: 5.5rem; }
section a { overflow-wrap: anywhere; }
.course-memo [hidden] { display: none; }
@media (max-width: 640px) {
  .course-path-inner { gap: .5rem; }
  .course-switcher { flex-basis: 100%; width: 100%; }
  .course-switcher select { width: 100%; min-width: 0; flex: 1; }
  .course-memo-grid { grid-template-columns: 1fr; }
  .course-memo textarea { min-height: 6rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto !important; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
@media print {
  .course-path, .course-skip, .course-memo-actions, .course-memo-status { display: none !important; }
  .course-memo { break-inside: avoid; }
}
