/* ============================================================
   nnds_ebds – public page styles
   Tokens, hero and shared utilities mirror about.html. NAV STYLES ARE NOT
   HERE: nav.html ships its own (it needs the :root tokens below). Everything below the
   "NNDS" marker is specific to this app.
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body.nnds-body { font-family: var(--font-body); background: var(--surface); color: var(--ink); overflow-x: hidden; }

:root {
      --yellow:      #F5D800;
      --yellow-dark: #C9A800;
      --blue:        #1e4d8c;
      --blue-mid:    #2a6db5;
      --teal:        #27a89e;
      --teal-light:  #3fcfc4;
      --red:         #E04A2F;
      --green:       #2DB34A;
      --ink:         #0d1b2a;
      --ink-2:       #2d3e50;
      --ink-3:       #5a6a7a;
      --surface:     #f0f4f8;
      --surface-2:   #ffffff;
      --border:      #dce4ef;
      --grad:        linear-gradient(135deg, #1e4d8c 0%, #27a89e 100%);
      --grad-warm:   linear-gradient(135deg, #1e4d8c 0%, #F5D800 100%);
      --grad-soft:   linear-gradient(135deg, rgba(30,77,140,.07) 0%, rgba(39,168,158,.07) 100%);
      --font-display:'Fraunces', Georgia, serif;
      --font-body:   'DM Sans', sans-serif;
      --font-mono:   'DM Mono', monospace;
      --radius-sm:   8px; --radius-md:16px; --radius-lg:28px;
      --shadow-sm:   0 2px 8px rgba(0,0,0,.06);
      --shadow-md:   0 8px 28px rgba(0,0,0,.09);
      --shadow-lg:   0 20px 60px rgba(0,0,0,.12);
      --shadow-blue: 0 8px 28px rgba(30,77,140,.22);
      --tr:          220ms cubic-bezier(.4,0,.2,1);
    }
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; }
    body { font-family: var(--font-body); background: var(--surface); color: var(--ink); overflow-x: hidden; }

    /* ════ PAGE HERO ════ */
    .page-hero {
      padding: 112px 0 0;
      background: var(--surface-2);
      position: relative; overflow: hidden;
    }
    .page-hero::before {
      content:''; position:absolute; inset:0; pointer-events:none;
      background:
        radial-gradient(ellipse 60% 50% at 85% 20%, rgba(39,168,158,.1) 0%, transparent 60%),
        radial-gradient(ellipse 50% 60% at 15% 80%, rgba(245,216,0,.08) 0%, transparent 55%),
        radial-gradient(ellipse 40% 40% at 50% 50%, rgba(30,77,140,.04) 0%, transparent 70%);
    }
    .hero-ring { position:absolute; border-radius:50%; pointer-events:none; border:1px solid; animation:ringFloat 8s ease-in-out infinite; }
    .hero-ring-1 { width:380px;height:380px; border-color:rgba(39,168,158,.12); top:-60px;right:-80px; }
    .hero-ring-2 { width:240px;height:240px; border-color:rgba(245,216,0,.15); bottom:60px;left:-40px; animation-delay:-3s; }
    .hero-ring-3 { width:160px;height:160px; border-color:rgba(30,77,140,.1); top:30%;right:8%; animation-delay:-5s; }
    @keyframes ringFloat { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-14px)} }

    .page-hero-inner {
      max-width: 1200px; margin: 0 auto; width: 100%;
      padding: 72px 44px 80px;
      position: relative; z-index: 1;
    }
    .hero-badge {
      display: inline-flex; align-items: center; gap: 9px;
      background: linear-gradient(135deg, rgba(245,216,0,.15), rgba(39,168,158,.12));
      border: 1px solid rgba(245,216,0,.5); border-radius: 30px;
      padding: 6px 18px; font-family: var(--font-mono); font-size: 11px; font-weight: 500;
      letter-spacing: .14em; text-transform: uppercase; color: var(--blue);
      margin-bottom: 24px; animation: fadeUp .5s ease both;
    }
    .hero-badge-dot { width:7px;height:7px;border-radius:50%;background:var(--yellow-dark); animation:pulse 2s ease infinite; }
    @keyframes pulse { 0%,100%{box-shadow:0 0 0 0 rgba(201,168,0,.4)} 50%{box-shadow:0 0 0 5px rgba(201,168,0,0)} }
    .page-hero-title {
      font-family: var(--font-display); font-size: clamp(36px,5.5vw,68px);
      font-weight: 700; line-height: 1.08; letter-spacing: -.035em;
      color: var(--ink); max-width: 700px;
      animation: fadeUp .5s ease .1s both;
    }
    .page-hero-title span { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
    .page-hero-sub {
      font-size: 17px; font-weight: 400; color: var(--ink-2);
      max-width: 640px; line-height: 1.82; margin: 22px 0 36px;
      animation: fadeUp .5s ease .2s both;
    }
    .page-hero-sub strong { color: var(--blue); font-weight: 600; }
    .hero-stats {
      display: flex; flex-wrap: wrap; gap: 32px;
      animation: fadeUp .5s ease .3s both;
    }
    .hero-stat { display: flex; flex-direction: column; }
    .hero-stat-num { font-family: var(--font-display); font-size: 32px; font-weight: 700; color: var(--blue); letter-spacing: -.03em; line-height: 1; }
    .hero-stat-num span { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
    .hero-stat-label { font-size: 13px; color: var(--ink-3); margin-top: 4px; font-weight: 500; }

    /* ════ SHARED UTILS ════ */
    /* (about.html's global `section` padding intentionally not copied: it could restyle sections inside footer.html) */
    .section-wrap { max-width: 1140px; margin: 0 auto; }
    .label-tag { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-mono); font-size: 10.5px; font-weight: 500; letter-spacing: .15em; text-transform: uppercase; color: var(--teal); background: rgba(39,168,158,.09); border: 1px solid rgba(39,168,158,.25); padding: 4px 13px; border-radius: 20px; margin-bottom: 14px; }
    .label-tag::before { content:''; width:5px;height:5px;border-radius:50%;background:var(--teal); }
    .section-title { font-family: var(--font-display); font-size: clamp(28px,4vw,46px); font-weight: 700; letter-spacing: -.025em; color: var(--ink); line-height: 1.14; }
    .section-title span { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
    .section-lead { font-size: 16px; color: var(--ink-2); line-height: 1.82; margin-top: 16px; max-width: 680px; }
    .section-lead strong { color: var(--blue); font-weight: 600; }

    
/* ════ NNDS · intro ════ */
.nnds-points { list-style: none; max-width: 780px; margin: 0 0 8px; animation: fadeUp .5s ease .25s both; }
.nnds-points li { position: relative; padding-left: 30px; margin-bottom: 12px; font-size: 15.5px; line-height: 1.75; color: var(--ink-2); }
.nnds-points li::before { content: '\2713'; position: absolute; left: 0; top: 1px; width: 20px; height: 20px; border-radius: 50%; background: var(--grad); color: #fff; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.nnds-points li strong { color: var(--blue); font-weight: 600; }
.nnds-lead-in { font-family: var(--font-display); font-size: 22px; font-weight: 600; color: var(--blue); margin-top: 26px; animation: fadeUp .5s ease .3s both; }

/* ════ NNDS · section + grid ════ */
.nnds-section { background: var(--surface); padding: 88px 44px 104px; scroll-margin-top: 110px; }
.nnds-section .section-wrap { max-width: 1240px; }
.nnds-section-head { text-align: center; margin-bottom: 48px; }
.nnds-section-head .section-lead { margin-left: auto; margin-right: auto; }

.nnds-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));   /* desktop: 4 per row */
  gap: 22px;
  align-items: start;                                  /* expanding one card never stretches its row */
}
@media (max-width: 1100px) { .nnds-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }   /* tablet */
@media (max-width: 640px)  { .nnds-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; } }    /* mobile */

