/* =========================================================================
   PRISM WEALTH — master stylesheet
   Editorial / private-bank aesthetic. Black + cream + gold + restrained red.
   ========================================================================= */

/* ---------- Page enter / exit transitions ----------
   Driven by JS in main.js — works on every browser and every protocol
   (file://, http://, https://). Header & footer stay anchored; only
   <main> and the footer fade as a unit, giving a soft cinematic feel.
   ===================================================== */

@keyframes prism-page-enter {
  0%   {
    opacity: 0;
    transform: translateY(14px);
    filter: blur(4px);
  }
  60%  {
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes prism-page-exit {
  0%   {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-10px);
    filter: blur(4px);
  }
}

/* The site shell stays anchored (the sticky nav is the only "persistent"
   element). Everything else — content sections and the footer — animates
   together as one. Targeting body's direct children rather than a single
   wrapper avoids any markup changes. */
body > section,
body > div,
body > .site-footer {
  animation: prism-page-enter 620ms cubic-bezier(.16, 1, .3, 1) both;
  will-change: opacity, transform, filter;
}

body.is-leaving > section,
body.is-leaving > div,
body.is-leaving > .site-footer {
  animation: prism-page-exit 320ms cubic-bezier(.4, 0, .2, 1) both;
}

/* Lock interaction during the exit so users can't double-click links. */
body.is-leaving {
  pointer-events: none;
  cursor: progress;
}

/* Honor reduced-motion: instant render, no animation. */
@media (prefers-reduced-motion: reduce) {
  body > section,
  body > div,
  body > .site-footer,
  body.is-leaving > section,
  body.is-leaving > div,
  body.is-leaving > .site-footer {
    animation: none !important;
  }
}

:root {
  /* Color tokens — extracted from the brand mark */
  --black:        #000000;
  --bg:           #0a0908;
  --bg-card:      #121110;
  --bg-elev:      #1a1715;
  --hairline:     #2a2620;
  --hairline-2:   #3a342c;

  --gold:         #c4a25c;
  --gold-bright:  #d9bd7e;
  --gold-dim:     #8a7142;

  --red:          #9d1714;
  --red-dim:      #6c0f0c;

  --cream:        #f5e6c8;
  /* Text — brightened for stronger contrast on older eyes */
  --text:         #f4e8cf;
  --text-soft:    #d6cbaf;
  --text-mute:    #a39a87;

  /* Typography */
  --f-display:    'Cormorant Garamond', 'Cormorant', Georgia, serif;
  --f-brand:      'Cinzel', 'Trajan Pro', Georgia, serif;
  --f-gotham:     'Gotham', 'Montserrat', 'Proxima Nova', -apple-system, BlinkMacSystemFont, sans-serif;
  --f-body:       'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --f-mono:       'JetBrains Mono', ui-monospace, Menlo, monospace;

  /* Spacing rhythm */
  --gutter:       clamp(1.25rem, 3vw, 2.5rem);
  --pad-section:  clamp(4rem, 9vw, 8rem);
  --container:    1280px;

  /* Motion */
  --ease:         cubic-bezier(.2, .7, .2, 1);
  --ease-emph:    cubic-bezier(.16, 1, .3, 1);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 18px;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* Subtle vignette to give the black depth */
  background-image:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(196, 162, 92, .04), transparent 60%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(200, 66, 74, .025), transparent 70%);
  background-attachment: fixed;
}

img { max-width: 100%; display: block; }

a {
  color: var(--gold-bright);
  text-decoration: none;
  transition: color .2s var(--ease);
}
a:hover { color: var(--cream); }

::selection { background: var(--gold); color: var(--black); }

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: 400;
  letter-spacing: -.01em;
  line-height: 1.1;
  color: var(--cream);
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.75rem); letter-spacing: -.02em; }
h2 { font-size: clamp(2rem, 4.2vw, 3.25rem); }
h3 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }
h4 { font-size: 1.25rem; font-family: var(--f-body); font-weight: 600; letter-spacing: .02em; text-transform: uppercase; color: var(--gold); }

p { margin: 0 0 1.1em; color: var(--text); }

.eyebrow {
  font-family: var(--f-body);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: .75rem;
}
.eyebrow::before {
  content: '';
  width: 28px; height: 1px;
  background: var(--gold);
}

