:root {
  --umarn-primary: #0d9488;
  --umarn-primary-dark: #0f766e;
  --umarn-primary-light: #ccfbf1;
  --umarn-accent: #6366f1;
  --umarn-accent-warm: #f59e0b;
  --umarn-bg: #fafbfc;
  --umarn-surface: #ffffff;
  --umarn-text: #0f172a;
  --umarn-muted: #64748b;
  --umarn-border: #e2e8f0;
  --umarn-radius: 16px;
  --umarn-radius-sm: 10px;
  --umarn-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
  --umarn-shadow-lg: 0 20px 50px rgba(15, 23, 42, 0.12);
  --font-sans: "DM Sans", system-ui, -apple-system, sans-serif;
  --font-display: "Instrument Serif", Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--umarn-text);
  background: var(--umarn-bg);
  line-height: 1.65;
  font-size: 1rem;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--umarn-primary);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--umarn-primary-dark);
}

.container {
  width: min(1140px, 92vw);
  margin: 0 auto;
}

/* Typography */
.eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--umarn-primary);
  margin: 0 0 0.75rem;
}

.section-eyebrow {
  text-align: center;
}

h1, h2, h3 {
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* Header */
.site-header {
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--umarn-border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 0.9rem 0;
  flex-wrap: wrap;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--umarn-text);
  text-decoration: none;
}

.logo-link:hover {
  text-decoration: none;
  color: var(--umarn-text);
}

.logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--umarn-primary), var(--umarn-accent));
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 1rem;
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.35);
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--umarn-muted);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--umarn-primary);
}

/* Campus selector */
.campus-selector {
  position: relative;
}

.campus-selector select {
  appearance: none;
  background: var(--umarn-bg);
  border: 1px solid var(--umarn-border);
  border-radius: 999px;
  padding: 0.5rem 2.25rem 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--umarn-text);
  cursor: pointer;
  min-width: 180px;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.campus-selector select:focus {
  outline: none;
  border-color: var(--umarn-primary);
  box-shadow: 0 0 0 3px var(--umarn-primary-light);
}

.campus-selector::after {
  content: "";
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  border: 5px solid transparent;
  border-top-color: var(--umarn-muted);
}

/* Hero — home */
.hero-home {
  position: relative;
  padding: 4.5rem 0 5rem;
  text-align: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(13, 148, 136, 0.15), transparent),
    radial-gradient(ellipse 50% 40% at 90% 20%, rgba(99, 102, 241, 0.08), transparent);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-home h1 {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 3.75rem);
  font-weight: 400;
  margin: 0 0 1.25rem;
  line-height: 1.08;
}

.hero-home h1 em {
  font-style: italic;
  color: var(--umarn-primary);
}

.hero .lead,
.hero-home .lead {
  font-size: 1.125rem;
  color: var(--umarn-muted);
  max-width: 540px;
  margin: 0 auto 2rem;
}

/* Hero — campus */
.hero-campus {
  background: linear-gradient(155deg, var(--campus-primary, var(--umarn-primary)) 0%, #0f172a 72%);
  color: #fff;
  padding: 3.5rem 0 4.5rem;
}

.hero-campus h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 400;
  margin: 0 0 0.5rem;
  color: #fff;
}

.hero-campus .tagline {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
  color: rgba(255, 255, 255, 0.95);
}

.hero-campus .lead {
  color: rgba(255, 255, 255, 0.8);
  max-width: 520px;
  margin: 0 auto 1.5rem;
}

.campus-logo-hero {
  width: 96px;
  height: 96px;
  object-fit: contain;
  border-radius: 22px;
  background: #fff;
  padding: 10px;
  margin-bottom: 1.25rem;
  box-shadow: var(--umarn-shadow-lg);
}

.campus-logo-placeholder {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.15);
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 800;
  margin: 0 auto 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Icons */
.ui-icon {
  display: inline-flex;
  width: 1.25em;
  height: 1.25em;
  vertical-align: middle;
}

.ui-icon svg {
  width: 100%;
  height: 100%;
}

.benefit-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--umarn-primary-light);
  color: var(--umarn-primary);
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
}

.benefit-icon .ui-icon {
  width: 24px;
  height: 24px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.5rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  font-family: inherit;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s;
}

.btn:hover {
  transform: translateY(-2px);
  text-decoration: none;
}

.btn-lg {
  padding: 1rem 1.75rem;
  font-size: 1rem;
}

.btn-primary {
  background: #25d366;
  color: #fff;
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.35);
}

.btn-primary:hover {
  color: #fff;
  box-shadow: 0 12px 32px rgba(37, 211, 102, 0.45);
}

