/*
 * Class Planner student guide
 *
 * Decorator 5 supplies the UC San Diego shell, typography, colors, and
 * controls. These styles are limited to the guide's content layout,
 * screenshot and video treatment, focus visibility, and responsive fixes.
 *
 * Sizing note: the Decorator shell leaves the root font-size at the browser
 * default (16px), so every rem here is authored against a 16px root.
 */

:root {
  --ucsd-navy: #182b49;
  --ucsd-blue: #00629b;
  --ucsd-bright-blue: #00c6d7;
  --ucsd-yellow: #ffcd00;
  --guide-ink: #202a44;
  --guide-muted: #52616b;
  --guide-line: #d7dde5;
  --guide-tint: #f5f7fa;
  --guide-info: #e7f3f8;
}

html {
  scroll-behavior: auto;
}

body {
  color: var(--guide-ink);
  overflow-wrap: break-word;
  position: relative;
}

a,
button {
  text-underline-offset: 0.16em;
}

a:focus,
button:focus,
[tabindex]:focus {
  outline: 3px solid var(--ucsd-yellow) !important;
  outline-offset: 3px;
}

.skip-to-main:focus {
  background: #fff;
  color: var(--ucsd-navy);
  display: block;
  font-weight: 700;
  left: 1rem;
  padding: 0.75rem 1rem;
  position: fixed;
  top: 1rem;
  z-index: 10000;
}

.layout-title .title-header {
  text-decoration: none;
}

.mobile-logo-wrap {
  margin: 0;
  max-width: 155px;
  padding: 0;
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
}

.mobile-logo-wrap .header-logo {
  margin: 0;
}

.decorator-script-hooks {
  display: none !important;
}

.navbar-toggle {
  align-items: center;
  display: flex;
  gap: 0.55rem;
  min-height: 44px;
}

/* Keep the drawer's visually-hidden Close button out of normal flow;
   Bootstrap's .navbar-toggle otherwise floats it into the first menu
   rows and indents their text. */
.navmenu > .navbar-toggle {
  float: none;
  position: absolute;
}

.navbar-toggle .mobile-nav-bars {
  display: inline-block;
  width: 22px;
}

.navbar-toggle .icon-bar {
  display: block;
}

.navbar-toggle .mobile-nav-icon {
  font-weight: 700;
}

.breadcrumb {
  margin-bottom: 0;
  margin-top: 0.625rem;
}

.breadcrumb > .active {
  color: #4a4a4a;
}

.guide-hero,
.guide-section {
  scroll-margin-top: 1.5rem;
}

.guide-hero {
  background:
    linear-gradient(115deg, rgba(24, 43, 73, 0.98), rgba(0, 98, 155, 0.92)),
    var(--ucsd-navy);
  color: #fff;
  margin-top: 0.625rem;
  padding: 3.5rem 0 2rem;
}

.guide-hero h1 {
  color: #fff;
  font-size: clamp(2.25rem, 5vw, 3.875rem);
  line-height: 1.06;
  margin-bottom: 1.25rem;
  margin-top: 0;
  max-width: 850px;
}

.guide-hero .lead {
  color: #fff;
  font-size: 1.375rem;
  line-height: 1.55;
  max-width: 820px;
}

.guide-hero p:not(.eyebrow) {
  color: #fff;
}

.eyebrow,
.step-label {
  color: var(--ucsd-blue);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  margin-bottom: 0.625rem;
  text-transform: uppercase;
}

.guide-hero .eyebrow {
  color: var(--ucsd-yellow);
}

.hero-actions {
  margin: 1.5rem 0 0;
}

.hero-actions .btn {
  white-space: normal;
}

.planner-launch-button {
  background: var(--ucsd-yellow);
  border: 2px solid var(--ucsd-yellow);
  box-shadow: 0 8px 22px rgba(11, 21, 38, 0.35);
  color: var(--ucsd-navy) !important;
  font-size: 1.0625rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 0.875rem 1.5rem;
  text-decoration: none;
  text-transform: uppercase;
}

