/* ObiNine 共通スタイル（サイト・ツール共通）
   配色はアールジャパン株式会社のコーポレートカラー（ロゴの水色 #6FA6ED）を基準にした水色系 */
:root {
  --brand: #6FA6ED;
  --brand-50: #F3F8FE;
  --brand-100: #E6F0FC;
  --brand-200: #CFE2F9;
  --brand-300: #A9CBF4;
  --brand-600: #2F74D0;
  --brand-700: #245FB2;
  --brand-800: #1E4F96;
  --brand-900: #14335F;
  --ink: #16202C;
  --ink-2: #39475A;
  --muted: #627084;
  --line: #DCE6F2;
  --line-2: #C9D8EA;
  --bg: #FFFFFF;
  --bg-soft: #F5F9FE;
  --marker: #FFE08A;
  --danger: #C93C3C;
  --warn: #A86E00;
  --ok: #17845A;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(20, 51, 95, .06), 0 2px 10px rgba(20, 51, 95, .06);
  --shadow: 0 14px 40px rgba(20, 51, 95, .12);
  --font: "Noto Sans JP", system-ui, -apple-system, "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  --font-en: "Outfit", "Noto Sans JP", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "palt" 1;
}
img, svg, canvas { display: block; max-width: 100%; }
figure { margin: 0; }
a { color: var(--brand-700); }
a:hover { color: var(--brand-800); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid rgba(47, 116, 208, .45); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.en { font-family: var(--font-en); letter-spacing: .02em; }

/* ---------- ロゴ ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 36px; height: 36px; flex: none; }
.brand-word { display: flex; flex-direction: column; line-height: 1.05; }
.brand-word b { font-family: var(--font-en); font-size: 23px; font-weight: 700; letter-spacing: .005em; color: var(--brand-900); }
.brand-word b span { color: var(--brand-600); }
.brand-word small { font-family: var(--font-en); font-size: 9.5px; letter-spacing: .16em; color: var(--muted); font-weight: 600; margin-top: 2px; }

/* ---------- ボタン（押した反応つき） ---------- */
.btn {
  --b-bg: #fff; --b-fg: var(--brand-800); --b-bd: var(--line-2); --b-bg-h: var(--brand-50); --b-bg-a: var(--brand-100);
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 20px;
  border-radius: 999px; border: 1.5px solid var(--b-bd);
  background: var(--b-bg); color: var(--b-fg);
  font-weight: 700; font-size: 15px; line-height: 1.3; letter-spacing: .02em;
  text-decoration: none; cursor: pointer; user-select: none; white-space: nowrap;
  transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease), transform .12s var(--ease), box-shadow .15s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { background: var(--b-bg-h); color: var(--b-fg); }
.btn:active, .btn.is-pressed { transform: scale(.96); background: var(--b-bg-a); }
.btn-primary { --b-bg: var(--brand-600); --b-fg: #fff; --b-bd: var(--brand-600); --b-bg-h: var(--brand-700); --b-bg-a: var(--brand-900); box-shadow: 0 6px 18px rgba(47, 116, 208, .28); }
.btn-primary:hover { border-color: var(--brand-700); }
.btn-primary:active, .btn-primary.is-pressed { border-color: var(--brand-900); box-shadow: 0 2px 8px rgba(47, 116, 208, .25); }
.btn-outline { --b-bg: #fff; --b-fg: var(--brand-700); --b-bd: var(--brand-600); }
.btn-ghost { --b-bg: transparent; --b-bd: transparent; --b-fg: var(--brand-800); --b-bg-h: var(--brand-50); --b-bg-a: var(--brand-100); }
.btn-white { --b-bg: #fff; --b-fg: var(--brand-800); --b-bd: #fff; --b-bg-h: var(--brand-50); }
.btn-lg { min-height: 56px; padding: 14px 30px; font-size: 17px; }
.btn-sm { min-height: 36px; padding: 6px 14px; font-size: 13.5px; }
.btn-block { width: 100%; }
.btn .arrow { transition: transform .2s var(--ease); }
.btn:hover .arrow { transform: translateX(3px); }

/* 処理中：回る印＋二度押し防止（disabled は使わない） */
.is-busy { pointer-events: none; cursor: progress; }
.btn.is-busy { color: transparent !important; }
.btn.is-busy::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px;
  border-radius: 50%; border: 2.5px solid currentColor; border-color: var(--b-fg) var(--b-fg) var(--b-fg) transparent;
  animation: spin .7s linear infinite;
}
.btn-primary.is-busy::after { border-color: #fff #fff #fff transparent; }
@keyframes spin { to { transform: rotate(360deg); } }

/* 画面上部の進行バー */
.progress-bar { position: fixed; left: 0; top: 0; height: 3px; width: 0; z-index: 9999; background: linear-gradient(90deg, var(--brand), var(--brand-600)); box-shadow: 0 0 10px rgba(47, 116, 208, .5); transition: width .25s var(--ease), opacity .3s; opacity: 0; }
.progress-bar.is-active { opacity: 1; }
.progress-bar.is-indeterminate { width: 40% !important; animation: indeterminate 1.1s ease-in-out infinite; }
@keyframes indeterminate { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }

/* トースト */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; z-index: 9998; background: var(--brand-900); color: #fff; padding: 12px 20px; border-radius: 12px; box-shadow: var(--shadow); font-size: 14px; max-width: min(92vw, 560px); transition: opacity .2s, transform .2s var(--ease); }
.toast.is-show { opacity: 1; transform: translate(-50%, 0); }
.toast.is-error { background: var(--danger); }

/* 制作中の表示（公開前に site-config.js の DRAFT を false に） */
.draft-ribbon { position: relative; z-index: 60; background: repeating-linear-gradient(45deg, #fff6d8, #fff6d8 12px, #ffeeb8 12px, #ffeeb8 24px); color: #6b4b00; font-size: 12.5px; text-align: center; padding: 6px 12px; line-height: 1.5; border-bottom: 1px solid #f0d78a; }
.draft-ribbon.is-beta { background: var(--brand-50); color: var(--brand-900); border-bottom-color: var(--brand-200); padding: 8px 16px; }
.draft-ribbon.is-beta a { display: inline-block; margin-left: 10px; color: var(--brand-700); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