.btn-secondary {
  background: var(--umarn-surface);
  color: var(--umarn-text);
  border: 2px solid var(--umarn-border);
  box-shadow: var(--umarn-shadow);
}

.btn-secondary:hover {
  border-color: var(--umarn-primary);
  color: var(--umarn-primary);
}

.btn-campus {
  background: var(--campus-primary, var(--umarn-primary));
  color: #fff;
  box-shadow: 0 8px 24px rgba(13, 148, 136, 0.35);
}

.btn-campus:hover {
  color: #fff;
}

.btn-ghost-light {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.btn-ghost-light:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
  margin-top: 1.5rem;
}

/* Sections */
.section {
  padding: 4rem 0;
}

.section-muted {
  background: var(--umarn-surface);
  border-top: 1px solid var(--umarn-border);
  border-bottom: 1px solid var(--umarn-border);
}

.section-title {
  text-align: center;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400;
  margin: 0 0 0.5rem;
}

.section-sub {
  text-align: center;
  color: var(--umarn-muted);
  margin: 0 0 2.5rem;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.empty-state {
  text-align: center;
  color: var(--umarn-muted);
  padding: 2rem;
}

/* Campus grid */
.campus-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.campus-card {
  background: var(--umarn-surface);
  border: 1px solid var(--umarn-border);
  border-radius: var(--umarn-radius);
  padding: 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.2s;
  display: block;
}

.campus-card:hover {
  box-shadow: var(--umarn-shadow-lg);
  border-color: var(--umarn-primary);
  transform: translateY(-4px);
  text-decoration: none;
  color: inherit;
}

.campus-card-top {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.campus-card-logo {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  object-fit: contain;
  background: var(--umarn-bg);
}

.campus-card-initial {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--umarn-primary), var(--umarn-accent));
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.1rem;
}

.campus-card h3 {
  margin: 0;
  font-size: 1.1rem;
}

.campus-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--umarn-muted);
}

.campus-card .arrow {
  margin-top: 1rem;
  font-weight: 700;
  color: var(--umarn-primary);
  font-size: 0.875rem;
}

/* Benefits */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.25rem;
}

.benefit-card {
  background: var(--umarn-surface);
  border-radius: var(--umarn-radius);
  padding: 1.75rem;
  border: 1px solid var(--umarn-border);
  transition: box-shadow 0.2s;
}

.benefit-card:hover {
  box-shadow: var(--umarn-shadow);
}

.benefit-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
}

.benefit-card p {
  margin: 0;
  color: var(--umarn-muted);
  font-size: 0.9375rem;
}

/* CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--umarn-primary) 0%, #0f766e 100%);
  color: #fff;
  text-align: center;
  padding: 3.5rem 0;
}

.cta-campus {
  background: linear-gradient(135deg, var(--campus-primary, var(--umarn-primary)) 0%, #0f172a 100%);
}

.cta-inner h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 400;
  margin: 0 0 0.5rem;
  color: #fff;
}

.cta-inner p {
  margin: 0 0 1.5rem;
  opacity: 0.9;
}

/* Footer */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 3rem 0 0;
  margin-top: 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 2rem;
  padding-bottom: 2rem;
}

.footer-brand {
  color: #fff;
  font-weight: 800;
  font-size: 1.15rem;
  margin: 0 0 0.5rem;
}

.footer-tagline {
  margin: 0;
  font-size: 0.9rem;
  max-width: 280px;
  line-height: 1.6;
}

.footer-heading {
  color: #e2e8f0;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 0.75rem;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.site-footer a {
  color: #cbd5e1;
  font-size: 0.9375rem;
}

.site-footer a:hover {
  color: #fff;
}

.footer-wa-link {
  display: inline-block;
  margin-top: 0.5rem;
  font-weight: 600;
  color: #25d366 !important;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.25rem 0;
  font-size: 0.8125rem;
  text-align: center;
}

.footer-bottom p {
  margin: 0;
}

/* Content pages */
.page-hero {
  padding: 3rem 0;
  text-align: center;
  border-bottom: 1px solid var(--umarn-border);
  background: var(--umarn-surface);
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 400;
  margin: 0;
}

.prose {
  max-width: 680px;
  margin: 0 auto;
  padding: 2.5rem 0 4rem;
}

.prose h2 {
  margin-top: 2rem;
  font-size: 1.25rem;
}

.prose ul, .prose ol {
  padding-left: 1.25rem;
}

.prose li {
  margin-bottom: 0.35rem;
}

.legal-prose code {
  background: var(--umarn-bg);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.875em;
}