.lead {
  font-family: var(--f-display);
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  line-height: 1.5;
  color: var(--text-soft);
  font-style: italic;
  font-weight: 300;
}

/* ---------- Layout primitives ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container-narrow {
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

section { padding: var(--pad-section) 0; }

/* Decorative gold hairline rule — echoes the gold flanks of "WEALTH" in the logo */
.rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 1.5rem 0;
}
.rule::before,
.rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dim), transparent);
  max-width: 80px;
}
.rule__diamond {
  width: 6px; height: 6px;
  background: var(--gold);
  transform: rotate(45deg);
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 9, 8, .82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--hairline);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem var(--gutter);
  max-width: var(--container);
  margin: 0 auto;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
}
.nav__brand img { height: 60px; width: auto; }
.nav__brand-text {
  font-family: var(--f-brand);
  font-size: 1.35rem;
  letter-spacing: .22em;
  color: var(--cream);
  font-weight: 500;
  line-height: 1;
}
/* PRISM — Trajan/Cinzel engraved treatment:
   - SemiBold weight for substantial Roman-inscription strokes
   - Cream fill with a hairline gold rim for the metallic outline
   - Soft drop shadow below for engraved depth */
.nav__brand-text .prism {
  color: var(--cream);
  font-weight: 600;
  -webkit-text-stroke: 0.4px var(--gold);
  paint-order: stroke fill;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, .55),
    0 0 14px rgba(196, 162, 92, .12);
}
.nav__brand-text .wealth {
  /* Gotham geometric sans (Montserrat is the free fallback that ships
     identically at this scale). If the viewer has Gotham installed
     locally, the browser uses the real font. */
  font-family: var(--f-gotham);
  color: var(--red);
  -webkit-text-stroke: 1px #ffede9;
  paint-order: stroke fill;
  font-weight: 700;
  letter-spacing: .22em;
  margin-left: .25em;
  text-shadow: none;
  /* Lift slightly so the sans-serif baseline lines up with Cinzel's caps */
  position: relative;
  top: -.05em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2.25rem;
  list-style: none;
  margin: 0; padding: 0;
}
.nav__links a {
  font-family: var(--f-body);
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text);
  position: relative;
  padding: .25rem 0;
}
.nav__links a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--ease-emph);
}
.nav__links a:hover,
.nav__links a.active { color: var(--cream); }
.nav__links a:hover::after,
.nav__links a.active::after { transform: scaleX(1); }

.nav__toggle {
  display: none;
  background: none;
  border: 1px solid var(--hairline-2);
  color: var(--cream);
  padding: .5rem .75rem;
  font-family: var(--f-body);
  font-size: .75rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  cursor: pointer;
}

@media (max-width: 820px) {
  .nav__links { display: none; }
  .nav__toggle { display: inline-block; }
  .nav__links.open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--hairline);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: .5rem var(--gutter) 1.5rem;
  }
  .nav__links.open li { width: 100%; }
  .nav__links.open a {
    display: block;
    padding: 1rem 0;
    border-bottom: 1px solid var(--hairline);
  }
}

/* ---------- Hero (home) ---------- */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  padding: 6rem 0 4rem;
  overflow: hidden;
}

