/* Nexvix — The Wealth Journal */

:root {
  --emerald: #15803d;
  --sage: #86efac;
  --forest: #166534;
  --ivory: #fffcf5;
  --cream: #f8f5ec;
  --charcoal: #1f2937;
  --gold-beige: #e7dfc8;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-heading: "Libre Baskerville", Georgia, serif;
  --font-body: "Inter", system-ui, sans-serif;
  --max-width: 72rem;
  --section-pad: clamp(3rem, 8vw, 6rem);
  --ribbon-h: 2.25rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--charcoal);
  background-color: var(--ivory);
  background-image:
    radial-gradient(ellipse 120% 80% at 50% -20%, rgba(21, 128, 61, 0.04), transparent 50%),
    linear-gradient(180deg, var(--ivory) 0%, #faf8f2 100%);
  background-attachment: fixed;
  animation: bg-drift 45s ease-in-out infinite alternate;
}

@keyframes bg-drift {
  0% { background-position: 0% 0%, 0% 0%; }
  100% { background-position: 2% 1%, 0% 0%; }
}

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

a {
  color: var(--forest);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--emerald);
}

/* ——— Header ribbon ——— */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--ivory);
  border-bottom: 1px solid var(--gold-beige);
}

.ribbon {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: var(--ribbon-h);
  padding: 0 clamp(1rem, 4vw, 2.5rem);
  background: linear-gradient(90deg, var(--forest) 0%, var(--emerald) 50%, var(--forest) 100%);
  background-size: 200% 100%;
  animation: ribbon-shift 20s ease-in-out infinite alternate;
  color: var(--ivory);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

@keyframes ribbon-shift {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}

.ribbon-left {
  justify-self: start;
  opacity: 0.92;
}

.ribbon-center {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.35em;
  text-transform: uppercase;
}

.ribbon-right {
  justify-self: end;
  text-align: right;
  font-style: italic;
  letter-spacing: 0.12em;
  text-transform: none;
  font-size: 0.6rem;
  opacity: 0.9;
}

.minimal-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(1.25rem, 4vw, 2.5rem);
  padding: 0.85rem 1.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.minimal-nav a {
  color: var(--charcoal);
  position: relative;
  padding-bottom: 2px;
}

.minimal-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--emerald);
  transition: width 0.4s ease;
}

.minimal-nav a:hover::after {
  width: 100%;
}

/* ——— Section utilities ——— */

.section-masthead {
  max-width: var(--max-width);
  margin: 0 auto 2.5rem;
  padding: 0 clamp(1.25rem, 5vw, 2rem);
}

.section-masthead--center {
  text-align: center;
}

.section-masthead__label {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--emerald);
  margin-bottom: 0.5rem;
}

.section-masthead h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 400;
  color: var(--charcoal);
}

.section-fade {
  opacity: 0;
  transform: translateY(1.25rem);
  animation: section-in 1.2s ease forwards;
  animation-timeline: view();
  animation-range: entry 0% cover 25%;
}

@supports not (animation-timeline: view()) {
  .section-fade {
    opacity: 1;
    transform: none;
  }
}

@keyframes section-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.reveal-text {
  opacity: 0;
  animation: text-reveal 1.4s ease forwards;
}

.reveal-delay-1 {
  animation-delay: 0.35s;
}

@keyframes text-reveal {
  from {
    opacity: 0;
    transform: translateY(0.75rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ——— Front page ——— */

.front-page {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem) calc(var(--section-pad) * 0.75);
  border-bottom: 2px solid var(--charcoal);
}

.front-page__grid {
  display: grid;
  grid-template-columns: 1fr minmax(12rem, 16rem);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.dateline {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6b7280;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--gold-beige);
  padding-bottom: 0.75rem;
}

.front-page__lead h1 {
  font-family: var(--font-display);
  font-size: clamp(2.75rem, 8vw, 4.5rem);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--charcoal);
  margin-bottom: 1.5rem;
}

.front-page__deck {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  line-height: 1.75;
  color: #374151;
  max-width: 38rem;
  margin-bottom: 1.5rem;
}

.front-page__rule {
  width: 4rem;
  height: 3px;
  background: var(--emerald);
  margin-bottom: 1.25rem;
}

.front-page__byline {
  font-size: 0.85rem;
  font-style: italic;
  color: #6b7280;
  max-width: 32rem;
}

/* Market panel */

.market-panel {
  border-left: 3px solid var(--emerald);
  padding: 0 0 0 1.25rem;
  background: linear-gradient(90deg, rgba(248, 245, 236, 0.8), transparent);
}

.market-panel__title {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
  color: var(--forest);
}

.market-panel__list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.market-panel__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px dotted var(--gold-beige);
}

