/* ==========================================================================
   Main Stylesheet - Powered by Design Tokens
   All colors, fonts, and spacing are controlled via design/*.yaml files
   Palette derived from the AIS4I logo: Italian-flag green + red,
   green-tinted neutrals, serif display + grotesk body.
   ========================================================================== */

*, ::before, ::after {
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}

::backdrop {
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}

/* ! tailwindcss v3.4.19 | MIT License | https://tailwindcss.com *//*
1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
*/

*,
::before,
::after {
  box-sizing: border-box; /* 1 */
  border-width: 0; /* 2 */
  border-style: solid; /* 2 */
  border-color: #e5e7eb; /* 2 */
}

::before,
::after {
  --tw-content: '';
}

/*
1. Use a consistent sensible line-height in all browsers.
2. Prevent adjustments of font size after orientation changes in iOS.
3. Use a more readable tab size.
4. Use the user's configured `sans` font-family by default.
5. Use the user's configured `sans` font-feature-settings by default.
6. Use the user's configured `sans` font-variation-settings by default.
7. Disable tap highlights on iOS
*/

html,
:host {
  line-height: 1.5; /* 1 */
  -webkit-text-size-adjust: 100%; /* 2 */
  -moz-tab-size: 4; /* 3 */
  -o-tab-size: 4;
     tab-size: 4; /* 3 */
  font-family: 'Hanken Grotesk', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; /* 4 */
  font-feature-settings: normal; /* 5 */
  font-variation-settings: normal; /* 6 */
  -webkit-tap-highlight-color: transparent; /* 7 */
}

/*
1. Remove the margin in all browsers.
2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.
*/

body {
  margin: 0; /* 1 */
  line-height: inherit; /* 2 */
}

/*
1. Add the correct height in Firefox.
2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
3. Ensure horizontal rules are visible by default.
*/

hr {
  height: 0; /* 1 */
  color: inherit; /* 2 */
  border-top-width: 1px; /* 3 */
}

/*
Add the correct text decoration in Chrome, Edge, and Safari.
*/

abbr:where([title]) {
  -webkit-text-decoration: underline dotted;
          text-decoration: underline dotted;
}

/*
Remove the default font size and weight for headings.
*/

h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: inherit;
  font-weight: inherit;
}

/*
Reset links to optimize for opt-in styling instead of opt-out.
*/

a {
  color: inherit;
  text-decoration: inherit;
}

/*
Add the correct font weight in Edge and Safari.
*/

b,
strong {
  font-weight: bolder;
}

/*
1. Use the user's configured `mono` font-family by default.
2. Use the user's configured `mono` font-feature-settings by default.
3. Use the user's configured `mono` font-variation-settings by default.
4. Correct the odd `em` font sizing in all browsers.
*/

code,
kbd,
samp,
pre {
  font-family: ui-monospace, SFMono-Regular, 'Menlo', 'Monaco', 'Cascadia Code', 'Segoe UI Mono', monospace; /* 1 */
  font-feature-settings: normal; /* 2 */
  font-variation-settings: normal; /* 3 */
  font-size: 1em; /* 4 */
}

/*
Add the correct font size in all browsers.
*/

small {
  font-size: 80%;
}

/*
Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/

sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/*
1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
3. Remove gaps between table borders by default.
*/

table {
  text-indent: 0; /* 1 */
  border-color: inherit; /* 2 */
  border-collapse: collapse; /* 3 */
}

/*
1. Change the font styles in all browsers.
2. Remove the margin in Firefox and Safari.
3. Remove default padding in all browsers.
*/

button,
input,
optgroup,
select,
textarea {
  font-family: inherit; /* 1 */
  font-feature-settings: inherit; /* 1 */
  font-variation-settings: inherit; /* 1 */
  font-size: 100%; /* 1 */
  font-weight: inherit; /* 1 */
  line-height: inherit; /* 1 */
  letter-spacing: inherit; /* 1 */
  color: inherit; /* 1 */
  margin: 0; /* 2 */
  padding: 0; /* 3 */
}

/*
Remove the inheritance of text transform in Edge and Firefox.
*/

