* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: var(--font-ui);
  color: var(--color-ink);
  background: var(--color-surface);
}
.wrap { max-width: var(--container-max); margin: 0 auto; padding: 0 var(--screen-pad) 88px; }
h1 { font-size: 22px; margin: 4px 0 8px; font-weight: 700; }
h2 { font-size: 18px; margin: 0; font-weight: 700; }
p.lead { color: var(--color-slate); font-size: var(--fs-body); line-height: var(--lh-body); margin: 0 0 16px; }
p.helper { color: var(--color-slate); font-size: 13px; margin: 4px 0 0; }
.hidden { display: none !important; }
section.screen { display: none; padding-top: 12px; }
section.screen.active { display: block; }
label.field { display: block; font-size: 14px; font-weight: 600; margin: 16px 0 6px; }
input[type=text], input[type=date], input[type=email], input[type=tel], input[type=file], input[type=search], select, textarea {
  width: 100%; padding: 12px; font-size: 16px; border: 1px solid var(--color-border);
  border-radius: var(--r-md); background: var(--color-surface); font-family: inherit;
  -webkit-user-select: text; user-select: text; touch-action: manipulation;
}
.chip {
  border: 1px solid var(--color-border); background: var(--color-green-tint); color: var(--color-ink);
  border-radius: var(--r-pill); padding: 10px 16px; font-size: 14px; cursor: pointer; font-family: inherit;
}
.chip.on { background: var(--color-emerald); border-color: var(--color-emerald); color: #fff; }
.consent-item {
  display: flex; gap: 10px; align-items: flex-start; padding: 14px;
  border: 1px solid var(--color-border); border-radius: var(--r-md); background: var(--color-surface); margin-top: 16px;
}
.consent-item input { margin-top: 3px; width: 18px; height: 18px; flex: 0 0 auto; }
.consent-item .t { font-size: 14px; line-height: 1.5; }
button.primary {
  width: 100%; margin-top: 24px; padding: 14px; font-size: 16px; font-weight: 700;
  color: #fff; background: var(--color-emerald); border: none; border-radius: var(--r-pill); cursor: pointer;
}
button.primary:disabled { opacity: 0.5; }
button.primary:active { background: var(--color-emerald-hover); }
button.secondary {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 16px; border-radius: var(--r-pill);
  border: 1px solid var(--color-border); background: #fff;
  color: var(--color-ink); font-family: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
}
button.secondary:disabled { opacity: 0.5; }
.err { color: var(--color-error); font-size: 13px; margin-top: 12px; }
.center { text-align: center; padding-top: 48px; }
.splash-title { font-size: 26px; font-weight: 700; margin: 24px 0 8px; }
a { color: var(--color-emerald); }

#g-app { display: none; }
#g-app.active { display: block; }
#g-onboarding { display: block; }
#g-onboarding:not(.active) { display: none; }

.greeting-row { display: flex; gap: 12px; align-items: center; margin: 16px 0 8px; }
.greeting-row .kla-img { flex: 0 0 auto; }
.splash-kla { display: block; margin: 0 auto 8px; }
.context-chip {
  display: inline-block; margin-top: 4px; padding: 6px 12px; border-radius: var(--r-pill);
  background: var(--color-green-tint); font-size: 12px; color: var(--color-text-700);
}
.search-wrap { position: relative; margin-bottom: 20px; }
.search-wrap .search-icon {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--color-slate); pointer-events: none;
}
.search-pill {
  width: 100%; padding: 12px 16px 12px 42px; border-radius: var(--r-pill);
  border: 1px solid var(--color-border); background: var(--color-green-tint); font-size: 15px;
  color: var(--color-slate); font-family: inherit;
}
.featured-card {
  background: var(--color-forest); color: #fff; border-radius: var(--r-xl); padding: 18px 20px;
  margin-bottom: 12px; position: relative; overflow: hidden; min-height: 96px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.featured-card .featured-body { flex: 1; min-width: 0; z-index: 1; }
.featured-card .featured-kla { flex: 0 0 auto; opacity: 0.95; }
.featured-card .tag {
  display: inline-block; background: var(--color-amber); color: var(--color-ink);
  font-size: 11px; font-weight: 700; padding: 4px 12px; border-radius: var(--r-pill); margin-bottom: 8px;
}
.featured-card h3 { margin: 0 0 4px; font-size: 15px; font-weight: 700; line-height: 1.35; }
.featured-card p { margin: 0; font-size: 12px; color: rgba(255,255,255,.75); }
.section-header {
  display: flex; justify-content: space-between; align-items: baseline; margin: 20px 0 12px; gap: 8px;
}
.section-header h3 { margin: 0; font-size: 16px; font-weight: 700; }
.section-header .section-sub { font-size: 12px; color: var(--color-slate); font-weight: 500; }
.section-header a { font-size: 13px; font-weight: 700; text-decoration: none; color: var(--color-emerald); flex-shrink: 0; }

.family-section { margin-bottom: 18px; }
.family-header {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 700; color: var(--color-text-700);
  margin: 22px 0 12px; line-height: 1.35;
}
.family-accent {
  width: 4px; height: 18px; border-radius: 4px; flex-shrink: 0;
  background: var(--color-emerald);
}
.family-accent.fam-career { background: var(--fam-career-accent); }
.family-accent.fam-university { background: var(--fam-university-accent); }
.family-accent.fam-grow { background: var(--fam-grow-accent); }
.family-ico {
  width: 32px; height: 32px; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; flex-shrink: 0;
}
.family-ico.type-university { background: #2F6FB0; }
.family-ico.type-club { background: #12805C; }
.family-ico.type-company { background: #CE8A22; }
.family-ico.type-ngo { background: #C45C4A; }
.family-ico.type-other { background: #6B7B70; }

.browse-orgs-block {
  margin-top: 28px; padding-top: 8px;
  border-top: 1px dashed var(--color-border);
}
.browse-orgs-title {
  margin: 16px 0 4px; font-size: 18px; font-weight: 700; color: var(--color-ink);
}

.org-grid-visual {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.org-row { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 8px; }
.org-card {
  position: relative;
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--r-xl);
  padding: 14px 12px 12px; cursor: pointer; text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border-top: 3px solid var(--color-border);
}
.org-row .org-card { flex: 0 0 148px; }
.org-card.type-university { border-top-color: #2F6FB0; }
.org-card.type-club { border-top-color: #12805C; }
.org-card.type-company { border-top-color: #CE8A22; }
.org-card.type-ngo { border-top-color: #C45C4A; }
.org-card:active { transform: scale(0.98); }
.org-logo-fallback {
  display: flex !important; align-items: center; justify-content: center;
  color: #fff;
}
.org-logo-fallback.type-university { background: #2F6FB0 !important; }
.org-logo-fallback.type-club { background: #12805C !important; }
.org-logo-fallback.type-company { background: #CE8A22 !important; }
.org-logo-fallback.type-ngo { background: #C45C4A !important; }
.org-logo-fallback.type-other { background: #6B7B70 !important; }

/* Capability passport — open-ended tiers + medals (no progress bars) */
.passport-section { margin-top: 8px; }
.passport-eyebrow {
  margin: 0 0 2px; font-size: 11px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase; opacity: 0.75;
}
.passport-empty {
  text-align: center; padding: 22px 16px; border-radius: var(--r-2xl);
  background: linear-gradient(180deg, #E9F6EF, #fff); border: 1px solid var(--color-border);
}
.passport-empty .tier-seal { margin: 0 auto 8px; }
.passport-empty h3 { margin: 10px 0 4px; font-size: 16px; }
.passport-empty p { margin: 0 0 12px; color: var(--color-slate); font-size: 13px; line-height: 1.45; }
.passport-empty .primary { margin-top: 0; }

.passport-tier-card {
  display: flex; gap: 14px; align-items: center;
  background: linear-gradient(145deg, #0E3A29 0%, #12805C 65%, #1a5c40 120%);
  color: #fff; border-radius: var(--r-2xl); padding: 16px 18px; margin-bottom: 12px;
  box-shadow: var(--shadow-md);
}
.tier-seal {
  width: 72px; height: 72px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center;
  background: radial-gradient(circle at 35% 30%, #fff8e6, #F2A93B 45%, #C77F1A 100%);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.25), 0 8px 20px rgba(0,0,0,0.25);
  color: #0E3A29; font-weight: 800; font-size: 11px; letter-spacing: 0.02em;
  text-align: center; line-height: 1.1; padding: 6px;
}
.tier-seal span { transform: rotate(-6deg); display: block; }
.tier-seal.tier-seed { background: radial-gradient(circle at 35% 30%, #E2CDA8, #C4A574); }
.tier-seal.tier-sprout { background: radial-gradient(circle at 35% 30%, #C8EBD9, #5FC195); }
.tier-seal.tier-grow { background: radial-gradient(circle at 35% 30%, #E9F6EF, #12805C); color: #fff; }
.tier-seal.tier-rise { background: radial-gradient(circle at 35% 30%, #D9E7F5, #2F6FB0); color: #fff; }
.tier-seal.tier-peak { background: radial-gradient(circle at 35% 30%, #FDEFD6, #CE8A22); }
.tier-seal.tier-legend { background: radial-gradient(circle at 35% 30%, #FBE6C0, #C45C4A); color: #fff; }
.tier-seal.tier-beyond { background: radial-gradient(circle at 35% 30%, #E5E0F2, #5B4B8A); color: #fff; }
.tier-copy h3 { margin: 0 0 4px; font-size: 17px; }
.tier-next { margin: 0; font-size: 12px; line-height: 1.4; opacity: 0.9; }
.tier-next strong { color: #F2A93B; }

.passport-stats {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px;
}
.passport-stat {
  background: #fff; border: 1px solid var(--color-border); border-radius: 16px;
  padding: 12px 8px; text-align: center;
}
.passport-stat strong { display: block; font-size: 18px; font-weight: 800; color: var(--color-ink); margin: 4px 0 2px; }
.passport-stat span:last-child { font-size: 11px; color: var(--color-slate); font-weight: 600; }
.stat-ico {
  display: inline-block; width: 22px; height: 22px; border-radius: 8px;
  background: var(--color-green-tint);
}
.stat-ico.xp { background: linear-gradient(135deg, #FDEFD6, #F2A93B); }
.stat-ico.badge { background: linear-gradient(135deg, #E9F6EF, #5FC195); }
.stat-ico.tier { background: linear-gradient(135deg, #D9E7F5, #2F6FB0); }

.passport-section-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 8px;
  margin: 4px 0 10px;
}
.passport-section-head h4 { margin: 0; font-size: 15px; }
.passport-section-head span { font-size: 11px; color: var(--color-slate); font-weight: 600; }

.skill-medal-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.skill-medal {
  border: 1px solid var(--color-border); background: #fff; border-radius: 18px;
  padding: 12px 10px 10px; text-align: center; cursor: default;
  font: inherit; color: inherit;
  box-shadow: var(--shadow-sm);
}
.skill-medal.locked {
  background: #f7faf8; opacity: 0.85; border-style: dashed;
}
.medal-face {
  width: 56px; height: 56px; margin: 0 auto 8px; border-radius: 50%;
  display: grid; place-items: center; position: relative;
  background: radial-gradient(circle at 35% 30%, #fff, #C8EBD9 55%, #12805C);
  color: #0E3A29; box-shadow: inset 0 -3px 0 rgba(0,0,0,0.08);
}
.skill-medal.fam-thinking .medal-face { background: radial-gradient(circle at 35% 30%, #fff, #D9E7F5 55%, #2F6FB0); color: #163a5c; }
.skill-medal.fam-communication .medal-face { background: radial-gradient(circle at 35% 30%, #fff, #FDEFD6 55%, #CE8A22); }
.skill-medal.fam-collaboration .medal-face { background: radial-gradient(circle at 35% 30%, #fff, #C8EBD9 55%, #12805C); }
.skill-medal.fam-execution .medal-face { background: radial-gradient(circle at 35% 30%, #fff, #FBDECB 55%, #C45C4A); color: #5c2418; }
.skill-medal.fam-digital .medal-face { background: radial-gradient(circle at 35% 30%, #fff, #E5E0F2 55%, #5B4B8A); color: #2d2450; }
.skill-medal.locked .medal-face {
  background: radial-gradient(circle at 35% 30%, #f4f4f4, #d8dde0); color: #8a9490;
}
.medal-glyph { font-size: 18px; font-weight: 800; line-height: 1; }
.medal-stars {
  position: absolute; bottom: -2px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 2px;
}
.medal-stars i {
  width: 6px; height: 6px; border-radius: 50%; background: #F2A93B;
  box-shadow: 0 0 0 1px rgba(14,58,41,0.15);
}
.medal-name {
  display: block; font-size: 12px; font-weight: 700; line-height: 1.25;
  color: var(--color-ink); min-height: 2.4em;
}
.medal-rank {
  display: inline-block; margin-top: 2px; font-size: 10px; font-weight: 700;
  padding: 2px 8px; border-radius: 999px;
  background: var(--color-green-tint); color: var(--color-emerald);
}
.medal-next {
  display: block; margin-top: 6px; font-size: 10px; color: var(--color-slate); font-weight: 600;
}

.passport-family-chips {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px;
}
.fam-chip {
  font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 999px;
  background: var(--color-green-50); color: var(--color-text-700); border: 1px solid var(--color-border);
}
.fam-chip.fam-thinking { background: #EAF2FB; color: #2F6FB0; }
.fam-chip.fam-communication { background: #FDEFD6; color: #9a6818; }
.fam-chip.fam-collaboration { background: #E9F6EF; color: #12805C; }
.fam-chip.fam-execution { background: #FBDECB; color: #8a3d2e; }
.fam-chip.fam-digital { background: #EFEAF8; color: #5B4B8A; }

.passport-train-cta { width: 100%; margin-top: 0; }

.cat-tile {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.cat-tile:active { transform: scale(0.97); }
.opp-card {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.opp-card:active { transform: scale(0.99); }

.cat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cat-tile {
  border: none; text-align: left; padding: 14px 14px 12px; border-radius: var(--r-xl);
  min-height: 96px; cursor: pointer; position: relative; font-family: inherit;
  box-shadow: var(--shadow-sm); display: flex; flex-direction: column;
}
.cat-tile.compact { min-height: 80px; min-width: 120px; }
.cat-tile .icon-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%; margin-bottom: 10px; color: #fff;
}
.cat-tile .icon-badge.fam-career { background: var(--fam-career-accent); }
.cat-tile .icon-badge.fam-university { background: var(--fam-university-accent); }
.cat-tile .icon-badge.fam-grow { background: var(--fam-grow-accent); }
.cat-tile .icon-badge svg { display: block; }
.cat-tile.signup-tile.on { outline: 2.5px solid var(--color-emerald); outline-offset: 2px; }
.signup-grid { margin-top: 8px; }
.cat-tile .label {
  font-size: 15px; font-weight: 700; color: var(--color-ink); line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  padding-right: 28px;
}
.cat-star {
  position: absolute; top: 8px; right: 8px; width: 40px; height: 40px;
  border: none; background: rgba(255,255,255,.65); padding: 8px; cursor: pointer;
  color: var(--color-ink); line-height: 0; border-radius: 50%;
  box-shadow: var(--shadow-sm); z-index: 2;
}
.cat-star:active { transform: scale(0.92); }
.cat-star.on { color: var(--color-amber); background: #fff; }
.profile-focus-section { margin: 16px 0 8px; }
.profile-focus-section .shortcut-row { margin-top: 8px; }
.details-kla { display: block; margin: 0 0 12px; }
.consent-kla { display: block; margin: 0 0 12px; }
.shortcut-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 8px; }
.shortcut-row .cat-tile { flex: 0 0 auto; }

#screen-category .back-header {
  background: linear-gradient(180deg, var(--cat-header-bg, var(--color-green-tint)) 0%, transparent 100%);
  margin: -12px -20px 12px; padding: 12px 20px;
}
#screen-category .back-header h2 { color: var(--cat-header-accent, var(--color-emerald)); }

.filter-bar {
  display: flex; gap: 8px; overflow-x: auto; padding: 8px 0 16px; position: sticky; top: 0;
  background: var(--color-surface); z-index: 2;
}
.filter-bar .chip { flex: 0 0 auto; margin: 0; }

.opp-card {
  display: flex; gap: 12px; align-items: flex-start; padding: 16px; margin-bottom: 10px;
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--r-xl); box-shadow: var(--shadow-sm); cursor: pointer;
}
.opp-thumb {
  width: 72px; height: 72px; border-radius: var(--r-md); background: var(--color-green-tint);
  flex: 0 0 auto; display: flex; align-items: center; justify-content: center;
}
.opp-thumb .icon-badge { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; }
.opp-thumb .icon-badge.fam-career { background: var(--fam-career-accent); }
.opp-thumb .icon-badge.fam-university { background: var(--fam-university-accent); }
.opp-thumb .icon-badge.fam-grow { background: var(--fam-grow-accent); }
.opp-body { flex: 1; min-width: 0; }
.opp-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; }
.tag-pill {
  font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: var(--r-pill);
  background: var(--color-green-tint); color: var(--color-emerald);
}
.tag-pill.amber { background: var(--color-amber-tint); color: var(--color-amber-text); }
.tag-pill.sponsor { background: #f3f4f6; color: #555; }
.opp-title { font-size: 15px; font-weight: 700; margin: 0; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.opp-org { font-size: 12px; color: var(--color-slate); margin: 4px 0 0; }

.empty-state { text-align: center; padding: 40px 16px; }
.empty-state p { color: var(--color-slate); font-size: 14px; line-height: 1.5; }

.profile-card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--r-xl); padding: 20px; margin: 16px 0; box-shadow: var(--shadow-sm);
}
.profile-header { display: flex; gap: 14px; align-items: center; }
.profile-header .avatar {
  width: 56px; height: 56px; border-radius: 50%; background: var(--color-green-50);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.consent-settings {
  padding: 14px 0; border-bottom: 1px solid var(--color-border);
}
.consent-toggle {
  display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.45; cursor: pointer;
}
.consent-toggle input { margin-top: 3px; flex: 0 0 auto; }
.empty-state .kla-img { width: 72px; height: 66px; margin: 0 auto 12px; display: block; }
.list-row {
  display: flex; justify-content: space-between; align-items: center; padding: 14px 0;
  border-bottom: 1px solid var(--color-border); font-size: 15px; cursor: pointer;
}

.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; background: var(--color-surface);
  border-top: 1px solid var(--color-border); display: flex; z-index: 10;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.bottom-nav button {
  flex: 1; border: none; background: none; padding: 10px 4px 12px; font-family: inherit;
  font-size: 11px; color: var(--color-slate); cursor: pointer;
}
.bottom-nav button.on { color: var(--color-emerald); font-weight: 700; }
.bottom-nav .nav-icon { display: block; margin: 0 auto 2px; }

.back-header { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.back-header button {
  border: none; background: none; font-size: 22px; color: var(--color-ink); cursor: pointer;
  min-width: 44px; min-height: 44px; padding: 8px; display: inline-flex; align-items: center; justify-content: center;
}
.icon-btn {
  margin-left: auto; border: none; background: none; font-size: 20px;
  color: var(--color-slate); cursor: pointer;
  min-width: 44px; min-height: 44px; padding: 8px;
}
.icon-btn.on { color: var(--color-amber); }

.opp-card .opp-chevron { flex: 0 0 auto; color: var(--color-slate); font-size: 18px; margin-top: 24px; }
.opp-card .opp-bookmark {
  position: absolute; top: 8px; right: 8px; border: none; background: transparent;
  font-size: 18px; color: var(--color-slate); cursor: pointer; padding: 8px; line-height: 1;
}
.opp-card .opp-bookmark.on { color: var(--color-amber); }
.opp-card { position: relative; }
.screen-detail { padding-bottom: 88px; }
.screen-detail.active { display: block; }

.opp-hero {
  width: 100%; border-radius: var(--r-xl); overflow: hidden; margin-bottom: 16px;
  min-height: 160px; background: var(--color-green-tint); display: flex; align-items: center; justify-content: center;
}
.opp-hero img { width: 100%; height: auto; display: block; object-fit: cover; }
.opp-detail-title { font-size: 20px; font-weight: 700; margin: 8px 0 4px; line-height: 1.35; }
.opp-detail-org { color: var(--color-slate); font-size: 14px; margin: 0 0 16px; }
.opp-detail-body h3 { font-size: 15px; margin: 0 0 8px; }
.opp-detail-body p { font-size: 14px; line-height: 1.55; color: var(--color-text-700); margin: 0; white-space: pre-wrap; }
.opp-deadline-line { font-size: 13px; color: var(--color-slate); margin: 16px 0; }
.opp-next-hint {
  font-size: 12px; color: var(--color-slate); line-height: 1.45;
  margin: 0 0 8px; padding: 10px 12px; border-radius: 12px;
  background: var(--color-green-50);
}
.apply-result-sheet { text-align: center; }
.apply-result-sheet img { margin: 0 auto 8px; display: block; }
.apply-result-sheet .primary { margin-top: 8px; width: 100%; }
.apply-result-sheet .text-btn { margin-top: 4px; }

.action-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 12;
  display: flex; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0));
  background: var(--color-surface); border-top: 1px solid var(--color-border);
}
.action-bar .flex-grow { flex: 1; }
.action-bar .icon-only {
  flex: 0 0 auto; width: 48px; height: 48px; border-radius: var(--r-pill);
  border: 1px solid var(--color-border); background: var(--color-surface); font-size: 20px; cursor: pointer;
}
.action-bar .icon-only.on { color: var(--color-amber); border-color: var(--color-amber); }
.action-bar .primary:disabled { opacity: 0.5; cursor: not-allowed; }
.action-bar .primary { margin-top: 0; width: auto; }
.action-bar .secondary { margin-top: 0; }
.secondary { font-family: inherit; }
.detail-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.detail-chip {
  display: inline-flex; align-items: center; padding: 6px 10px; border-radius: 999px;
  background: var(--color-green-tint); color: var(--color-text-700); font-size: 12px; font-weight: 600;
}
.tag {
  display: inline-block; background: var(--color-green-tint); color: var(--color-emerald);
  font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: var(--r-pill);
}
button.list-row {
  width: 100%; background: none; border: none; font: inherit; text-align: left; color: inherit;
}

.training-banner {
  background: var(--color-forest); color: #fff; border-radius: var(--r-xl); padding: 18px 20px;
  margin-bottom: 20px; display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.training-banner .tag {
  display: inline-block; background: var(--color-amber); color: var(--color-ink);
  font-size: 11px; font-weight: 700; padding: 4px 12px; border-radius: var(--r-pill); margin-bottom: 8px;
}
.training-banner h2 { margin: 0 0 4px; font-size: 16px; font-weight: 700; line-height: 1.35; }
.training-banner p { margin: 0; font-size: 12px; color: rgba(255,255,255,.75); }

.session-row {
  display: flex; gap: 12px; align-items: center; padding: 14px 0;
  border-bottom: 1px solid var(--color-border);
}
.session-row .session-icon {
  width: 44px; height: 44px; border-radius: 50%; background: var(--color-green-tint);
  display: flex; align-items: center; justify-content: center; flex: 0 0 auto; color: var(--color-emerald);
}
.session-row .session-body { flex: 1; min-width: 0; }
.session-row .session-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.session-row .session-meta { font-size: 12px; color: var(--color-slate); margin: 0; }
.session-row button {
  flex: 0 0 auto; border: none; background: var(--color-emerald); color: #fff;
  font-weight: 700; font-size: 13px; padding: 8px 14px; border-radius: var(--r-pill); cursor: pointer; font-family: inherit;
}
.session-row button:disabled { background: var(--color-border); color: var(--color-slate); cursor: default; }

.cert-row {
  display: flex; gap: 12px; align-items: center; margin-top: 20px; padding: 16px;
  background: var(--color-amber-tint); border-radius: var(--r-xl);
}
.cert-row .cert-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }

.readiness-bar {
  height: 8px; background: var(--color-green-tint); border-radius: var(--r-pill);
  margin: 12px 0 6px; overflow: hidden;
}
.readiness-bar .fill {
  height: 100%; width: 0%; background: var(--color-emerald); border-radius: var(--r-pill);
  transition: width 0.4s ease;
}
.checklist { list-style: none; margin: 12px 0 0; padding: 0; }
.checklist li {
  display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 6px 0;
  color: var(--color-slate);
}
.checklist li.done { color: var(--color-ink); }
.checklist li .tick { color: var(--color-emerald); font-weight: 700; }

.app-row {
  display: flex; gap: 12px; align-items: center; padding: 14px 0;
  border-bottom: 1px solid var(--color-border); cursor: pointer;
}
.app-row .app-body { flex: 1; min-width: 0; }
.app-row .app-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.app-row .app-meta { font-size: 12px; color: var(--color-slate); margin: 0; }
.status-pill {
  font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: var(--r-pill);
  background: var(--color-green-tint); color: var(--color-ink); flex: 0 0 auto;
}
.status-pill.applied { background: var(--color-emerald); color: #fff; }
.status-pill.saved { background: var(--color-amber-tint); }
.status-pill.withdrawn { background: var(--color-border); }
.status-pill.screened { background: var(--color-amber-tint); }
.status-pill.matched { background: var(--color-green-tint); }
.status-pill.active { background: var(--color-green-50); }
.status-pill.complete { background: var(--color-forest); color: #fff; }
.apply-profile-strip {
  background: var(--color-green-tint); border: 1px solid var(--color-border);
  border-radius: var(--r-md); padding: 12px 14px; margin-bottom: 14px; font-size: 13px;
}
.apply-field-block { margin-bottom: 14px; }
.apply-field-block textarea { min-height: 120px; resize: vertical; }
.word-counter.warn { color: var(--color-error); font-weight: 700; }
.apply-form-sheet { max-height: 92vh; }

.achievement-card {
  display: flex; gap: 12px; padding: 14px; margin-bottom: 10px;
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--r-xl); box-shadow: var(--shadow-sm);
}
.achievement-card .ach-icon {
  width: 40px; height: 40px; border-radius: 50%; background: var(--color-amber-tint);
  display: flex; align-items: center; justify-content: center; flex: 0 0 auto; font-size: 18px;
}
.achievement-card .ach-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.achievement-card .ach-sub { font-size: 12px; color: var(--color-slate); margin: 0; }
.achievement-card .ach-date { font-size: 11px; color: var(--color-slate); margin: 4px 0 0; }

.sheet-tall { max-height: 92vh; overflow-y: auto; }

.list-row:active { opacity: 0.7; }

.overlay {
  position: fixed; inset: 0; z-index: 20; background: rgba(0,0,0,.45);
  display: flex; align-items: flex-end; justify-content: center;
}
.overlay.hidden { display: none; }
.overlay .sheet {
  width: 100%; max-width: 480px; max-height: 90vh; overflow-y: auto;
  background: var(--color-surface); border-radius: var(--r-xl) var(--r-xl) 0 0;
  padding: 24px 20px calc(24px + env(safe-area-inset-bottom, 0));
}
.text-btn {
  display: block; width: 100%; margin-top: 8px; border: none; background: none;
  color: var(--color-slate); font-size: 14px; cursor: pointer; font-family: inherit;
}

.org-card .org-bookmark {
  position: absolute; top: 4px; right: 4px; border: none; background: transparent;
  font-size: 16px; color: var(--color-slate); cursor: pointer; padding: 4px; line-height: 1;
}
.org-card .org-bookmark.on { color: var(--color-amber); }
.org-card .org-badge {
  display: inline-block; font-size: 10px; font-weight: 700; padding: 2px 8px;
  border-radius: var(--r-pill); margin: 0 auto 6px;
}
.org-card .org-badge.affiliation { background: var(--color-green-tint); color: var(--color-emerald); }
.org-card .org-badge.affiliation.core-team,
.chip.core-team { background: #1a3d2e; color: #fff; }
.org-card .org-badge.follow { background: #fff8e6; color: #856404; }
.org-card .org-badge.suggested { background: var(--color-green-tint); color: var(--color-slate); }
.browse-org-groups .family-section { margin-top: 12px; }
.browse-org-groups .family-section:first-child { margin-top: 0; }
.chip-link { cursor: pointer; border: 1px solid var(--color-border); background: var(--color-green-tint); }
.org-card .org-logo { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; margin: 0 auto 8px; display: block; background: var(--color-green-tint); }
.org-card .org-name { font-size: 13px; font-weight: 700; line-height: 1.3; }
.org-card .org-meta { font-size: 11px; color: var(--color-slate); margin-top: 4px; }
.org-profile-hero {
  background: var(--color-green-tint); border-radius: var(--r-xl); padding: 20px; text-align: center; margin-bottom: 16px;
}
.org-profile-hero img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; background: #fff; }
.org-profile-hero h1 { font-size: 20px; margin: 12px 0 4px; }
.org-profile-hero .tagline { font-size: 13px; color: var(--color-slate); margin: 0; }
.org-verified { display: inline-block; font-size: 11px; background: var(--color-emerald); color: #fff; padding: 2px 8px; border-radius: var(--r-pill); margin-top: 8px; }
.org-about { font-size: 14px; line-height: 1.55; color: var(--color-ink); margin-bottom: 16px; white-space: pre-wrap; }
.org-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.org-chips .chip { font-size: 12px; padding: 4px 10px; border-radius: var(--r-pill); background: var(--color-green-tint); }
.org-actions { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.org-actions .secondary { background: #fff; color: var(--color-ink); border: 1px solid var(--color-border); }
.org-actions button { width: 100%; }
.opp-org-link { color: var(--color-emerald); font-weight: 600; cursor: pointer; text-decoration: underline; }

/* ---- Continue card (Duolingo-style next action) ---- */
.continue-card {
  background: linear-gradient(135deg, #E9F6EF 0%, #FDEFD6 100%);
  border: 1px solid var(--color-border);
  border-radius: var(--r-xl);
  padding: 16px 18px;
  margin-bottom: 14px;
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center;
  box-shadow: var(--shadow-sm);
}
.continue-card .continue-body { flex: 1 1 160px; min-width: 0; }
.continue-card .continue-eyebrow {
  font-size: 11px; font-weight: 700; color: var(--color-emerald);
  text-transform: uppercase; letter-spacing: 0.04em; margin: 0 0 4px;
}
.continue-card h3 { margin: 0 0 4px; font-size: 16px; font-weight: 700; line-height: 1.3; }
.continue-card p { margin: 0; font-size: 13px; color: var(--color-slate); line-height: 1.4; }
.continue-card .continue-cta {
  flex: 1 1 auto; margin: 0; padding: 10px 16px; font-size: 13px; font-weight: 700;
  background: var(--color-emerald); color: #fff; border: none; border-radius: var(--r-pill);
  cursor: pointer; font-family: inherit; white-space: nowrap; text-align: center;
}
.continue-card.complete {
  background: var(--color-green-tint);
}
.home-browse-cta {
  width: 100%; margin-top: 8px; padding: 12px; border-radius: var(--r-pill);
  border: 1px solid var(--color-border); background: #fff; font-weight: 700;
  color: var(--color-ink); cursor: pointer; font-family: inherit; font-size: 14px;
}
.profile-resume-card {
  margin-top: 16px; padding: 16px; border: 1px solid var(--color-border);
  border-radius: var(--r-xl); background: #fff;
}
.side-nav { display: none; }

.settings-panel {
  position: fixed; inset: 0; z-index: 50;
  background: var(--color-surface);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.settings-panel.open { transform: translateX(0); }
.settings-inner {
  max-width: 480px; margin: 0 auto;
  padding: 20px 20px calc(40px + env(safe-area-inset-bottom, 0));
}
.settings-form { margin-top: 8px; }
.settings-readonly {
  background: var(--color-green-tint) !important;
  color: var(--color-slate) !important;
  cursor: default;
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ---- Desktop / laptop shell (≥900px) ---- */
@media (min-width: 900px) {
  :root {
    --container-max: 1280px;
    --side-nav-w: 220px;
  }
  body {
    background:
      radial-gradient(ellipse 50% 40% at 0% 0%, #c8ebd9 0%, transparent 50%),
      var(--color-green-50);
  }
  .wrap {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 28px 40px 56px calc(var(--side-nav-w) + 52px);
    box-sizing: border-box;
  }
  #g-onboarding.wrap {
    padding-left: 40px;
    max-width: 560px;
  }
  .bottom-nav { display: none !important; }
  .side-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: fixed;
    left: max(20px, calc((100vw - min(100vw, var(--container-max))) / 2 + 20px));
    top: 20px;
    bottom: 20px;
    width: var(--side-nav-w);
    padding: 22px 14px;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--r-xl);
    box-shadow: var(--shadow-sm);
    z-index: 30;
  }
  .side-nav.hidden { display: none !important; }
  .side-nav-brand {
    font-size: 13px; font-weight: 700; color: var(--color-forest);
    letter-spacing: 0.06em; padding: 4px 12px 18px;
  }
  .side-nav button {
    display: flex; align-items: center; gap: 10px;
    border: none; background: transparent; text-align: left;
    padding: 12px 14px; border-radius: var(--r-lg);
    font-family: inherit; font-size: 14px; font-weight: 600;
    color: var(--color-slate); cursor: pointer;
  }
  .side-nav button .nav-icon { margin: 0; flex: 0 0 auto; }
  .side-nav button.on {
    background: var(--color-green-tint); color: var(--color-emerald);
  }

  /* Home: comfortable 2-col, no crushed panes */
  .home-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 32px;
    align-items: start;
  }
  .home-primary,
  .home-secondary,
  .profile-main,
  .profile-aside {
    min-width: 0;
  }
  .home-primary .featured-card { min-height: 120px; }
  .home-browse-hint { display: none; }
  .home-focus-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  #screen-home .shortcut-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    overflow: visible;
  }
  #screen-home .shortcut-row .cat-tile {
    flex: unset;
    width: 100%;
    min-width: 0;
  }

  /* Profile: stack sections full-width — resume never gets crushed */
  .profile-layout {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 16px;
  }
  .profile-main {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px;
    align-items: start;
  }
  .profile-resume-card {
    margin-top: 0;
    min-height: 160px;
  }
  .profile-aside {
    display: block;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--r-xl);
    padding: 18px 20px;
  }
  #screen-profile .checklist {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 28px;
  }
  #screen-profile .shortcut-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    overflow: visible;
    gap: 10px;
  }
  #screen-profile .shortcut-row .cat-tile {
    flex: unset;
    width: 100%;
    min-width: 0;
  }
  .cat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .org-grid-visual {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .action-bar {
    left: max(20px, calc((100vw - min(100vw, var(--container-max))) / 2 + var(--side-nav-w) + 40px));
    right: max(20px, calc((100vw - min(100vw, var(--container-max))) / 2 + 20px));
    max-width: none;
    margin: 0;
    border-radius: var(--r-xl) var(--r-xl) 0 0;
  }
  .screen-detail { padding-bottom: 100px; }
}

@media (min-width: 1100px) {
  :root {
    --container-max: 1320px;
  }
  .home-layout {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.95fr);
  }
}
