/* ============================================================
   Digitutors — tutor marketplace
   Palette: fountain-pen ink, marigold, leaf green, notebook paper
   ============================================================ */
:root {
  --ink: #1C2B6B;
  --ink-2: #2E3F8F;
  --ink-soft: #E7EBFA;
  --marigold: #F3A712;
  --marigold-soft: #FFF3D6;
  --leaf: #16876A;
  --leaf-soft: #DDF3EC;
  --margin-red: #E4572E;
  --paper: #F5F7FC;
  --white: #FFFFFF;
  --text: #1E2433;
  --muted: #5B6478;
  --line: #DDE3F0;
  --radius-lg: 22px;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px -12px rgba(28, 43, 107, .25);
  --shadow-lift: 0 22px 40px -18px rgba(28, 43, 107, .35);
  --display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --wrap: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--ink-2); text-decoration: none; }
a:hover { text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--marigold); outline-offset: 2px; border-radius: 4px; }
.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

h1, h2, h3, h4 { font-family: var(--display); line-height: 1.12; margin: 0 0 .5em; color: var(--ink); letter-spacing: -.01em; }
h1 { font-size: clamp(2.3rem, 5vw, 3.9rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.5rem); font-weight: 750; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 56ch; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; cursor: pointer; text-decoration: none !important; white-space: nowrap;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--ink); color: var(--white); }
.btn-primary:hover { background: var(--ink-2); box-shadow: var(--shadow); }
.btn-marigold { background: var(--marigold); color: var(--ink); }
.btn-marigold:hover { background: #FFB92E; box-shadow: 0 10px 24px -10px rgba(243, 167, 18, .7); }
.btn-ghost { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--white); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: .92rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 247, 252, .88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.scrolled { border-color: var(--line); box-shadow: 0 6px 20px -16px rgba(28, 43, 107, .5); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 20px; }
.logo { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 1.45rem; color: var(--ink); text-decoration: none !important; }
.logo-mark {
  width: 38px; height: 38px; border-radius: 11px; background: var(--ink); position: relative; display: grid; place-items: center;
}
.logo-mark::before { content: ""; width: 16px; height: 20px; border: 3px solid var(--white); border-radius: 3px 3px 3px 10px; }
.logo-mark::after { content: ""; position: absolute; width: 11px; height: 11px; border-radius: 50%; background: var(--marigold); right: -3px; top: -3px; border: 2px solid var(--paper); }
.logo-img { display: block; height: 66px; width: auto; }
@media (max-width: 600px) { .logo-img { height: 56px; } }
.site-footer .logo-img { height: 56px; background: var(--white); border-radius: 12px; padding: 6px 12px; box-sizing: content-box; }
.nav-links { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.nav-links a { padding: 8px 14px; border-radius: 999px; color: var(--text); font-weight: 600; }
.nav-links a:hover, .nav-links a.active { background: var(--ink-soft); color: var(--ink); text-decoration: none; }
.nav-cta { display: flex; gap: 10px; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.menu-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: transform .25s, opacity .25s; }
.menu-open .menu-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
.menu-open .menu-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 60px 0 90px; }
.hero::before { /* notebook ruling */
  content: ""; position: absolute; inset: 0;
  background-image: repeating-linear-gradient(to bottom, transparent 0 35px, #D6DEF2 35px 36px);
  mask-image: linear-gradient(to bottom, #000 40%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, #000 40%, transparent);
  z-index: -1;
}
.hero::after { /* notebook margin line */
  content: ""; position: absolute; top: 0; bottom: 0; left: max(20px, calc(50% - 640px)); width: 2px;
  background: var(--margin-red); opacity: .35; z-index: -1;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 60px; align-items: center; }
.hero h1 { max-width: 14ch; }
.hero .lead { margin-bottom: 28px; }
.search-box {
  display: grid; grid-template-columns: 1.2fr 1fr auto; gap: 8px;
  background: var(--white); padding: 8px; border-radius: 20px; box-shadow: var(--shadow);
  border: 1px solid var(--line); max-width: 620px;
}
.search-box label { display: flex; flex-direction: column; padding: 6px 14px; border-radius: 14px; transition: background .15s; }
.search-box label:hover, .search-box label:focus-within { background: var(--paper); }
.search-box label span { font-size: .78rem; font-weight: 700; color: var(--muted); }
.search-box select { border: 0; background: transparent; padding: 2px 0; font-weight: 600; cursor: pointer; outline: none; }
.search-box .btn { border-radius: 14px; }
.quick-cities { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; align-items: center; }
.quick-cities > span { color: var(--muted); font-size: .92rem; margin-right: 4px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px;
  background: var(--white); border: 1px solid var(--line); font-size: .9rem; font-weight: 600; color: var(--ink);
  cursor: pointer; transition: border-color .15s, background .15s;
}
.chip:hover { border-color: var(--ink); text-decoration: none; }
.chip.on { background: var(--ink); color: var(--white); border-color: var(--ink); }

/* The memorable moment: a deck of real tutor cards that shuffles */
.deck-stage { position: relative; height: 440px; }
.deck-sun {
  position: absolute; width: 330px; height: 330px; border-radius: 50%; background: var(--marigold);
  right: 0; top: 30px; animation: sunPulse 7s ease-in-out infinite;
}
.deck-sun::after { content: ""; position: absolute; inset: -26px; border-radius: 50%; border: 2px dashed rgba(243, 167, 18, .6); animation: spin 40s linear infinite; }
@keyframes sunPulse { 50% { transform: scale(1.05); } }
@keyframes spin { to { transform: rotate(360deg); } }
.deck { position: absolute; inset: 0; }
.deck-card {
  position: absolute; left: 50%; top: 50%; width: 320px; padding: 22px;
  background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-lift);
  transform-origin: 50% 120%;
  transition: transform .7s cubic-bezier(.2, .8, .2, 1), opacity .7s ease;
}
.deck-card[data-pos="0"] { transform: translate(-50%, -50%) rotate(-2deg); z-index: 3; }
.deck-card[data-pos="1"] { transform: translate(-44%, -54%) rotate(5deg) scale(.95); z-index: 2; }
.deck-card[data-pos="2"] { transform: translate(-56%, -56%) rotate(-9deg) scale(.9); z-index: 1; }
.deck-card[data-pos="out"] { transform: translate(40%, -40%) rotate(22deg); opacity: 0; z-index: 4; }
.deck-card[data-pos="hidden"] { transform: translate(-50%, -50%) scale(.85); opacity: 0; z-index: 0; }
.deck-card .dc-top { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.deck-card h4 { margin: 0; font-size: 1.1rem; }
.deck-card .dc-meta { color: var(--muted); font-size: .9rem; }
.deck-card .dc-row { display: flex; justify-content: space-between; border-top: 1px dashed var(--line); padding-top: 12px; margin-top: 12px; font-size: .92rem; }
.deck-card .dc-row b { color: var(--ink); }
.deck-note {
  position: absolute; bottom: 12px; left: 8px; background: var(--leaf); color: var(--white); padding: 10px 16px;
  border-radius: 14px; font-weight: 700; font-size: .92rem; box-shadow: var(--shadow); z-index: 5;
  transform: rotate(-3deg);
}

/* ---------- Avatar ---------- */
.avatar {
  --c: var(--ink); flex: none;
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  background: var(--c); color: var(--white); font-family: var(--display); font-weight: 800; font-size: 1.15rem;
  position: relative;
}
.avatar.lg { width: 110px; height: 110px; font-size: 2.3rem; }
.avatar .tick {
  position: absolute; right: -2px; bottom: -2px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--leaf); border: 2px solid var(--white); display: grid; place-items: center;
}
.avatar.lg .tick { width: 30px; height: 30px; }
.avatar .tick svg { width: 60%; height: 60%; }

/* ---------- Sections ---------- */
.section { padding: 80px 0; }
.section-alt { background: var(--white); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 36px; flex-wrap: wrap; }
.section-head p { color: var(--muted); margin: 0; max-width: 52ch; }

/* Stats band */
.stats { background: var(--ink); color: var(--white); padding: 36px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat b { display: block; font-family: var(--display); font-size: 2.3rem; font-weight: 800; color: var(--marigold); line-height: 1.1; }
.stat span { color: #C9D1F2; font-size: .95rem; }

/* City tiles */
.city-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.city-tile {
  position: relative; display: block; padding: 22px 20px 20px; border-radius: var(--radius-lg);
  background: var(--white); border: 1px solid var(--line); color: var(--text); overflow: hidden; min-height: 190px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s;
}
.city-tile:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); border-color: transparent; text-decoration: none; }
.city-tile svg { width: 100%; height: 70px; color: var(--ink); margin-bottom: 14px; }
.city-tile svg .accent { fill: var(--marigold); }
.city-tile h3 { margin: 0; }
.city-tile p { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }

/* Subject grid */
.subject-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.subject {
  display: flex; flex-direction: column; gap: 10px; padding: 20px; border-radius: var(--radius);
  background: var(--paper); border: 1px solid var(--line); color: var(--text); transition: background .2s, transform .2s;
}
.subject:hover { background: var(--ink); color: var(--white); transform: translateY(-3px); text-decoration: none; }
.subject:hover .s-count { color: #C9D1F2; }
.subject:hover .s-icon { background: var(--marigold); color: var(--ink); }
.s-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--ink-soft); color: var(--ink); display: grid; place-items: center; font-family: var(--display); font-weight: 800; transition: background .2s; }
.subject b { font-size: 1.02rem; }
.s-count { color: var(--muted); font-size: .88rem; }

/* Tutor cards */
.tutor-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 20px; }
.tutor-card {
  display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 20px; transition: transform .22s ease, box-shadow .22s ease;
  animation: cardIn .45s ease both;
}
.tutor-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
@keyframes cardIn { from { opacity: 0; transform: translateY(14px); } }
.tc-top { display: flex; gap: 14px; align-items: center; }
.tc-top h3 { font-size: 1.08rem; margin: 0 0 2px; }
.tc-top h3 a { color: var(--ink); }
.tc-loc { color: var(--muted); font-size: .88rem; display: flex; align-items: center; gap: 4px; }
.tc-subject { margin: 14px 0 6px; font-weight: 700; color: var(--ink-2); }
.tc-qual { color: var(--muted); font-size: .9rem; margin-bottom: 12px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: .78rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--paper); color: var(--muted); border: 1px solid var(--line); }
.tag.mode { background: var(--leaf-soft); color: var(--leaf); border-color: transparent; }
.tc-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 16px; }
.tc-stats { display: flex; justify-content: space-between; margin: 14px 0 0; padding: 12px 0; border-top: 1px dashed var(--line); font-size: .88rem; color: var(--muted); }
.tc-stats b { color: var(--text); }
.rating { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; color: var(--text); }
.rating svg { width: 16px; height: 16px; fill: var(--marigold); }
.fee { font-family: var(--display); font-weight: 800; color: var(--ink); font-size: 1.2rem; }
.fee small { font-family: var(--body); font-weight: 500; color: var(--muted); font-size: .8rem; }

