/**
 * V.F. Stampi — Colors & Type
 * Foundation tokens (base + semantic) for the design system.
 *
 * Sources:
 *  - uploads/vfstampi-design-tokens.css (official spec)
 *  - vfstampi.com/css/skins/skin-construction.css (production site)
 *  - vfstampi.com/index.html (Google Fonts: Open Sans 300/400/600/700/800)
 *
 * Note: the brand spec calls for AVENIR NEXT, but the live website uses
 * OPEN SANS from Google Fonts. We expose both via --font-display (Avenir
 * Next, used for print + brand-forward layouts) and --font-ui (Open Sans,
 * used for digital surfaces / web). Designs targeting the web should
 * default to --font-ui to match what users actually see.
 */

/* Open Sans si carica dall'HTML (<link> con preconnect). Shadows Into Light
   (--font-accent) non e' usato da nessuna pagina e non si scarica piu'. */

:root {
  /* ============================================================
     BRAND COLORS — Italian institutional palette
     ============================================================ */

  --vf-blue:            #004493;  /* Blu Istituzionale — primary, Pantone 2945 C */
  --vf-blue-dark:       #003070;  /* hover / pressed / depth */
  --vf-blue-light:      #1a5aaa;  /* gradient companion */
  --vf-blue-50:         #e6edf6;  /* tint — section backgrounds */
  --vf-blue-100:        #cdd9eb;

  --vf-white:           #FFFFFF;
  --vf-green:           #009246;  /* Verde Italia — Pantone 355 C */
  --vf-red:             #CE2B37;  /* Rosso Italia — Pantone 485 C */

  /* Neutral scale */
  --vf-n-100:           #FFFFFF;
  --vf-n-200:           #F5F7FA;  /* page bg */
  --vf-n-300:           #E8ECF0;  /* hairline / divider */
  --vf-n-400:           #C8D0DA;
  --vf-n-500:           #8A96A3;
  --vf-n-600:           #555F6B;
  --vf-n-700:           #333D47;  /* body text */
  --vf-n-800:           #1A2028;
  --vf-n-900:           #0A0E12;

  /* Semantic foreground/background */
  --fg-1:               var(--vf-n-700);   /* primary body text */
  --fg-2:               var(--vf-n-600);   /* secondary text */
  --fg-3:               var(--vf-n-500);   /* muted / captions */
  --fg-on-blue:         var(--vf-white);
  --fg-link:            var(--vf-blue);
  --fg-heading:         var(--vf-blue);    /* headings are brand blue */

  --bg-1:               var(--vf-white);
  --bg-2:               var(--vf-n-200);   /* page bg */
  --bg-3:               var(--vf-n-300);   /* alt rows */
  --bg-brand:           var(--vf-blue);
  --bg-brand-deep:      var(--vf-blue-dark);

  --border-1:           var(--vf-n-300);
  --border-strong:      var(--vf-blue);

  /* Semantic state — mostly informational; brand uses red sparingly */
  --state-success:      var(--vf-green);
  --state-danger:       var(--vf-red);
  --state-info:         var(--vf-blue);

  /* ============================================================
     TYPOGRAPHY
     ============================================================ */

  /* Brand spec font (print + formal) */
  --font-display:  'Avenir Next', 'Avenir', 'Open Sans', Arial, sans-serif;

  /* Web font actually loaded on vfstampi.com */
  --font-ui:       'Open Sans', 'Avenir Next', Arial, Helvetica, sans-serif;

  /* Decorative — used on the production site for chalk-style accents */
  --font-accent:   'Shadows Into Light', cursive;

  --font-fallback: Arial, Helvetica, sans-serif;

  --fw-light:    300;
  --fw-regular:  400;
  --fw-semibold: 600;
  --fw-bold:     700;
  --fw-black:    800;

  /* Type scale */
  --fs-xs:   11px;
  --fs-sm:   13px;
  --fs-base: 15px;
  --fs-md:   17px;
  --fs-lg:   20px;
  --fs-xl:   24px;
  --fs-2xl:  30px;
  --fs-3xl:  38px;
  --fs-4xl:  48px;
  --fs-5xl:  60px;

  --lh-tight:   1.2;
  --lh-normal:  1.5;
  --lh-relaxed: 1.75;

  --ls-tight: -0.01em;
  --ls-normal: 0;
  --ls-wide:   0.05em;
  --ls-wider:  0.10em;

  /* ============================================================
     SPACING (8px grid) / RADII / SHADOW / MOTION
     ============================================================ */
  --space-1: 4px;  --space-2: 8px;  --space-3: 12px; --space-4: 16px;
  --space-5: 20px; --space-6: 24px; --space-8: 32px; --space-10: 40px;
  --space-12: 48px; --space-16: 64px; --space-20: 80px; --space-24: 96px;

  /* Brand prefers SHARP corners. Soft radii reserved for cards/pills. */
  --radius-none: 0;
  --radius-sm:   2px;
  --radius-md:   4px;
  --radius-lg:   8px;
  --radius-pill: 9999px;

  --shadow-sm: 0 1px 3px rgba(0, 68, 147, 0.12);
  --shadow-md: 0 4px 12px rgba(0, 68, 147, 0.15);
  --shadow-lg: 0 8px 24px rgba(0, 68, 147, 0.18);
  --shadow-xl: 0 16px 40px rgba(0, 68, 147, 0.22);

  --t-fast: 0.15s ease;
  --t-base: 0.25s ease;
  --t-slow: 0.4s  ease;

  /* Italian flag accent gradient — used as decorative bar */
  --flag-stripe: linear-gradient(
    to right,
    var(--vf-green) 33.33%,
    var(--vf-white) 33.33% 66.66%,
    var(--vf-red)   66.66%
  );
}