button,
select {
  text-transform: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Remove default button styles.
*/

button,
input:where([type='button']),
input:where([type='reset']),
input:where([type='submit']) {
  -webkit-appearance: button; /* 1 */
  background-color: transparent; /* 2 */
  background-image: none; /* 2 */
}

/*
Use the modern Firefox focus style for all focusable elements.
*/

:-moz-focusring {
  outline: auto;
}

/*
Remove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
*/

:-moz-ui-invalid {
  box-shadow: none;
}

/*
Add the correct vertical alignment in Chrome and Firefox.
*/

progress {
  vertical-align: baseline;
}

/*
Correct the cursor style of increment and decrement buttons in Safari.
*/

::-webkit-inner-spin-button,
::-webkit-outer-spin-button {
  height: auto;
}

/*
1. Correct the odd appearance in Chrome and Safari.
2. Correct the outline style in Safari.
*/

[type='search'] {
  -webkit-appearance: textfield; /* 1 */
  outline-offset: -2px; /* 2 */
}

/*
Remove the inner padding in Chrome and Safari on macOS.
*/

::-webkit-search-decoration {
  -webkit-appearance: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Change font properties to `inherit` in Safari.
*/

::-webkit-file-upload-button {
  -webkit-appearance: button; /* 1 */
  font: inherit; /* 2 */
}

/*
Add the correct display in Chrome and Safari.
*/

summary {
  display: list-item;
}

/*
Removes the default spacing and border for appropriate elements.
*/

blockquote,
dl,
dd,
h1,
h2,
h3,
h4,
h5,
h6,
hr,
figure,
p,
pre {
  margin: 0;
}

fieldset {
  margin: 0;
  padding: 0;
}

legend {
  padding: 0;
}

ol,
ul,
menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

/*
Reset default styling for dialogs.
*/
dialog {
  padding: 0;
}

/*
Prevent resizing textareas horizontally by default.
*/

textarea {
  resize: vertical;
}

/*
1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
2. Set the default placeholder color to the user's configured gray 400 color.
*/

input::-moz-placeholder, textarea::-moz-placeholder {
  opacity: 1; /* 1 */
  color: #9ca3af; /* 2 */
}

input::placeholder,
textarea::placeholder {
  opacity: 1; /* 1 */
  color: #9ca3af; /* 2 */
}

/*
Set the default cursor for buttons.
*/

button,
[role="button"] {
  cursor: pointer;
}

/*
Make sure disabled buttons don't get the pointer cursor.
*/
:disabled {
  cursor: default;
}

/*
1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)
2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
   This can trigger a poorly considered lint error in some tools but is included by design.
*/

img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  display: block; /* 1 */
  vertical-align: middle; /* 2 */
}

/*
Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
*/

img,
video {
  max-width: 100%;
  height: auto;
}

/* Make elements with the HTML hidden attribute stay hidden by default */
[hidden]:where(:not([hidden="until-found"])) {
  display: none;
}
.container {
  width: 100%;
  margin-right: auto;
  margin-left: auto;
}
@media (min-width: 640px) {

  .container {
    max-width: 640px;
  }
}
@media (min-width: 768px) {

  .container {
    max-width: 768px;
    padding-right: 1.5rem;
    padding-left: 1.5rem;
  }
}
@media (min-width: 1024px) {

  .container {
    max-width: 1024px;
    padding-right: 2rem;
    padding-left: 2rem;
  }
}
@media (min-width: 1280px) {

  .container {
    max-width: 1280px;
  }
}
@media (min-width: 1536px) {

  .container {
    max-width: 1536px;
  }
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
.visible {
  visibility: visible;
}
.static {
  position: static;
}
.relative {
  position: relative;
}
.sticky {
  position: sticky;
}
.z-10 {
  z-index: 10;
}
.mx-auto {
  margin-left: auto;
  margin-right: auto;
}
.mb-0 {
  margin-bottom: 0;
}
.mb-16 {
  margin-bottom: 4rem;
}
.mb-2 {
  margin-bottom: 0.5rem;
}
.mb-3 {
  margin-bottom: 0.75rem;
}
.mb-4 {
  margin-bottom: 1rem;
}
.mb-6 {
  margin-bottom: 1.5rem;
}
.mb-8 {
  margin-bottom: 2rem;
}
.mt-10 {
  margin-top: 2.5rem;
}
.mt-2 {
  margin-top: 0.5rem;
}
.mt-4 {
  margin-top: 1rem;
}
.mt-6 {
  margin-top: 1.5rem;
}
.mt-8 {
  margin-top: 2rem;
}
.block {
  display: block;
}
.inline-block {
  display: inline-block;
}
.inline {
  display: inline;
}
.flex {
  display: flex;
}
.table {
  display: table;
}
.grid {
  display: grid;
}
.hidden {
  display: none;
}
.h-6 {
  height: 1.5rem;
}
.w-6 {
  width: 1.5rem;
}
.w-full {
  width: 100%;
}
.max-w-2xl {
  max-width: 42rem;
}
.max-w-3xl {
  max-width: 48rem;
}
.flex-1 {
  flex: 1 1 0%;
}
.grow {
  flex-grow: 1;
}
.transform {
  transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
}
.resize {
  resize: both;
}
.grid-cols-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr));
}
.grid-cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.flex-col {
  flex-direction: column;
}
.items-center {
  align-items: center;
}
.justify-center {
  justify-content: center;
}
.gap-2 {
  gap: 0.5rem;
}
.gap-3 {
  gap: 0.75rem;
}
.gap-4 {
  gap: 1rem;
}
.gap-6 {
  gap: 1.5rem;
}
.gap-8 {
  gap: 2rem;
}
.space-x-3 > :not([hidden]) ~ :not([hidden]) {
  --tw-space-x-reverse: 0;
  margin-right: calc(0.75rem * var(--tw-space-x-reverse));
  margin-left: calc(0.75rem * calc(1 - var(--tw-space-x-reverse)));
}
.space-x-4 > :not([hidden]) ~ :not([hidden]) {
  --tw-space-x-reverse: 0;
  margin-right: calc(1rem * var(--tw-space-x-reverse));
  margin-left: calc(1rem * calc(1 - var(--tw-space-x-reverse)));
}
.rounded {
  border-radius: 0.25rem;
}
.border {
  border-width: 1px;
}
.bg-accent {
  --tw-bg-opacity: 1;
  background-color: rgb(0 140 69 / var(--tw-bg-opacity, 1));
}
.bg-white {
  --tw-bg-opacity: 1;
  background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
}
.bg-gradient-to-r {
  background-image: linear-gradient(to right, var(--tw-gradient-stops));
}
.from-accent {
  --tw-gradient-from: #008C45 var(--tw-gradient-from-position);
  --tw-gradient-to: rgb(0 140 69 / 0) var(--tw-gradient-to-position);
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}
.to-safety-green {
  --tw-gradient-to: #008C45 var(--tw-gradient-to-position);
}
.p-6 {
  padding: 1.5rem;
}
.text-center {
  text-align: center;
}
.text-right {
  text-align: right;
}
.font-display {
  font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
}
.font-sans {
  font-family: 'Hanken Grotesk', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
.text-2xl {
  font-size: 1.5rem;
  line-height: 1.4;
}
.text-3xl {
  font-size: 1.875rem;
  line-height: 1.3;
}
.text-4xl {
  font-size: 2.25rem;
  line-height: 1.2;
}
.text-lg {
  font-size: 1.125rem;
  line-height: 1.6;
}
.text-sm {
  font-size: 0.875rem;
  line-height: 1.5;
}
.text-xl {
  font-size: 1.25rem;
  line-height: 1.6;
}
.font-bold {
  font-weight: 700;
}
.font-semibold {
  font-weight: 600;
}
.text-blue-100 {
  --tw-text-opacity: 1;
  color: rgb(219 234 254 / var(--tw-text-opacity, 1));
}
.text-blue-200 {
  --tw-text-opacity: 1;
  color: rgb(191 219 254 / var(--tw-text-opacity, 1));
}
.text-gray-600 {
  --tw-text-opacity: 1;
  color: rgb(75 85 99 / var(--tw-text-opacity, 1));
}
.text-white {
  --tw-text-opacity: 1;
  color: rgb(255 255 255 / var(--tw-text-opacity, 1));
}
.opacity-90 {
  opacity: 0.9;
}
.shadow {
  --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);
  box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}