.planner-launch-button:hover,
.planner-launch-button:focus {
  background: #fff;
  border-color: #fff;
  color: var(--ucsd-navy) !important;
  text-decoration: none;
}

.planner-launch-button span {
  margin-left: 0.35rem;
}

.hero-shot {
  margin: 0;
}

.hero-shot img {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(11, 21, 38, 0.45);
  height: auto;
  margin: 0 auto;
  max-width: 100%;
}

.hero-shot-detailed {
  aspect-ratio: 1800 / 1110;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(11, 21, 38, 0.45);
  overflow: hidden;
}

.hero-shot-detailed img {
  border-radius: 0;
  box-shadow: none;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  width: 100%;
}

.planner-notice {
  align-items: flex-start;
  background: #fff;
  border-left: 6px solid var(--ucsd-yellow);
  color: var(--guide-ink);
  display: flex;
  gap: 0.875rem;
  margin-top: 1.25rem;
  padding: 1.25rem;
}

.planner-notice h2,
.planner-notice h3 {
  color: var(--ucsd-navy);
  font-size: 1.125rem;
  margin: 0 0 0.4375rem;
}

.planner-notice p {
  color: var(--guide-ink) !important;
  margin-bottom: 0;
}

.notice-icon {
  align-items: center;
  background: var(--ucsd-navy);
  border-radius: 50%;
  color: #fff;
  display: inline-flex;
  flex: 0 0 30px;
  font-family: Georgia, serif;
  font-size: 1.25rem;
  font-style: italic;
  font-weight: 700;
  height: 30px;
  justify-content: center;
  width: 30px;
}

.step-nav {
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  margin-top: 2.5rem;
  padding-top: 1.5rem;
}

.step-nav ol {
  display: grid;
  gap: 0.625rem;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}

.step-nav a {
  align-items: center;
  color: #fff;
  display: flex;
  font-weight: 700;
  gap: 0.5rem;
  text-decoration: none;
}

.step-nav a:hover,
.step-nav a:focus {
  text-decoration: underline;
}

.step-nav span,
.step-label span {
  align-items: center;
  background: var(--ucsd-yellow);
  border-radius: 50%;
  color: var(--ucsd-navy);
  display: inline-flex;
  flex: 0 0 auto;
  height: 1.75rem;
  justify-content: center;
  letter-spacing: normal;
  width: 1.75rem;
}

.guide-section {
  padding: 4.5rem 0;
}

.section-tint {
  background: var(--guide-tint);
}

.guide-row {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
}

.guide-section h2 {
  color: var(--ucsd-navy);
  font-size: clamp(1.875rem, 4vw, 2.8125rem);
  line-height: 1.15;
  margin: 0 0 1.25rem;
}

.guide-section h3 {
  color: var(--ucsd-navy);
  font-size: 1.375rem;
  line-height: 1.25;
}

.guide-section p,
.guide-section li,
.guide-section dd {
  font-size: 1.0625rem;
  line-height: 1.7;
}

.guide-section .lead {
  color: var(--guide-muted);
  font-size: 1.25rem;
}

.feature-list {
  list-style: none;
  margin: 1.25rem 0;
  padding: 0;
}

.feature-list li {
  padding: 0 0 0.75rem 1.875rem;
  position: relative;
}

.feature-list li::before {
  color: var(--ucsd-blue);
  content: "✓";
  font-size: 1.125rem;
  font-weight: 700;
  left: 0;
  position: absolute;
  top: 0;
}

.screenshot {
  margin: 0;
  padding: 0 0 0 1.875rem;
}

.screenshot img,
.screenshot video {
  background: #fff;
  border: 1px solid var(--guide-line);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(24, 43, 73, 0.14);
  display: block;
  height: auto;
  margin: 0 auto;
  max-width: 100%;
}

.screenshot-frame {
  border: 1px solid var(--guide-line);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(24, 43, 73, 0.14);
  overflow: hidden;
}