/* ════ NNDS · card ════ */
.nnds-card {
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-md); overflow: hidden; position: relative;
  box-shadow: var(--shadow-sm);
  transition: transform var(--tr), box-shadow var(--tr), border-color var(--tr), opacity .65s ease;
}
.nnds-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--grad); z-index: 2; }
.nnds-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: rgba(30,77,140,.15); }
.nnds-card.is-open { border-color: rgba(39,168,158,.45); box-shadow: var(--shadow-md); }

.nnds-card-image { aspect-ratio: 4 / 3; background: var(--surface); overflow: hidden; }
.nnds-card-image img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center 30%; transition: transform .45s ease; }
.nnds-card:hover .nnds-card-image img { transform: scale(1.04); }
.nnds-card-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: var(--grad-soft); color: var(--blue); font-size: 44px; opacity: .55; }

.nnds-card-heading { margin: 0; font-size: inherit; }
.nnds-card-toggle {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 15px 16px; background: var(--surface-2); border: 0; border-top: 1px solid var(--border);
  font: inherit; text-align: left; cursor: pointer; color: var(--ink);
  transition: background var(--tr);
}
.nnds-card-toggle:hover { background: var(--grad-soft); }
.nnds-card-toggle:focus-visible { outline: 2px solid var(--teal); outline-offset: -2px; }
.nnds-card-title { font-family: var(--font-display); font-size: 16.5px; font-weight: 700; letter-spacing: -.01em; line-height: 1.28; }
.nnds-toggle-icon {
  flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%;
  background: rgba(39,168,158,.1); border: 1px solid rgba(39,168,158,.3); color: var(--teal);
  display: flex; align-items: center; justify-content: center; font-size: 18px;
  transition: transform var(--tr), background var(--tr), color var(--tr);
}
.nnds-card.is-open .nnds-toggle-icon { transform: rotate(180deg); background: var(--grad); color: #fff; border-color: transparent; }

.nnds-card-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .3s ease; }
.nnds-card.is-open .nnds-card-body { grid-template-rows: 1fr; }
.nnds-card-body-inner { overflow: hidden; min-height: 0; }
.nnds-card-description { padding: 14px 16px 18px; border-top: 1px solid var(--border); font-size: 14px; line-height: 1.75; color: var(--ink-2); }
.nnds-card:not(.is-open) .nnds-card-body-inner { visibility: hidden; transition: visibility 0s .3s; }

.nnds-empty { grid-column: 1 / -1; text-align: center; padding: 56px 20px; color: var(--ink-3); }
.nnds-empty i { font-size: 40px; color: var(--teal); opacity: .6; display: block; margin-bottom: 10px; }

/* ════ ANIMATIONS ════ */
@keyframes fadeUp { from{opacity:0;transform:translateY(20px)} to{opacity:1;transform:none} }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .65s ease, transform .65s ease; }
.reveal.visible { opacity: 1; transform: none; }
.nnds-card.reveal.visible:hover { transform: translateY(-5px); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .nnds-card, .nnds-card-body, .nnds-card-image img, .hero-ring { transition: none; animation: none; }
}

/* ════ RESPONSIVE ════ */
@media (max-width: 700px) {
  .page-hero-inner { padding: 44px 20px 56px; }
  .nnds-section { padding: 64px 20px 72px; }
  .nnds-points li { font-size: 15px; }
}
.nnds-card.reveal { transition: opacity .65s ease, transform var(--tr), box-shadow var(--tr), border-color var(--tr); }
.nnds-chevron { width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); }