/* ============================================================
   SEMANTIC TYPE STYLES
   ============================================================ */

.vf-h1 {
  font-family: var(--font-ui);
  font-weight: var(--fw-bold);
  font-size: var(--fs-4xl);
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  color: var(--fg-heading);
}
.vf-h2 {
  font-family: var(--font-ui);
  font-weight: var(--fw-bold);
  font-size: var(--fs-2xl);
  line-height: var(--lh-tight);
  color: var(--fg-heading);
}
.vf-h3 {
  font-family: var(--font-ui);
  font-weight: var(--fw-bold);
  font-size: var(--fs-xl);
  line-height: var(--lh-tight);
  color: var(--fg-heading);
}
.vf-h4 {
  font-family: var(--font-ui);
  font-weight: var(--fw-bold);
  font-size: var(--fs-md);
  color: var(--fg-heading);
}
.vf-lead {
  font-family: var(--font-ui);
  font-weight: var(--fw-light);
  font-size: var(--fs-lg);
  color: var(--fg-2);
  line-height: var(--lh-normal);
}
.vf-body {
  font-family: var(--font-ui);
  font-weight: var(--fw-regular);
  font-size: var(--fs-base);
  line-height: var(--lh-relaxed);
  color: var(--fg-1);
}
.vf-small {
  font-family: var(--font-ui);
  font-size: var(--fs-sm);
  color: var(--fg-2);
}
.vf-eyebrow {
  font-family: var(--font-ui);
  font-weight: var(--fw-bold);
  font-size: var(--fs-xs);
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  color: var(--vf-blue);
}
.vf-caption {
  font-family: var(--font-ui);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xs);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--fg-3);
}
.vf-accent {                /* chalk / hand-drawn marker — used sparingly */
  font-family: var(--font-accent);
  font-weight: var(--fw-regular);
  color: var(--vf-blue);
}

/* ============================================================
   BASE ELEMENT STYLES (opt-in via .vf-prose wrapper)
   ============================================================ */

.vf-prose {
  font-family: var(--font-ui);
  font-size: var(--fs-base);
  line-height: var(--lh-relaxed);
  color: var(--fg-1);
}
.vf-prose h1 { @apply vf-h1; }
.vf-prose h2 { @apply vf-h2; }
.vf-prose h3 { @apply vf-h3; }
.vf-prose h4 { @apply vf-h4; }
.vf-prose a  { color: var(--fg-link); text-decoration: none; border-bottom: 1px solid currentColor; }
.vf-prose a:hover { color: var(--vf-blue-dark); }

/* ============================================================
   FLAG STRIPE — decorative element, brand signature
   ============================================================ */

.vf-flag {
  display: inline-block;
  width: 36px;
  height: 8px;
  background: var(--flag-stripe);
  border-radius: 1px;
  vertical-align: middle;
}
.vf-flag-bar {                /* full-width separator */
  height: 3px;
  background: var(--flag-stripe);
  border-radius: 2px;
}
