/* CollegeBudgetHacks.com — site stylesheet
   Design system: emerald + navy + amber on warm off-white
   Fonts: Instrument Serif (display) + Inter (body) via Google Fonts */

:root {
  --emerald: #10b981;
  --emerald-dark: #059669;
  --emerald-light: #d1fae5;
  --navy: #0f172a;
  --navy-soft: #1e293b;
  --amber: #fbbf24;
  --amber-dark: #f59e0b;
  --bg: #fafaf9;
  --bg-alt: #f5f5f4;
  --card: #ffffff;
  --text: #0f172a;
  --text-soft: #475569;
  --text-muted: #94a3b8;
  --border: #e7e5e4;
  --border-strong: #d6d3d1;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 20px 40px -12px rgba(15, 23, 42, 0.12);
  --radius: 14px;
  --radius-sm: 8px;
  --radius-lg: 24px;
  --font-display: 'Instrument Serif', 'Times New Roman', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --max-w: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--emerald-dark); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--navy); }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 400; line-height: 1.1; letter-spacing: -0.01em; color: var(--navy); margin: 0 0 .5em; }
h1 { font-size: clamp(2.4rem, 5.5vw, 4.6rem); }
h2 { font-size: clamp(1.9rem, 3.5vw, 3rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); }
p { margin: 0 0 1em; color: var(--text-soft); }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: 760px; margin: 0 auto; padding: 0 24px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 249, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--navy);
  font-weight: 400;
  letter-spacing: -0.01em;
}
.logo:hover { color: var(--navy); }
.logo-mark {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--emerald) 0%, var(--emerald-dark) 100%);
  display: grid; place-items: center;
  color: white;
  font-weight: 700;
  font-family: var(--font-body);
  box-shadow: var(--shadow-md);
}
.nav-links { display: flex; gap: 28px; align-items: center; font-size: .95rem; }
.nav-links a { color: var(--text-soft); font-weight: 500; }
.nav-links a:hover { color: var(--navy); }
.nav-cta {
  background: var(--navy);
  color: white !important;
  padding: 10px 18px;
  border-radius: 100px;
  font-weight: 600;
  font-size: .9rem;
}
.nav-cta:hover { background: var(--emerald-dark); color: white !important; }
@media (max-width: 720px) {
  .nav-links { gap: 16px; }
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
  text-decoration: none;
  font-family: var(--font-body);
}
.btn-primary {
  background: var(--navy);
  color: white;
  box-shadow: var(--shadow-md);
}
.btn-primary:hover { background: var(--emerald-dark); color: white; transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.btn-secondary {
  background: white;
  color: var(--navy);
  border: 1px solid var(--border-strong);
}
.btn-secondary:hover { border-color: var(--navy); color: var(--navy); }
.btn-lg { padding: 18px 34px; font-size: 1.05rem; }

/* ---------- Hero ---------- */
.hero {
  padding: 80px 0 60px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--emerald-light);
  color: var(--emerald-dark);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 20px;
}
.hero h1 { margin-bottom: 20px; }
.hero h1 em { font-style: italic; color: var(--emerald-dark); }
.hero-sub {
  font-size: 1.2rem;
  color: var(--text-soft);
  max-width: 620px;
  margin-bottom: 32px;
  line-height: 1.55;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 36px; }
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 640px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.hero-stat-num {
  font-family: var(--font-display);
  font-size: 2.4rem;
  color: var(--navy);
  line-height: 1;
  margin-bottom: 4px;
}
.hero-stat-lbl { font-size: .85rem; color: var(--text-soft); }

/* ---------- Sections ---------- */
.section { padding: 80px 0; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--navy); color: white; }
.section-dark h1, .section-dark h2, .section-dark h3 { color: white; }
.section-dark p { color: #cbd5e1; }
.section-header { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section-eyebrow {
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--emerald-dark);
  margin-bottom: 12px;
}

/* ---------- Tool cards ---------- */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.tool-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.tool-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--emerald); }
.tool-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--emerald-light);
  display: grid; place-items: center;
  font-size: 1.6rem;
  margin-bottom: 16px;
}
.tool-card h3 { font-size: 1.4rem; margin-bottom: 8px; }
.tool-card p { font-size: .95rem; margin-bottom: 16px; }
.tool-card .btn { padding: 10px 20px; font-size: .9rem; }

