/* Hedge and Harvest Capital — homepage styles
   The homepage has its own stylesheet; member pages and join.html use styles.css. */

:root {
  --gold: #c9973a;
  --gold-light: #f0c66e;
  --gold-pale: #f1d9a3;
  --ink-bg: #120c04;
  --text: #ece6d8;
  --text-soft: #e6dfcf;
  --text-muted: #cbbf9f;
  --line: rgba(255, 255, 255, .14);
  --line-gold: rgba(227, 185, 100, .45);
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Libre Franklin", system-ui, -apple-system, "Segoe UI", sans-serif;
  --side: 260px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--ink-bg);
}

/* Full-page photo: the desk, monitors and gold sit at the bottom right. The
   left side is darkened so the content over it stays easy to read. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(18, 12, 4, .9) 0%, rgba(18, 12, 4, .84) 50%, rgba(18, 12, 4, .45) 66%, rgba(18, 12, 4, 0) 82%),
    /* fades the top edge of the photo into the page background; sized to match the photo (801/1964) */
    linear-gradient(180deg, var(--ink-bg) 0%, rgba(18, 12, 4, .6) 18%, rgba(18, 12, 4, 0) 45%) right bottom / max(100%, 1500px) calc(max(100vw, 1500px) * .4079) no-repeat,
    url("../assets/bg-desk.jpg") right bottom / max(100%, 1500px) auto no-repeat,
    var(--ink-bg);
}

h1, h2, h3 { font-family: var(--serif); color: #fff; font-weight: 600; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(36px, 4.4vw, 52px); }
h2 { font-size: clamp(28px, 3vw, 36px); }
h3 { font-size: 22px; }
p { margin: 0 0 1em; }
a { color: #e3c98e; }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 16px; top: 16px; background: #fff; color: #000; padding: 8px 12px; z-index: 10; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Sidebar with vertical tabs ---------- */
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--side);
  display: flex;
  flex-direction: column;
  padding: 28px 20px;
  border-right: 1px solid rgba(201, 151, 58, .25);
  overflow-y: auto;
  text-shadow: 0 1px 10px rgba(0, 0, 0, .6);
}
.sidebar__logo img {
  display: block;
  width: 168px;
  height: auto;
  margin: 0 auto 28px;
  padding: 10px 12px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .35);
}

.tabs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.tabs a {
  display: block;
  padding: 10px 14px;
  border-left: 3px solid transparent;
  border-radius: 0 4px 4px 0;
  color: #efe9db;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: background .25s ease, color .25s ease, padding-left .25s ease;
}
.tabs a:hover { background: rgba(255, 255, 255, .08); color: #fff; padding-left: 18px; }
.tabs a[aria-current="page"] { border-left-color: var(--gold); background: rgba(201, 151, 58, .14); color: var(--gold-pale); font-weight: 600; }
.tabs .ext::after { content: " ↗"; font-size: 12px; color: #9fb3a5; }

/* Shown only on small screens, where the top-right bar is hidden */
.sidebar__actions { display: none; margin-top: auto; padding-top: 24px; flex-direction: column; gap: 10px; }
.sidebar__actions .btn { text-shadow: none; }
.login { text-align: center; font-size: 14px; font-weight: 500; color: #e9e2cf; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 11px 20px;
  border: 1px solid var(--gold);
  border-radius: 4px;
  background: var(--gold);
  color: #0b2a1d;
  font: 600 14px/1.2 var(--sans);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background .25s ease, box-shadow .25s ease, transform .25s ease;
}
.btn:hover { background: #dcae58; box-shadow: 0 0 0 3px rgba(201, 151, 58, .25), 0 10px 24px rgba(201, 151, 58, .3); transform: translateY(-1px); }
.btn--line { background: rgba(255, 255, 255, .04); border-color: rgba(227, 201, 142, .7); color: var(--gold-pale); }
.btn--line:hover { background: rgba(201, 151, 58, .15); }
.btn:disabled { opacity: .6; cursor: default; }

/* ---------- Member login and Subscribe, top right on every tab ---------- */
.topbar {
  position: fixed;
  top: 14px;
  right: 24px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px;
  border-radius: 10px;
  background: rgba(18, 12, 4, .55);
  border: 1px solid rgba(227, 185, 100, .3);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.topbar .btn { padding: 9px 18px; }
.topbar__login { display: inline-flex; align-items: center; gap: 8px; }
.topbar__login svg { width: 16px; height: 16px; }

/* ---------- Content and tab panels ---------- */
.content { margin-left: var(--side); min-height: 100vh; display: flex; flex-direction: column; }
.panel {
  max-width: 1000px;
  padding: 84px clamp(20px, 6vw, 80px) 64px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .85), 0 0 18px rgba(0, 0, 0, .6);
}
.panel .btn { text-shadow: none; }
/* main.js adds .js; without it every panel shows, one after another */
.js .panel { display: none; }
.js .panel.is-active { display: block; }

.eyebrow { display: block; margin-bottom: 10px; color: var(--gold-light); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.lead { font-size: 19px; max-width: 640px; color: #f6f1e6; }
.note { font-size: 14px; color: var(--text-muted); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 0; }
.divider { border: 0; border-top: 1px solid var(--line); margin: 56px 0; }

/* Section header banner */
.banner {
  position: relative;
  margin: 0 0 40px;
  padding: 28px 32px 26px;
  border: 1px solid rgba(227, 185, 100, .35);
  border-left: 4px solid var(--gold);
  border-radius: 10px;
  background: linear-gradient(100deg, rgba(201, 151, 58, .26) 0%, rgba(201, 151, 58, .1) 55%, rgba(201, 151, 58, .03) 100%);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 230, 170, .15);
  overflow: hidden;
}
.banner::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 228, 160, .14) 45%, transparent 60%);
  transform: translateX(-100%);
  animation: sweep 1.6s ease .3s 1 both;
}
.banner h1, .banner h2 { margin-bottom: .2em; }
.banner .eyebrow { margin-bottom: 8px; }
.banner .lead { margin: 10px 0 0; }

/* Headline accent with a slow gold shimmer */
h1 em {
  font-style: normal;
  background: linear-gradient(100deg, #c9973a 0%, #f5dc9a 25%, #c9973a 50%, #f5dc9a 75%, #c9973a 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: none;
  animation: shimmer 6s linear infinite;
}

/* Highlights and feature lists */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 24px; margin: 48px 0 0; padding-top: 28px; border-top: 1px solid var(--line); }
.facts strong { display: block; font-family: var(--serif); font-size: 22px; color: var(--gold-pale); }
.facts span { font-size: 15px; color: var(--text-soft); }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 28px 40px; margin-top: 40px; }
.grid > div { transition: transform .3s ease; }
.grid > div:hover { transform: translateX(4px); }
.grid h3 { font-size: 20px; margin-bottom: .3em; }
.grid p { margin: 0; }

