/* ============================================================
   DAILY OPPORTUNITIES — legal.css
   Shared by: Disclaimer · Privacy Policy · Terms · Editorial Policy
   Inherits all design tokens from index.css (:root).
   ============================================================ */

/* ─────────────────────────────────────────────────────────────
   HERO
   ───────────────────────────────────────────────────────────── */
.legal-hero {
  background: var(--green-deep);
  position: relative;
  overflow: hidden;
  padding: clamp(48px, 7vw, 88px) 5% clamp(40px, 6vw, 72px);
}

/* Dot-grid overlay */
.legal-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

/* Ambient orb — top right */
.legal-hero::after {
  content: '';
  position: absolute;
  width: 500px; height: 500px;
  top: -180px; right: -110px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(67,160,71,.26) 0%, transparent 68%);
  pointer-events: none;
}

/* Second orb — amber bottom left */
.legal-hero-inner::before {
  content: '';
  position: absolute;
  width: 280px; height: 280px;
  bottom: -120px; left: -70px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,179,0,.10) 0%, transparent 68%);
  pointer-events: none;
}

/* Hairline bottom rule */
.legal-hero-inner::after {
  content: '';
  display: block;
  margin-top: clamp(32px, 5vw, 52px);
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255,255,255,.12) 20%,
    rgba(255,255,255,.22) 50%,
    rgba(255,255,255,.12) 80%,
    transparent 100%
  );
}

.legal-hero-inner {
  max-width: 820px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
  animation: legalHeroUp .68s var(--ease-out, cubic-bezier(.22,.61,.36,1)) both;
}

@keyframes legalHeroUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Breadcrumb */
.legal-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: .78rem;
  font-weight: 500;
  color: rgba(255,255,255,.50);
  margin-bottom: 20px;
}
.legal-breadcrumb a {
  color: rgba(255,255,255,.62);
  text-decoration: none;
  transition: color .2s;
}
.legal-breadcrumb a:hover { color: #fff; }

/* Eyebrow */
.legal-eyebrow {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--amber-bright);
  margin: 0 0 12px;
}

/* H1 */
.legal-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(2rem, 5.5vw, 3.4rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -.03em;
  line-height: 1.1;
  margin: 0 0 18px;
}
.legal-title em {
  font-style: normal;
  color: var(--amber-bright);
}

/* Lead / date */
.legal-lead {
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(.9rem, 1.8vw, 1rem);
  color: rgba(255,255,255,.60);
  line-height: 1.7;
  margin: 0;
  max-width: 520px;
}

/* ─────────────────────────────────────────────────────────────
   PAGE CONTAINER
   ───────────────────────────────────────────────────────────── */
.legal-container {
  font-family: 'DM Sans', sans-serif;
  max-width: 1200px;
  margin: 0 auto;
  min-height: 60vh;
  padding: clamp(16px, 3vw, 36px) 5% clamp(64px, 12vw, 100px);
}

/* ─────────────────────────────────────────────────────────────
   ARTICLE SHELL
   ───────────────────────────────────────────────────────────── */
.legal-article {
  max-width: 760px;
  margin: 0 auto;
}

/* ─────────────────────────────────────────────────────────────
   CONTENT CARD
   ───────────────────────────────────────────────────────────── */
.legal-content {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: clamp(28px, 5vw, 52px) clamp(24px, 5vw, 52px);
}

/* Lead paragraph */
.legal-content .lead {
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(1rem, 2.2vw, 1.1rem);
  color: var(--muted-text);
  line-height: 1.8;
  margin: 0 0 28px;
  font-weight: 400;
}

/* Horizontal rule */
.legal-content hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 32px 0;
}

/* Links */
.legal-content a {
  color: var(--green-mid);
  text-decoration: underline;
  text-decoration-color: #A7D7A9;
  text-underline-offset: 3px;
  font-weight: 500;
  transition: color .2s, text-decoration-color .2s;
}
.legal-content a:hover {
  color: var(--green-deep);
  text-decoration-color: var(--green-mid);
}

/* ─────────────────────────────────────────────────────────────
   TABLE OF CONTENTS
   ───────────────────────────────────────────────────────────── */
.legal-toc {
  background: var(--green-pale);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin-bottom: 36px;
}
.legal-toc-title {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--light-text);
  margin: 0 0 12px;
}
.legal-toc ol {
  margin: 0;
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  counter-reset: toc-counter;
}
.legal-toc ol li {
  counter-increment: toc-counter;
  padding-left: 0;
  font-size: .875rem;
}
.legal-toc ol li::before { display: none; }
.legal-toc ol li a {
  color: var(--muted-text);
  text-decoration: none;
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color .2s;
  text-decoration: none;
}
.legal-toc ol li a::before {
  content: counter(toc-counter, decimal-leading-zero);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--green-bright);
  opacity: .9;
  flex-shrink: 0;
  letter-spacing: .02em;
  font-family: 'Poppins', sans-serif;
}
.legal-toc ol li a:hover {
  color: var(--green-deep);
  text-decoration: none;
}