.market-panel__row dt {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b7280;
}

.market-panel__value {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--charcoal);
}

.market-panel__value--up {
  color: var(--emerald);
}

.market-panel__value--neutral {
  color: var(--forest);
}

.market-panel__note {
  margin-top: 1.25rem;
  font-size: 0.6rem;
  color: #9ca3af;
  font-style: italic;
}

/* ——— Philosophy ——— */

.philosophy {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
  border-top: 1px solid var(--gold-beige);
}

.philosophy__columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  column-rule: 1px solid var(--gold-beige);
}

.philosophy__column {
  padding: 0 clamp(0.5rem, 2vw, 1.25rem);
  border-right: 1px solid var(--gold-beige);
}

.philosophy__column:last-child {
  border-right: none;
}

.philosophy__column h3 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 500;
  color: var(--forest);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--emerald);
}

.philosophy__column p {
  font-size: 0.92rem;
  margin-bottom: 1rem;
  text-align: justify;
  hyphens: auto;
}

.philosophy__column p:last-child {
  margin-bottom: 0;
}

/* ——— Indicators ——— */

.indicators {
  background: var(--cream);
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
  border-top: 1px solid var(--gold-beige);
  border-bottom: 1px solid var(--gold-beige);
}

.indicators .section-masthead {
  margin-bottom: 3rem;
}

.indicators__report {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  padding: 0 clamp(1.25rem, 5vw, 2rem);
}

.indicators__entry {
  text-align: center;
  padding: 1.5rem 0;
  border-top: 1px solid var(--charcoal);
  border-bottom: 1px solid var(--gold-beige);
}

.indicators__figure {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 3.75rem);
  font-weight: 600;
  color: var(--forest);
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.indicators__label {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6b7280;
}

/* ——— Insights ——— */

.insights {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
}

.insights__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  border: 1px solid var(--charcoal);
}

.insights__article {
  padding: clamp(1.5rem, 4vw, 2.25rem);
  border: 1px solid var(--gold-beige);
  background: var(--ivory);
  transition: background 0.4s ease;
}

.insights__article:hover {
  background: var(--cream);
}

.insights__category {
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--emerald);
  display: block;
  margin-bottom: 0.5rem;
}

.insights__article h3 {
  font-family: var(--font-heading);
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  font-weight: 700;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.insights__article h3 a {
  color: var(--charcoal);
  position: relative;
  background-image: linear-gradient(var(--emerald), var(--emerald));
  background-size: 0% 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size 0.4s ease, color 0.3s ease;
}

.insights__article h3 a:hover {
  color: var(--forest);
  background-size: 100% 1px;
}

.insights__article p {
  font-size: 0.88rem;
  color: #4b5563;
  margin-bottom: 1rem;
}

.insights__read {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--emerald);
}

/* ——— Global presence / map ——— */

.presence {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
  background: linear-gradient(180deg, transparent, rgba(248, 245, 236, 0.6));
}

.presence__layout {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  align-items: center;
  padding: 0 clamp(1.25rem, 5vw, 2rem);
}

.world-map {
  position: relative;
  width: 100%;
  max-width: 36rem;
  aspect-ratio: 2 / 1;
  margin: 0 auto;
  background: var(--cream);
  border: 1px solid var(--gold-beige);
  overflow: hidden;
}

.world-map__ocean {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #f0ebe0 0%, var(--cream) 100%);
}

.world-map__land {
  position: absolute;
  background: var(--sage);
  opacity: 0.35;
  border-radius: 2px;
}

.world-map__land--na {
  top: 22%;
  left: 8%;
  width: 22%;
  height: 28%;
  clip-path: polygon(0% 40%, 15% 0%, 85% 5%, 100% 35%, 90% 100%, 20% 95%);
}