/* How it works (true sequence) */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: step; position: relative; }
.steps::before { content: ""; position: absolute; top: 28px; left: 10%; right: 10%; border-top: 2px dashed var(--line); z-index: 0; }
.step { position: relative; z-index: 1; text-align: center; padding: 0 12px; }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 56px; height: 56px; margin: 0 auto 18px; border-radius: 50%;
  background: var(--marigold); color: var(--ink); font-family: var(--display); font-weight: 800; font-size: 1.4rem;
  box-shadow: 0 0 0 8px var(--white);
}
.step p { color: var(--muted); }

/* Testimonials */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.quote { background: var(--white); border-radius: var(--radius-lg); padding: 28px; border: 1px solid var(--line); position: relative; }
.quote::before { content: "“"; position: absolute; top: -8px; right: 22px; font-family: var(--display); font-size: 6rem; color: var(--marigold); line-height: 1; }
.quote p { font-size: 1.02rem; }
.quote footer { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.quote footer .avatar { width: 44px; height: 44px; font-size: .95rem; }
.quote footer small { display: block; color: var(--muted); }

/* CTA band */
.cta-band {
  background: var(--marigold); border-radius: 28px; padding: 50px; display: grid; grid-template-columns: 1.4fr 1fr; gap: 30px; align-items: center;
  position: relative; overflow: hidden;
}
.cta-band::after {
  content: ""; position: absolute; right: -60px; bottom: -80px; width: 260px; height: 260px; border-radius: 50%;
  border: 30px solid rgba(28, 43, 107, .08);
}
.cta-band h2 { margin-bottom: 10px; }
.cta-band p { color: #4A3A10; margin: 0; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: flex-end; position: relative; z-index: 1; }

/* ---------- Listing page ---------- */
.page-head { padding: 40px 0 26px; background: var(--white); border-bottom: 1px solid var(--line); }
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.page-head h1 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); margin-bottom: 6px; }
.city-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 18px; }

.listing { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 30px; padding: 30px 0 80px; align-items: start; }
.filters {
  position: sticky; top: 90px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px;
}
.filters h3 { display: flex; justify-content: space-between; align-items: center; font-size: 1.1rem; }
.filters h3 button { background: none; border: 0; color: var(--ink-2); font-weight: 600; font-size: .88rem; cursor: pointer; }
.f-group { border-top: 1px solid var(--line); padding: 16px 0; }
.f-group:last-child { padding-bottom: 0; }
.f-group > b { display: block; font-size: .92rem; margin-bottom: 10px; }
.f-group select, .f-group input[type="search"] {
  width: 100%; padding: 10px 12px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--paper);
}
.check { display: flex; align-items: center; gap: 10px; padding: 4px 0; cursor: pointer; font-size: .95rem; }
.check input { accent-color: var(--ink); width: 17px; height: 17px; }
input[type="range"] { width: 100%; accent-color: var(--ink); }
.range-val { display: flex; justify-content: space-between; font-size: .85rem; color: var(--muted); }
.results-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.results-bar p { margin: 0; color: var(--muted); }
.results-bar p b { color: var(--text); }
.results-bar select { padding: 9px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--white); font-weight: 600; }
.filter-toggle { display: none; }
.pager { display: flex; justify-content: center; gap: 6px; margin-top: 34px; flex-wrap: wrap; }
.pager button {
  min-width: 42px; height: 42px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--white);
  font-weight: 700; cursor: pointer; transition: background .15s;
}
.pager button:hover:not(:disabled) { border-color: var(--ink); }
.pager button.on { background: var(--ink); color: var(--white); border-color: var(--ink); }
.pager button:disabled { opacity: .4; cursor: default; }
.empty { text-align: center; padding: 60px 20px; background: var(--white); border-radius: var(--radius-lg); border: 1px dashed var(--line); }