/* Gold underline that draws in under highlight titles on hover */
.facts strong, .grid h3 { position: relative; width: fit-content; }
.facts strong::after, .grid h3::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  height: 2px;
  width: 0;
  background: linear-gradient(90deg, #c9973a, #f5dc9a);
  transition: width .4s ease;
}
.facts div:hover strong::after, .grid > div:hover h3::after { width: 100%; }

ul.plain { margin: 0; padding-left: 18px; }
ul.plain li { margin-bottom: 4px; }

.grid p, .plan__desc, ul.plain, .steps p, .faq details p, .box p { color: var(--text-soft); font-size: 15.5px; }

/* Numbered steps */
.steps { margin: 32px 0 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; position: relative; padding: 0 0 18px 48px; }
.steps li::before {
  content: counter(s);
  position: absolute;
  left: 0;
  top: 2px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(201, 151, 58, .2);
  color: var(--gold-pale);
  font-size: 14px;
  font-weight: 600;
  display: grid;
  place-items: center;
  animation: ring 2.4s ease-out 1s 1;
}
.steps h3 { font-size: 19px; margin: 0 0 .1em; }
.steps p { margin: 0; }

/* Sample research boxes and membership plans: outlined, see-through */
.box, .plan {
  border: 1px solid var(--line-gold);
  border-radius: 6px;
  background: transparent;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease, background .3s ease;
}
.box:hover, .plan:hover {
  transform: translateY(-4px);
  border-color: rgba(227, 185, 100, .8);
  background: rgba(201, 151, 58, .07);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .35), 0 0 0 1px rgba(227, 185, 100, .25);
}
.box { padding: 24px; }
.box__meta { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-light); margin-bottom: 6px; }
.box h3 { font-size: 20px; }
.soon { display: inline-block; margin-top: 12px; font-size: 14px; color: var(--text-muted); }

.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-top: 40px; }
.plan { display: flex; flex-direction: column; padding: 24px 20px; }
.plan--featured { border-color: var(--gold); box-shadow: inset 0 3px 0 var(--gold); }
.plan__badge { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-light); }
.plan h3 { margin: 6px 0 4px; }
.plan__price { font-family: var(--serif); font-size: 21px; line-height: 1.2; color: var(--gold-pale); margin-bottom: 14px; }
.plan ul { margin-bottom: 20px; flex: 1; }

