/* Family Trees v2.7.2 — main page visual layer. */
.home-page { min-height: 100vh; }
.home-main { overflow: hidden; }
.home-shell { width: min(1180px, calc(100% - 36px)); margin: 0 auto; }

.home-hero {
  position: relative;
  isolation: isolate;
  min-height: 570px;
  display: flex;
  align-items: center;
  padding: clamp(54px, 7vw, 92px) 0;
  background:
    radial-gradient(circle at 12% 16%, rgba(255,255,255,.92), transparent 30%),
    radial-gradient(circle at 84% 26%, rgba(181,205,219,.42), transparent 34%),
    linear-gradient(125deg, #f7f4ed 0%, #edf2f2 48%, #dce8eb 100%);
  border-bottom: 1px solid rgba(66, 84, 92, .12);
}
[data-theme="dark"] .home-hero {
  background:
    radial-gradient(circle at 15% 12%, rgba(255,255,255,.08), transparent 28%),
    radial-gradient(circle at 82% 28%, rgba(73,120,143,.24), transparent 34%),
    linear-gradient(125deg, #171c1e 0%, #172126 50%, #142d35 100%);
}
.home-hero-atmosphere { position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.home-glow { position: absolute; display: block; border-radius: 999px; filter: blur(2px); opacity: .58; }
.home-glow-one { width: 380px; height: 380px; right: -120px; top: -130px; background: rgba(255,255,255,.55); }
.home-glow-two { width: 280px; height: 280px; left: -120px; bottom: -170px; background: rgba(190,145,83,.13); }
.home-lineage-line { position: absolute; display: block; width: 1px; height: 330px; background: linear-gradient(transparent, rgba(70,104,116,.22), transparent); transform: rotate(38deg); }
.home-lineage-one { right: 22%; top: -70px; }
.home-lineage-two { right: 17%; top: 120px; height: 430px; opacity: .65; }

.home-hero-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(330px, .8fr); gap: clamp(42px, 7vw, 92px); align-items: center; }
.home-intro { max-width: 690px; }
.home-panel-eyebrow { margin-bottom: 16px; font-size: 12px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: #536d76; }
[data-theme="dark"] .home-panel-eyebrow { color: #9bb9c4; }
.home-intro h1 { margin: 0; max-width: 760px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(48px, 7vw, 84px); line-height: .98; letter-spacing: -.045em; font-weight: 500; color: #1f2c30; }
[data-theme="dark"] .home-intro h1 { color: #f1f4f3; }
.home-lead { max-width: 620px; margin: 28px 0 0; font-size: clamp(17px, 2vw, 20px); line-height: 1.65; color: #53636a; }
[data-theme="dark"] .home-lead { color: #bdc9cd; }
.home-primary-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.home-action { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 0 18px; border-radius: 999px; border: 1px solid rgba(38,61,68,.18); font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.home-action:hover { transform: translateY(-2px); text-decoration: none; box-shadow: 0 10px 22px rgba(31,44,48,.10); }
.home-action-primary { color: #fff; background: #263e45; border-color: #263e45; }
.home-action-primary:hover { color: #fff; background: #1b3036; }
.home-action-secondary { color: #263e45; background: rgba(255,255,255,.52); backdrop-filter: blur(8px); }
[data-theme="dark"] .home-action-secondary { color: #edf3f5; background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.18); }
.home-action-icon { font-size: 17px; }

.home-family-panel { position: relative; padding: clamp(26px, 4vw, 38px); border: 1px solid rgba(255,255,255,.72); border-radius: 26px; background: rgba(255,255,255,.67); box-shadow: 0 24px 70px rgba(43,64,70,.13); backdrop-filter: blur(16px); }
[data-theme="dark"] .home-family-panel { background: rgba(19,28,32,.72); border-color: rgba(255,255,255,.10); box-shadow: 0 24px 70px rgba(0,0,0,.28); }
.home-family-panel h2 { margin: 0 0 20px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(27px, 3vw, 36px); font-weight: 500; color: var(--text); }
.home-current-family { margin: 0 0 24px; padding: 15px 17px; border: 1px solid rgba(74,104,114,.13); border-left: 3px solid #587b86; border-radius: 14px; background: rgba(74,104,114,.055); }
[data-theme="dark"] .home-current-family { border-color: rgba(255,255,255,.09); border-left-color: #86aab5; background: rgba(255,255,255,.035); }
.home-current-family div { min-width: 0; }
.home-current-family > div > strong, .home-current-family > div > span { display: block; }
.home-current-family strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 17px; }
.home-current-family span { margin-top: 3px; color: var(--muted); font-size: 13px; }
.home-panel-copy, .home-empty { color: var(--muted); line-height: 1.55; }
.home-family-form { margin: 0; }
.home-family-form label { display: block; margin-bottom: 9px; font-size: 13px; font-weight: 800; letter-spacing: .02em; }
.home-select-wrap { position: relative; }
.home-family-form select { width: 100%; min-height: 54px; appearance: none; padding: 0 44px 0 15px; border: 1px solid rgba(58,83,91,.22); border-radius: 14px; background: rgba(255,255,255,.78); color: #223237; font: inherit; font-weight: 650; cursor: pointer; }
[data-theme="dark"] .home-family-form select { background: rgba(255,255,255,.07); color: #f0f4f5; border-color: rgba(255,255,255,.16); }
.home-family-form select:focus { outline: none; border-color: #537b89; box-shadow: 0 0 0 4px rgba(83,123,137,.13); }
.home-select-arrow { position: absolute; right: 16px; top: 50%; transform: translateY(-55%); pointer-events: none; font-size: 20px; color: var(--muted); }
.home-family-form p { margin: 10px 2px 0; color: var(--muted); font-size: 13px; line-height: 1.45; }

.home-content { padding: clamp(30px, 5vw, 58px) 0 clamp(44px, 7vw, 76px); background: var(--bg); }
.home-flash { margin: 0 0 24px; }
.home-paths { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.home-path-card { min-width: 0; min-height: 160px; display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: start; padding: 28px 26px; border: 0; border-right: 1px solid var(--border); background: transparent; color: var(--text); text-align: left; font: inherit; cursor: pointer; text-decoration: none; transition: background .18s ease; }
.home-path-card:last-child { border-right: 0; }
.home-path-card:hover { background: rgba(74,104,114,.055); text-decoration: none; }
.home-path-number { padding-top: 3px; color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .12em; }
.home-path-body strong, .home-path-body span { display: block; }
.home-path-body strong { margin-bottom: 9px; font-family: Georgia, "Times New Roman", serif; font-size: 23px; font-weight: 500; }
.home-path-body span { color: var(--muted); font-size: 14px; line-height: 1.55; }
.home-path-arrow { font-size: 22px; line-height: 1; transition: transform .18s ease; }
.home-path-card:hover .home-path-arrow { transform: translateX(4px); }

@media (max-width: 860px) {
  .home-hero { min-height: 0; }
  .home-hero-grid { grid-template-columns: 1fr; gap: 38px; }
  .home-intro { max-width: 760px; }
  .home-family-panel { max-width: 680px; }
  .home-paths { grid-template-columns: 1fr; }
  .home-path-card { min-height: 0; border-right: 0; border-bottom: 1px solid var(--border); }
  .home-path-card:last-child { border-bottom: 0; }
}
@media (max-width: 560px) {
  .home-shell { width: min(100% - 28px, 1180px); }
  .home-hero { padding: 44px 0; }
  .home-intro h1 { font-size: clamp(42px, 14vw, 60px); }
  .home-lead { margin-top: 22px; font-size: 16px; }
  .home-primary-actions { align-items: stretch; }
  .home-action { flex: 1 1 100%; }
  .home-family-panel { padding: 24px 20px; border-radius: 22px; }
  .home-path-card { grid-template-columns: auto 1fr auto; padding: 24px 10px; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-action, .home-path-card, .home-path-arrow { transition: none; }
}