.outline {
  outline-style: solid;
}
.filter {
  filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
}

/* ==========================================================================
   CSS Variables from Design Tokens
   ========================================================================== */

:root {
  /* Light theme (default) - All variables populated from design tokens */

  /* Font families — Source Serif 4 (display) + Hanken Grotesk (body/UI) */
  --font-sans: 'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue',
    Arial, sans-serif;
  --font-display: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* Backgrounds */
  --bg-primary: #fcfdfc;
  --bg-primary-rgb: 252, 253, 252;
  --bg-secondary: #f3f7f4;
  --bg-tertiary: #e7f4ec;
  --bg-overlay: #edf3ef;

  /* Surfaces / Cards */
  --card-bg: #ffffff;
  --card-hover: #f3f7f4;
  --card-border: #e2eae5;
  --card-shadow: 0 1px 2px rgba(20, 32, 26, 0.05), 0 8px 24px -12px rgba(20, 32, 26, 0.12);
  --card-shadow-hover: 0 2px 4px rgba(20, 32, 26, 0.06), 0 16px 36px -14px rgba(20, 32, 26, 0.18);

  /* Text Colors */
  --text-primary: #14201a;
  --text-secondary: #43544b;
  --text-tertiary: #6b7d73;
  --text-muted: #8a9c91;
  --text-on-accent: #ffffff;
  --text-on-dark: #ffffff;

  /* Borders */
  --border-default: #e2eae5;
  --border-strong: #c7d6cc;
  --border-muted: #edf3ef;

  /* Primary Accent - Logo green */
  --accent: #008c45;
  --accent-50: #f0faf4;
  --accent-100: #e7f4ec;
  --accent-200: #c9e8d6;
  --accent-300: #9ed8ba;
  --accent-400: #2fbf71;
  --accent-500: #16a34a;
  --accent-600: #008c45;
  --accent-700: #006f38;
  --accent-800: #005c2e;
  --accent-900: #0a3d22;

  /* Secondary Accent - Logo red (small accents only) */
  --secondary: #cd212a;
  --secondary-50: #fdf3f2;
  --secondary-100: #fbecea;
  --secondary-200: #f6d4d1;
  --secondary-300: #eeb0ac;
  --secondary-400: #e5484d;
  --secondary-500: #cd212a;
  --secondary-600: #a81a22;
  --secondary-700: #8a151d;
  --secondary-800: #6b1117;
  --secondary-900: #4c0c10;

  /* Semantic Colors */
  --success: #16a34a;
  --success-light: #dcfce7;
  --warning: #d97706;
  --warning-light: #fef3c7;
  --error: #cd212a;
  --error-light: #fbecea;
  --info: #008c45;
  --info-light: #e7f4ec;

  /* Gradients */
  --gradient-primary: linear-gradient(120deg, #008c45, #005c2e);
  --gradient-accent: linear-gradient(135deg, #008c45, #006f38);
  --gradient-hero: linear-gradient(160deg, #f4fbf6 0%, #fcfdfc 45%, #fbf3f2 100%);
  --gradient-hero-deep: linear-gradient(150deg, #0e1512 0%, #152019 55%, #0e1512 100%);

  /* Shadows — soft, ink-tinted (never pure black), low spread */
  --shadow-sm: 0 1px 2px rgba(20, 32, 26, 0.05);
  --shadow: 0 1px 2px rgba(20, 32, 26, 0.05), 0 8px 24px -12px rgba(20, 32, 26, 0.12);
  --shadow-md: 0 2px 4px rgba(20, 32, 26, 0.06), 0 16px 36px -14px rgba(20, 32, 26, 0.18);
  --shadow-lg: 0 12px 24px -6px rgba(20, 32, 26, 0.1), 0 4px 8px -4px rgba(20, 32, 26, 0.05);
  --shadow-xl: 0 24px 40px -10px rgba(20, 32, 26, 0.12), 0 8px 16px -8px rgba(20, 32, 26, 0.06);

  /* Focus ring (green, accessible) */
  --ring: 0 0 0 3px rgba(0, 140, 69, 0.18);

  --overlay: rgba(20, 32, 26, 0.7);
  --overlay-light: rgba(20, 32, 26, 0.5);

  /* Shape & motion */
  --radius: 14px;
  --radius-sm: 10px;
  --radius-full: 9999px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  --header-h: 72px;
}

[data-theme='dark'] {
  /* Dark theme - deep green-blacks; brighter green/red only for small accents */

  /* Backgrounds */
  --bg-primary: #0e1512;
  --bg-primary-rgb: 14, 21, 18;
  --bg-secondary: #111b15;
  --bg-tertiary: #12301f;
  --bg-overlay: #152019;

  /* Surfaces / Cards */
  --card-bg: #152019;
  --card-hover: #1b2a21;
  --card-border: #24342b;
  --card-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -12px rgba(0, 0, 0, 0.5);
  --card-shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.35), 0 16px 36px -14px rgba(0, 0, 0, 0.6);

  /* Text Colors */
  --text-primary: #e9f0eb;
  --text-secondary: #b4c4ba;
  --text-tertiary: #8a9c91;
  --text-muted: #64766b;
  --text-on-accent: #ffffff;
  --text-on-dark: #e9f0eb;

  /* Borders */
  --border-default: #24342b;
  --border-strong: #35483c;
  --border-muted: #1b2a21;

  /* Primary Accent - brighter green for dark surfaces */
  --accent: #2fbf71;
  --accent-50: #0f2a1b;
  --accent-100: #12301f;
  --accent-200: #1a4529;
  --accent-300: #27683f;
  --accent-400: #2fbf71;
  --accent-500: #4fd68a;
  --accent-600: #2fbf71;
  --accent-700: #4fd68a;
  --accent-800: #7ce3a6;
  --accent-900: #b8f0cf;

  /* Secondary Accent - brighter red for dark surfaces */
  --secondary: #e5484d;
  --secondary-50: #2f1215;
  --secondary-100: #3a171a;
  --secondary-200: #5c2024;
  --secondary-300: #7e2a2f;
  --secondary-400: #e5484d;
  --secondary-500: #f0636a;
  --secondary-600: #e5484d;
  --secondary-700: #f0636a;
  --secondary-800: #f49296;
  --secondary-900: #f9c1c3;

  /* Semantic Colors */
  --success: #4ade80;
  --success-light: #166534;
  --warning: #fbbf24;
  --warning-light: #78350f;
  --error: #e5484d;
  --error-light: #3a171a;
  --info: #2fbf71;
  --info-light: #12301f;

  /* Gradients */
  --gradient-primary: linear-gradient(120deg, #008c45, #005c2e);
  --gradient-accent: linear-gradient(135deg, #2fbf71, #008c45);
  --gradient-hero: linear-gradient(160deg, #0e1512 0%, #111b15 50%, #0e1512 100%);
  --gradient-hero-deep: linear-gradient(150deg, #0e1512 0%, #152019 55%, #0e1512 100%);

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -12px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.35), 0 16px 36px -14px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 12px 24px -6px rgba(0, 0, 0, 0.5), 0 4px 8px -4px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 24px 40px -10px rgba(0, 0, 0, 0.6), 0 8px 16px -8px rgba(0, 0, 0, 0.4);

  /* Focus ring */
  --ring: 0 0 0 3px rgba(47, 191, 113, 0.3);

  --overlay: rgba(0, 0, 0, 0.8);
  --overlay-light: rgba(0, 0, 0, 0.6);
}

/* ==========================================================================
   Base Styles
   ========================================================================== */

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  transition: background-color 0.25s ease, color 0.25s ease;
  /* Sticky footer: main grows so the footer sits at the bottom of short pages */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body > main {
  flex: 1 0 auto;
}

/* Fixed dot texture — a barely-there grid that stays put while the page
   scrolls. position:fixed keeps it out of the flex flow above; the negative
   z-index paints it over the body background but under all content. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(11, 61, 33, 0.5) 1px, transparent 1.2px);
  background-size: 22px 22px;
  opacity: 0.16;
}

[data-theme='dark'] body::before {
  background-image: radial-gradient(circle, rgba(180, 230, 200, 0.55) 1px, transparent 1.2px);
  opacity: 0.13;
}

/* Cursor spotlight — the same dot grid, brighter, revealed only through a mask
   of three soft circles. JS (initDotSpotlight) lerps those circles along a
   chain, each lagging further behind the cursor, which draws the tail. The
   opacity transition is what makes the tail fade out slowly once the pointer
   stops or leaves. Positions default off-screen so nothing shows until the
   first pointermove. */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(11, 61, 33, 0.9) 1px, transparent 1.2px);
  background-size: 22px 22px;
  opacity: 0;
  transition: opacity 0.65s ease-out;
  -webkit-mask-image: radial-gradient(
      circle 130px at var(--spot-x0, -999px) var(--spot-y0, -999px),
      #000 0%,
      rgba(0, 0, 0, 0.45) 55%,
      transparent 75%
    ),
    radial-gradient(
      circle 100px at var(--spot-x1, -999px) var(--spot-y1, -999px),
      rgba(0, 0, 0, 0.6) 0%,
      transparent 72%
    ),
    radial-gradient(
      circle 74px at var(--spot-x2, -999px) var(--spot-y2, -999px),
      rgba(0, 0, 0, 0.35) 0%,
      transparent 70%
    );
  mask-image: radial-gradient(
      circle 130px at var(--spot-x0, -999px) var(--spot-y0, -999px),
      #000 0%,
      rgba(0, 0, 0, 0.45) 55%,
      transparent 75%
    ),
    radial-gradient(
      circle 100px at var(--spot-x1, -999px) var(--spot-y1, -999px),
      rgba(0, 0, 0, 0.6) 0%,
      transparent 72%
    ),
    radial-gradient(
      circle 74px at var(--spot-x2, -999px) var(--spot-y2, -999px),
      rgba(0, 0, 0, 0.35) 0%,
      transparent 70%
    );
  -webkit-mask-composite: source-over;
  mask-composite: add;
}

body.spotlight-on::after {
  opacity: 0.5;
}

[data-theme='dark'] body::after {
  background-image: radial-gradient(circle, rgba(190, 240, 210, 0.95) 1px, transparent 1.2px);
}

[data-theme='dark'] body.spotlight-on::after {
  opacity: 0.42;
}

@media (prefers-reduced-motion: reduce) {
  body.spotlight-on::after {
    opacity: 0;
  }
}

img {
  max-width: 100%;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
  text-wrap: balance;
  margin: 0 0 0.5em;
}

h1 {
  font-size: clamp(2.1rem, 4vw, 3rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.75rem, 3.4vw, 2.4rem);
  font-weight: 700;
}

h3 {
  font-size: 1.25rem;
}

h4 {
  font-size: 1.125rem;
}

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

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

a:hover {
  color: var(--accent-700);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.container {
  width: 100%;
  max-width: 70rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (max-width: 640px) {
  .container {
    padding: 0 1.25rem;
  }
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.25;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease,
    border-color 0.15s ease, color 0.15s ease;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 6px 16px -6px rgba(0, 140, 69, 0.5);
}

.btn-primary:hover {
  background: var(--accent-700);
  color: #fff;
  transform: translateY(-1px);
}

[data-theme='dark'] .btn-primary {
  background: var(--accent-600);
  color: #062015;
}

[data-theme='dark'] .btn-primary:hover {
  background: var(--accent-500);
  color: #062015;
}

.btn-outline {
  background: transparent;
  border-color: var(--border-default);
  color: var(--text-primary);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}

/* Secondary — clean surface with border (hero pairing) */
.btn-secondary {
  background: var(--card-bg);
  border-color: var(--border-strong);
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}

/* CTA — surface card with accent border (style guide) */
.btn-cta {
  background-color: var(--card-bg);
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-cta:hover {
  background: var(--accent);
  color: #fff;
}

.btn-ghost {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--text-on-dark);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.btn-ghost:hover {
  background-color: rgba(255, 255, 255, 0.18);
  color: var(--text-on-dark);
}

.btn-sm {
  padding: 0.45rem 1.05rem;
  font-size: 0.925rem;
}

.btn-lg {
  padding: 0.9rem 1.9rem;
  font-size: 1.05rem;
}

/* ==========================================================================
   Header — sticky, blurred, two-tone active-nav underline
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(var(--bg-primary-rgb), 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-default);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-right: auto;
}

.brand:hover {
  color: var(--text-primary);
}

.brand img {
  width: 40px;
  height: 40px;
}

.brand .brand-accent {
  color: var(--accent);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.main-nav a {
  position: relative;
  padding: 0.5rem 0.8rem;
  font-size: 0.975rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: color 0.15s ease;
}

.main-nav a:hover {
  color: var(--text-primary);
}

.main-nav a.active {
  color: var(--accent);
  font-weight: 600;
}

.main-nav a.active::after {
  content: '';
  position: absolute;
  left: 0.8rem;
  right: 0.8rem;
  bottom: 0.1rem;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--accent) 55%, var(--secondary) 55%);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.icon-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* Theme toggle icon.
   Both icons ship in the markup and the theme decides which one is displayed,
   so the correct icon is painted on the first frame — the pre-paint bootstrap
   in <head> has already set data-theme. Nothing here is swapped by JS, so the
   icon cannot flash the way a JS-assigned one would. Each icon shows the theme
   the button switches TO. */
.theme-icon {
  line-height: 1;
}

.theme-icon--to-light {
  display: none;
}

[data-theme='dark'] .theme-icon--to-dark {
  display: none;
}

[data-theme='dark'] .theme-icon--to-light {
  display: inline;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 0.7rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-tertiary);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.lang-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.menu-toggle {
  display: none;
}

/* Mobile nav */
@media (max-width: 1023px) {
  .menu-toggle {
    display: inline-flex;
  }

  .main-nav,
  .header-actions .btn {
    display: none;
  }

  .mobile-menu {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-default);
    box-shadow: var(--card-shadow-hover);
    padding: 0.75rem 1.5rem 1.25rem;
  }

  .mobile-menu nav a {
    display: block;
    padding: 0.7rem 0.9rem;
    font-size: 1.02rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
  }

  .mobile-menu nav a:hover {
    color: var(--text-primary);
  }

  .mobile-menu nav a.active {
    color: var(--accent);
    font-weight: 600;
    background: var(--accent-100);
  }

  .mobile-menu .btn {
    margin-top: 0.75rem;
  }
}

@media (min-width: 1024px) {
  .mobile-menu {
    display: none;
  }
}

/* ==========================================================================
   Hero — logo, serif title, italic tagline, green/red glows
   ========================================================================== */

.hero {
  position: relative;
  overflow: hidden;
  padding: 6rem 0 5rem;
  text-align: center;
}

/* Logo-echo glow: green petals left, red petals right */
.hero::before,
.hero::after {
  content: '';
  position: absolute;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.26;
  pointer-events: none;
}

.hero::before {
  background: var(--accent);
  left: -160px;
  top: -120px;
  transform: translate3d(var(--glow-a-x, 0px), var(--glow-a-y, 0px), 0);
}

.hero::after {
  background: var(--secondary);
  right: -160px;
  bottom: -180px;
  transform: translate3d(var(--glow-b-x, 0px), var(--glow-b-y, 0px), 0);
}

/* Cursor repulsion is driven by JS (initHeroGlow); the easing lives there,
   so no CSS transition here — it would fight the rAF interpolation. */
@media (prefers-reduced-motion: reduce) {
  .hero::before,
  .hero::after {
    transform: none;
  }
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero-logo {
  width: clamp(140px, 15vw, 200px);
  height: auto;
  margin: 0 auto 1.75rem;
}

.hero-title {
  font-size: clamp(2.5rem, 5.5vw, 3.9rem);
  font-weight: 700;
  max-width: 18ch;
  margin: 0 auto 0.75rem;
}

.hero-tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.2rem, 2.4vw, 1.5rem);
  font-weight: 500;
  color: var(--accent);
  margin: 0 auto 1.25rem;
}

.hero-sub {
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  color: var(--text-secondary);
  max-width: 56ch;
  margin: 0 auto 1rem;
}

.hero-ctas {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

/* Page hero (interior pages) */
.page-hero {
  position: relative;
  overflow: hidden;
  padding: 4.5rem 0 3.5rem;
  border-bottom: 1px solid var(--border-default);
  background: var(--bg-secondary);
}

.page-hero::before,
.page-hero::after {
  content: '';
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.12;
  pointer-events: none;
}

.page-hero::before {
  background: var(--accent);
  left: -140px;
  top: -160px;
}

.page-hero::after {
  background: var(--secondary);
  right: -140px;
  bottom: -220px;
}

.page-hero .container {
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  margin-bottom: 0.6rem;
}

.page-hero .lede,
.lede {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 62ch;
  margin-bottom: 0;
}

/* ==========================================================================
   Sections & eyebrows
   ========================================================================== */

.section {
  padding: 4.5rem 0;
  background-color: var(--bg-primary);
  color: var(--text-primary);
}

.section-alt {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-default);
  border-bottom: 1px solid var(--border-default);
}

.section-head {
  max-width: 640px;
  margin-bottom: 2.75rem;
}

.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section-head h2 {
  margin-bottom: 0.5rem;
}

.section-head p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  margin-bottom: 0;
}

/* Two-tone eyebrow echoing the logo petals */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 0.9rem;
}

.eyebrow::before {
  content: '';
  width: 26px;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--accent) 62%, var(--secondary) 62%);
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border-default);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--card-shadow);
  color: var(--text-primary);
  height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--accent-200);
}