.detailed-workspace-frame {
  aspect-ratio: 1535 / 1059;
  border: 1px solid var(--guide-line);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(24, 43, 73, 0.14);
  overflow: hidden;
}

.screenshot .detailed-workspace-frame img {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  height: auto;
  margin: 0;
  max-width: none;
  transform: translateY(-5.867%);
  width: 100%;
}

.screenshot-zoom .screenshot-frame {
  aspect-ratio: 897 / 710;
}

.screenshot-zoom img {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  height: 100%;
  max-width: none;
  object-fit: cover;
  transform: scale(1.3);
  transform-origin: center 47%;
  width: 100%;
}

/* The source recordings have ~12px black-cornered frames baked in; clipping
   slightly deeper than that radius keeps the video corners clean. */
.screenshot video {
  border-radius: 16px;
}

.screenshot figcaption {
  color: var(--guide-muted);
  font-size: 0.875rem;
  line-height: 1.55;
  margin: 1rem auto 0;
  max-width: 860px;
  text-align: center;
}

.guide-row-reverse .screenshot,
.detail-row .screenshot {
  padding-left: 0;
  padding-right: 1.875rem;
}

.section-heading {
  margin: 0 auto 2.5rem;
  max-width: 900px;
  text-align: center;
}

.compare-notes {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.compare-notes > div {
  display: flex;
}

.info-card {
  background: var(--guide-info);
  border-top: 5px solid var(--ucsd-bright-blue);
  padding: 1.25rem 1.5rem;
  width: 100%;
}

.info-card h3 {
  color: var(--ucsd-navy);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 0.75rem;
}

.info-card p {
  font-size: 1rem;
  margin-bottom: 0;
}

.planning-methods {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 1.5rem 0;
}

.personal-schedule-card {
  margin: 1.5rem 0;
}

.map-feature-row {
  scroll-margin-top: 1.5rem;
}

.map-feature-row .screenshot picture {
  display: block;
}

.screenshot-wide {
  padding: 0;
}

.screenshot-wide img {
  width: 930px;
}

.screenshot-wide .detailed-workspace-frame img {
  width: 100%;
}

.term-list {
  margin: 1.5rem 0;
}

.term-list dt {
  color: var(--ucsd-navy);
  font-size: 1.0625rem;
  margin-top: 0.8125rem;
}

.term-list dd {
  color: var(--guide-muted);
  margin-left: 0;
}

.small-note {
  border-left: 4px solid var(--ucsd-blue);
  color: var(--guide-muted);
  padding-left: 1rem;
}

.detail-row {
  border-top: 1px solid var(--guide-line);
  margin-top: 3.75rem;
  padding-top: 3.75rem;
}

.planner-notice-wide {
  background: var(--guide-info);
  border: 1px solid #b7d8e8;
  border-left: 6px solid var(--ucsd-blue);
  margin-top: 3rem;
}

.release-notes-row {
  display: flex;
  flex-wrap: wrap;
}

.release-notes-row > div {
  display: flex;
}

.release-note-latest {
  margin-bottom: 1.5rem;
}

.release-note-initial {
  margin-top: 1.5rem;
}

.release-note-latest .release-note {
  border-top-color: var(--ucsd-yellow);
}

.release-note {
  background: #fff;
  border-top: 5px solid var(--ucsd-blue);
  box-shadow: 0 12px 30px rgba(24, 43, 73, 0.1);
  padding: 1.5rem;
  width: 100%;
}

.release-note time,
.release-note .release-date {
  color: var(--ucsd-blue);
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin-bottom: 0.625rem;
  text-transform: uppercase;
}

.release-note h3 {
  margin-top: 0;
}

.release-note ul {
  margin-bottom: 0;
  padding-left: 1.25rem;
}

.faq-item {
  border-top: 1px solid var(--guide-line);
  padding: 1.25rem 0;
}

.faq-item h3 {
  font-size: 1.25rem;
  margin: 0 0 0.625rem;
}

.faq-item p {
  color: var(--guide-muted);
  font-size: 1rem;
  margin-bottom: 0;
}

.faq-item a {
  text-decoration: underline;
}

.closing-cta {
  background: var(--ucsd-navy);
  color: #fff;
  margin-top: 2.5rem;
  padding: 1.875rem;
  text-align: center;
}

.closing-cta h2,
.closing-cta p {
  color: #fff;
}

.closing-cta h2 {
  margin-bottom: 0.625rem;
}

.closing-cta .btn {
  margin-top: 0.625rem;
}

code {
  color: var(--ucsd-navy);
  white-space: normal;
}

@media (max-width: 991px) {
  .guide-hero {
    padding-top: 2.5rem;
  }

  .guide-row {
    display: block;
  }

  .screenshot,
  .guide-row-reverse .screenshot,
  .detail-row .screenshot {
    margin-top: 1.875rem;
    padding: 0;
  }

  .planner-notice {
    margin-top: 1.875rem;
  }

  .release-notes-row > div {
    display: block;
    margin-bottom: 1.5rem;
  }

  .release-notes-row > div:last-child {
    margin-bottom: 0;
  }

  .hero-shot {
    margin-top: 1.875rem;
    max-width: 420px;
  }

  .step-nav ol {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .planning-methods {
    grid-template-columns: 1fr;
  }

  .navbar .container > .navbar-header {
    margin-left: 0;
    margin-right: 0;
    position: relative;
  }

  .navbar-collapse {
    max-height: none;
  }

  .navbar-nav-list > li > a {
    min-height: 44px;
    padding-bottom: 12px;
    padding-top: 12px;
  }

  .guide-hero {
    margin-top: 0.5rem;
    padding: 2.25rem 0 1.5rem;
  }

  .guide-hero h1 {
    font-size: 2.375rem;
  }

  .guide-hero .lead {
    font-size: 1.1875rem;
  }

  .step-nav ol {
    grid-template-columns: 1fr 1fr;
  }

  .guide-section {
    padding: 3rem 0;
  }

  .guide-section h2 {
    font-size: 2rem;
  }

  .guide-section p,
  .guide-section li,
  .guide-section dd {
    font-size: 1rem;
  }

  .compare-notes {
    display: block;
  }

  .compare-notes > div + div {
    margin-top: 1.25rem;
  }

  .section-heading {
    text-align: left;
  }

  /* Keep every screenshot fully inside the phone viewport. */
  .screenshot-scroller {
    overflow: hidden;
    width: 100%;
  }

  .screenshot-scroller img {
    max-width: 100%;
    width: 100%;
  }

  .screenshot-zoom img {
    transform: none;
  }

  .detail-row {
    margin-top: 2.5rem;
    padding-top: 2.5rem;
  }

  .planner-notice {
    padding: 1rem;
  }

  .closing-cta {
    padding: 1.5rem 1rem;
  }
}

@media (max-width: 420px) {
  .mobile-logo-wrap {
    max-width: 140px;
  }

  .guide-hero h1 {
    font-size: 2rem;
  }

  .step-nav ol {
    grid-template-columns: 1fr;
  }

  .hero-actions .btn {
    display: block;
    width: 100%;
  }

  .planner-notice {
    display: block;
  }

  .notice-icon {
    margin-bottom: 0.625rem;
  }
}

@media (min-width: 768px) {
  .navbar-toggle {
    display: none;
  }

  /* The horizontal navbar takes over at desktop widths; never render the
     off-canvas drawer as static content there. */
  .navmenu {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

@media print {
  .navbar,
  .step-nav,
  .hero-actions,
  .closing-cta {
    display: none !important;
  }

  .guide-hero {
    background: none;
    color: #000;
    padding: 2rem 0;
  }

  .guide-hero h1,
  .guide-hero .lead,
  .guide-hero p:not(.eyebrow) {
    color: #000;
  }

  .guide-section {
    padding: 2rem 0;
  }

  .screenshot img,
  .screenshot video {
    box-shadow: none;
  }
}