.hero__beam {
  position: absolute;
  top: 50%;
  left: -10%;
  width: 130%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(196, 162, 92, .15) 30%,
    rgba(200, 66, 74, .6) 50%,
    rgba(196, 162, 92, .15) 70%,
    transparent 100%
  );
  transform: rotate(-2deg);
  filter: blur(.4px);
  pointer-events: none;
}
.hero__beam::after {
  content: '';
  position: absolute;
  inset: -8px 0;
  background: inherit;
  filter: blur(8px);
  opacity: .6;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero__copy h1 {
  font-style: italic;
  font-weight: 300;
}
.hero__copy h1 .accent {
  font-style: normal;
  color: var(--gold);
  font-weight: 500;
}

.hero__copy .lead { margin-top: 1.5rem; max-width: 32em; }

.hero__cta {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero__mark {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}
.hero__mark img {
  max-width: 480px;
  width: 100%;
  filter: drop-shadow(0 30px 80px rgba(200, 66, 74, .12));
  animation: hero-mark-in 1.4s var(--ease-emph) both;
}

@keyframes hero-mark-in {
  from { opacity: 0; transform: translateY(20px) scale(.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 820px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__mark { order: -1; }
  .hero__mark img { max-width: 280px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  padding: .95rem 1.75rem;
  font-family: var(--f-body);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  border: 1px solid var(--gold);
  background: transparent;
  color: var(--cream);
  cursor: pointer;
  transition: all .3s var(--ease-emph);
  text-decoration: none;
  line-height: 1;
}
.btn:hover {
  background: var(--gold);
  color: var(--black);
}
.btn--primary {
  background: var(--gold);
  color: var(--black);
}
.btn--primary:hover {
  background: var(--gold-bright);
  color: var(--black);
}
.btn--ghost {
  border-color: var(--hairline-2);
  color: var(--text-soft);
}
.btn--ghost:hover {
  border-color: var(--gold);
  background: transparent;
  color: var(--cream);
}
.btn .arrow {
  display: inline-block;
  transition: transform .3s var(--ease-emph);
}
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Pillars / values grid ---------- */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  margin-top: 3rem;
}
.pillar {
  background: var(--bg);
  padding: 2.5rem 2rem;
  transition: background .4s var(--ease);
}
.pillar:hover { background: var(--bg-card); }
.pillar__num {
  font-family: var(--f-mono);
  font-size: .72rem;
  color: var(--gold);
  letter-spacing: .15em;
  margin-bottom: 1.25rem;
}
.pillar h3 { font-style: italic; }
.pillar p { color: var(--text); font-size: 1rem; margin: 0; line-height: 1.6; }

@media (max-width: 820px) {
  .pillars { grid-template-columns: 1fr; }
}

/* ---------- Page header (subpages) ---------- */
.page-head {
  padding: 8rem 0 4rem;
  border-bottom: 1px solid var(--hairline);
  position: relative;
}
.page-head__inner { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.page-head h1 { margin-bottom: 1rem; font-style: italic; font-weight: 300; }
.page-head .lead { max-width: 38em; }

/* ---------- Market Recap — feed ---------- */
.feed {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.feed-item {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 2.5rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--hairline);
  align-items: start;
}
.feed-item:first-child { padding-top: 0; }
.feed-item:last-child { border-bottom: 0; }

.feed-item__meta {
  position: sticky;
  top: 6rem;
}
.feed-item__date {
  font-family: var(--f-mono);
  font-size: .78rem;
  color: var(--gold);
  letter-spacing: .1em;
  text-transform: uppercase;
}
.feed-item__cat {
  display: inline-block;
  margin-top: .75rem;
  padding: .25rem .65rem;
  font-size: .68rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--red);
  border: 1px solid var(--red-dim);
  border-radius: 2px;
}

.feed-item__body h2 {
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  margin-bottom: .8rem;
  transition: color .2s var(--ease);
}
.feed-item__body a:hover h2 { color: var(--gold-bright); }
.feed-item__body p { color: var(--text); margin-bottom: 1rem; }

.feed-item__media {
  margin-bottom: 1.25rem;
  border: 1px solid var(--hairline);
  background: var(--bg-card);
  overflow: hidden;
}
.feed-item__media img,
.feed-item__media video,
.feed-item__media iframe {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.feed-item__readmore {
  font-size: .8rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}

@media (max-width: 720px) {
  .feed-item { grid-template-columns: 1fr; gap: 1rem; }
  .feed-item__meta { position: static; }
}

/* Feed empty state */
.feed-empty {
  text-align: center;
  padding: 5rem 1rem;
  border: 1px dashed var(--hairline-2);
}
.feed-empty p { color: var(--text-mute); }

/* ---------- Single post view ---------- */
.post {
  max-width: 760px;
  margin: 0 auto;
  padding: 4rem var(--gutter) 6rem;
}
.post__back {
  font-size: .78rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 2rem;
  display: inline-block;
}
.post__back:hover { color: var(--gold); }
.post__date {
  font-family: var(--f-mono);
  font-size: .8rem;
  color: var(--gold);
  letter-spacing: .1em;
}
.post h1 { margin-top: 1rem; font-style: italic; font-weight: 300; }
.post__media {
  margin: 2rem 0 2.5rem;
  border: 1px solid var(--hairline);
}
.post__media img,
.post__media video,
.post__media iframe {
  width: 100%;
  display: block;
}
.post__content {
  font-size: 1.05rem;
  line-height: 1.75;
}
.post__content p { color: var(--text); margin-bottom: 1.3em; }
.post__content h2,
.post__content h3 { margin-top: 2rem; }
.post__content blockquote {
  border-left: 2px solid var(--gold);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-family: var(--f-display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--cream);
}
.post__content ul,
.post__content ol { padding-left: 1.5rem; color: var(--text); margin-bottom: 1.3em; }
.post__content img { margin: 1.5rem 0; border: 1px solid var(--hairline); }

/* ---------- Regulatory list ---------- */
.filings {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin-top: 2.5rem;
  border-top: 1px solid var(--hairline);
}
.filing {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 2rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--hairline);
  transition: padding .25s var(--ease);
}
.filing:hover { padding-left: 1rem; }
.filing__title {
  font-family: var(--f-display);
  font-size: 1.4rem;
  color: var(--cream);
  margin: 0 0 .35rem;
}
.filing__desc { color: var(--text); font-size: 1rem; margin: 0; }
.filing__link {
  font-size: .78rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
}

/* ---------- Long-form (disclaimers) ---------- */
.longform {
  font-size: 1.1rem;
  line-height: 1.8;
}
.longform h2 {
  font-size: 1.7rem;
  margin: 3rem 0 1rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--hairline);
}
.longform h3 { font-size: 1.2rem; margin: 2rem 0 .75rem; color: var(--gold); font-family: var(--f-body); text-transform: uppercase; letter-spacing: .12em; font-weight: 600; }
.longform p { color: var(--text); }
.longform ul { color: var(--text); padding-left: 1.5rem; }
.longform li { margin-bottom: .5rem; }

/* ---------- Contact form ---------- */
.contact {
  background: var(--bg-card);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.contact__info h2 { font-style: italic; font-weight: 300; }
.contact__info dl {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem 1.5rem;
  align-items: baseline;
}
.contact__info dt {
  font-family: var(--f-body);
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold);
}
.contact__info dd {
  margin: 0;
  font-family: var(--f-display);
  font-size: 1.1rem;
  color: var(--cream);
}
.contact__info dd a { color: var(--cream); }
.contact__info dd a:hover { color: var(--gold-bright); }

.form {
  display: grid;
  gap: 1.25rem;
}
.form__row { display: grid; gap: .4rem; }
.form__row label {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--text-soft);
}
.form__row input,
.form__row textarea {
  background: var(--bg);
  border: 1px solid var(--hairline-2);
  color: var(--cream);
  padding: .85rem 1rem;
  font-family: var(--f-body);
  font-size: 1rem;
  border-radius: 0;
  transition: border-color .2s var(--ease);
}
.form__row input:focus,
.form__row textarea:focus {
  outline: none;
  border-color: var(--gold);
}
.form__row textarea { resize: vertical; min-height: 140px; }

.form__status {
  font-size: .85rem;
  padding: .75rem 1rem;
  border-left: 2px solid var(--gold);
  background: var(--bg);
  display: none;
}
.form__status.show { display: block; }
.form__status.error { border-left-color: var(--red); color: var(--red); }
.form__status.success { border-left-color: var(--gold); color: var(--gold-bright); }

@media (max-width: 820px) {
  .contact__grid { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 4rem 0 2.5rem;
  border-top: 1px solid var(--hairline);
  background: var(--black);
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer__brand img { height: 80px; margin-bottom: 1rem; }
.footer__brand p { color: var(--text-mute); font-size: .9rem; max-width: 30em; }
.footer__col h5 {
  font-family: var(--f-body);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 1rem;
}
.footer__col ul { list-style: none; padding: 0; margin: 0; }
.footer__col li { margin-bottom: .65rem; }
.footer__col a { color: var(--text-soft); font-size: .92rem; }
.footer__col a:hover { color: var(--cream); }

.footer__bottom {
  border-top: 1px solid var(--hairline);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: .78rem;
  color: var(--text-mute);
}
.footer__bottom .credentials {
  font-family: var(--f-display);
  font-style: italic;
  color: var(--text-soft);
}

@media (max-width: 820px) {
  .footer__grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .8s var(--ease-emph), transform .8s var(--ease-emph);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Utilities ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.muted { color: var(--text-mute); }
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}