.world-map__land--sa {
  top: 52%;
  left: 18%;
  width: 12%;
  height: 32%;
  clip-path: polygon(30% 0%, 100% 10%, 70% 100%, 0% 90%);
  opacity: 0.2;
}

.world-map__land--eu {
  top: 18%;
  left: 44%;
  width: 14%;
  height: 22%;
  clip-path: polygon(10% 20%, 90% 0%, 100% 80%, 40% 100%, 0% 60%);
}

.world-map__land--af {
  top: 38%;
  left: 46%;
  width: 12%;
  height: 35%;
  clip-path: polygon(20% 0%, 80% 5%, 100% 100%, 0% 95%);
  opacity: 0.2;
}

.world-map__land--me {
  top: 32%;
  left: 52%;
  width: 10%;
  height: 14%;
  clip-path: polygon(0% 30%, 100% 0%, 100% 100%, 10% 80%);
}

.world-map__land--as {
  top: 20%;
  left: 58%;
  width: 32%;
  height: 38%;
  clip-path: polygon(0% 25%, 60% 0%, 100% 20%, 95% 70%, 50% 100%, 5% 80%);
}

.world-map__land--oc {
  top: 58%;
  left: 72%;
  width: 18%;
  height: 22%;
  clip-path: polygon(0% 20%, 80% 0%, 100% 60%, 40% 100%);
  opacity: 0.2;
}

.world-map__marker {
  position: absolute;
  width: 10px;
  height: 10px;
  background: var(--emerald);
  border: 2px solid var(--ivory);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(21, 128, 61, 0.25);
  animation: marker-pulse 3s ease-in-out infinite;
}

.world-map__marker--na { top: 32%; left: 16%; }
.world-map__marker--eu { top: 26%; left: 50%; }
.world-map__marker--me { top: 36%; left: 56%; }
.world-map__marker--ap { top: 38%; left: 72%; }

@keyframes marker-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(21, 128, 61, 0.25); }
  50% { box-shadow: 0 0 0 8px rgba(21, 128, 61, 0.1); }
}

.presence__regions {
  list-style: none;
  font-family: var(--font-heading);
  font-size: 0.95rem;
}

.presence__regions li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--gold-beige);
}

.presence__dot {
  width: 8px;
  height: 8px;
  background: var(--emerald);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ——— Principles ——— */

.principles {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
  border-top: 2px solid var(--charcoal);
}

.principles__list {
  list-style: none;
  padding: 0 clamp(1.25rem, 5vw, 2rem);
}

.principles__list li {
  display: grid;
  grid-template-columns: 5rem 1fr;
  align-items: baseline;
  gap: 1.5rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--gold-beige);
}

.principles__num {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 300;
  color: var(--gold-beige);
  line-height: 1;
}

.principles__name {
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  font-weight: 400;
  color: var(--charcoal);
}

/* ——— CTA ——— */

.cta {
  background: linear-gradient(145deg, var(--forest) 0%, var(--emerald) 45%, #14532d 100%);
  background-size: 150% 150%;
  animation: cta-gradient 18s ease infinite alternate;
  padding: calc(var(--section-pad) * 1.1) clamp(1.25rem, 5vw, 2rem);
  text-align: center;
}

@keyframes cta-gradient {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}

.cta__inner {
  max-width: 36rem;
  margin: 0 auto;
}

.cta h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.75rem);
  font-weight: 500;
  color: var(--ivory);
  line-height: 1.2;
  margin-bottom: 1rem;
  animation: text-reveal 1.2s ease forwards;
}

.cta__text {
  color: var(--sage);
  font-size: 0.95rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.btn {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, border-color 0.35s ease;
}

.btn--light {
  background: var(--ivory);
  color: var(--forest);
}

.btn--light:hover {
  background: var(--cream);
  color: var(--emerald);
}

.btn--outline {
  background: transparent;
  color: var(--ivory);
  border-color: rgba(255, 252, 245, 0.6);
}

.btn--outline:hover {
  border-color: var(--ivory);
  background: rgba(255, 252, 245, 0.08);
}

.btn--primary {
  background: var(--emerald);
  color: var(--ivory);
  border-color: var(--emerald);
  margin-top: 0.5rem;
}

.btn--primary:hover {
  background: var(--forest);
  border-color: var(--forest);
}

/* ——— Contact ——— */

.contact {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad) clamp(1.25rem, 5vw, 2rem);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 4rem);
  padding: 0 clamp(1.25rem, 5vw, 2rem);
}

