/* ============================================================
   My Class Attendance — style.css
   Palette, typography and layout (WordPress-migration friendly)
   ============================================================ */

:root {
  --primary: #2563EB;
  --primary-dark: #1D4ED8;
  --secondary: #3B82F6;
  --bg: #F8FAFC;
  --card: #FFFFFF;
  --text: #0F172A;
  --text-muted: #64748B;
  --border: #E2E8F0;
  --success: #10B981;
  --danger: #EF4444;
  --warning: #F59E0B;
  --blog-heading-color: #0F172A;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
  --shadow: 0 4px 20px rgba(15, 23, 42, .06);
  --shadow-lg: 0 20px 40px rgba(15, 23, 42, .10);
  --container: 1120px;
  --font-head: "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

/* ---------- Reset (after Tailwind preflight) ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  font-family: var(--font-body) !important;
  color: var(--text) !important;
  background: var(--bg) !important;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color .25s ease, color .25s ease;
}
h1, h2, h3, h4 {
  font-family: var(--font-head) !important;
  color: var(--text);
  line-height: 1.2;
  font-weight: 700;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
button { font-family: inherit; background: none; border: none; color: inherit; }
input, button, textarea, select { font: inherit; }

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-body); font-weight: 600; font-size: .95rem;
  padding: .7rem 1.3rem; border-radius: var(--radius-sm);
  border: 1px solid transparent; cursor: pointer;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
  min-height: 44px;
}
.btn:active { transform: scale(.98); }
.btn-lg { padding: .9rem 1.6rem; font-size: 1rem; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); box-shadow: var(--shadow); }
.btn-ghost { background: #fff; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn-white { background: #fff; color: var(--primary); }
.btn-white:hover { box-shadow: var(--shadow-lg); }
.link { color: var(--primary); font-weight: 600; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.85); backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; gap: 1.5rem; height: 68px; }
.brand { display: flex; align-items: center; gap: .55rem; font-weight: 700; }
.brand-mark {
  display: grid; place-items: center; width: 32px; height: 32px;
  background: var(--primary); color: #fff; border-radius: 9px; overflow: hidden;
}
.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.brand-name { font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; }
.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: 1.4rem; }
.main-nav a { color: var(--text-muted); font-weight: 500; font-size: .92rem; transition: color .15s; }
.main-nav a:hover { color: var(--primary); }
.header-cta { flex-shrink: 0; }
.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 22px; height: 2px; background: var(--text); border-radius: 2px; }
.mobile-nav { display: none; flex-direction: column; gap: .25rem; padding: 12px 20px 20px; border-bottom: 1px solid var(--border); background: #fff; }
.mobile-nav a { padding: .7rem 0; color: var(--text); font-weight: 500; border-bottom: 1px solid var(--border); }
.mobile-nav a.btn { border: 1px solid transparent; margin-top: .5rem; }

/* ---------- Hero ---------- */
.hero { padding: clamp(3rem, 7vw, 6rem) 0 clamp(2.5rem, 5vw, 4rem); }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 3rem; align-items: center; }
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 600; color: var(--primary);
  background: #EFF6FF; padding: .35rem .75rem; border-radius: 999px; margin-bottom: 1rem;
}
.hero h1 { font-size: clamp(2.1rem, 4.5vw, 3.3rem); font-weight: 800; letter-spacing: -.02em; }
.hero .lead { font-size: 1.12rem; color: var(--text-muted); margin: 1.1rem 0 1.8rem; max-width: 40ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; }
.hero-trust { display: flex; gap: 1.6rem; margin-top: 1.8rem; color: var(--text-muted); font-size: .9rem; }
.hero-trust strong { color: var(--text); font-family: var(--font-head); }