.card h3 {
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-secondary);
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--accent-100);
  color: var(--accent);
  margin-bottom: 1.1rem;
}

.card-icon svg {
  width: 24px;
  height: 24px;
}

.card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-footer {
  padding-top: 1rem;
  border-top: 1px solid var(--border-muted);
  margin-top: auto;
}

/* News cards — red uppercase date chip */
.news-card {
  display: flex;
  flex-direction: column;
}

.news-date {
  align-self: flex-start;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--secondary);
  background: var(--secondary-100);
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-full);
  margin-bottom: 1rem;
}

.news-link {
  margin-top: auto;
  padding-top: 1.1rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.news-link svg {
  width: 16px;
  height: 16px;
  transition: transform 0.15s ease;
}

.news-link:hover svg {
  transform: translateX(3px);
}

/* ==========================================================================
   Split (challenge / solution) — colored top borders
   ========================================================================== */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

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

.split-card {
  border-radius: var(--radius);
  padding: 2.25rem;
  border: 1px solid var(--border-default);
  background: var(--card-bg);
  box-shadow: var(--card-shadow);
}

.split-card h2,
.split-card h3 {
  font-size: 1.6rem;
}

.split-card p {
  color: var(--text-secondary);
}

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

.split-card.accent-green {
  border-top: 4px solid var(--accent);
}

.split-card.accent-red {
  border-top: 4px solid var(--secondary);
}

/* ==========================================================================
   CTA band — translucent deep-green gradient + red corner glow + white button.
   The green stops sit at 85% alpha so the page shows through. Because that
   composites toward the page background, the stops are darker in light mode
   and lighter in dark mode — both tuned so white text stays ≥ WCAG AA
   (≥4.5:1) over bg-primary and bg-secondary alike. Never use the raw
   bright dark-mode green here.
   ========================================================================== */

.cta-band {
  position: relative;
  overflow: hidden;
  background: radial-gradient(
      720px 470px at 95% 128%,
      rgba(229, 72, 77, 0.6),
      rgba(229, 72, 77, 0) 72%
    ),
    linear-gradient(120deg, rgba(0, 110, 52, 0.85) 0%, rgba(0, 84, 40, 0.85) 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 3.5rem 2.5rem;
  text-align: center;
}

[data-theme='dark'] .cta-band {
  background: radial-gradient(
      720px 470px at 95% 128%,
      rgba(229, 72, 77, 0.6),
      rgba(229, 72, 77, 0) 72%
    ),
    linear-gradient(120deg, rgba(0, 140, 67, 0.85) 0%, rgba(0, 110, 54, 0.85) 100%);
}

.cta-band h2 {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  color: #fff;
  margin-bottom: 0.6rem;
}

.cta-band p {
  color: #fff;
  max-width: 52ch;
  margin: 0 auto 1.75rem;
  position: relative;
  z-index: 1;
}

.cta-band .btn {
  position: relative;
  z-index: 1;
  background: #fff;
  color: #006f38;
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.35);
}

.cta-band .btn:hover {
  color: #005c2e;
  transform: translateY(-1px);
}

/* ==========================================================================
   Team — avatar/initials head, green contribution tags, red interest tags
   ========================================================================== */

.team-card {
  display: flex;
  flex-direction: column;
}

.team-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.team-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  -o-object-fit: cover;
     object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--accent-100);
}