.contact__office {
  font-style: normal;
  font-size: 0.92rem;
  line-height: 1.8;
}

.contact__brand {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--forest);
  margin-bottom: 1rem;
}

.contact__office p {
  margin-bottom: 0.75rem;
}

.contact__hours {
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: #6b7280;
  font-style: italic;
}

.contact__form {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.contact__form label {
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6b7280;
  margin-top: 1rem;
}

.contact__form label:first-of-type {
  margin-top: 0;
}

.contact__form input,
.contact__form textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--charcoal);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--charcoal);
  padding: 0.5rem 0;
  outline: none;
  transition: border-color 0.3s ease;
  resize: vertical;
}

.contact__form input:focus,
.contact__form textarea:focus {
  border-bottom-color: var(--emerald);
}

.contact__form input::placeholder,
.contact__form textarea::placeholder {
  color: #d1d5db;
}

/* ——— Footer ——— */

.site-footer {
  position: relative;
  background: var(--charcoal);
  color: #d1d5db;
  padding: 4rem clamp(1.25rem, 5vw, 2rem) 2.5rem;
  overflow: hidden;
}

.site-footer__watermark {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-display);
  font-size: clamp(6rem, 22vw, 14rem);
  font-weight: 700;
  letter-spacing: 0.15em;
  color: rgba(255, 252, 245, 0.04);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

.site-footer__content {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-footer__brand {
  margin-bottom: 2rem;
}

.site-footer__name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.3em;
  color: var(--ivory);
  display: block;
  margin-bottom: 0.35rem;
}

.site-footer__brand p {
  font-size: 0.8rem;
  opacity: 0.7;
}

.site-footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
  margin-bottom: 2.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-footer__nav a {
  color: var(--sage);
  position: relative;
  padding-bottom: 2px;
}

.site-footer__nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--sage);
  transition: width 0.4s ease;
}

.site-footer__nav a:hover::after {
  width: 100%;
}

.site-footer__nav a:hover {
  color: var(--ivory);
}

.site-footer__legal {
  font-size: 0.65rem;
  line-height: 1.6;
  opacity: 0.5;
  max-width: 40rem;
}

/* ——— Responsive ——— */

@media (max-width: 900px) {
  .front-page__grid {
    grid-template-columns: 1fr;
  }

  .market-panel {
    border-left: none;
    border-top: 3px solid var(--emerald);
    padding: 1.5rem 0 0;
  }

  .philosophy__columns {
    grid-template-columns: 1fr;
  }

  .philosophy__column {
    border-right: none;
    border-bottom: 1px solid var(--gold-beige);
    padding-bottom: 2rem;
    margin-bottom: 0.5rem;
  }

  .philosophy__column:last-child {
    border-bottom: none;
    padding-bottom: 0;
  }

  .indicators__report {
    grid-template-columns: repeat(2, 1fr);
  }

  .presence__layout {
    grid-template-columns: 1fr;
  }

  .presence__regions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0 1rem;
  }

  .contact__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .ribbon {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 0.25rem;
    padding: 0.5rem 1rem;
    min-height: auto;
  }

  .ribbon-left,
  .ribbon-right {
    justify-self: center;
    text-align: center;
    font-size: 0.55rem;
  }

  .ribbon-center {
    order: -1;
    font-size: 1rem;
  }

  .minimal-nav {
    gap: 0.85rem 1.25rem;
    font-size: 0.62rem;
  }

  .insights__grid {
    grid-template-columns: 1fr;
  }

  .indicators__report {
    grid-template-columns: 1fr;
  }

  .principles__list li {
    grid-template-columns: 3.5rem 1fr;
    gap: 1rem;
  }

  .presence__regions {
    grid-template-columns: 1fr;
  }

  .cta__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  .section-fade {
    opacity: 1;
    transform: none;
  }

  .reveal-text {
    opacity: 1;
    animation: none;
  }
}