/* Hero art */
.hero-art { position: relative; min-height: 320px; }
.art-card { position: absolute; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.art-progress { top: 10px; left: 8%; padding: 20px; display: flex; align-items: center; gap: 14px; }
.art-progress-label span { font-family: var(--font-head); font-weight: 700; font-size: 1.6rem; }
.art-progress-label small { display: block; color: var(--text-muted); font-size: .8rem; }
.art-chart { bottom: 20px; left: 0; padding: 18px; display: flex; align-items: flex-end; gap: 8px; height: 120px; }
.art-chart .bar { width: 16px; background: linear-gradient(var(--secondary), var(--primary)); border-radius: 4px; }
.art-calendar { top: 40%; right: 4%; padding: 14px; width: 140px; }
.cal-head { height: 8px; width: 46px; background: var(--primary); border-radius: 4px; margin-bottom: 10px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-grid i { display: block; aspect-ratio: 1; border-radius: 4px; background: var(--border); }
.cal-grid i.on { background: var(--success); }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 6vw, 5rem) 0; }
.section-alt { background: #fff; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 640px; margin: 0 auto 2.6rem; text-align: center; }
.section-head.left { margin-left: 0; text-align: left; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.3rem); font-weight: 700; letter-spacing: -.01em; }
.section-head p { color: var(--text-muted); margin-top: .6rem; font-size: 1.05rem; }

/* ---------- Ad slot ---------- */
.ad-slot {
  margin: 1.5rem auto; min-height: 90px; display: grid; place-items: center;
  border: 1px dashed var(--border); border-radius: var(--radius);
  color: #94A3B8; font-size: .82rem; letter-spacing: .04em; text-transform: uppercase;
  background: #fff;
}

/* ---------- Calculator ---------- */
.calc-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; align-items: start; }
.calc-card, .result-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.8rem;
}
.field { margin-bottom: 1.2rem; display: flex; flex-direction: column; gap: .45rem; }
.field label { font-weight: 600; font-size: .92rem; }
.field input {
  font-family: var(--font-body); font-size: 1rem; padding: .8rem 1rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm); background: #fff;
  min-height: 48px; transition: border-color .15s, box-shadow .15s;
}
.field input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.field input.invalid { border-color: var(--danger); box-shadow: 0 0 0 3px rgba(239,68,68,.12); }
.field-hint { color: var(--text-muted); font-size: .8rem; }
.field-error { color: var(--danger); font-size: .8rem; min-height: 1em; }
.calc-buttons { display: flex; gap: .8rem; margin-top: .5rem; }
.calc-buttons .btn { flex: 1; }

/* Result card */
.result-card { min-height: 100%; text-align: center; }
.result-empty { color: var(--text-muted); display: flex; flex-direction: column; align-items: center; gap: 1rem; padding: 1rem 0; }
/* Respect the [hidden] attribute so the empty-state ring and the result
   ring are never shown at the same time (prevents a duplicate chart). */
.result-empty[hidden],
.result-full[hidden] { display: none !important; }
.result-ring, .result-ring-svg { position: relative; display: inline-grid; place-items: center; }
.result-ring .ring-center { position: absolute; display: flex; flex-direction: column; }
.ring-value { font-family: var(--font-head); font-weight: 800; font-size: 2.1rem; }
.ring-caption { color: var(--text-muted); font-size: .8rem; }
#progressArc { transition: stroke-dashoffset 1s cubic-bezier(.22,1,.36,1), stroke .3s; }
.status-badge {
  display: inline-block; margin: 1rem 0 .5rem; padding: .4rem 1rem; border-radius: 999px;
  font-weight: 600; font-size: .85rem; color: #fff; background: var(--success);
}
.status-badge.excellent { background: var(--success); }
.status-badge.safe { background: var(--primary); }
.status-badge.warning { background: var(--warning); }
.status-badge.critical { background: var(--danger); }
.result-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.2rem; }
.stat { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 1rem; }
.stat-label { display: block; color: var(--text-muted); font-size: .8rem; }
.stat-value { display: block; font-family: var(--font-head); font-weight: 800; font-size: 1.8rem; color: var(--primary); }
.stat-unit { color: var(--text-muted); font-size: .78rem; }
.result-note { margin-top: 1.1rem; color: var(--text-muted); font-size: .92rem; }