.team-initials {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-700));
}

.team-initials.red {
  background: linear-gradient(135deg, var(--secondary), var(--secondary-600));
}

.team-head h3 {
  margin: 0;
  font-size: 1.2rem;
}

.team-role {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0.1rem 0 0;
}

.team-card > p {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.tag-group {
  margin-top: 0.4rem;
}

.tag-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 0.4rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.tag {
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.22rem 0.7rem;
  border-radius: var(--radius-full);
  background: var(--accent-100);
  color: var(--accent-700);
  border: 1px solid var(--accent-200);
}

.tag.red {
  background: var(--secondary-100);
  color: var(--secondary-600);
  border-color: var(--secondary-200);
}

.team-links {
  margin-top: auto;
  padding-top: 1.1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-weight: 600;
  font-size: 0.95rem;
}

/* ==========================================================================
   Members table — clean bordered table
   ========================================================================== */

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-default);
  border-radius: var(--radius);
  background: var(--card-bg);
  box-shadow: var(--card-shadow);
}

.table-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.table-wrap th,
.table-wrap td {
  text-align: left;
  padding: 0.9rem 1.25rem;
  vertical-align: top;
}

.table-wrap thead th {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-default);
}

.table-wrap tbody tr + tr td {
  border-top: 1px solid var(--border-default);
}

