/* ==========================================================================
   Design tokens
   Single source of truth for colour, type, spacing and layout values.
   Components must reference these variables instead of raw values.
   Design reference width: 1920px (Figma frame).
   ========================================================================== */

@font-face {
  font-family: "Geom";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../assets/fonts/Geom-VariableFont_wght.woff2") format("woff2");
}

@font-face {
  font-family: "Geom";
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url("../assets/fonts/Geom-Italic-VariableFont_wght.woff2") format("woff2");
}

:root {
  /* ---- Typography -------------------------------------------------------- */
  --font-family: "Geom", "Avenir Next", Avenir, Arial, sans-serif;

  --font-weight-light: 300;
  --font-weight-regular: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  /* Fluid sizes: clamp(min, value at 1920px expressed in vw, max) */
  --font-size-display: clamp(42px, 3.0208vw, 58px); /* hero h1        */
  --font-size-h2: clamp(34px, 2.1875vw, 42px);      /* section titles */
  --font-size-h3: clamp(18px, 1.25vw, 24px);        /* card titles    */
  --font-size-stat: clamp(38px, 2.5vw, 48px);       /* highlight nums */
  --font-size-hashtag: 20px;
  --font-size-lead-lg: 24px;                        /* about band lead, large video title */
  --font-size-body-lg: 20px;                        /* section leads  */
  --font-size-nav: 16px;
  --font-size-button: 16px;
  --font-size-base: 16px;
  --font-size-sm: 14px;

  --line-height-tight: 1.1;
  --line-height-heading: 1.138;
  --line-height-body: 1.5;

  --letter-spacing-tight: -0.01em;
  --letter-spacing-nav: 0.02em;

  /* ---- Type scale: four sizes (Δράσεις page and newer components) ---------
     Every text on the page uses one of these; hierarchy inside a size comes
     from weight and colour, not from another size. Two of them are the
     global components' own sizes: 20 = FAQ question, 15 = FAQ answer.
       xl  section titles (h2)                        42 (32 on phones), 400
       lg  lead, card titles, key numbers              20, 400 / 600
       md  text, meta (date / place), buttons, pills   15, 400 / 500 / 600
       sm  labels, statuses, captions, small nav       13, 500 / 600
     Line heights: 1.25 titles, 1.4 single lines and card titles, 1.6 prose.
     All-caps labels are sm, bold, +0.05em. */
  --text-xl: var(--font-size-h2);
  --text-lg: 20px;
  --text-md: 15px;
  --text-sm: 13px;
  --leading-title: 1.25;
  --leading-snug: 1.4;
  --leading-prose: 1.6;
  --letter-spacing-caps: 0.05em;

  /* ---- Colour palette (raw values from Figma) ---------------------------- */
  --navy-975: #0b1a3c;
  --navy-950: #071639;
  --navy-900: #04244a;
  --navy-700: #013c81;
  --slate-600: #3d6376;
  --slate-500: #56708f; /* was #617c9b: 5.1:1 on white */
  --slate-400: #7490b1;
  --teal-500: #5288a3;
  --teal-300: #71a4bd;

  /* NOTE: three very close blues exist in the Figma file.
     Kept separate until design confirms whether they should be one colour. */
  --blue-500: #0f62fe;
  --blue-550: #0d67e7;
  --blue-600: #0e63d8;
  --blue-700: #0d57df;
  --blue-900: #0031a7;
  --blue-300: #87b9ff;
  --blue-100: #d9e6ff;
  --blue-75: #eaf2ff; /* one light blue (was #e4f2fb) */
  --blue-50: #f3f7ff;

  --gray-25: #f9fbfc; /* unified with gray-40 (was #fbfcfd) */
  --gray-40: #f9fbfc;
  --gray-50: #f9fbfc; /* unified with gray-40 (was #f8fafb) */
  --gray-200: #dfe8f2;
  --gray-300: #b8c8dc;

  --white: #ffffff;
  --black: #000000;

  /* ---- Semantic colours (use these in components) ------------------------ */
  --color-heading: var(--navy-900);
  --color-heading-strong: var(--navy-900);  /* step titles */
  --color-text: var(--slate-500);
  --color-text-muted: var(--slate-500);
  --color-text-topbar: var(--slate-600);
  --color-nav-link: var(--navy-900);
  --color-icon: var(--navy-700);

  --color-primary: var(--blue-500);
  --color-primary-hover: var(--blue-700);
  --color-primary-ring: var(--blue-100);
  --color-highlight: var(--blue-500);   /* coloured words inside headings */
  --color-stat: var(--blue-500);        /* stat numbers, hashtag          */

  --color-bg: var(--white);
  --color-bg-hero: var(--gray-25);
  --color-bg-band: var(--gray-50);
  --color-bg-board: var(--gray-40);
  --color-bg-dark: var(--navy-975);          /* events band */
  --color-link-on-dark: var(--blue-300);
  --color-bg-active: var(--blue-75);                 /* selected list item */
  --color-video-shade: #000f20;               /* caption shade on video */
  --color-video-speaker: var(--blue-300);
  --color-faq-divider: #e4ebf2;
  --color-breadcrumb: #cfd8de;               /* breadcrumb on photos */
  --color-benefit-text: #667f9e;             /* benefit card text */
  --color-faq-answer: var(--color-text);
  --gradient-newsletter: linear-gradient(90deg, var(--blue-900), var(--blue-500));

  /* ---- Footer -------------------------------------------------------------- */
  --color-footer-bg: var(--navy-975);
  --color-footer-heading: var(--blue-300);
  --color-footer-text: rgb(255 255 255 / 72%);
  --color-footer-line: rgb(255 255 255 / 15%);
  --color-icon-bg: var(--blue-75);
  /* Pillar page courses table (Figma 82:2538) */
  --color-filter-bg: #f1f6fa;
  --color-filter-text: #7489a7;
  --color-row-bg: #f8fafb;
  --color-row-bg-tinted: #eef3f8;        /* course rows on the faint chapter background (pillar page) */
  --color-row-bg-tinted-hover: #e4ecf5;
  --color-row-number-bg: #eaf6fd;
  --color-table-head: #173d70;
  --color-table-rule: #dce7f1;
  --color-scroll-track: #c1c9d8;
  --color-scroll-thumb: #235ca2;
  /* Module colours inside a pillar (dots, filter icons) */
  --module-1: #2b8cf0;
  --module-2: #ff633f;
  --module-3: #38a16f;
  --module-4: #8245d6;
  --color-ink-soft: #3d4b66;                     /* body text on white, 9:1 */
  --color-rule: #e3e9f0;
  --color-progress: var(--blue-300);            /* reading progress (pillar v2 rail) */                         /* hairlines between chapters and rows */
  --color-eyebrow-light: #a5d6ff;               /* small uppercase label on dark bands */
  /* Δράσεις: key-figures strip */
  --color-stat-value: var(--color-event-title);
  --color-stat-label: #41516a;
  --color-stat-divider: #dde3e7;
  --gradient-stats: linear-gradient(90deg, #fffbf0 0%, #eef8ff 58%, #f1f7fa 100%);
  /* Δράσεις: region map and event card */
  --gradient-map: linear-gradient(127.13deg, #0b1a3c 15.5%, #0b2766 77.29%);
  --color-region: #405c83;
  --color-region-hover: #55749f;
  --color-region-active: #66a5ff;
  --color-map-dot: var(--blue-300);            /* workshop cities (not selected) */
  --color-event-title: #08183a;
  --color-event-text: #62718d;
  --color-event-muted: #8590a5;
  --color-event-rule: #e8ecf2;
  /* Δράσεις: workshop cards */
  --color-card-bg: #f9fbfc;
  --color-card-badge: #f8fafd;
  --color-card-ink: var(--color-event-title); /* one title ink on all event cards (was #071431) */
  --color-card-link: var(--blue-500);
  --color-card-button: var(--blue-75);
  /* Forms (form-field.css) and the registration drawer */
  --color-form-border: #d3dce6;
  --color-form-error: #c62f3a;                   /* 5.6:1 on white */
  --color-form-error-ring: rgb(198 47 58 / 16%);
  --color-drawer-backdrop: rgb(4 18 43 / 55%);
  /* Δράσεις: conference cards (Figma 128:631) */
  --color-conference-border: #d5e9f7;
  --color-conference-date: #123d7e;              /* date block, 1st card */
  --color-conference-date-alt: #2469f3;          /* date block, 2nd card; "ΣΥΝΕΔΡΙΟ" badge */
  --color-conference-tag: #f1f4f8;
  --color-conference-text: var(--color-event-text);   /* same greys as the other event cards */
  --color-conference-title: var(--color-event-title);
  --shadow-conference: 0 4px 18px rgb(90 136 178 / 8%);
  --color-logo-panel: #eef3f7;                   /* light panel behind a partner logo (Moodle) */
  --shadow-float: 0 2px 15px rgb(4 36 74 / 15%); /* small white card floating over a photo */
  --color-band-blue: var(--blue-500);             /* blue feature band */
  --color-band-tint: rgb(14 99 216 / 51%);       /* photo overlay (multiply) */
  --color-bg-hover: var(--blue-50);

  --color-border: var(--gray-200);
  --color-border-header: rgb(116 144 177 / 10%);
  --color-border-input: var(--gray-300);
  --color-divider: rgb(82 136 163 / 15%);   /* teal-500 @ 15% */
  --color-rule: rgb(116 144 177 / 10%);     /* slate-400 @ 10% */
  --color-dot: var(--teal-500);

  /* ---- Pillar themes ------------------------------------------------------ */
  --pillar-blue-accent: var(--blue-500);
  --pillar-blue-dot: var(--blue-500);
  --pillar-blue-bg: #ecfaff;
  --pillar-blue-tag-bg: #daf0f8;
  --pillar-blue-tag-text: #2f5889;
  --pillar-blue-count: var(--blue-500);

  --pillar-orange-accent: #ff8800;
  --pillar-orange-strong: #ff793f;  /* pillar page CTA + heading highlight */
  --pillar-orange-bg: #fff8f0;
  --pillar-orange-tag-bg: #ffedd9;
  --pillar-orange-badge-bg: #fdead4; /* pillar page module badge */
  --pillar-orange-tag-text: #8a4500;

  --pillar-green-accent: #007728;
  --pillar-green-bg: #effbf0;
  --pillar-green-tag-bg: #cfecd1;
  --pillar-green-tag-text: #1f6a35;

  --pillar-gray-accent: #595d61;
  --pillar-gray-bg: #f3f3f3;
  --pillar-gray-tag-bg: #e6e6e6;
  --pillar-gray-tag-text: #838383;

  /* ---- Audience cards (company size) -------------------------------------- */
  --audience-sky-bg: #cbe5ff;
  --audience-sky-text: var(--navy-900);
  --audience-sky-label: #3b5d8f;
  --audience-white-label: var(--slate-500);
  --audience-primary-label: var(--white);

  /* ---- Effects ------------------------------------------------------------ */
  --shadow-topbar: 0 3px 10px rgb(10 73 211 / 8%);
  --shadow-menu: 0 18px 45px rgb(4 36 74 / 14%);
  --shadow-button-hover: 0 10px 24px rgb(15 98 254 / 24%);
  --shadow-icon-hover: 0 8px 18px rgb(4 36 74 / 16%);
  --focus-ring: 3px solid rgb(15 98 254 / 35%);

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-pill: 999px;

  --transition-fast: 180ms ease;
  --transition-panel: 240ms ease;

  /* ---- Layout ------------------------------------------------------------- */
  --container-max: 1520px;
  /* 200px at 1920 (Figma), tapering faster below so the header fits */
  --page-padding: clamp(24px, calc(26.04vw - 300px), 200px);

  --topbar-height: 38px;
  --navbar-height: 127px;

  --z-header: 50;
  --z-dropdown: 20;
  --z-search: 25;
  --z-menu: 30;
  --z-skip-link: 100;

  /* Breakpoints — CSS cannot use variables inside @media, so these values are
     repeated in the media queries. JS reads --breakpoint-nav. Keep in sync. */
  --breakpoint-xl: 1600px;  /* compact header: smaller logo, no social icons */
  --breakpoint-nav: 1280px; /* hamburger / off-canvas navigation             */
  --breakpoint-md: 1100px;  /* tablet layout                                 */
  --breakpoint-sm: 700px;   /* phone                                         */
}

/* ---- Pillar themes -------------------------------------------------------
   Put one of these on a pillar page (e.g. <body> or <main>). Components use
   --accent (number, tabs), --accent-strong (CTA, heading highlight; falls back
   to --accent) and --accent-soft (tinted backgrounds), so one class recolours
   the whole page. */
.theme-pillar--blue {
  --accent: var(--pillar-blue-accent);
  --accent-soft: var(--pillar-blue-bg);
}

.theme-pillar--orange {
  --accent: var(--pillar-orange-accent);
  --accent-strong: var(--pillar-orange-strong);
  --accent-soft: var(--pillar-orange-bg);
  --accent-tint: var(--pillar-orange-badge-bg);
  --accent-ink: #c2500a; /* text-safe orange (4.7:1 on white) for links, buttons, small text */
}

.theme-pillar--green {
  --accent: var(--pillar-green-accent);
  --accent-soft: var(--pillar-green-bg);
}

.theme-pillar--gray {
  --accent: var(--pillar-gray-accent);
  --accent-soft: var(--pillar-gray-bg);
}

/* Sticky header after scrolling (js/site-header.js) */
:root.is-header-compact {
  --navbar-height: 72px;
}

@media (max-width: 1280px) {
  :root {
    --navbar-height: 94px;
  }

  /* Sticky header after scrolling (js/site-header.js) */
  :root.is-header-compact {
    --navbar-height: 60px;
  }
}

@media (max-width: 1100px) {
  :root {
    --page-padding: clamp(24px, 5vw, 56px);
  }
}

@media (max-width: 700px) {
  :root {
    --topbar-height: 34px;
    --navbar-height: 82px;
    --text-xl: 32px; /* section titles on phones (type scale) */
  }

  :root.is-header-compact {
    --navbar-height: 54px;
  }
}
