/* =====================================================================
   BUS622 — Global Marketing Study Guide
   Shared design system: light glassmorphism, navy/crimson/gold palette.
   ===================================================================== */

:root {
  --navy:         #1F3A52;
  --navy-dark:    #14283A;
  --navy-soft:    #2C4A66;
  --crimson:      #A63A3A;
  --gold:         #D4AF37;
  --gold-soft:    #E6C76A;
  --text:         #1A1A1A;
  --text-muted:   #555555;
  --bg-base:      linear-gradient(135deg, #EEF2F8 0%, #F2F5FA 50%, #E8EEF6 100%);
  --glass-bg:     rgba(255, 255, 255, 0.78);
  --glass-border: rgba(31, 58, 82, 0.12);
  --shadow-sm:    0 4px 16px rgba(31, 58, 82, 0.08);
  --shadow-md:    0 8px 32px rgba(31, 58, 82, 0.10);
  --font-sans:    "Segoe UI", "Inter", -apple-system, BlinkMacSystemFont,
                   "Helvetica Neue", Arial, sans-serif;
  --radius:       16px;
}

/* ----- Reset ----- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-base);
  background-attachment: fixed;
  min-height: 100vh;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--crimson); }

/* ----- Crimson top stripe + sticky navy header ----- */
.top-stripe {
  position: sticky;
  top: 0;
  height: 4px;
  background: var(--crimson);
  z-index: 30;
}
.site-header {
  position: sticky;
  top: 4px;
  z-index: 25;
  background: var(--navy);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.wordmark {
  color: #fff;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.wordmark-eyebrow {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  color: var(--gold-soft);
  text-transform: uppercase;
  font-weight: 700;
}
.wordmark-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}
.breadcrumb a {
  color: #DCE5F0;
  text-decoration: none;
  font-size: 0.95rem;
}
.breadcrumb a:hover { color: var(--gold-soft); }

/* Header title block — compressed hero, max ~140px */
.header-titleblock {
  background: var(--navy-dark);
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.header-titleblock-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 16px 24px 22px;
}
.header-titleblock .page-title {
  margin: 4px 0 2px;
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1.2;
  color: #fff;
}
.header-titleblock .page-subtitle {
  margin: 0;
  color: #B6C2D2;
  font-size: 0.95rem;
}

/* ----- Overline labels (gold all-caps) ----- */
.overline-gold {
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gold);
}
.header-titleblock .overline-gold {
  color: var(--gold-soft);
}

/* ----- Main + Cards ----- */
.site-main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 24px 20px 64px;
}
.card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 24px 26px;
  margin: 0 0 22px;
  backdrop-filter: blur(10px) saturate(1.05);
  -webkit-backdrop-filter: blur(10px) saturate(1.05);
  box-shadow: var(--shadow-sm);
}

/* ----- Meta card (dl grid) ----- */
.meta-card { padding: 18px 22px; }
.meta-grid {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px 24px;
}
@media (min-width: 720px) {
  .meta-grid { grid-template-columns: 1fr 1fr; }
}
.meta-row { margin: 0; }
.meta-row dt { margin: 0; }
.meta-row dd {
  margin: 2px 0 0;
  color: var(--text);
  font-size: 0.97rem;
}