.table-wrap tbody tr:hover {
  background: var(--bg-secondary);
}

.member-initial {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), var(--accent-700));
}

.member-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  font-size: 0.85rem;
}

.table-note {
  color: var(--text-tertiary);
  font-size: 0.95rem;
  margin-top: 0.75rem;
}

/* ==========================================================================
   Chips & badges
   ========================================================================== */

.chip {
  align-self: flex-start;
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-full);
  margin-bottom: 1rem;
  background: var(--accent-100);
  color: var(--accent-700);
}

.chip.red {
  background: var(--secondary-100);
  color: var(--secondary-600);
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-primary {
  background-color: var(--accent-100);
  color: var(--accent-700);
}

.badge-info {
  background-color: var(--bg-tertiary);
  color: var(--text-secondary);
}

.badge-success {
  background-color: var(--success-light);
  color: var(--success);
}

/* ==========================================================================
   Program details (initiatives)
   ========================================================================== */

.program-card h3 {
  font-size: 1.35rem;
}

.program-meta {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.6rem;
}

.program-meta li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.95rem;
  color: var(--text-secondary);
  border-top: 1px dashed var(--border-default);
  padding-top: 0.6rem;
}

.program-meta strong {
  color: var(--text-primary);
  min-width: 96px;
  flex-shrink: 0;
}

/* ==========================================================================
   FAQ accordion
   ========================================================================== */

.faq-group {
  margin-bottom: 2.5rem;
}

.faq-item {
  background: var(--card-bg);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  margin-bottom: 0.75rem;
  overflow: hidden;
  transition: border-color 0.15s ease;
}

.faq-item[open] {
  border-color: var(--accent-300);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.05rem 1.25rem;
  font-weight: 600;
  font-size: 1.02rem;
  cursor: pointer;
  list-style: none;
  color: var(--text-primary);
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:hover {
  color: var(--accent);
}

.faq-chevron {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent-100);
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}

.faq-chevron svg {
  width: 14px;
  height: 14px;
}

.faq-item[open] .faq-chevron {
  transform: rotate(45deg);
}

.faq-body {
  padding: 0 1.25rem 1.15rem;
  color: var(--text-secondary);
}

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

/* ==========================================================================
   Contact — side methods + form card
   ========================================================================== */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

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

.contact-side h2 {
  font-size: 1.6rem;
}

.contact-side p {
  color: var(--text-secondary);
}