/* ---------- Interactive tool blocks ---------- */
.tool-block {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-md);
  margin: 0 auto 32px;
  max-width: 820px;
}
.tool-block h3 { font-size: 1.9rem; margin-bottom: 8px; }
.tool-block .tool-desc { font-size: 1.02rem; margin-bottom: 28px; color: var(--text-soft); }
.tool-result {
  background: var(--emerald-light);
  border: 1px solid var(--emerald);
  border-radius: var(--radius);
  padding: 24px;
  margin-top: 24px;
  font-size: 1rem;
}
.tool-result.hidden { display: none; }
.tool-result h4 { color: var(--emerald-dark); margin-bottom: 10px; font-family: var(--font-body); font-weight: 700; font-size: 1.1rem; }
.savings-big {
  font-family: var(--font-display);
  font-size: 3.2rem;
  color: var(--emerald-dark);
  line-height: 1;
  display: block;
  margin: 10px 0;
}
.checklist { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; margin-bottom: 20px; }
.check-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all .15s ease;
}
.check-item:hover { border-color: var(--emerald); background: var(--emerald-light); }
.check-item input { margin-top: 3px; accent-color: var(--emerald-dark); cursor: pointer; }
.check-item-body { flex: 1; }
.check-item-name { font-weight: 600; color: var(--navy); font-size: .95rem; }
.check-item-save { font-size: .8rem; color: var(--text-soft); }

.tool-input {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
  font-family: var(--font-body);
  transition: border-color .15s ease;
}
.tool-input:focus { outline: none; border-color: var(--emerald); }

.quiz-question { margin-bottom: 24px; }
.quiz-q-text { font-weight: 600; color: var(--navy); margin-bottom: 12px; font-size: 1.02rem; }
.quiz-options { display: flex; flex-wrap: wrap; gap: 10px; }
.quiz-opt {
  padding: 10px 18px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 100px;
  cursor: pointer;
  font-size: .92rem;
  font-weight: 500;
  color: var(--navy);
  transition: all .15s ease;
  font-family: var(--font-body);
}
.quiz-opt:hover { border-color: var(--emerald); }
.quiz-opt.selected { background: var(--navy); color: white; border-color: var(--navy); }

.link-list { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 10px; }
.link-list li a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-weight: 500;
  color: var(--navy);
}
.link-list li a:hover { border-color: var(--emerald); transform: translateX(3px); }
.link-list small { color: var(--text-soft); font-weight: 400; }

/* ---------- Playbook cards ---------- */
.playbook-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}
.playbook-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
  display: flex;
  flex-direction: column;
  color: var(--navy);
}
.playbook-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--emerald); color: var(--navy); }
.playbook-tag {
  display: inline-block;
  background: var(--emerald-light);
  color: var(--emerald-dark);
  padding: 4px 12px;
  border-radius: 100px;
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
  align-self: flex-start;
}
.playbook-card h3 { font-size: 1.45rem; margin-bottom: 10px; }
.playbook-card p { font-size: .95rem; flex: 1; }
.playbook-card .read-more {
  font-weight: 600;
  color: var(--emerald-dark);
  font-size: .9rem;
  margin-top: 12px;
}

