/* ============================================================
   COLORS — デジタル庁デザインシステム準拠 7系統カラーパレット
   Source: Dashboard Design Guidebook 4.3 カラーパレット
   Contrast notes are vs white (#FFF). 600 ≈ 4.5:1, 400 ≈ 3:1.
   ============================================================ */

:root {
  /* ---- Blue (primary) ---- */
  --blue-50:   #D9E6FF;
  --blue-200:  #C5D7FB;
  --blue-400:  #7096F8;
  --blue-500:  #4979F5; /* min chart density on white (3:1) */
  --blue-600:  #3460FB;
  --blue-900:  #0017C1;
  --blue-1200: #000060;

  /* ---- Light Blue ---- */
  --light-blue-50:   #F0F9FF;
  --light-blue-200:  #C0E4FF;
  --light-blue-400:  #57B8FF;
  --light-blue-600:  #008BF2;
  --light-blue-900:  #0055AD;
  --light-blue-1200: #00234B;

  /* ---- Cyan ---- */
  --cyan-50:   #E9F7F9;
  --cyan-200:  #99F2FF;
  --cyan-400:  #2BC8E4;
  --cyan-600:  #00A3BF;
  --cyan-900:  #006F83;
  --cyan-1200: #003741;

  /* ---- Green ---- */
  --green-50:   #E6F5EC;
  --green-200:  #9BD4B5;
  --green-400:  #51B883;
  --green-600:  #259D63;
  --green-900:  #115A36;
  --green-1200: #032213;

  /* ---- Orange ---- */
  --orange-50:   #FFEEE2;
  --orange-200:  #FFC199;
  --orange-400:  #FF8D44;
  --orange-600:  #FB5B01;
  --orange-900:  #AC3E00;
  --orange-1200: #541E00;

  /* ---- Red ---- */
  --red-50:   #FDEEEE;
  --red-200:  #FFBBBB;
  --red-400:  #FF7171;
  --red-600:  #FE3939;
  --red-900:  #CE0000;
  --red-1200: #620000;

  /* ---- Solid Gray ---- */
  --gray-50:   #F2F2F2;
  --gray-200:  #CCCCCC;
  --gray-400:  #999999;
  --gray-536:  #767676; /* 4.5:1 text on white */
  --gray-700:  #4D4D4D;
  --gray-900:  #1A1A1A;

  /* ---- Yellow (chart secondary) ---- */
  --yellow-400: #FFC700;
  --yellow-600: #D2A400;
  --yellow-800: #A58000;

  /* ---- Extra neutral steps used by the palette spec ---- */
  --neutral-333: #333333;
  --neutral-626: #626264; /* Label */
  --neutral-666: #666666;

  /* ============================================================
     SEMANTIC ALIASES — what each color is FOR
     (Blue palette as the default key color; see guidebook p36)
     ============================================================ */

  /* Text */
  --text-black:    #000000;
  --text-white:    #FFFFFF;
  --text-body:     var(--neutral-333);   /* primary reading text */
  --text-strong:   var(--text-black);    /* metrics / headings */
  --text-muted:    var(--neutral-626);   /* labels, captions */
  --text-subtle:   var(--gray-536);      /* meta, footnotes */
  --text-disabled: var(--gray-400);
  --text-on-fill:  var(--text-white);
  --text-link:     var(--blue-900);      /* #0017C1 */

  /* Surfaces / background */
  --surface-page:    #F8F8FB;            /* Background Standard */
  --surface-card:    #FFFFFF;
  --surface-control: #F1F1F4;            /* Control */
  --surface-sunken:  var(--gray-50);
  --surface-hover:   #ECECF1;

  /* Borders / lines */
  --border-default: var(--gray-200);
  --border-strong:  var(--gray-400);
  --border-subtle:  #E4E4EA;
  --grid-line:      #E8E8EE;             /* chart gridlines (minimal data-ink) */
  --axis-line:      var(--gray-400);

  /* Brand / interactive */
  --brand:          var(--blue-900);     /* #0017C1 key color */
  --brand-strong:   var(--blue-1200);
  --brand-bright:   var(--blue-600);
  --highlight:      var(--blue-900);
  --focus-ring:     var(--blue-600);

  /* ---- Slide importance tier ----
     ORDER, not kind: a single-hue blue lightness ramp for CORE→REF,
     with INFO desaturated to gray to drop it out of the hierarchy
     ("skippable"). Applied ONLY to the three slide-chrome elements
     (keyline, accent bar, kicker) — body accents stay the one blue.
     Contrast (vs white): REF = blue-400 ≈ 3:1 (OK only for the bold
     22px kicker = large text); INFO = gray-536 = 4.5:1. Never use
     these on body-size text. */
  --tier-core: var(--blue-900);          /* 最重要・必ず理解 = current keyline */
  --tier-ref:  var(--blue-400);          /* あとで見返せればよい */
  --tier-info: var(--gray-536);          /* 聞き流してよい = out of hierarchy */

  /* Semantic status */
  --positive:       var(--blue-600);     /* increase (key-color positive) */
  --negative:       var(--red-600);      /* decrease */
  --success:        #197A4B;
  --error:          var(--red-900);      /* #CE0000 */
  --warning:        var(--orange-600);

  /* ---- Chart roles (data-ink minimal, ≤5 colors) ---- */
  --chart-primary:    var(--blue-1200);  /* #000060 emphasized series */
  --chart-secondary:  var(--yellow-800); /* #A58000 reference / comparison */
  --chart-target:     var(--gray-400);   /* target / reference value */
  --chart-positive:   var(--blue-600);
  --chart-negative:   var(--red-600);

  /* Categorical sequence — colorblind-aware, distinct hues */
  --cat-1: var(--blue-600);
  --cat-2: var(--orange-600);
  --cat-3: var(--cyan-600);
  --cat-4: var(--green-600);
  --cat-5: var(--yellow-800);

  /* Sequential (single-hue Blue ramp) for choropleth / heat */
  --seq-1: var(--blue-50);
  --seq-2: var(--blue-200);
  --seq-3: var(--blue-400);
  --seq-4: var(--blue-600);
  --seq-5: var(--blue-900);
}