/* ----- Section card (the workhorse) ----- */
.section-card { position: relative; }
.section-overline { margin-top: -4px; }
.section-header {
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.section-number {
  font-family: var(--font-sans);
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1;
  color: var(--navy);
  flex: 0 0 auto;
  min-width: 2ch;
}
.section-title {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.25;
}
.hairline {
  border: 0;
  border-top: 2px solid var(--crimson);
  margin: 10px 0 16px;
  width: 56px;
}

.section-body p {
  margin: 0 0 14px;
}
.section-body h3 {
  margin: 22px 0 8px;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.3;
}
.section-body ul,
.section-body ol {
  margin: 8px 0 16px;
  padding-left: 0;
  list-style: none;
}
.section-body ul li,
.section-body ol li {
  position: relative;
  padding: 4px 0 4px 22px;
  line-height: 1.55;
}
.section-body ul li::before {
  content: "▸";
  position: absolute;
  left: 0;
  top: 4px;
  color: var(--navy);
  font-weight: 700;
}
.section-body ol {
  counter-reset: olc;
}
.section-body ol li {
  counter-increment: olc;
}
.section-body ol li::before {
  content: counter(olc) ".";
  position: absolute;
  left: 0;
  top: 4px;
  color: var(--navy);
  font-weight: 700;
}

/* ----- Callout ----- */
.callout {
  margin: 16px 0;
  padding: 14px 18px;
  background: rgba(31, 58, 82, 0.04);
  border-left: 3px solid var(--gold);
  border-radius: 8px;
}
.callout p:last-child { margin: 0; }
.callout .overline-gold { margin-bottom: 4px; }

/* ----- Tables ----- */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 14px 0 18px;
  border-radius: 10px;
  border: 1px solid var(--glass-border);
  background: rgba(255,255,255,0.6);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
thead th {
  background: var(--navy);
  color: #fff;
  text-align: left;
  font-weight: 600;
  padding: 10px 12px;
  vertical-align: top;
}
tbody td {
  padding: 9px 12px;
  border-top: 1px solid var(--glass-border);
  vertical-align: top;
  color: var(--text);
}
tbody tr:nth-child(odd) td {
  background: rgba(31, 58, 82, 0.03);
}

/* ----- Index page ----- */
.hero-card {
  padding: 26px 28px;
}
.hero-title {
  margin: 4px 0 12px;
  color: var(--navy);
  font-size: 1.5rem;
  line-height: 1.25;
}
.hero-actions { margin: 14px 0 0; }
.weeks-heading {
  margin: 28px 8px 12px;
  color: var(--navy);
  font-size: 1.25rem;
  letter-spacing: 0.01em;
}

/* ----- Week accordion ----- */
.week-block {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  margin: 0 0 14px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.week-summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 22px;
  cursor: pointer;
  list-style: none;
  font-size: 1rem;
  color: var(--navy);
}
.week-summary::-webkit-details-marker { display: none; }
.week-summary::before {
  content: "+";
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  flex: 0 0 auto;
  transition: transform .2s;
}
.week-block[open] .week-summary::before {
  content: "−";
}
.week-label {
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  color: var(--gold);
  flex: 0 0 auto;
}
.week-title {
  font-weight: 600;
  flex: 1 1 auto;
}
.week-count {
  color: var(--text-muted);
  font-size: 0.85rem;
  flex: 0 0 auto;
}
.week-body {
  padding: 4px 18px 18px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 720px) {
  .week-body { grid-template-columns: 1fr 1fr; }
}

/* ----- Guide card (in week body) ----- */
.guide-card {
  background: rgba(255,255,255,0.78);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.guide-card-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.guide-card-title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.3;
  flex: 1 1 auto;
}
.guide-card-title a {
  color: inherit;
  text-decoration: none;
}
.guide-card-title a:hover { color: var(--crimson); text-decoration: underline; }
.guide-card-descriptor {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.guide-card-actions {
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

/* ----- Badges ----- */
.badge {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
  border: 1px solid transparent;
}
.badge-study      { background: rgba(31,58,82,0.08); color: var(--navy); border-color: rgba(31,58,82,0.18); }
.badge-discussion { background: rgba(166,58,58,0.08); color: var(--crimson); border-color: rgba(166,58,58,0.22); }
.badge-assignment { background: rgba(212,175,55,0.14); color: #806A1F; border-color: rgba(212,175,55,0.40); }
.badge-journal    { background: rgba(44,74,102,0.10); color: var(--navy-soft); border-color: rgba(44,74,102,0.22); }
.badge-final      { background: rgba(20,40,58,0.85); color: #fff; border-color: var(--navy-dark); }

/* ----- Buttons ----- */
.btn-primary, .btn-secondary, .canvas-link {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 8px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background .15s, color .15s, border-color .15s;
}
.btn-primary {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}
.btn-primary:hover {
  background: var(--navy-dark);
  color: #fff;
}
.btn-secondary {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-secondary:hover {
  background: rgba(31,58,82,0.06);
  color: var(--navy-dark);
}
.canvas-link {
  padding: 6px 10px;
  background: transparent;
  color: var(--crimson);
  border: 0;
  text-decoration: underline;
}
.canvas-link:hover { color: var(--navy); }

/* ----- Reference card ----- */
.reference-card { margin-top: 24px; }
.reference-title {
  margin: 4px 0 8px;
  color: var(--navy);
  font-size: 1.15rem;
}

/* ----- Page-bottom nav ----- */
.page-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 28px 0 0;
}

/* ----- Footer ----- */
.site-footer {
  border-top: 1px solid var(--glass-border);
  background: rgba(255,255,255,0.55);
  padding: 18px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.88rem;
}
.site-footer a { color: var(--navy); text-decoration: none; }
.site-footer a:hover { color: var(--crimson); text-decoration: underline; }

/* ===================================================================
   Mobile (<= 720px) — typography + layout step-down
   =================================================================== */
@media (max-width: 720px) {
  body { font-size: 16px; }
  .site-main { padding: 18px 14px 56px; }
  .header-inner { padding: 0 16px; height: 56px; }
  .wordmark-title { font-size: 0.95rem; }
  .header-titleblock-inner { padding: 14px 16px 18px; }
  .header-titleblock .page-title { font-size: 1.32rem; }
  .header-titleblock .page-subtitle { font-size: 0.88rem; }

  .card { padding: 18px 18px; }
  .section-number { font-size: 1.7rem; }
  .section-title { font-size: 1.2rem; }
  .section-body h3 { font-size: 1.05rem; }

  .week-summary { padding: 12px 16px; gap: 10px; font-size: 0.95rem; }
  .week-body { padding: 4px 12px 14px; }
  .guide-card { padding: 12px 14px 14px; }
  .badge { font-size: 0.62rem; padding: 2px 7px; }

  .meta-grid { grid-template-columns: 1fr; }
  table { font-size: 0.88rem; }
  thead th, tbody td { padding: 8px 10px; }
}
@media (max-width: 380px) {
  .header-titleblock .page-title { font-size: 1.18rem; }
  .section-number { font-size: 1.5rem; }
  .section-title { font-size: 1.08rem; }
}
