/* CollandUni shared design system (matches index.html) */
:root {
  --bg: #ffffff;
  --surface: #f6f7f9;
  --border: #e6e8ec;

  --text: #111418;
  --muted: #5b6470;
  --faint: #8b939e;

  --primary: #ffd60a;
  --primary-hover: #ffdb33;
  --primary-shade: #e6b800;
  --primary-text: #111418;
  --topbar-h: 64px;
  --btn-size: 17px;
  --input-radius: 14px;

  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-soft: #dbeafe;
  --accent-border: #bfdbfe;

  --success: #16a34a;
  --danger: #dc2626;

  --radius: 16px;
  --container: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Poppins;
  line-height: 1.55;
  font-size: 1rem;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

img, svg { max-width: 100%; height: auto; }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 20px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--topbar-h);
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 100%;
  min-height: 0;
}

.brand {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s ease;
}

.brand:hover { color: var(--accent); }

.desktop-nav {
  display: none;
  gap: 22px;
  align-items: center;
}

.desktop-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a:focus-visible { color: var(--accent); }

/* Language switcher */
.cu-lang {
  min-height: 40px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--muted);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}

.cu-lang:hover { border-color: var(--accent-border); color: var(--accent); }

/* Video guides (borderless cards: video + title only) */
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.video-card { border: 0; background: transparent; padding: 0; }
.video-frame { position: relative; width: 100%; padding-top: 56.25%; border-radius: 12px; overflow: hidden; background: #000; }
.video-frame iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.video-title { font-family: 'Poppins'; font-weight: 700; font-size: .875rem; margin-top: 8px; color: var(--ink); }
@media (max-width: 860px) { .video-grid { grid-template-columns: 1fr; } }

/* Buttons */
button, .btn {
  font-family: 'Poppins' !important;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  min-width: 48px;
  padding: 14px 26px;
  border: 0;
  border-radius: 14px;
  font: inherit;
  font-size: var(--btn-size);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-text);
  box-shadow: 0 4px 0 var(--primary-shade);
}

.btn-primary:hover { background: var(--primary-hover); }
.btn-primary:active { transform: translateY(3px); box-shadow: none; }

.btn-outline {
  background: #fff;
  color: var(--accent);
  border: 2px solid var(--accent-border);
  box-shadow: 0 4px 0 var(--accent-border);
}

.btn-outline:hover { background: #f4f5f7; color: var(--ink); }
.btn-outline:active { transform: translateY(3px); box-shadow: none; }

.btn-dark {
  background: var(--primary);
  color: #201900;
  min-height: 44px;
  padding: 10px 18px;
}

.btn-dark:hover { background: var(--primary-hover); }

/* Back icon beside auth titles */
.lx-title-row { display: flex; align-items: center; gap: 10px; margin: 8px 0; }
.lx-title-row > .lx-title { margin: 0; }
.lx-back {
  flex: none;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 0;
  border-radius: 50%;
  color: #17191c;
  cursor: pointer;
  padding: 0;
  margin: 0 0 0 -10px;
}
.lx-back:hover { background: transparent; }
.lx-back svg { width: 20px; height: 20px; display: block; }

/* Auth + flow titles and subtitles (same scale as index page headings) */
.lx-title { margin: 8px 0; font-size: clamp(1.625rem, 5vw, 2.125rem); line-height: 1.15; letter-spacing: -0.01em; font-weight: 700; }
.lx-sub { margin: 0 0 16px; color: var(--muted); font-size: .9375rem; line-height: 1.5; }

/* Hero */
.hero {
  padding: 56px 0 64px;
  text-align: center;
}

.hero-inner {
  display: grid;
  gap: 18px;
  justify-items: center;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2rem, 6vw, 3.1rem);
  line-height: 1.08;
  max-width: 22ch;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.hero p {
  margin: 0;
  max-width: 54ch;
  color: var(--muted);
  transition: color 0.2s ease;
}

.hero p strong { color: var(--text); font-weight: 700; }

.hero h1:hover {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: var(--primary);
  text-decoration-thickness: 4px;
  text-underline-offset: 8px;
}

.hero p:hover { color: var(--accent-hover); }

@media (hover: none) {
  .hero h1:hover,
  .hero p:hover {
    color: inherit;
    text-decoration: none;
  }
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 8px 15px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
}

.badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
}

.cta-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  width: min(100%, 320px);
  margin-top: 8px;
}

/* Generic page sections (content pages) */
.page-main { padding: 48px 0 72px; }

.page-main h1 {
  margin: 0 0 8px;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  line-height: 1.1;
}