/* ---------- Features ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.feature { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.6rem; transition: transform .18s, box-shadow .18s, border-color .18s; }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #CBD5E1; }
.feature-icon { width: 44px; height: 44px; display: grid; place-items: center; background: #EFF6FF; color: var(--primary); border-radius: 10px; font-size: 1.2rem; margin-bottom: 1rem; }
.feature h3 { font-size: 1.1rem; margin-bottom: .35rem; }
.feature p { color: var(--text-muted); font-size: .95rem; }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; counter-reset: step; }
.step { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.8rem 1.5rem; position: relative; }
.step-num { display: grid; place-items: center; width: 40px; height: 40px; background: var(--primary); color: #fff; border-radius: 10px; font-family: var(--font-head); font-weight: 700; margin-bottom: 1rem; }
.step h3 { font-size: 1.1rem; margin-bottom: .35rem; }
.step p { color: var(--text-muted); font-size: .95rem; }

/* ---------- Explainer ---------- */
.explainer h3 { font-size: 1.2rem; margin: 1.6rem 0 .4rem; }
.explainer h3:first-child { margin-top: 0; }
.explainer p { color: var(--text-muted); }

/* ---------- Tools ---------- */
.tools-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.tool-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; transition: transform .18s, box-shadow .18s, border-color .18s; }
.tool-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary); }
.tool-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: #EFF6FF; color: var(--primary); font-family: var(--font-head); font-weight: 700; margin-bottom: .9rem; }
.tool-card h3 { font-size: 1rem; margin-bottom: .3rem; }
.tool-card p { color: var(--text-muted); font-size: .88rem; }