/* ─────────────────────────────────────────────────────────────
   SECTIONS
   ───────────────────────────────────────────────────────────── */
.legal-section {
  margin-bottom: 36px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--border);
}
.legal-section:last-of-type {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* Section h2 with green left-bar accent */
.legal-section h2 {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.05rem, 2.4vw, 1.28rem);
  font-weight: 700;
  color: var(--dark-text);
  letter-spacing: -.01em;
  margin: 0 0 14px;
  line-height: 1.3;
  display: flex;
  align-items: center;
  gap: 10px;
}
.legal-section h2::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 1.1em;
  background: var(--green-bright);
  border-radius: 2px;
  flex-shrink: 0;
}

/* Section body text */
.legal-section p {
  font-family: 'DM Sans', sans-serif;
  font-size: .9375rem;
  color: var(--muted-text);
  line-height: 1.78;
  margin: 0 0 12px;
}
.legal-section p:last-child { margin-bottom: 0; }
.legal-section strong {
  color: var(--dark-text);
  font-weight: 600;
}

/* Lists */
.legal-section ul,
.legal-section ol {
  margin: 8px 0 14px;
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.legal-section ul li,
.legal-section ol li {
  font-family: 'DM Sans', sans-serif;
  font-size: .9375rem;
  color: var(--muted-text);
  line-height: 1.65;
  padding-left: 22px;
  position: relative;
}

/* Green dot bullet */
.legal-section ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: .58em;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green-bright);
  opacity: .75;
}

/* Numbered list */
.legal-section ol { counter-reset: ol-counter; }
.legal-section ol li { counter-increment: ol-counter; }
.legal-section ol li::before {
  content: counter(ol-counter) '.';
  position: absolute;
  left: 0; top: 0;
  font-size: .8125rem;
  font-weight: 700;
  color: var(--green-bright);
  line-height: 1.65;
  font-family: 'Poppins', sans-serif;
}

/* Sub-headings (h3) */
.legal-h3 {
  font-family: 'DM Sans', sans-serif;
  font-size: .9375rem;
  font-weight: 600;
  color: var(--dark-text);
  letter-spacing: .01em;
  margin: 24px 0 10px;
  padding-left: 12px;
  border-left: 2px solid #A7D7A9;
  line-height: 1.4;
}

/* ─────────────────────────────────────────────────────────────
   ALERT / CALLOUT BOXES
   ───────────────────────────────────────────────────────────── */
.legal-alert {
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-top: 24px;
  font-family: 'DM Sans', sans-serif;
  font-size: .9rem;
  line-height: 1.65;
  border: 1.5px solid transparent;
}
.legal-alert p {
  margin: 0;
  color: inherit;
  font-size: inherit;
  line-height: inherit;
}
.legal-alert strong { font-weight: 600; }

/* Warning — amber tint */
.legal-alert-warning {
  background: var(--amber-light);
  border-color: #FFD54F;
  color: #7B4F00;
}
.legal-alert-warning strong { color: #5C3900; }

/* Info — green pale tint */
.legal-alert-info {
  background: var(--green-pale);
  border-color: var(--border);
  color: var(--muted-text);
}
.legal-alert-info strong { color: var(--dark-text); }
.legal-alert-info a {
  color: var(--green-mid);
  text-decoration: underline;
  text-decoration-color: #A7D7A9;
  font-weight: 500;
  transition: color .2s;
}
.legal-alert-info a:hover { color: var(--green-deep); }

/* ─────────────────────────────────────────────────────────────
   PRINCIPLE CARDS GRID  (editorial policy)
   ───────────────────────────────────────────────────────────── */
.principle-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: clamp(24px, 4vw, 36px);
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.principle-card {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-card);
  padding: 24px 20px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  box-shadow: var(--shadow-card);
  transition: transform .22s var(--ease-out), box-shadow .22s, border-color .22s;
  position: relative;
  overflow: hidden;
}

/* Green top accent strip */
.principle-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--green-bright);
}

.principle-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: #D1FAE5;
}

.principle-icon {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--green-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green-mid);
  flex-shrink: 0;
  margin-top: 4px;
}

.principle-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--dark-text);
  margin: 0;
  letter-spacing: -.01em;
  line-height: 1.2;
}

.principle-desc {
  font-family: 'DM Sans', sans-serif;
  font-size: .8rem;
  color: var(--light-text);
  line-height: 1.6;
  margin: 0;
}

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE
   ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .hide-on-mobile    { display: none; }
  .principle-grid    { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .legal-content {
    padding: 24px 20px;
  }
  .legal-section h2   { font-size: 1rem; }
  .legal-section p,
  .legal-section ul li,
  .legal-section ol li { font-size: .875rem; }
}

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

/* ─────────────────────────────────────────────────────────────
   REDUCED MOTION
   ───────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .legal-hero-inner  { animation: none !important; }
  .principle-card    { transition: none !important; }
}