/* FAQ */
.faq details { border-bottom: 1px solid var(--line); padding: 16px 0; }
.faq summary { cursor: pointer; font-weight: 600; color: #fff; }
.faq details p { margin: 10px 0 0; }

/* Signup form */
.signup { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; max-width: 520px; }
.signup input[type="email"] {
  flex: 1 1 240px;
  padding: 11px 14px;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 4px;
  background: rgba(255, 255, 255, .08);
  color: #fff;
  font: 15px var(--sans);
}
.signup input::placeholder { color: #9fb0a4; }
.signup input:focus { outline: 2px solid var(--gold); outline-offset: 1px; }
.signup__status { min-height: 1.5em; margin-top: 12px; font-size: 14px; color: var(--gold-pale); }

/* Footer */
.footer {
  margin-top: auto;
  padding: 28px clamp(20px, 6vw, 80px);
  border-top: 1px solid rgba(201, 151, 58, .25);
  background: rgba(14, 10, 4, .6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: 12.5px;
  color: #c9bfa6;
}
.footer__links { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-bottom: 12px; }
.footer__links a { color: var(--text-soft); }
.footer p { max-width: 900px; margin: 0 0 8px; }

/* ---------- Content effects ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes sweep { to { transform: translateX(100%); } }
@keyframes shimmer { to { background-position: 200% center; } }
@keyframes ring { 0% { box-shadow: 0 0 0 0 rgba(201, 151, 58, .55); } 100% { box-shadow: 0 0 0 12px rgba(201, 151, 58, 0); } }

/* Each section of the open tab rises in, one after another */
.panel.is-active > * { animation: rise .7s var(--ease) both; }
.panel.is-active > :nth-child(2) { animation-delay: .08s; }
.panel.is-active > :nth-child(3) { animation-delay: .16s; }
.panel.is-active > :nth-child(4) { animation-delay: .24s; }
.panel.is-active > :nth-child(5) { animation-delay: .32s; }
.panel.is-active > :nth-child(n+6) { animation-delay: .4s; }
.grid > *, .plans > *, .facts > *, .steps > li { animation: rise .6s var(--ease) both; }
.grid > :nth-child(2), .plans > :nth-child(2), .facts > :nth-child(2), .steps > li:nth-child(2) { animation-delay: .45s; }
.grid > :nth-child(3), .plans > :nth-child(3), .facts > :nth-child(3), .steps > li:nth-child(3) { animation-delay: .55s; }
.grid > :nth-child(4), .plans > :nth-child(4), .facts > :nth-child(4), .steps > li:nth-child(4) { animation-delay: .65s; }
.grid > :nth-child(n+5), .steps > li:nth-child(n+5) { animation-delay: .75s; }

@media (prefers-reduced-motion: reduce) {
  .panel.is-active > *, .grid > *, .plans > *, .facts > *, .steps > li, .steps li::before, h1 em, .banner::after { animation: none !important; }
  .banner::after { display: none; }
  .box:hover, .plan:hover, .grid > div:hover, .btn:hover { transform: none; }
}

/* ---------- Wide screens: keep the right side clear for the monitors and gold ---------- */
@media (min-width: 1281px) {
  .content { padding-right: 460px; }
  .panel { padding-left: 56px; padding-right: 32px; }
  .plans, .facts { grid-template-columns: repeat(2, 1fr); }
  .footer { padding-left: 56px; }
}

/* ---------- Small screens: sidebar becomes a top bar ---------- */
@media (max-width: 860px) {
  body::before {
    background:
      linear-gradient(180deg, rgba(18, 12, 4, .82), rgba(18, 12, 4, .7)),
      url("../assets/bg-desk.jpg") 80% bottom / cover no-repeat;
  }
  .sidebar { position: static; width: auto; padding: 16px; border-right: 0; border-bottom: 2px solid var(--gold); }
  .sidebar__logo img { width: 120px; margin: 0 0 12px; }
  .tabs { flex-direction: row; overflow-x: auto; gap: 4px; }
  .tabs a { white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; border-radius: 4px 4px 0 0; padding: 8px 12px; }
  .tabs a:hover { padding-left: 12px; }
  .tabs a[aria-current="page"] { border-bottom-color: var(--gold); }
  .sidebar__actions { display: flex; flex-direction: row; align-items: center; justify-content: space-between; padding-top: 12px; }
  .topbar { display: none; }
  .content { margin-left: 0; }
  .panel { padding: 40px 16px; }
  .banner { padding: 20px 18px; margin-bottom: 28px; }
  .footer { padding: 24px 16px; }
}
