/* ============================================================
   ケミコ デザインシステム — colors_and_type.css
   小野田ケミコ株式会社 / ケミコプラットフォーム
   Font: Noto Sans JP (Google Fonts)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&family=Inter:wght@400;700&display=swap');

:root {
  /* ---------- Brand / Primary ---------- */
  --primary: #005aff;
  --primary-hover: #004bd5;
  --primary-disabled: #bbbbbb;
  --primary-foreground: #ffffff;
  --primary-background: #e5f5ff;

  /* ---------- Secondary ---------- */
  --secondary: #f3f3f3;
  --secondary-hover: #eeeeee;
  --secondary-foreground: #1f2937;

  /* ---------- Destructive ---------- */
  --destructive: #ff3366;
  --destructive-hover: #eb2e5d;
  --destructive-foreground: #ffffff;
  --destructive-background: #ffbccd;

  /* ---------- Success ---------- */
  --success: #4dde91;
  --success-foreground: #ffffff;

  /* ---------- Neutrals (surface + text) ---------- */
  --bg: #ffffff;
  --bg-card: #ffffff;
  --bg-sidebar: #f7f8f9;
  --bg-hover: #f5f5f5;
  --bg-selected: #e5f5ff;

  --text-primary: #1f2937;
  --text-secondary: #989898;
  --text-icon: #656c87;

  --border: #e5e7eb;

  /* ---------- Accent palette (chips / illustrations only) ---------- */
  --blue: #0099ff;
  --navy: #3666ff;
  --purple: #8855ff;
  --green: #4ad68b;
  --yellow: #ffbb00;
  --orange: #ff8822;
  --red: #ff4488;
  --dark: #565656;

  /* ---------- Type ---------- */
  --font-jp: 'Noto Sans JP', system-ui, -apple-system, sans-serif;
  --font-en: 'Inter', system-ui, sans-serif;

  --size-h1: 32px;
  --size-h2: 24px;
  --size-h3: 20px;
  --size-h4: 18px;
  --size-lg: 16px;
  --size-md: 15px;
  --size-body: 14px;
  --size-sm: 13px;
  --size-xs: 12px;
  --size-2xs: 11px;

  --weight-regular: 400;
  --weight-medium: 500;
  --weight-bold: 700;

  --lh-tight: 1;     /* @kind font */
  --lh-heading: 1.2; /* @kind font */
  --lh-body: 1.5;    /* @kind font */

  /* ---------- Radius ---------- */
  --radius-sm: 6px;   /* chips, badges */
  --radius: 8px;      /* buttons, inputs */
  --radius-md: 10px;  /* base UI */
  --radius-lg: 14px;  /* cards, dialogs */
  --radius-full: 9999px;

  /* ---------- Shadows (from Figma /Style/Shadows) ---------- */
  --shadow-flat: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-1: 0px 2px 6px 0px rgba(0, 0, 0, 0.14);
  --shadow-2: 0px 6px 14px 0px rgba(0, 0, 0, 0.10);
  --shadow-3: 0px 8px 20px 0px rgba(0, 0, 0, 0.10);
  --focus-ring-primary: 0 0 0 3px rgba(0, 90, 255, 0.10);
  --focus-ring-destructive: 0 0 0 3px rgba(255, 51, 102, 0.20);

  /* ---------- Layout ---------- */
  --height-header: 55px;
  --width-sidebar: 240px;
  --width-sidebar-collapsed: 64px;
  --width-ticket-sidebar: 320px;
  --content-max: 1280px;

  /* ---------- Spacing (4px base) ---------- */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;

  /* ---------- Motion ---------- */
  --transition: 200ms ease;      /* @kind other */
  --transition-slow: 300ms ease; /* @kind other */
}

/* ============================================================
   Semantic base styles
   ============================================================ */
html, body {
  font-family: var(--font-jp);
  font-size: var(--size-body);
  font-weight: var(--weight-regular);
  line-height: var(--lh-body);
  color: var(--text-primary);
  background: var(--bg);
  margin: 0;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-weight: var(--weight-bold);
  line-height: var(--lh-heading);
  color: var(--text-primary);
  margin: 0;
}
h1 { font-size: var(--size-h1); }
h2 { font-size: var(--size-h2); }
h3 { font-size: var(--size-h3); }
h4 { font-size: var(--size-h4); }

p  { margin: 0; font-size: var(--size-body); color: var(--text-primary); }
small, .small { font-size: var(--size-xs); color: var(--text-secondary); }

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--primary-hover); text-decoration: underline; }

code, pre { font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; }

/* ============================================================
   Utility / helper classes
   ============================================================ */
.text-primary   { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-icon      { color: var(--text-icon); }
.text-brand     { color: var(--primary); }
.text-danger    { color: var(--destructive); }

.font-regular { font-weight: var(--weight-regular); }
.font-medium  { font-weight: var(--weight-medium); }
.font-bold    { font-weight: var(--weight-bold); }

.surface       { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.surface-muted { background: var(--bg-sidebar); }

.required::after { content: '※必須'; color: var(--destructive); font-size: var(--size-sm); margin-left: 8px; }