/* ---------- Profile ---------- */
.profile-hero { background: var(--ink); color: var(--white); padding: 40px 0 110px; position: relative; overflow: hidden; }
.profile-hero::before {
  content: ""; position: absolute; inset: 0;
  background-image: repeating-linear-gradient(to bottom, transparent 0 35px, rgba(255, 255, 255, .06) 35px 36px);
}
.profile-hero .crumbs, .profile-hero .crumbs a { color: #C9D1F2; position: relative; }
.profile-main { display: flex; gap: 28px; align-items: center; position: relative; }
.profile-main h1 { color: var(--white); font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: 6px; }
.profile-main .avatar { box-shadow: 0 0 0 6px rgba(255, 255, 255, .15); }
.profile-main p { color: #D5DBF5; margin: 0; }
.p-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.p-badge { background: rgba(255, 255, 255, .12); padding: 5px 12px; border-radius: 999px; font-size: .88rem; font-weight: 600; }
.p-badge.v { background: var(--leaf); }
.profile-body { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; margin-top: -70px; position: relative; padding-bottom: 80px; }
.panel { background: var(--white); border-radius: var(--radius-lg); border: 1px solid var(--line); padding: 28px; margin-bottom: 22px; }
.panel h2 { font-size: 1.35rem; margin-bottom: 16px; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.fact { background: var(--paper); border-radius: var(--radius); padding: 14px; }
.fact b { display: block; font-family: var(--display); font-size: 1.4rem; color: var(--ink); }
.fact span { font-size: .85rem; color: var(--muted); }
.fact-note { display: block; margin-top: 4px; font-style: normal; font-size: .78rem; font-weight: 700; color: var(--leaf); }
.detail-list { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 10px 20px; margin: 0; }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; font-weight: 600; }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.day { text-align: center; padding: 10px 0; border-radius: 10px; background: var(--paper); color: #A6AEC2; font-weight: 700; font-size: .88rem; }
.day.on { background: var(--leaf-soft); color: var(--leaf); }
.review { padding: 16px 0; border-top: 1px solid var(--line); }
.review:first-of-type { border-top: 0; padding-top: 0; }
.review .stars { color: var(--marigold); letter-spacing: 2px; }
.review small { color: var(--muted); }
.booking { position: sticky; top: 90px; }
.booking .fee { font-size: 2rem; }
.form-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.form-field label { font-weight: 600; font-size: .92rem; }
.form-field input, .form-field select, .form-field textarea {
  padding: 11px 13px; border-radius: 10px; border: 1px solid var(--line); background: var(--paper); transition: border-color .15s, background .15s;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus { outline: none; border-color: var(--ink); background: var(--white); }
.form-field .err { color: var(--margin-red); font-size: .84rem; display: none; }
.form-field.invalid input, .form-field.invalid select, .form-field.invalid textarea { border-color: var(--margin-red); }
.form-field.invalid .err { display: block; }
.form-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }

/* ---------- Join page ---------- */
.tabs { display: inline-flex; background: var(--ink-soft); padding: 5px; border-radius: 999px; margin-bottom: 24px; }
.tabs button { border: 0; background: transparent; padding: 10px 22px; border-radius: 999px; font-weight: 700; cursor: pointer; color: var(--ink); }
.tabs button.on { background: var(--ink); color: var(--white); }
.join-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 40px; padding: 50px 0 80px; align-items: start; }
.perks { list-style: none; padding: 0; margin: 24px 0 0; }
.perks li { display: flex; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.perks li::before { content: ""; flex: none; width: 24px; height: 24px; margin-top: 2px; border-radius: 50%; background: var(--leaf-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12l4 4 8-8' fill='none' stroke='%2316876A' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/14px no-repeat; }
.perks b { display: block; }
.perks span { color: var(--muted); font-size: .95rem; }
.pane[hidden] { display: none; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140%); z-index: 100;
  background: var(--leaf); color: var(--white); padding: 14px 22px; border-radius: 14px; font-weight: 700;
  box-shadow: var(--shadow-lift); transition: transform .35s cubic-bezier(.2, .8, .2, 1); max-width: calc(100% - 32px);
}
.toast.show { transform: translate(-50%, 0); }

/* ---------- Footer ---------- */
.site-footer { background: #151F52; color: #C9D1F2; padding: 60px 0 30px; }
/* flex, so columns hidden for tutors (Cities, Popular subjects) leave no gaps */
.foot-grid { display: flex; flex-wrap: wrap; gap: 30px 36px; }
.foot-grid > * { flex: 1 1 150px; min-width: 0; }
.foot-grid > .foot-brand { flex: 1.5 1 230px; }
.foot-brand address { font-style: normal; line-height: 1.7; color: #9FB0E8; max-width: 34ch; margin-top: 4px; }
.foot-brand address b { color: var(--white); }
.foot-hours { margin: 14px 0 0; font-size: .92rem; line-height: 1.7; }
.foot-grid > .foot-contact-col { flex: 1.2 1 170px; }
.foot-contact-col a { overflow-wrap: anywhere; }
.site-footer .logo { color: var(--white); margin-bottom: 12px; }
.site-footer .logo-mark { background: var(--marigold); }
.site-footer .logo-mark::after { background: var(--white); border-color: #151F52; }
.site-footer h4 { color: var(--white); font-size: 1rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #C9D1F2; }
.site-footer a:hover { color: var(--white); }
.foot-bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 40px; padding-top: 22px; font-size: .88rem; display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Header auth ---------- */
.nav-cta { align-items: center; }
.nav-links a { white-space: nowrap; }
.mobile-auth { display: none; }
.user-chip { display: inline-flex; align-items: center; gap: 8px; padding: 4px 14px 4px 4px; border-radius: 999px; background: var(--white); border: 1px solid var(--line); font-weight: 700; color: var(--ink); }
.user-chip:hover { border-color: var(--ink); text-decoration: none; }
.user-chip .avatar { width: 32px; height: 32px; font-size: .8rem; }
.linklike { background: none; border: 0; padding: 12px 14px; font-weight: 600; color: var(--margin-red); cursor: pointer; text-align: left; }

/* ---------- Auth pages ---------- */
.auth { display: grid; grid-template-columns: .9fr 1.1fr; gap: 0; padding: 50px 0 80px; align-items: stretch; }
.auth-side {
  background: var(--ink); color: #D5DBF5; border-radius: var(--radius-lg) 0 0 var(--radius-lg); padding: 44px; position: relative; overflow: hidden;
  background-image: repeating-linear-gradient(to bottom, transparent 0 35px, rgba(255, 255, 255, .06) 35px 36px);
}
.auth-side::after { content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%; background: var(--marigold); right: -70px; bottom: -70px; }
.auth-side h2 { color: var(--white); }
.auth-points { list-style: none; padding: 0; margin: 28px 0 0; position: relative; z-index: 1; }
.auth-points li { padding: 12px 0 12px 34px; border-top: 1px solid rgba(255, 255, 255, .12); position: relative; color: var(--white); font-weight: 600; }
.auth-points li::before { content: ""; position: absolute; left: 0; top: 13px; width: 22px; height: 22px; border-radius: 50%; background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12l4 4 8-8' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/13px no-repeat; }
.auth-card { border-radius: 0 var(--radius-lg) var(--radius-lg) 0; margin: 0; padding: 44px; }
.auth-card h1 { font-size: 2rem; margin-bottom: 6px; }
.auth-card > .muted { margin-bottom: 24px; }
.pw-wrap { position: relative; display: flex; }
.pw-wrap input { flex: 1; padding-right: 70px; width: 100%; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: var(--ink-soft); color: var(--ink); font-weight: 700; font-size: .82rem; padding: 6px 10px; border-radius: 8px; cursor: pointer; }
.hint { font-size: .84rem; color: var(--muted); }
.form-field.invalid .hint { display: none; }
.form-msg { background: #FDECE7; color: #A93A1B; padding: 10px 14px; border-radius: 10px; font-weight: 600; font-size: .92rem; }
.role-pick { border: 0; padding: 0; margin: 0 0 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.role-pick legend { font-weight: 600; font-size: .92rem; margin-bottom: 8px; padding: 0; }
.role-card { position: relative; cursor: pointer; }
.role-card input { position: absolute; opacity: 0; }
.role-card span { display: block; padding: 14px 16px; border-radius: 12px; border: 2px solid var(--line); background: var(--paper); transition: border-color .15s, background .15s; }
.role-card b { display: block; color: var(--ink); }
.role-card small { color: var(--muted); }
.role-card input:checked + span { border-color: var(--ink); background: var(--ink-soft); }
.role-card input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 2px; }
.btn.loading { opacity: .75; cursor: progress; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }

/* ---------- Email code (OTP) step ---------- */
.auth-narrow { grid-template-columns: minmax(0, 520px); justify-content: center; }
.auth-narrow .auth-card { border-radius: var(--radius-lg); }
.label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.label-row a { font-weight: 600; }
.form-note { background: var(--leaf-soft); color: #0F5E4A; padding: 10px 14px; border-radius: 10px; font-weight: 600; font-size: .92rem; }
.otp-step h1 { font-size: 2rem; margin-bottom: 6px; }
.otp-step > .muted { margin-bottom: 20px; }
.otp-step b[data-otp-email] { color: var(--ink); word-break: break-all; }
.otp-icon {
  width: 58px; height: 58px; border-radius: 16px; background: var(--marigold-soft); margin-bottom: 18px; position: relative;
  animation: otpIn .5s cubic-bezier(.2, .8, .2, 1) both;
}
.otp-icon { background: var(--marigold-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231C2B6B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E") center/28px no-repeat; }
@keyframes otpIn { from { transform: scale(.6) rotate(-8deg); opacity: 0; } }
.otp-input { font-family: var(--display); font-size: 1.7rem !important; font-weight: 800; letter-spacing: .6em; text-align: center; padding: 14px 13px 14px calc(13px + .6em) !important; }
.otp-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.linkbtn { background: none; border: 0; padding: 4px 0; color: var(--ink-2); font-weight: 700; cursor: pointer; }
.linkbtn:hover:not(:disabled) { text-decoration: none; }
.linkbtn:disabled { color: var(--muted); cursor: default; }

/* Student / Tutor switch on sign in and forgot password */
.role-switch { display: grid; grid-template-columns: 1fr 1fr; background: var(--ink-soft); padding: 5px; border-radius: 14px; margin: 0 0 20px; position: relative; }
.role-switch label { position: relative; cursor: pointer; }
.role-switch input { position: absolute; opacity: 0; }
.role-switch span { display: block; text-align: center; padding: 11px 10px; border-radius: 10px; font-weight: 800; color: var(--ink); transition: background .2s, color .2s, box-shadow .2s; }
.role-switch input:checked + span { background: var(--ink); color: var(--white); box-shadow: 0 6px 14px -8px rgba(28, 43, 107, .8); }
.role-switch input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 2px; }
form[data-role="tutor"] .role-switch input:checked + span { background: var(--marigold); color: var(--ink); }

/* Sign-up: verify email inline */
.inline-input { display: flex; gap: 8px; align-items: stretch; position: relative; }
.inline-input input { flex: 1; min-width: 0; }
.inline-input .btn { border-radius: 10px; flex: none; }
.inline-input input[readonly] { background: var(--leaf-soft); border-color: transparent; color: #0F5E4A; font-weight: 600; padding-right: 100px; }
.verified-badge {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  display: inline-flex; align-items: center; gap: 5px; font-size: .82rem; font-weight: 800; color: var(--leaf);
  animation: otpIn .35s cubic-bezier(.2, .8, .2, 1) both;
}
.verified-badge::before { content: ""; width: 18px; height: 18px; border-radius: 50%; background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12l4 4 8-8' fill='none' stroke='%23fff' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/11px no-repeat; }
.hint.ok { color: var(--leaf); font-weight: 600; }
#edit-email { align-self: flex-start; padding: 0; }
.otp-inline {
  background: var(--marigold-soft); border: 1px solid #F6D98F; border-radius: 14px; padding: 16px; margin: -4px 0 16px;
  animation: slideDown .3s ease both;
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-6px); } }
.otp-inline .otp-actions { margin-top: 10px; }
.otp-sm { font-size: 1.3rem !important; letter-spacing: .45em; padding: 10px 10px 10px calc(10px + .45em) !important; background: var(--white) !important; }
.otp-inline-msg { color: #A93A1B; font-weight: 600; font-size: .9rem; margin: 8px 0 0; }

/* Sign-in required blocks */
.auth-gate p { color: var(--muted); }
.auth-gate .btn + .btn { margin-top: 10px; }
.auth-gate h2 { font-size: 1.4rem; }
.gate-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.gate-actions .btn + .btn { margin-top: 0; }

/* ---------- Dashboard ---------- */
.dashboard { padding: 40px 0 80px; }
.dash-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.dash-head h1 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); margin: 0; }
.dash-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.panel-head h2 { margin: 0; }
.panel.highlight { background: var(--marigold-soft); border-color: #F6D98F; }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .94rem; min-width: 560px; }
.table th { text-align: left; font-size: .82rem; color: var(--muted); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.status { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .8rem; font-weight: 700; }
.status-new { background: var(--marigold-soft); color: #8A6100; }
.status-contacted { background: var(--ink-soft); color: var(--ink); }
.status-closed { background: var(--leaf-soft); color: var(--leaf); }
.toast.error { background: var(--margin-red); }

/* ---------- Responsive ---------- */
@media (max-width: 1120px) {
  .nav-links, .nav-cta { display: none; }
  .menu-toggle { display: block; }
  .menu-open .nav-links {
    display: flex; flex-direction: column; align-items: stretch; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--white); padding: 14px 20px 20px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    max-height: calc(100vh - 72px); overflow-y: auto;
  }
  .menu-open .nav-links a { padding: 12px 14px; }
  .menu-open .mobile-auth { display: flex; gap: 10px; padding-top: 12px; margin-top: 6px; border-top: 1px solid var(--line); flex-wrap: wrap; }
  .menu-open .mobile-auth .btn { flex: 1; padding: 11px 16px; }
  .menu-open .mobile-auth .btn-ghost { color: var(--ink); background: transparent; }
}
@media (max-width: 1080px) {
  .city-grid { grid-template-columns: repeat(3, 1fr); }
  .subject-grid { grid-template-columns: repeat(3, 1fr); }
  .profile-body { grid-template-columns: minmax(0, 1fr); }
  .booking { position: static; }
}
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 20px; }
  .deck-stage { height: 380px; }
  .deck-sun { width: 260px; height: 260px; right: 50%; transform: translateX(50%); animation: none; }
  .listing { grid-template-columns: 1fr; }
  .filters { position: fixed; inset: 0 30% 0 0; top: 0; z-index: 80; border-radius: 0; overflow-y: auto; transform: translateX(-105%); transition: transform .3s ease; }
  .filters.open { transform: none; box-shadow: 30px 0 60px rgba(0, 0, 0, .25); }
  .filter-toggle { display: inline-flex; }
  .steps, .quotes { grid-template-columns: 1fr; }
  .steps::before { display: none; }
  .cta-band { grid-template-columns: 1fr; padding: 34px; }
  .cta-actions { justify-content: flex-start; }
  .join-grid { grid-template-columns: 1fr; }
  .auth { grid-template-columns: 1fr; }
  .auth-side { border-radius: var(--radius-lg) var(--radius-lg) 0 0; padding: 30px; }
  .auth-side .auth-points { display: none; }
  .auth-card { border-radius: 0 0 var(--radius-lg) var(--radius-lg); padding: 30px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .facts { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .section { padding: 56px 0; }
  .search-box { grid-template-columns: 1fr; }
  .hero::after { left: 8px; }
  .city-grid, .subject-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-main { flex-direction: column; align-items: flex-start; }
  .detail-list { grid-template-columns: 1fr; gap: 2px; }
  .detail-list dd { margin-bottom: 10px; }
  .form-row { grid-template-columns: 1fr; }
  .role-pick { grid-template-columns: 1fr; }
  .auth-card, .auth-side { padding: 24px; }
  .filters { inset: 0 10% 0 0; }
  .deck-card { width: 280px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ============================================================
   Tutor profile wizard (create-profile.html)
   ============================================================ */
.avatar.has-photo { background: var(--paper); overflow: visible; }
.avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.p-headline { font-family: var(--display); font-size: 1.15rem; font-weight: 700; color: var(--ink-2); }
.wizard-intro h2 { font-size: 1.4rem; }
.wizard-steps-list { margin: 18px 0 24px; padding-left: 22px; color: var(--muted); }
.wizard-steps-list li { padding: 5px 0; }
.wizard-steps-list li::marker { color: var(--marigold); font-weight: 800; }

.wizard-page { background: var(--white); min-height: 100vh; display: flex; flex-direction: column; }
.wz-header { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px); }
.wz-bar { width: min(1200px, 100% - 40px); margin-inline: auto; height: 76px; display: flex; align-items: center; gap: 20px; }
.wz-count { margin-left: auto; font-family: var(--display); font-weight: 800; font-size: 2rem; color: #9AA3B8; letter-spacing: -.02em; }
.wz-count b { color: var(--margin-red); }
.wz-exit { font-weight: 700; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink); }
.wz-exit:hover { border-color: var(--ink); text-decoration: none; }
.wz-progress { height: 5px; background: #D8E0F0; }
.wz-progress span { display: block; height: 100%; width: 0; background: var(--margin-red); border-radius: 0 3px 3px 0; transition: width .5s cubic-bezier(.2, .8, .2, 1); }

.wz-main { flex: 1; width: min(1200px, 100% - 40px); margin-inline: auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .95fr); gap: 50px; align-items: start; padding: 60px 0 70px; }
.wz-left { max-width: 540px; }
.wz-step h1 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); line-height: 1.15; margin-bottom: 10px; }
.wz-step.from-right { animation: wzRight .45s cubic-bezier(.2, .8, .2, 1) both; }
.wz-step.from-left { animation: wzLeft .45s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes wzRight { from { opacity: 0; transform: translateX(40px); } }
@keyframes wzLeft { from { opacity: 0; transform: translateX(-40px); } }
.wz-kicker { font-size: .85rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--margin-red); margin: 0 0 10px; }
.wz-help { color: var(--muted); font-size: 1.05rem; margin-bottom: 24px; }
.wz-body { margin-bottom: 8px; }
.wz-label { display: block; font-weight: 700; margin: 18px 0 8px; font-size: .95rem; }
.wz-body > .wz-label:first-child { margin-top: 0; }
.wz-input {
  width: 100%; padding: 15px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--white);
  box-shadow: 0 6px 18px -12px rgba(28, 43, 107, .35); font-size: 1.02rem; transition: border-color .15s, box-shadow .15s;
}
.wz-input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px var(--ink-soft); }
.wz-input.invalid { border-color: var(--margin-red); }
.wz-input.invalid:focus { box-shadow: 0 0 0 4px rgba(228, 87, 46, .15); }
textarea.wz-input { resize: vertical; min-height: 150px; line-height: 1.5; }
.wz-error { color: #A93A1B; background: #FDECE7; padding: 10px 14px; border-radius: 10px; font-weight: 600; margin: 14px 0 0; }
.wz-nav { display: flex; align-items: center; gap: 18px; margin-top: 26px; flex-wrap: wrap; }
.wz-next { min-width: 150px; border-radius: 10px; }
.wz-back { color: var(--muted); }

/* subject search */
.combo { position: relative; }
.combo-icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; color: #8A93A8; pointer-events: none; }
.combo-input { padding-left: 46px; }
.combo-list {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 5; list-style: none; margin: 0; padding: 6px;
  background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lift); max-height: 280px; overflow-y: auto;
}
.combo-list li { padding: 10px 12px; border-radius: 8px; cursor: pointer; font-weight: 600; }
.combo-list li:hover, .combo-list li[aria-selected="true"] { background: var(--ink-soft); color: var(--ink); }
.combo-toggle { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 8px; background: transparent; color: #6B7489; cursor: pointer; display: grid; place-items: center; }
.combo-toggle:hover { background: var(--ink-soft); color: var(--ink); }
.combo-toggle svg { width: 20px; height: 20px; }
.combo:has(.combo-toggle) .combo-input { padding-right: 52px; }
.combo-list li[role="option"] { display: flex; align-items: baseline; gap: 10px; }
.combo-list li[role="option"] small { color: var(--muted); font-weight: 500; font-size: .84rem; }
.combo-group { font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 12px 4px !important; cursor: default !important; }
.combo-group:hover { background: none !important; }
.combo-empty { color: var(--muted); cursor: default !important; font-weight: 500 !important; }
.wz-popular { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 16px; }
.wz-popular > span { color: var(--muted); font-size: .9rem; }

/* selectable chips and cards */
.wz-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.wz-chip { position: relative; cursor: pointer; }
.wz-chip input { position: absolute; opacity: 0; pointer-events: none; }
.wz-chip span {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 16px; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--white); font-weight: 600; transition: background .15s, border-color .15s, color .15s, transform .15s;
}
.wz-chip:hover span { border-color: var(--ink); }
.wz-chip input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.wz-chip input[type=checkbox]:checked + span::before { content: "✓"; font-weight: 800; color: var(--marigold); }
.wz-chip input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 2px; }
.wz-chip input:disabled + span { opacity: .4; cursor: not-allowed; }
.wz-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.wz-chip.day span { justify-content: center; width: 100%; border-radius: 12px; padding: 12px 0; }
.wz-chip.day input:checked + span::before { content: none; }
.wz-cards { display: grid; gap: 12px; }
.wz-card { position: relative; cursor: pointer; }
.wz-card input { position: absolute; opacity: 0; }
.wz-card span { display: block; padding: 16px 18px 16px 52px; border: 1.5px solid var(--line); border-radius: 14px; position: relative; transition: border-color .15s, background .15s; }
.wz-card span::before { content: ""; position: absolute; left: 18px; top: 50%; width: 20px; height: 20px; margin-top: -10px; border-radius: 50%; border: 2px solid #B8C1D6; transition: border .15s; }
.wz-card b { display: block; color: var(--ink); font-size: 1.05rem; }
.wz-card small { color: var(--muted); font-size: .92rem; }
.wz-card:hover span { border-color: var(--ink); }
.wz-card input:checked + span { border-color: var(--ink); background: var(--ink-soft); }
.wz-card input:checked + span::before { border: 6px solid var(--ink); }
.wz-card input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 2px; }

/* experience stepper, fee */
.stepper { display: inline-flex; align-items: center; gap: 10px; }
.stepper-btn { width: 52px; height: 52px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--white); font-size: 1.5rem; font-weight: 700; color: var(--ink); cursor: pointer; }
.stepper-btn:hover { border-color: var(--ink); background: var(--ink-soft); }
.stepper-input { width: 96px; text-align: center; font-family: var(--display); font-size: 1.6rem; font-weight: 800; padding: 10px; }
.stepper-unit { font-weight: 700; color: var(--muted); }
.fee-input { display: flex; align-items: center; gap: 10px; max-width: 320px; }
.fee-input > span:first-child { font-family: var(--display); font-size: 1.8rem; font-weight: 800; color: var(--ink); }
.fee-input input { font-family: var(--display); font-size: 1.5rem; font-weight: 800; }
.wz-hint { margin: 18px 0 0; padding: 12px 14px; background: var(--leaf-soft); color: #0F5E4A; border-radius: 10px; font-weight: 600; font-size: .94rem; }
.counter { text-align: right; font-size: .82rem; color: var(--muted); margin-top: 6px; }
.counter.ok { color: var(--leaf); font-weight: 700; }

/* photo + review */
.photo-pick { display: flex; align-items: center; gap: 20px; }
.photo-preview { width: 110px; height: 110px; border-radius: 50%; background: var(--ink); color: var(--white); display: grid; place-items: center; font-family: var(--display); font-size: 2.2rem; font-weight: 800; overflow: hidden; flex: none; box-shadow: 0 0 0 6px var(--marigold-soft); }
.photo-preview img { width: 100%; height: 100%; object-fit: cover; }
.photo-pick .linkbtn { margin-left: 10px; }
.wz-review-title { font-size: 1.15rem; margin: 30px 0 10px; }
.wz-review { margin: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.wz-review > div { display: grid; grid-template-columns: 130px 1fr auto; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); align-items: baseline; }
.wz-review > div:first-child { border-top: 0; }
.wz-review dt { color: var(--muted); font-size: .9rem; }
.wz-review dd { margin: 0; font-weight: 600; font-size: .95rem; overflow-wrap: anywhere; }

/* illustration side */
.wz-art { position: sticky; top: 110px; }
.wz-illus { width: 100%; height: auto; display: block; }
.wz-illus .blob { fill: #FBE3D9; }
.wz-illus .float-a { animation: bob 6s ease-in-out infinite; }
.wz-illus .float-b { animation: bob 7s ease-in-out -2s infinite; }
.wz-illus .float-c { animation: bob 5s ease-in-out -1s infinite; }
@keyframes bob { 50% { transform: translateY(-10px); } }
.wz-tip {
  position: absolute; left: 6%; bottom: -6px; max-width: 330px; background: var(--white); border-radius: 14px; padding: 14px 16px;
  box-shadow: var(--shadow-lift); border: 1px solid var(--line); font-size: .93rem; color: var(--text);
}
.wz-tip b { display: block; color: var(--margin-red); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 2px; }
.wz-tip.pop { animation: tipPop .5s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes tipPop { from { opacity: 0; transform: translateY(10px) scale(.97); } }

/* finish screen */
.wz-end { position: relative; }
.wz-done-icon { width: 76px; height: 76px; border-radius: 50%; margin-bottom: 20px; background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12l4 4 8-8' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/40px no-repeat; animation: otpIn .6s cubic-bezier(.2, .8, .2, 1) both; }
.wz-confetti { position: absolute; inset: -40px 0 auto 0; height: 0; pointer-events: none; }
.wz-confetti i { position: absolute; top: 0; left: var(--x); width: 9px; height: 14px; border-radius: 2px; opacity: 0;
  background: var(--marigold); animation: confetti 1.9s cubic-bezier(.2, .7, .4, 1) var(--delay) forwards; }
.wz-confetti i:nth-child(3n) { background: var(--leaf); }
.wz-confetti i:nth-child(3n+1) { background: var(--margin-red); }
.wz-confetti i:nth-child(4n) { background: var(--ink); }
@keyframes confetti { 0% { opacity: 1; transform: translate(0, 0) rotate(0); } 100% { opacity: 0; transform: translate(var(--dx), var(--fall)) rotate(calc(var(--i) * 67deg)); } }

@media (max-width: 900px) {
  .wz-main { grid-template-columns: 1fr; padding: 28px 0 50px; }
  .wz-art { display: none; }
  .wz-count { font-size: 1.5rem; }
  .wz-exit { display: none; }
  .wz-days { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 480px) {
  .wz-review > div { grid-template-columns: 1fr auto; }
  .wz-review dt { grid-column: 1 / -1; }
  .photo-pick { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   Student learning-profile wizard (student-profile.html)
   ============================================================ */
.wz-note {
  margin: 16px 0 0; padding: 12px 14px 12px 42px; border-radius: 10px; position: relative;
  background: var(--marigold-soft); border: 1px solid #F6D98F; color: #6B4E00; font-weight: 600; font-size: .94rem;
}
.wz-body > .wz-note:first-child { margin: 0 0 6px; }
.wz-note::before {
  content: "!"; position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; border-radius: 50%; background: var(--marigold); color: var(--ink);
  display: grid; place-items: center; font-weight: 900; font-size: .8rem;
}
.wz-note[hidden] { display: none; }
.class-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.class-grid .wz-chip span { justify-content: center; width: 100%; border-radius: 12px; padding: 12px 0; font-size: 1.05rem; }
.class-grid .wz-chip input:checked + span::before { content: none; }
@media (max-width: 480px) { .class-grid { grid-template-columns: repeat(4, 1fr); } }

/* ============================================================
   Session packages (tutor page + checkout)
   ============================================================ */
.buy-title { font-size: 1.3rem; margin-bottom: 4px; }
.pkg-list { display: grid; gap: 8px; margin-bottom: 16px; }
.pkg-group { margin: 8px 0 0; font-size: .8rem; font-weight: 800; color: var(--muted); letter-spacing: .02em; }
.pkg-group:first-child { margin-top: 0; }
.pkg-option { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: var(--white); transition: border-color .15s, background .15s, transform .15s; }
.pkg-option:hover { border-color: var(--ink); }
.pkg-option input { position: absolute; opacity: 0; }
.pkg-option::before { content: ""; flex: none; width: 18px; height: 18px; border-radius: 50%; border: 2px solid #B8C1D6; transition: border .15s; }
.pkg-option:has(input:checked) { border-color: var(--ink); background: var(--ink-soft); }
.pkg-option:has(input:checked)::before { border: 6px solid var(--ink); }
.pkg-option:has(input:focus-visible) { outline: 3px solid var(--marigold); outline-offset: 2px; }
.pkg-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pkg-name { font-weight: 700; color: var(--ink); display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pkg-sub { font-size: .84rem; color: var(--muted); }
.pkg-price { font-family: var(--display); font-weight: 800; color: var(--ink); font-size: 1.08rem; white-space: nowrap; }
.pkg-save, .pkg-best { font-size: .7rem; font-weight: 800; padding: 2px 8px; border-radius: 999px; }
.pkg-save { background: var(--leaf-soft); color: var(--leaf); }
.pkg-best { background: var(--marigold); color: var(--ink); }
.pkg-plans { display: flex; gap: 6px; padding: 4px; border-radius: 12px; background: var(--paper, #F4F6FB); border: 1px solid var(--line); }
.pkg-plan { flex: 1; position: relative; cursor: pointer; }
.pkg-plan input { position: absolute; opacity: 0; }
.pkg-plan span { display: block; text-align: center; padding: 8px 6px; border-radius: 9px; font-size: .82rem; font-weight: 700; white-space: nowrap; color: var(--muted); transition: background .15s, color .15s; }
.pkg-plan input:checked + span { background: var(--white); color: var(--ink); box-shadow: 0 1px 4px rgba(20,30,60,.12); }
.pkg-plan input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 1px; }
.pkg-select-field { margin: 0; }
.pkg-select-field select { width: 100%; cursor: pointer; font-weight: 600; }
.pkg-selected { cursor: default; border-color: var(--ink); background: var(--ink-soft); }
.pkg-selected::before { display: none; }
.pkg-selected:hover { border-color: var(--ink); }
.pkg-note { font-size: .86rem; color: var(--muted); text-align: center; margin: 8px 0 0; }
.pkg-secure { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: .8rem; color: var(--muted); margin: 14px 0 0; text-align: center; }
.pkg-secure svg { width: 16px; height: 16px; flex: none; color: var(--leaf); }
#enroll-btn { font-size: 1.02rem; padding: 14px 20px; }

/* ---------- package editor (tutor sign-up step 11 + My account) ---------- */
.pe-base { margin-bottom: 14px; }
.pe-base label { display: block; font-weight: 700; margin-bottom: 8px; }
.pe-base .fee-input { max-width: 240px; }
.pe-base .muted { margin: 8px 0 0; }
.pe-rows { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--white); }
.pe-row { display: grid; grid-template-columns: auto 1fr 150px auto; align-items: center; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); transition: opacity .15s; }
.pe-row:first-child { border-top: 0; }
.pe-row.off .pe-name, .pe-row.off .pe-price { opacity: .45; }
.pe-check input { width: 18px; height: 18px; accent-color: var(--ink); }
.pe-name { font-weight: 700; color: var(--ink); display: flex; flex-direction: column; gap: 2px; }
.pe-name select, .pe-n { font: inherit; font-weight: 700; padding: 3px 6px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.pe-n { width: 70px; }
.pe-hint { font-size: .8rem; font-weight: 600; color: var(--leaf); min-height: 1em; }
.pe-price { display: flex; align-items: center; gap: 6px; }
.pe-price span { font-weight: 800; color: var(--ink); }
.pe-price input { width: 100%; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; font-weight: 700; background: var(--paper); }
.pe-price input:focus { outline: none; border-color: var(--ink); background: var(--white); }
.pe-del { border: 0; background: none; font-size: 1.3rem; line-height: 1; color: var(--muted); cursor: pointer; padding: 4px; }
.pe-del:hover { color: var(--margin-red); }
#pe-add { margin-top: 10px; }
#pkg-save { margin-top: 14px; }
.wz-pkg { margin-top: 6px; }
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }

/* ============================================================
   Checkout (order summary + Razorpay)
   ============================================================ */
.checkout { padding: 36px 0 80px; }
.co-head { margin-bottom: 22px; }
.co-head h1 { font-size: clamp(1.8rem, 3.4vw, 2.4rem); margin: 8px 0 4px; }
.co-head .muted { margin: 0; }
.co-back { font-weight: 600; font-size: .92rem; }
.co-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 26px; align-items: start; }
.co-step h2 { display: flex; align-items: center; gap: 10px; font-size: 1.2rem; }
.co-step .panel-head h2 { margin: 0; }
.co-num { width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--white); display: grid; place-items: center; font-size: .9rem; flex: none; }
.co-tutor { font-size: 1.1rem; color: var(--ink); }
.co-details { margin: 0 0 16px; display: grid; gap: 8px; }
.co-details > div { display: grid; grid-template-columns: 150px 1fr; gap: 12px; }
.co-details dt { color: var(--muted); }
.co-details dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.co-form { margin-bottom: 8px; }
.co-form input[type=date] { font-weight: 600; }
.co-summary { position: sticky; top: 90px; margin: 0; }
.co-summary h2 { font-size: 1.2rem; }
.co-rows { margin: 0; }
.co-rows > div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: .95rem; }
.co-rows dt { color: var(--muted); }
.co-rows dd { margin: 0; font-weight: 600; text-align: right; }
.co-total-row { display: flex; justify-content: space-between; align-items: baseline; margin: 16px 0; }
.co-total-row span { font-weight: 700; }
.co-total-row b { font-family: var(--display); font-size: 2rem; color: var(--ink); }
.co-total-row b.bump { animation: bump .35s cubic-bezier(.2, .8, .2, 1); }
@keyframes bump { 40% { transform: scale(1.08); color: var(--leaf); } }
.co-test { background: var(--marigold-soft); border: 1px dashed #E5B84A; color: #6B4E00; border-radius: 10px; padding: 10px 12px; font-size: .86rem; }
.co-pay { font-size: 1.05rem; padding: 15px 20px; margin-top: 4px; }
.co-summary .form-msg, .co-summary .form-note { margin: 0 0 12px; }
.co-done { max-width: 620px; margin: 30px auto 0; text-align: center; position: relative; }
.co-done .wz-done-icon { margin: 0 auto 18px; }
.co-done .lead { margin: 0 auto 22px; }
.co-done .wz-nav { justify-content: center; }
.co-receipt { text-align: left; margin: 0; }
.co-receipt dl { margin: 0; }
.co-receipt dl > div { display: grid; grid-template-columns: 140px 1fr; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.co-receipt dl > div:last-child { border-bottom: 0; }
.co-receipt dt { color: var(--muted); }
.co-receipt dd { margin: 0; font-weight: 700; overflow-wrap: anywhere; }

@media (max-width: 900px) {
  .co-grid { grid-template-columns: 1fr; }
  .co-summary { position: static; }
  .stat-row { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .pe-row { grid-template-columns: auto 1fr; }
  .pe-price { grid-column: 2; }
  .pe-del { grid-column: 2; justify-self: end; }
  .co-details > div, .co-receipt dl > div { grid-template-columns: 1fr; gap: 2px; }
}
@media print {
  .site-header, .site-footer, .co-done .wz-nav, .wz-confetti { display: none !important; }
  body { background: #fff; }
}
.pe-title { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pe-title select, .pe-title .pe-n { width: auto; }
.pe-hint.warn { color: #9A6700; }
.co-mobile-bar { display: none; }
@media (max-width: 900px) {
  .co-mobile-bar {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px -16px rgba(28, 43, 107, .5);
  }
  .co-mobile-bar b { display: block; font-family: var(--display); font-size: 1.35rem; color: var(--ink); line-height: 1.1; }
  .co-mobile-bar .btn { padding: 12px 22px; }
  body[data-page="checkout"] .site-footer { padding-bottom: 100px; }
}
.btn:disabled, .btn[disabled] { opacity: .5; cursor: not-allowed; box-shadow: none; }

/* Long unbroken text typed by users (e.g. "KKKKKKKK…") must wrap instead of pushing cards off screen */
body { overflow-wrap: break-word; }
.profile-body > *, .listing > *, .join-grid > * { min-width: 0; }
.panel, .tutor-card, .review, .detail-list dd { overflow-wrap: anywhere; }

/* ---------- Student requests (tutors) ---------- */
.btn-leaf { background: var(--leaf); color: var(--white); border-color: var(--leaf); }
.btn-leaf:hover { filter: brightness(1.08); color: var(--white); }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; border-radius: 12px; background: var(--paper); border: 1px solid var(--line); }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; }
.seg span { display: block; text-align: center; padding: 7px 4px; border-radius: 9px; font-size: .86rem; font-weight: 700; color: var(--muted); transition: background .15s, color .15s; }
.seg input:checked + span { background: var(--white); color: var(--ink); box-shadow: 0 1px 4px rgba(20, 30, 60, .12); }
.seg input:focus-visible + span { outline: 3px solid var(--marigold); outline-offset: 1px; }
.f-hint { margin: 8px 0 0; font-size: .8rem; color: var(--muted); line-height: 1.4; }
.f-group select:disabled { opacity: .6; cursor: not-allowed; }
.req-list { display: grid; gap: 16px; }
.req-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px 22px; display: grid; gap: 12px; overflow-wrap: anywhere; transition: box-shadow .15s, border-color .15s; }
.req-card:hover { border-color: #C9D0E2; box-shadow: 0 10px 28px -20px rgba(28, 43, 107, .5); }
.req-card.is-contacted { border-left: 4px solid var(--leaf); }
.req-top { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.req-top h3 { font-size: 1.1rem; margin: 0 0 4px; color: var(--ink); }
.req-budget { text-align: right; font-family: var(--display); font-weight: 800; color: var(--ink); white-space: nowrap; }
.req-budget small { display: block; font-family: inherit; font-weight: 600; font-size: .75rem; color: var(--muted); }
.tag.near { background: var(--marigold-soft); color: #7A5600; border-color: transparent; }
.req-msg { margin: 0; padding: 10px 14px; background: var(--paper); border-radius: 10px; font-size: .95rem; }
.req-goals { margin: 0; font-size: .9rem; color: var(--muted); }
.req-goals b { color: var(--text); }
.req-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border-top: 1px dashed var(--line); padding-top: 12px; }
.req-contact { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; background: var(--leaf-soft); padding: 10px 14px; border-radius: 12px; }
.req-contact a[href^="tel"] { font-weight: 700; }
.req-actions { display: flex; gap: 8px; }
.req-loading { padding: 40px; text-align: center; }
.req-gate { grid-column: 1 / -1; max-width: 640px; margin: 20px auto; }
.req-gate .gate-actions { justify-content: center; margin-top: 16px; }
#req-root:not(.listing) { padding: 30px 0 80px; }
@media (max-width: 900px) {
  .req-filters { position: static; inset: auto; transform: none; border-radius: var(--radius-lg); z-index: auto; overflow: visible; }
}
@media (max-width: 600px) {
  .req-top { flex-direction: column; gap: 6px; }
  .req-budget { text-align: left; }
  .req-foot { flex-direction: column; align-items: stretch; }
  .req-foot .btn { width: 100%; }
}

/* ---------- Tutor home ---------- */
.th-kicker { display: inline-block; margin: 0 0 14px; padding: 5px 12px; border-radius: 999px; background: var(--leaf-soft); color: var(--leaf); font-weight: 800; font-size: .85rem; letter-spacing: .02em; }
.th-hero h1 { max-width: 16ch; }
.th-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.th-note { margin: 14px 0 0; font-size: .92rem; color: var(--muted); }
.th-board { background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: 26px; box-shadow: var(--shadow-lift); max-width: 440px; justify-self: end; width: 100%; }
.th-board-head { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; font-family: var(--display); font-size: 1.1rem; color: var(--ink); }
.th-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--leaf); box-shadow: 0 0 0 5px var(--leaf-soft); }
.th-board-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
.th-board-grid > div { background: var(--paper); border-radius: 14px; padding: 14px; }
.th-board-grid b { display: block; font-family: var(--display); font-size: 2rem; font-weight: 800; color: var(--ink); line-height: 1.1; }
.th-board-grid span { font-size: .85rem; color: var(--muted); }
.btn-block { width: 100%; justify-content: center; }
.th-n { color: var(--ink); font-size: 1.05rem; }
.city-tile.is-mine { border-color: var(--leaf); box-shadow: 0 0 0 2px var(--leaf-soft); }
.city-tile h3 .tag { vertical-align: middle; margin-left: 4px; }
.subject.is-mine { border-color: var(--leaf); }
@media (max-width: 900px) { .th-board { justify-self: stretch; max-width: none; } }

/* Tutor home hero: text sits on the notebook ruling (lines every 36px from the top of the hero).
   Every line height and gap below is a multiple of 36px, so all lines stay on the ruling. */
.th-hero .hero-grid { align-items: start; }
.th-hero .th-board { align-self: center; }
.th-hero .th-text { padding-top: 25px; }            /* puts the heading's baseline just on a ruled line */
.th-hero .lead { position: relative; top: -4px; }     /* same for the paragraph (its font sits lower in the line) */
.th-hero .th-kicker { display: block; width: fit-content; box-sizing: border-box; height: 36px; line-height: 26px; margin: 0; }
.th-hero h1 { font-size: 3.9rem; line-height: 72px; margin: 0 0 36px; }
.th-hero .lead { font-size: 1.2rem; line-height: 36px; margin: 0 0 36px; }
.th-hero .th-note { line-height: 36px; margin: 0; }
@media (max-width: 1023px) {
  .th-hero h1 { font-size: 3.2rem; }
  .th-hero .th-text { padding-top: 28px; }
  .th-hero .lead { top: -7px; }
}
@media (max-width: 600px) {
  .th-hero h1 { font-size: 2.1rem; line-height: 36px; }
  .th-hero .th-text { padding-top: 16px; }
  .th-hero .lead { font-size: 1.1rem; top: 5px; }
}

.co-rows dt { white-space: nowrap; flex: none; }
.co-rows dd { text-align: right; min-width: 0; }
.form-row:has(> .form-field[hidden]) { grid-template-columns: 1fr; }
.req-anywhere { margin-top: 10px; align-items: flex-start; font-size: .86rem; line-height: 1.35; color: var(--text); }
.req-anywhere input { margin-top: 1px; flex: none; }

/* ---------- Footer contact strip ---------- */
.foot-contact { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 30px; margin-top: 40px; padding-top: 28px; border-top: 1px solid rgba(255, 255, 255, .12); font-size: .95rem; line-height: 1.7; }
.foot-contact address { font-style: normal; max-width: 38ch; color: #9FB0E8; }
.foot-contact address b { color: var(--white); }
.foot-contact p { margin: 12px 0 0; }
.foot-contact ul li { margin-bottom: 6px; }
.foot-contact + .foot-bottom { margin-top: 28px; }
@media (max-width: 900px) { .foot-contact { grid-template-columns: 1fr 1fr; } .foot-contact address { grid-column: 1 / -1; } }
@media (max-width: 600px) { .foot-contact { grid-template-columns: 1fr; } }

/* ---------- Policy & contact pages ---------- */
.legal { max-width: 800px; padding: 40px 0 80px; }
.legal .updated { color: var(--muted); font-size: .92rem; margin: 0 0 24px; }
.legal h2 { font-size: 1.35rem; margin: 34px 0 10px; }
.legal h3 { font-size: 1.05rem; margin: 20px 0 6px; }
.legal p, .legal li { line-height: 1.7; }
.legal ul, .legal ol { padding-left: 22px; }
.legal li { margin-bottom: 6px; }
.legal .callout { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px 20px; margin: 18px 0; }
.legal table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: .95rem; }
.legal th, .legal td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal th { background: var(--paper); }
.legal-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin: 20px 0 10px; }
.contact-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; }
.contact-card h2 { font-size: 1.05rem; margin: 0 0 8px; }
.contact-card p { margin: 0; line-height: 1.7; }
.form-agree { font-size: .82rem; color: var(--muted); text-align: center; margin: 10px 0 0; }

/* No underlines anywhere: links and link-style buttons, on hover and focus too */
a, a:hover, a:focus, a:active, .linkbtn, .linkbtn:hover, .linklike, .linklike:hover { text-decoration: none !important; }