@charset "UTF-8";
/* ============================================================
   KAMOS DESIGN HARNESS — Unified Design Tokens & Base Elements
   - Zero-dependency Design System
   - Semantic data-accent & data-theme token switching
   - Ambient Texture Layers (Grid, Glow, Noise, Ticks)
   - Resilient Layout Components (.slab, .panel, .stat, .eyebrow)
   ============================================================ */

/* ---------- 1. Core Tokens ---------------------------------- */
:root {
  /* 地（Background & Surfaces） */
  --ink:          #07080b;
  --ink-2:        #0b0d12;
  --surface:      #ffffff;
  --surface-2:    #f8fafc;
  --surface-dim:  #f1f5f9;
  --panel:        rgba(0, 0, 0, 0.03);
  --panel-2:      rgba(0, 0, 0, 0.06);
  --line:         rgba(0, 0, 0, 0.08);
  --line-2:       rgba(0, 0, 0, 0.14);

  /* 文字（Typography Colors） */
  --fg:           #0f172a;
  --fg-dim:       #475569;
  --fg-mute:      #64748b;
  --fg-faint:     #94a3b8;

  /* デフォルトアクセント（Kamos Emerald） */
  --accent:       #10b981;
  --accent-2:     #34d399;
  --accent-ink:   #ffffff;
  --accent-subtle: rgba(16, 185, 129, 0.08);

  /* レイアウト＆余白 */
  --wrap:         1180px;
  --gap:          clamp(18px, 2.4vw, 32px);
  --radius:       18px;
  --radius-sm:    10px;
  --radius-full:  9999px;

  /* フォント指定 */
  --f-display:    "Outfit", "Josefin Sans", "Montserrat", "Noto Sans JP", sans-serif;
  --f-sans:       "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --f-serif:      "Lora", "Shippori Mincho B1", serif;
  --f-mono:       "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --ease-spring:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth:  cubic-bezier(0.4, 0, 0.2, 1);
}

/* ダークモード時の基本サーフェス */
[data-theme="dark"],
html.dark {
  --ink:          #07080b;
  --ink-2:        #0b0d12;
  --surface:      #0b0d12;
  --surface-2:    #11141c;
  --surface-dim:  #181d28;
  --panel:        rgba(255, 255, 255, 0.032);
  --panel-2:      rgba(255, 255, 255, 0.055);
  --line:         rgba(255, 255, 255, 0.09);
  --line-2:       rgba(255, 255, 255, 0.17);

  --fg:           #e9ebf1;
  --fg-dim:       #a3abbb;
  --fg-mute:      #6d7585;
  --fg-faint:     #454c5b;
}

/* ---------- 2. Semantic Accents (data-accent) ---------------- */
[data-accent="emerald"], [data-accent="kamos"] {
  --accent: #10b981; --accent-2: #34d399; --accent-ink: #ffffff;
  --accent-subtle: rgba(16, 185, 129, 0.08);
}
[data-accent="brass"], [data-accent="gold"] {
  --accent: #c9ab6d; --accent-2: #e3cca0; --accent-ink: #1a1608;
  --accent-subtle: rgba(201, 171, 109, 0.10);
}
[data-accent="amber"], [data-accent="orange"] {
  --accent: #ff8a30; --accent-2: #ffc98a; --accent-ink: #180a00;
  --accent-subtle: rgba(255, 138, 48, 0.09);
}
[data-accent="cyan"], [data-accent="sky"] {
  --accent: #0ea5e9; --accent-2: #38bdf8; --accent-ink: #001216;
  --accent-subtle: rgba(14, 165, 233, 0.08);
}
[data-accent="violet"], [data-accent="purple"] {
  --accent: #8b5cf6; --accent-2: #a78bfa; --accent-ink: #ffffff;
  --accent-subtle: rgba(139, 92, 246, 0.08);
}
[data-accent="rose"], [data-accent="pink"] {
  --accent: #f43f5e; --accent-2: #fb7185; --accent-ink: #ffffff;
  --accent-subtle: rgba(244, 63, 94, 0.08);
}
[data-accent="kosuke"], [data-accent="kosukekato"] {
  --accent: #e53935; --accent-2: #f59e0b; --accent-ink: #ffffff;
  --accent-subtle: rgba(229, 57, 53, 0.08);
}
[data-accent="indigo"] {
  --accent: #6366f1; --accent-2: #818cf8; --accent-ink: #ffffff;
  --accent-subtle: rgba(99, 102, 241, 0.08);
}

/* ---------- 3. Texture Layers (方眼・光暈・ノイズ) ------------ */
[data-texture="vault"]::before,
[data-texture="vault"]::after,
body.has-texture::before,
body.has-texture::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

[data-texture="vault"]::before,
body.has-texture::before {
  background-image:
    radial-gradient(120% 70% at 50% -10%, color-mix(in srgb, var(--accent) 12%, transparent) 0%, transparent 64%),
    radial-gradient(90% 60% at 100% 105%, rgba(99, 102, 241, 0.05) 0%, transparent 60%),
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 64px 64px, 64px 64px;
}

[data-texture="vault"]::after,
body.has-texture::after {
  opacity: 0.35;
  mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

/* ---------- 4. Base Components ------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--gap);
  padding-right: var(--gap);
  position: relative;
  z-index: 1;
}

/* Eyebrow (章立て見出し) */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.eyebrow__no {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
  padding: 2px 6px;
  background: var(--accent-subtle);
  border-radius: 4px;
}
.eyebrow__title {
  margin: 0;
  font-family: var(--f-display);
  font-size: clamp(14px, 1.2vw, 16px);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg);
}
.eyebrow__note {
  margin-left: auto;
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--fg-mute);
  letter-spacing: 0.05em;
}

/* Slab (高密度情報カード) */
.slab {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(20px, 2.5vw, 32px);
  position: relative;
  text-decoration: none;
  color: inherit;
  transition: transform 0.25s var(--ease-spring), border-color 0.25s var(--ease-spring), box-shadow 0.25s var(--ease-spring);
  overflow: hidden;
}
.slab:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  box-shadow: 0 12px 32px -8px color-mix(in srgb, var(--accent) 18%, transparent);
}
.slab__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--fg-mute);
}
.slab__title {
  margin: 0 0 10px;
  font-family: var(--f-display);
  font-size: clamp(18px, 1.8vw, 24px);
  font-weight: 700;
  color: var(--fg);
  line-height: 1.3;
}
.slab__jp {
  font-family: var(--f-sans);
  font-size: 14px;
  color: var(--fg-dim);
  line-height: 1.7;
}
.slab__cta {
  margin-top: auto;
  padding-top: 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}

/* Tag & Badges */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: var(--panel-2);
  color: var(--fg-dim);
  border: 1px solid var(--line);
}
.tag--accent {
  background: var(--accent-subtle);
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
}

/* Stat Box */
.stat {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
}
.stat__num {
  font-family: var(--f-display);
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}
.stat__label {
  margin-top: 6px;
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--fg-mute);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* 隅金具装飾 (.ticks) */
.ticks {
  position: relative;
}
.ticks::before, .ticks::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  border-color: var(--accent);
  border-style: solid;
  pointer-events: none;
  opacity: 0.6;
}
.ticks::before {
  top: 8px; left: 8px;
  border-width: 1.5px 0 0 1.5px;
}
.ticks::after {
  bottom: 8px; right: 8px;
  border-width: 0 1.5px 1.5px 0;
}