.page-main .lede {
  margin: 0 0 32px;
  color: var(--muted);
  max-width: 62ch;
}

.prose h2 {
  margin: 36px 0 10px;
  font-size: 1.25rem;
}

.prose p,
.prose li {
  color: var(--muted);
  max-width: 70ch;
}

.prose a { color: var(--accent); font-weight: 700; }

/* Cards / forms */
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--input-radius);
  font: inherit;
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-note {
  margin: 16px 0 0;
  font-size: 0.9rem;
  color: var(--muted);
  text-align: center;
}

.form-note a { color: var(--accent); font-weight: 700; }

/* Stats */
.stats {
  border-block: 1px solid var(--border);
  padding: 36px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px 16px;
  text-align: center;
}

.stat b {
  display: block;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  transition: color 0.2s ease;
}

.stat:hover b { color: var(--accent); }

.stat small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
}

/* FAQ */
.faq { padding: 56px 0; }
.faq-inner { max-width: 760px; }

.faq h2 {
  margin: 0 0 20px;
  font-size: clamp(1.5rem, 4vw, 2rem);
}

.faq details {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 12px;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.faq details:hover {
  border-color: var(--accent-border);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.08);
}

.faq summary {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
  cursor: pointer;
  transition: color 0.2s ease;
}

.faq summary:hover { color: var(--accent); }

.faq p {
  margin: 12px 0 0;
  color: var(--muted);
}

/* Partners */
.partners { padding: 24px 0 56px; }

.partners-card {
  display: grid;
  gap: 28px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 32px;
}

.partners-card img {
  width: 100%;
  border-radius: var(--radius);
  display: block;
}

.partners-card h2 {
  margin: 0 0 12px;
  font-size: clamp(1.4rem, 3.5vw, 1.9rem);
  line-height: 1.15;
}

.partners-card p {
  margin: 0 0 20px;
  color: var(--muted);
  max-width: 58ch;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

.footer-grid h2 {
  margin: 0 0 10px;
  font-size: 1.05rem;
}

.footer-grid p {
  margin: 0 0 16px;
  color: var(--muted);
  max-width: 52ch;
}

.footer-links {
  display: grid;
  gap: 4px;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover,
.footer-links a:focus-visible { color: var(--accent); }

.social-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.social-row a {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.social-row a:hover,
.social-row a:focus-visible {
  background: var(--accent-soft);
  color: var(--accent);
  transform: translateY(-2px);
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: 0.85rem;
}

.footer-base a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-base a:hover,
.footer-base a:focus-visible { color: var(--accent); }

/* Tablet: 640px+ */
@media (min-width: 640px) {
  .container { padding-inline: 28px; }

  .cta-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(100%, 520px);
  }

  .footer-grid {
    grid-template-columns: 1.4fr 1fr;
    gap: 40px;
  }

  .partners-card {
    grid-template-columns: 1.2fr 1fr;
    padding: 40px;
  }
}

/* Desktop: 900px+ */
@media (min-width: 900px) {
  .desktop-nav { display: flex; }

  .hero {
    padding: 88px 0 96px;
  }

  .stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
  }

  .faq { padding: 80px 0; }
}

@media (min-width: 1200px) {
  .hero h1 {
    font-size: 3.25rem;
  }

  .stats-grid { gap: 40px; }
}

/* Accessibility */
a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

/* ========================================================
   Skeleton Shimmer Placeholders (Modern Loading States)
   ======================================================== */
.skel {
  position: relative;
  overflow: hidden;
  background: var(--surface, #f4f5f7);
  border-radius: 10px;
  min-height: 14px;
}

.skel::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.75) 50%,
    transparent 100%
  );
  animation: skelSweep 1.3s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes skelSweep {
  to { transform: translateX(100%); }
}

html.dark .skel {
  background: #23272d;
}

html.dark .skel::after {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 100%
  );
}

.skel-card {
  background: #fff;
  border: 1px solid var(--border, #e6e8ec);
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 12px;
}

.skel-pill {
  border-radius: 999px !important;
  display: inline-block;
}

.skel-text {
  height: 14px;
  border-radius: 6px;
  margin-bottom: 8px;
}

.skel-title {
  height: 22px;
  border-radius: 8px;
  margin-bottom: 12px;
}

/* Shimmer button state during active forms/actions */
.btn-shimmer {
  position: relative;
  overflow: hidden;
  opacity: 0.88;
  pointer-events: none;
}

.btn-shimmer::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.45) 50%,
    transparent 100%
  );
  animation: skelSweep 1s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