.contact-methods {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.contact-method {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  background: var(--card-bg);
  font-weight: 600;
  color: var(--text-primary);
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.contact-method:hover {
  border-color: var(--accent);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.contact-method svg {
  width: 20px;
  height: 20px;
  color: var(--accent);
  flex-shrink: 0;
}

.contact-form {
  display: grid;
  gap: 1.1rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}

@media (max-width: 640px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.form-input {
  width: 100%;
  padding: 0.8rem 1rem;
  font: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  background: var(--bg-primary);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--ring);
}

.form-input::-moz-placeholder {
  color: var(--text-muted);
}

.form-input::placeholder {
  color: var(--text-muted);
}

textarea.form-input {
  resize: vertical;
  min-height: 140px;
}

.form-note {
  font-size: 0.9rem;
  color: var(--text-tertiary);
  margin: 0;
}

/* ==========================================================================
   Animated map of Italy — About page

   Sequence on scroll: the coastline draws itself in, the fill washes up
   behind it, the network knits together link by link, the dots drop in, and
   then it settles into a loop where a bright packet keeps travelling along
   every link and each dot breathes. Everything keys off .is-visible, added
   by the shared scroll-reveal observer in base.njk.
   ========================================================================== */

.map-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 3.25rem;
  align-items: center;
}

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

.map-figure {
  margin: 0;
  text-align: center;
}

.italy-map {
  width: 100%;
  max-width: 380px;
  height: auto;
  overflow: visible;
}

/* --- Coastline ---
   Each path carries pathLength="1" in the markup, so its length is
   normalised to 1 and this single dash rule drives all three rings. */
.italy-shape {
  fill: var(--accent-100);
  stroke: url(#italyStroke);
  stroke-width: 1.5;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  fill-opacity: 0;
}

.map-figure.is-visible .italy-shape {
  animation: italy-draw 1.5s ease-in-out forwards, italy-fill 0.9s ease 1s forwards;
}

.map-figure.is-visible .italy-sardinia {
  animation-delay: 0.35s, 1.2s;
}

.map-figure.is-visible .italy-sicily {
  animation-delay: 0.5s, 1.3s;
}

@keyframes italy-draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes italy-fill {
  to {
    fill-opacity: 1;
  }
}

/* --- Network links ---
   Two layers per link. The base line is a constant faint red. Over it, a long
   blurred dash travels the same curve, so brightness swells and fades as it
   passes: a moving breath rather than a hard packet driving along the route.
   Each link is given its own phase so the graph shimmers instead of blinking
   in unison. */
.map-link {
  fill: none;
  stroke: var(--secondary);
  stroke-width: 1;
  stroke-opacity: 0;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}

.map-figure.is-visible .map-link {
  animation: link-draw 0.7s ease-out forwards;
  animation-delay: calc(1.5s + var(--link-index) * 0.07s);
}

@keyframes link-draw {
  from {
    stroke-dashoffset: 1;
    stroke-opacity: 0;
  }
  to {
    stroke-dashoffset: 0;
    stroke-opacity: 0.22;
  }
}

.map-link-wave {
  fill: none;
  stroke: var(--secondary);
  stroke-width: 1.8;
  stroke-linecap: round;
  /* a long lit stretch, not a dot, so it reads as a swell of brightness */
  stroke-dasharray: 0.4 0.6;
  stroke-dashoffset: 1;
  filter: url(#linkGlow);
  opacity: 0;
}

.map-figure.is-visible .map-link-wave {
  animation: link-breath 5.4s ease-in-out infinite;
  animation-delay: calc(2.2s + var(--link-index) * 0.31s);
}

@keyframes link-breath {
  0% {
    stroke-dashoffset: 1;
    opacity: 0;
  }
  25% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.75;
  }
  75% {
    opacity: 0.45;
  }
  100% {
    stroke-dashoffset: 0;
    opacity: 0;
  }
}

/* --- Dots --- */
.map-pin {
  opacity: 0;
  transform-origin: center;
  transform-box: fill-box;
}

.map-figure.is-visible .map-pin {
  animation: pin-in 0.55s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: calc(1.75s + var(--pin-index) * 0.1s);
}

@keyframes pin-in {
  from {
    opacity: 0;
    transform: scale(0.2);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.map-pin-dot {
  fill: var(--secondary);
  stroke: var(--bg-secondary);
  stroke-width: 1.4;
  filter: url(#pinGlow);
}

.map-pin-halo {
  fill: none;
  stroke: var(--secondary);
  stroke-width: 1.2;
  transform-origin: center;
  transform-box: fill-box;
  opacity: 0;
}

.map-figure.is-visible .map-pin-halo {
  animation: pin-halo 3s ease-out infinite;
  animation-delay: calc(2.3s + var(--pin-index) * 0.22s);
}

@keyframes pin-halo {
  0% {
    opacity: 0.55;
    transform: scale(1);
  }
  70%,
  100% {
    opacity: 0;
    transform: scale(3.4);
  }
}

/* Motion is decorative here, so drop straight to the finished state. */
@media (prefers-reduced-motion: reduce) {
  .italy-shape,
  .map-figure.is-visible .italy-shape {
    animation: none;
    stroke-dashoffset: 0;
    fill-opacity: 1;
  }

  .map-link,
  .map-figure.is-visible .map-link {
    animation: none;
    stroke-dashoffset: 0;
    stroke-opacity: 0.28;
  }

  .map-link-wave,
  .map-figure.is-visible .map-link-wave {
    animation: none;
    opacity: 0;
  }

  .map-pin,
  .map-figure.is-visible .map-pin {
    animation: none;
    opacity: 1;
  }

  .map-pin-halo,
  .map-figure.is-visible .map-pin-halo {
    animation: none;
    opacity: 0;
  }
}

/* ==========================================================================
   Resource groups
   ========================================================================== */

.resource-group {
  margin-bottom: 3rem;
}

.resource-group h2,
.resource-group-title {
  font-size: 1.45rem;
  margin-bottom: 1.25rem;
}

.resource-intro {
  max-width: 46rem;
  margin-bottom: 2.5rem;
}

.resource-intro h2 {
  margin-bottom: 0.75rem;
}

/* Resource cards — logo tile above/beside the title */
.resource-card-head {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 0.85rem;
}

.resource-card-titles {
  min-width: 0;
}

.resource-card-head h3 {
  margin-bottom: 0;
  font-size: 1.1rem;
  line-height: 1.3;
}

/* Logos are third-party marks of many shapes, several dark-on-transparent.
   The tile keeps a light backdrop in both themes so every mark stays legible. */
.resource-logo {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid var(--border-muted);
  overflow: hidden;
}

.resource-logo img {
  width: 100%;
  height: 100%;
  -o-object-fit: contain;
     object-fit: contain;
  display: block;
}

.resource-logo-mono {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: var(--accent);
  background: var(--accent-100);
  border-color: transparent;
}

.resource-country {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0;
  margin-top: 0.15rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ==========================================================================
   Footer — green-white-red dots
   ========================================================================== */

.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-default);
  padding: 3.5rem 0 2rem;
  color: var(--text-secondary);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

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

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.9rem;
  color: var(--text-primary);
}

.footer-brand img {
  width: 34px;
  height: 34px;
}

.footer-brand strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
}

.site-footer p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 40ch;
}

.site-footer h4 {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 0.9rem;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid var(--border-default);
  padding-top: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: var(--text-tertiary);
}

.footer-flag {
  display: inline-flex;
  gap: 3px;
}

.footer-flag i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: block;
}

.footer-flag i:nth-child(1) {
  background: var(--accent);
}

.footer-flag i:nth-child(2) {
  background: var(--card-bg);
  border: 1px solid var(--border-strong);
}

.footer-flag i:nth-child(3) {
  background: var(--secondary);
}

/* ==========================================================================
   Typography helpers
   ========================================================================== */

/* Elegant lead paragraph — serif, large, balanced (About mission prose) */
.lead-text {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  line-height: 1.5;
  color: var(--text-primary);
  text-wrap: balance;
  margin: 0;
}

.accent-text {
  color: var(--accent);
  font-weight: 600;
}

/* Inline line-icon (Lucide via <use>) */
.ds-icon {
  width: 1.85rem;
  height: 1.85rem;
  display: block;
  stroke: currentColor;
}

/* ==========================================================================
   Utility classes
   ========================================================================== */

.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: var(--card-shadow);
}

.hover-lift:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
}

.focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.divider {
  height: 1px;
  margin: 3rem 0;
  background: var(--border-default);
}

.stat-box {
  border-radius: var(--radius);
  padding: 1.5rem;
  border: 1px solid var(--card-border);
  text-align: center;
  background-color: var(--card-bg);
  color: var(--text-primary);
  box-shadow: var(--card-shadow);
  transition: box-shadow 0.2s ease;
}

.stat-box:hover {
  box-shadow: var(--card-shadow-hover);
}

.stat-number {
  font-size: 1.875rem;
  font-weight: 800;
  color: var(--accent);
}

.testimonial {
  padding: 1.5rem;
  border-radius: var(--radius-sm);
  background-color: var(--card-hover);
  border: 1px solid var(--card-border);
  border-left: 4px solid var(--accent);
  color: var(--text-primary);
  box-shadow: var(--card-shadow);
}

.membership-card {
  border-radius: var(--radius);
  padding: 1.5rem;
  border: 1px solid var(--card-border);
  background-color: var(--card-bg);
  color: var(--text-primary);
  box-shadow: var(--card-shadow);
  transition: box-shadow 0.2s ease;
}

.membership-card:hover {
  box-shadow: var(--card-shadow-hover);
}

/* ==========================================================================
   Reveal on scroll (JS adds .is-visible, staggered per sibling group)
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.55s ease, transform 0.55s ease;
    will-change: opacity, transform;
  }

  .reveal.is-visible {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* ==========================================================================
   Loading animation
   ========================================================================== */

.loading {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

/* ==========================================================================
   Blockquote, code, pre
   ========================================================================== */

blockquote {
  color: var(--text-primary);
  border-left: 4px solid var(--accent);
  background-color: var(--card-hover);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 1rem;
  margin: 1rem 0;
}

code {
  color: var(--accent);
  background-color: var(--bg-tertiary);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-size: 0.875em;
  font-family: var(--font-mono);
}

pre {
  background-color: var(--bg-secondary);
  padding: 1rem;
  border-radius: var(--radius-sm);
  overflow-x: auto;
  border: 1px solid var(--card-border);
}

pre code {
  color: var(--text-primary);
  background: none;
  padding: 0;
  border-radius: 0;
}

/* ==========================================================================
   Small screens polish
   ========================================================================== */

@media (max-width: 640px) {
  .brand {
    font-size: 1.02rem;
    gap: 0.5rem;
  }

  .brand img {
    width: 34px;
    height: 34px;
  }

  .hero {
    padding: 4rem 0 3.5rem;
  }

  .section {
    padding: 3.25rem 0;
  }

  .cta-band {
    padding: 2.5rem 1.5rem;
  }

  .split-card {
    padding: 1.75rem;
  }
}

.focus\:not-sr-only:focus {
  position: static;
  width: auto;
  height: auto;
  padding: 0;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

.focus\:absolute:focus {
  position: absolute;
}

.focus\:left-4:focus {
  left: 1rem;
}

.focus\:top-4:focus {
  top: 1rem;
}

.focus\:z-50:focus {
  z-index: 50;
}

.focus\:rounded-md:focus {
  border-radius: 0.5rem;
}

.focus\:px-4:focus {
  padding-left: 1rem;
  padding-right: 1rem;
}

.focus\:py-2:focus {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.focus\:text-sm:focus {
  font-size: 0.875rem;
  line-height: 1.5;
}

@media (min-width: 640px) {

  .sm\:w-auto {
    width: auto;
  }

  .sm\:flex-row {
    flex-direction: row;
  }
}

@media (min-width: 768px) {

  .md\:grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .md\:grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .md\:grid-cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .md\:text-2xl {
    font-size: 1.5rem;
    line-height: 1.4;
  }

  .md\:text-4xl {
    font-size: 2.25rem;
    line-height: 1.2;
  }
}

@media (min-width: 1024px) {

  .lg\:flex {
    display: flex;
  }

  .lg\:grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .lg\:grid-cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