/* ---------- Blog landing ---------- */
.blog-landing {
  background: var(--bg);
  overflow: hidden;
}
.blog-article-page { background: var(--bg); }
.blog-hero {
  position: relative;
  padding: clamp(2.2rem, 5vw, 3.6rem) 0 clamp(1.5rem, 3vw, 2.4rem);
}
.blog-hero-blobs { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.blog-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
}
.blog-blob-a {
  width: 280px; height: 280px;
  top: -80px; left: -60px;
  background: rgba(191, 219, 254, 0.55);
}
.blog-blob-b {
  width: 320px; height: 220px;
  top: 10%; right: -40px;
  background: rgba(254, 240, 138, 0.4);
  border-radius: 60% 40% 50% 50%;
}
.blog-blob-c {
  width: 180px; height: 180px;
  bottom: -40px; left: 35%;
  background: rgba(221, 214, 254, 0.35);
}
.blog-hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: clamp(2.5rem, 7vw, 5.5rem);
  align-items: center;
}
.blog-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  background: #DBEAFE;
  color: #1D4ED8;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 1rem;
}
.blog-hero-title {
  font-size: clamp(2.15rem, 4.6vw, 3.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: var(--blog-heading-color);
  max-width: 16ch;
}
.blog-hero-title-main {
  color: var(--blog-heading-color);
}
.blog-hero-title-accent {
  position: relative;
  display: inline-block;
  color: var(--primary);
}
.blog-hero-underline {
  position: absolute;
  left: 0;
  bottom: -0.15em;
  width: 100%;
  height: 12px;
  overflow: visible;
}
.blog-hero-art {
  position: relative;
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.blog-hero-art-stack {
  position: relative;
  width: min(100%, 340px);
  height: 230px;
}
.blog-hero-book {
  position: absolute;
  left: 18%;
  height: 28px;
  border-radius: 6px 10px 10px 6px;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}
.blog-hero-book-1 { bottom: 52px; width: 58%; background: #3B82F6; }
.blog-hero-book-2 { bottom: 78px; width: 52%; background: #FBBF24; left: 22%; }
.blog-hero-book-3 { bottom: 104px; width: 46%; background: #60A5FA; left: 26%; }
.blog-hero-cup {
  position: absolute;
  left: 8%;
  bottom: 118px;
  width: 48px;
  height: 42px;
  background: linear-gradient(180deg, #FDE68A, #F59E0B);
  border-radius: 8px 8px 12px 12px;
  box-shadow: 0 8px 18px rgba(245, 158, 11, 0.25);
}
.blog-hero-pencil {
  position: absolute;
  bottom: 100%;
  width: 8px;
  height: 36px;
  border-radius: 3px 3px 2px 2px;
}
.blog-hero-pencil.p1 { left: 8px; background: #38BDF8; transform: rotate(-8deg); }
.blog-hero-pencil.p2 { left: 20px; background: #F472B6; height: 42px; }
.blog-hero-pencil.p3 { left: 32px; background: #A78BFA; transform: rotate(6deg); height: 34px; }
.blog-hero-plant {
  position: absolute;
  right: 38%;
  bottom: 118px;
  width: 44px;
}
.blog-hero-pot {
  display: block;
  width: 36px;
  height: 28px;
  margin: 0 auto;
  background: #E2E8F0;
  border-radius: 4px 4px 10px 10px;
}
.blog-hero-leaf {
  position: absolute;
  width: 22px;
  height: 28px;
  background: #34D399;
  border-radius: 80% 0 80% 0;
  bottom: 24px;
}
.blog-hero-leaf.l1 { left: 4px; transform: rotate(-25deg); }
.blog-hero-leaf.l2 { right: 4px; background: #10B981; transform: rotate(20deg); border-radius: 0 80% 0 80%; }
.blog-hero-clipboard {
  position: absolute;
  right: 4%;
  bottom: 48px;
  width: 110px;
  height: 140px;
  background: #fff;
  border: 2.5px solid #2563EB;
  border-radius: 14px;
  box-shadow: 0 14px 30px rgba(30, 58, 138, 0.12);
  padding: 22px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.blog-hero-clipboard::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 36px;
  height: 14px;
  background: #2563EB;
  border-radius: 6px;
}
.blog-hero-clip-line {
  height: 8px;
  border-radius: 4px;
  background: #DBEAFE;
}
.blog-hero-clip-line.short { width: 55%; }
.blog-hero-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #22C55E;
  margin-top: auto;
  align-self: flex-end;
  position: relative;
}
.blog-hero-check::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 4px;
  width: 6px;
  height: 11px;
  border: solid #fff;
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}
.blog-hero-deco {
  position: absolute;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  opacity: 0.9;
}
.blog-hero-bulb {
  top: 8%;
  right: 6%;
  background: radial-gradient(circle at 40% 35%, #FEF08A, #FBBF24 60%, transparent 70%);
  box-shadow: 0 0 0 6px rgba(251, 191, 36, 0.15);
}
.blog-hero-plane {
  top: 18%;
  left: 2%;
  width: 36px;
  height: 36px;
  background: conic-gradient(from 210deg, transparent 40%, #93C5FD 40% 70%, transparent 70%);
  border-radius: 4px;
  opacity: 0.7;
}
.blog-hero-description {
  max-width: 48ch;
  margin: 1rem 0 1.5rem;
  color: #475569;
  font-size: clamp(.98rem, 1.6vw, 1.08rem);
  line-height: 1.7;
}
.blog-hero-cta { gap: .7rem; box-shadow: 0 10px 22px rgba(37, 99, 235, .18); }
.blog-hero-cta span { font-size: 1.15rem; line-height: 1; transition: transform .15s ease; }
.blog-hero-cta:hover span { transform: translateX(3px); }
.blog-hero-visual {
  position: relative;
  min-height: 230px;
  display: grid;
  place-items: center;
}
.attendance-card {
  position: relative;
  z-index: 2;
  width: min(100%, 330px);
  padding: 1.35rem 1.35rem 1.1rem;
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 1.15rem;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 24px 55px rgba(30, 64, 175, .16), 0 4px 14px rgba(15, 23, 42, .06);
  backdrop-filter: blur(10px);
  transform: rotate(2deg);
}
.attendance-card-top, .attendance-score-row, .attendance-card-footer {
  display: flex;
  align-items: center;
}
.attendance-card-top { gap: .65rem; color: #64748B; font-size: .76rem; font-weight: 600; }
.attendance-card-label { flex: 1; }
.attendance-card-dots { color: #94A3B8; letter-spacing: .12em; }
.attendance-calendar-icon {
  display: grid;
  grid-template-columns: repeat(2, 4px);
  gap: 2px;
  width: 30px;
  height: 30px;
  place-content: center;
  border-radius: 9px;
  background: #DBEAFE;
}
.attendance-calendar-icon span { width: 4px; height: 4px; border-radius: 50%; background: #2563EB; }
.attendance-score-row { gap: .7rem; margin: 1.35rem 0 .85rem; }
.attendance-score-row strong { color: #0F172A; font-family: var(--font-head); font-size: 2rem; letter-spacing: -.04em; }
.attendance-status { padding: .25rem .55rem; border-radius: 999px; background: #DCFCE7; color: #15803D; font-size: .7rem; font-weight: 700; }
.attendance-progress { height: 9px; overflow: hidden; border-radius: 999px; background: #E2E8F0; }
.attendance-progress span { display: block; width: 82.5%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #60A5FA, #2563EB); }
.attendance-card-footer { justify-content: space-between; margin-top: .85rem; color: #64748B; font-size: .73rem; }
.attendance-card-footer strong { color: #1E3A8A; font-size: .82rem; }
.attendance-orbit { position: absolute; border: 1px dashed rgba(96, 165, 250, .5); border-radius: 50%; transform: rotate(-18deg); }
.attendance-orbit-one { width: 335px; height: 170px; }
.attendance-orbit-two { width: 235px; height: 285px; border-color: rgba(251, 191, 36, .45); transform: rotate(34deg); }
.attendance-check {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 4px solid #F8FBFF;
  border-radius: 50%;
  background: #22C55E;
  color: #fff;
  font-size: .95rem;
  font-weight: 700;
  box-shadow: 0 7px 16px rgba(34, 197, 94, .25);
}
.attendance-check-one { top: 28px; right: 9%; }
.attendance-check-two { bottom: 27px; left: 11%; background: #F59E0B; box-shadow: 0 7px 16px rgba(245, 158, 11, .22); }
.blog-listing { padding-top: 0.5rem; padding-bottom: clamp(3rem, 6vw, 5rem); position: relative; }
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
}
.blog-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 1.35rem;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  display: flex;
  flex-direction: column;
}
.blog-card::after {
  content: "";
  position: absolute;
  right: -30px;
  bottom: -40px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}
.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.1);
}
.blog-card-media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #F1F5F9;
  margin: 0.7rem 0.7rem 0;
  border-radius: 1rem;
  position: relative;
  z-index: 1;
}
.blog-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.blog-card:hover .blog-card-img { transform: scale(1.05); }
.blog-card-body {
  padding: 1.15rem 1.35rem 1.4rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  position: relative;
  z-index: 1;
}
.blog-tag {
  display: inline-flex;
  align-self: flex-start;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.32rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.blog-card h3 {
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 0.5rem;
  letter-spacing: -0.015em;
  color: #0F172A;
}
.blog-card h3 a {
  color: inherit;
  text-decoration: none;
}
.blog-card h3 a:hover { color: #1D4ED8; }
.blog-card p {
  color: #64748B;
  font-size: 0.9rem;
  line-height: 1.55;
  margin-bottom: 1.1rem;
  flex: 1;
}
.blog-read {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  font-weight: 700;
  font-size: 0.86rem;
  padding: 0.55rem 1.05rem;
  border-radius: 999px;
  text-decoration: none;
  transition: transform 0.15s ease, filter 0.15s ease;
}
.blog-read:hover { filter: brightness(0.97); transform: translateY(-1px); }
.blog-read:active { transform: scale(0.98); }

/* Per-card pastel accents (visual only) */
.blog-card--amber { background: linear-gradient(180deg, #fff 55%, #FFFBEB 100%); }
.blog-card--amber::after { background: #FEF3C7; }
.blog-card--amber .blog-tag { background: #FEF3C7; color: #B45309; }
.blog-card--amber .blog-read { background: #FDE68A; color: #92400E; }

.blog-card--mint { background: linear-gradient(180deg, #fff 55%, #ECFDF5 100%); }
.blog-card--mint::after { background: #D1FAE5; }
.blog-card--mint .blog-tag { background: #D1FAE5; color: #047857; }
.blog-card--mint .blog-read { background: #6EE7B7; color: #065F46; }

.blog-card--lavender { background: linear-gradient(180deg, #fff 55%, #F5F3FF 100%); }
.blog-card--lavender::after { background: #EDE9FE; }
.blog-card--lavender .blog-tag { background: #EDE9FE; color: #6D28D9; }
.blog-card--lavender .blog-read { background: #DDD6FE; color: #5B21B6; }

.blog-card--rose { background: linear-gradient(180deg, #fff 55%, #FFF1F2 100%); }
.blog-card--rose::after { background: #FECDD3; }
.blog-card--rose .blog-tag { background: #FFE4E6; color: #BE123C; }
.blog-card--rose .blog-read { background: #FECDD3; color: #9F1239; }

.blog-card--sky { background: linear-gradient(180deg, #fff 55%, #EFF6FF 100%); }
.blog-card--sky::after { background: #BFDBFE; }
.blog-card--sky .blog-tag { background: #DBEAFE; color: #1D4ED8; }
.blog-card--sky .blog-read { background: #93C5FD; color: #1E3A8A; }

.blog-card--teal { background: linear-gradient(180deg, #fff 55%, #F0FDFA 100%); }
.blog-card--teal::after { background: #99F6E4; }
.blog-card--teal .blog-tag { background: #CCFBF1; color: #0F766E; }
.blog-card--teal .blog-read { background: #5EEAD4; color: #115E59; }

.blog-card--violet { background: linear-gradient(180deg, #fff 55%, #FAF5FF 100%); }
.blog-card--violet::after { background: #E9D5FF; }
.blog-card--violet .blog-tag { background: #F3E8FF; color: #7E22CE; }
.blog-card--violet .blog-read { background: #E9D5FF; color: #6B21A8; }

.blog-card--gold { background: linear-gradient(180deg, #fff 55%, #FFFBEB 100%); }
.blog-card--gold::after { background: #FDE68A; }
.blog-card--gold .blog-tag { background: #FEF3C7; color: #A16207; }
.blog-card--gold .blog-read { background: #FBBF24; color: #78350F; }

@media (max-width: 960px) {
  .blog-hero-inner { grid-template-columns: 1fr; text-align: center; }
  .blog-hero-copy { margin: 0 auto; max-width: 760px; }
  .blog-hero-description { margin-left: auto; margin-right: auto; }
  .blog-hero-visual { display: none; }
  .blog-hero-art { min-height: 200px; max-width: 320px; margin: 0 auto; }
  .blog-hero-title { max-width: none; }
}
@media (max-width: 560px) {
  .blog-hero-art { display: none; }
  .blog-card-media { margin: 0.55rem 0.55rem 0; border-radius: 0.85rem; }
  .blog-card-body { padding: 1rem 1.1rem 1.2rem; }
}

/* ---------- FAQ ---------- */
.faq { display: flex; flex-direction: column; gap: .8rem; }
.faq-item { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0 1.2rem; }
.faq-item summary { cursor: pointer; list-style: none; font-weight: 600; padding: 1.1rem 0; position: relative; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 1.3rem; color: var(--primary); transition: transform .2s; }
.faq-item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq-item p { color: var(--text-muted); padding-bottom: 1.1rem; }

/* ---------- CTA ---------- */
.cta { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: #fff; padding: clamp(3rem, 6vw, 4.5rem) 0; }
.cta-inner { text-align: center; }
.cta h2 { color: #fff; font-size: clamp(1.8rem, 4vw, 2.5rem); }
.cta p { color: rgba(255,255,255,.85); margin: .8rem 0 1.8rem; font-size: 1.1rem; }

/* ---------- Two col ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; }
.two-col h2 { font-size: 1.6rem; margin-bottom: .6rem; }
.two-col p { color: var(--text-muted); }

/* ---------- Footer ---------- */
.site-footer { background: #0F172A; color: #CBD5E1; padding: 3rem 0 1.5rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; padding-bottom: 2rem; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-brand .brand-name { color: #fff; }
.footer-brand p { color: #94A3B8; margin-top: .6rem; font-size: .92rem; max-width: 34ch; }
.footer-links h3 { color: #fff; font-size: .95rem; margin-bottom: .8rem; }
.footer-links a { display: block; color: #94A3B8; padding: .3rem 0; font-size: .9rem; transition: color .15s; }
.footer-links a:hover { color: #fff; }
.footer-bottom { padding-top: 1.3rem; color: #64748B; font-size: .85rem; }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .main-nav, .header-cta { display: none; }
  .nav-toggle { display: flex; margin-left: auto; }
  .mobile-nav:not([hidden]) { display: flex; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { display: none; }
  .calc-layout { grid-template-columns: 1fr; }
  .feature-grid, .tools-grid, .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .two-col { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .feature-grid, .tools-grid, .blog-grid { grid-template-columns: 1fr; }
  .hero-trust { flex-wrap: wrap; gap: 1rem; }
  .footer-grid { grid-template-columns: 1fr; }
  .result-stats { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  #progressArc { transition: none; }
}

/* ============================================================
   Dark mode — modern dark-navy palette.
   Light mode is unchanged; this block only activates when the
   <html> element has the `dark` class (managed by next-themes).
   ============================================================ */
.dark {
  --primary: #3B82F6;
  --primary-dark: #2563EB;
  --secondary: #60A5FA;
  --blog-heading-color: #FFFFFF;
  --bg: #0B1220;
  --card: #131C2E;
  --text: #E6EDF7;
  --text-muted: #94A3B8;
  --border: #243044;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 4px 20px rgba(0, 0, 0, .35);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, .45);
}

.dark .site-header {
  background: rgba(11, 18, 32, .85);
  border-bottom-color: var(--border);
}
.dark .mobile-nav { background: var(--card); }
.dark .nav-toggle span { background: var(--text); }

.dark .btn-ghost { background: var(--card); color: var(--text); }
.dark .btn-white { background: var(--card); color: var(--primary); }

.dark .section-alt { background: var(--card); }
.dark .ad-slot { background: var(--card); color: #64748B; }

.dark .field input { background: var(--card); color: var(--text); }
.dark .field input:focus { box-shadow: 0 0 0 3px rgba(37, 99, 235, .25); }

.dark .stat { background: rgba(255, 255, 255, .03); }

.dark .feature-icon,
.dark .tool-icon,
.dark .eyebrow {
  background: rgba(59, 130, 246, .15);
}
.dark .feature:hover { border-color: var(--border); }

.dark .blog-landing,
.dark .blog-article-page { background: var(--bg); }
.dark .blog-card {
  background: var(--card);
  border-color: var(--border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
}
.dark .blog-card:hover { box-shadow: 0 18px 40px rgba(0, 0, 0, .4); }
.dark .blog-card-media { background: #1E293B; }
.dark .blog-card h3 { color: #EAEAEB; }
.dark .blog-card h3 a:hover { color: #93C5FD; }

/* ---------- Theme toggle ---------- */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  margin-left: .25rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.theme-toggle:hover { border-color: var(--primary); color: var(--primary); }
.theme-toggle:active { transform: scale(.96); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
.dark .theme-toggle { background: var(--card); }
.dark .theme-toggle .icon-sun { display: block; }
.dark .theme-toggle .icon-moon { display: none; }

@media (max-width: 960px) {
  .theme-toggle { margin-left: auto; }
  .nav-toggle { margin-left: .25rem; }
}

/* Responsive blog tables — scroll internally, never force the page wider */
.blog-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  width: 100%;
}
.blog-table {
  font-size: .95rem;
}
@media (max-width: 480px) {
  .blog-table {
    font-size: 13px;
  }
}