.contact-box {
  background: var(--umarn-surface);
  border: 1px solid var(--umarn-border);
  border-radius: var(--umarn-radius);
  padding: 2rem;
  max-width: 480px;
  margin: 2rem auto;
  box-shadow: var(--umarn-shadow);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand-col {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .main-nav {
    order: 3;
    width: 100%;
  }
  .nav-links {
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
  }
  .header-inner {
    justify-content: center;
  }
  .campus-selector {
    width: 100%;
  }
  .campus-selector select {
    width: 100%;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Legal pages with TOC sidebar ────────────────────────────────── */

/* Full-width layout wrapper that sits inside .container */
.legal-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 3rem;
  align-items: start;
  padding: 2.5rem 0 4rem;
}

/* TOC sidebar */
.legal-toc {
  position: sticky;
  top: calc(64px + 1.5rem); /* below sticky header */
  background: var(--umarn-surface);
  border: 1px solid var(--umarn-border);
  border-radius: var(--umarn-radius-sm);
  padding: 1.25rem 1rem;
  font-size: 0.875rem;
}

.legal-toc-title {
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--umarn-muted);
  margin: 0 0 0.75rem;
}

.legal-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc-counter;
}

.legal-toc li {
  counter-increment: toc-counter;
  margin-bottom: 0.3rem;
  line-height: 1.35;
}

.legal-toc a {
  color: var(--umarn-muted);
  text-decoration: none;
  display: block;
  padding: 0.2rem 0.35rem;
  border-radius: 4px;
  transition: background 0.12s, color 0.12s;
}

.legal-toc a:hover {
  background: var(--umarn-primary-light);
  color: var(--umarn-primary-dark);
}

/* Main prose column inside the layout */
.legal-body {
  min-width: 0; /* prevent grid blowout */
}

.legal-body h2 {
  margin-top: 2.5rem;
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  scroll-margin-top: 80px; /* offset for sticky header */
  border-bottom: 1px solid var(--umarn-border);
  padding-bottom: 0.35rem;
}

.legal-body h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.4rem;
  font-size: 1rem;
  font-weight: 700;
  scroll-margin-top: 80px;
}

.legal-body p {
  margin: 0 0 1rem;
}

.legal-body ul,
.legal-body ol {
  padding-left: 1.4rem;
  margin: 0 0 1rem;
}

.legal-body li {
  margin-bottom: 0.4rem;
}

.legal-body code {
  background: var(--umarn-bg);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.875em;
}

/* Highlight / callout box inside legal pages */
.legal-callout {
  background: var(--umarn-primary-light);
  border-left: 4px solid var(--umarn-primary);
  border-radius: 0 var(--umarn-radius-sm) var(--umarn-radius-sm) 0;
  padding: 0.9rem 1.1rem;
  margin: 1.25rem 0;
  font-size: 0.9375rem;
}

.legal-callout strong {
  color: var(--umarn-primary-dark);
}

.legal-callout-warn {
  background: #fff7ed;
  border-left-color: #f59e0b;
}

.legal-callout-warn strong {
  color: #b45309;
}

/* Commission / earnings table */
.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
  margin: 1rem 0 1.5rem;
}

.legal-table th {
  background: var(--umarn-bg);
  border: 1px solid var(--umarn-border);
  padding: 0.6rem 0.85rem;
  text-align: left;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.legal-table td {
  border: 1px solid var(--umarn-border);
  padding: 0.6rem 0.85rem;
  vertical-align: top;
}

.legal-table tr:nth-child(even) td {
  background: #f8fafc;
}

/* Nav dropdown for Legal links */
.nav-dropdown {
  position: relative;
}

.nav-dropdown > a {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.nav-dropdown > a::after {
  content: "";
  display: inline-block;
  border: 4px solid transparent;
  border-top-color: currentColor;
  margin-top: 2px;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.5rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--umarn-surface);
  border: 1px solid var(--umarn-border);
  border-radius: var(--umarn-radius-sm);
  box-shadow: var(--umarn-shadow-lg);
  min-width: 200px;
  list-style: none;
  margin: 0;
  padding: 0.4rem 0;
  z-index: 200;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu li a {
  display: block;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--umarn-muted);
  white-space: nowrap;
}

.nav-dropdown-menu li a:hover {
  color: var(--umarn-primary);
  background: var(--umarn-primary-light);
}

/* Responsive: stack TOC above content on small screens */
@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .legal-toc {
    position: static;
  }
}

@media (max-width: 640px) {
  .nav-dropdown-menu {
    left: 0;
    transform: none;
  }
}