/* ---------- Newsletter ---------- */
.newsletter {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-soft) 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.newsletter::before {
  content: '';
  position: absolute;
  top: -40%; right: -20%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.25), transparent 70%);
  pointer-events: none;
}
.newsletter h2 { color: white; max-width: 600px; margin: 0 auto 12px; position: relative; }
.newsletter p { color: #cbd5e1; max-width: 520px; margin: 0 auto 32px; position: relative; }
.newsletter-form {
  display: flex;
  gap: 10px;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
  flex-wrap: wrap;
  justify-content: center;
}
.newsletter-form input {
  flex: 1;
  min-width: 240px;
  padding: 16px 20px;
  border-radius: 100px;
  border: none;
  font-size: 1rem;
  font-family: var(--font-body);
}
.newsletter-form input:focus { outline: 2px solid var(--emerald); }
.newsletter-form button { background: var(--emerald); color: white; }
.newsletter-form button:hover { background: var(--emerald-dark); }

/* ---------- Footer ---------- */
.footer {
  background: var(--navy);
  color: #cbd5e1;
  padding: 64px 0 32px;
}
.footer a { color: #cbd5e1; }
.footer a:hover { color: white; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 48px;
}
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-brand p { color: #94a3b8; font-size: .92rem; margin-top: 12px; max-width: 320px; }
.footer h4 {
  color: white;
  font-family: var(--font-body);
  font-size: .85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 18px;
}
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer ul li { margin-bottom: 10px; font-size: .92rem; }
.footer-network {
  border-top: 1px solid rgba(255,255,255,0.1);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding: 28px 0;
  margin-bottom: 28px;
}
.footer-network-title {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #94a3b8;
  margin-bottom: 16px;
  text-align: center;
}
.footer-network-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
}
@media (max-width: 760px) { .footer-network-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 440px) { .footer-network-grid { grid-template-columns: 1fr; } }
.footer-network-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  padding: 16px;
  text-align: center;
  transition: all .15s ease;
  color: #cbd5e1;
}
.footer-network-card:hover { background: rgba(16,185,129,0.1); border-color: var(--emerald); color: white; }
.footer-network-card strong { display: block; color: white; font-size: .95rem; margin-bottom: 4px; }
.footer-network-card small { font-size: .78rem; color: #94a3b8; }
.footer-network-card:hover small { color: #cbd5e1; }
.footer-bottom {
  text-align: center;
  font-size: .84rem;
  color: #64748b;
  padding-top: 16px;
}
.footer-bottom a { color: #94a3b8; margin: 0 10px; }

/* ---------- Article/Blog styling ---------- */
.article {
  max-width: 760px;
  margin: 0 auto;
  padding: 60px 24px 80px;
}
.article-meta {
  display: flex;
  gap: 14px;
  align-items: center;
  font-size: .85rem;
  color: var(--text-soft);
  margin-bottom: 18px;
}
.article-meta .tag {
  background: var(--emerald-light);
  color: var(--emerald-dark);
  padding: 4px 12px;
  border-radius: 100px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: .72rem;
}
.article h1 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); margin-bottom: 16px; }
.article-lede { font-size: 1.25rem; color: var(--text-soft); line-height: 1.55; margin-bottom: 40px; }
.article h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-top: 48px; margin-bottom: 16px; }
.article h3 { font-size: 1.35rem; margin-top: 32px; margin-bottom: 12px; font-family: var(--font-body); font-weight: 700; color: var(--navy); }
.article p { font-size: 1.08rem; line-height: 1.75; margin-bottom: 1.2em; color: #1f2937; }
.article ul, .article ol { font-size: 1.06rem; line-height: 1.75; margin-bottom: 1.2em; color: #1f2937; padding-left: 1.5em; }
.article li { margin-bottom: .5em; }
.article strong { color: var(--navy); font-weight: 700; }
.article a { color: var(--emerald-dark); font-weight: 500; border-bottom: 1px solid var(--emerald-light); }
.article a:hover { border-bottom-color: var(--emerald-dark); }
.article blockquote {
  border-left: 4px solid var(--emerald);
  background: var(--emerald-light);
  padding: 20px 24px;
  margin: 28px 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 1.08rem;
  color: var(--navy);
}
.article blockquote p:last-child { margin-bottom: 0; }
.callout {
  background: #fef3c7;
  border: 1px solid var(--amber);
  border-left: 4px solid var(--amber-dark);
  padding: 20px 24px;
  border-radius: var(--radius-sm);
  margin: 28px 0;
}
.callout strong { color: #78350f; }
.callout p { color: #78350f; margin-bottom: 0; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }
