/* ATR沖縄情報サイト - 公開サイト用スタイル
   テーマ: AI・ロボット系（近未来） × 誰でも読みやすい大きな文字 */

:root {
  --navy: #0B1626;          /* ヘッダー等の濃紺 */
  --navy-2: #12233D;
  --cyan: #22D3EE;          /* AIらしい発光シアン */
  --cyan-deep: #0E7490;
  --bg: #F3F7FB;            /* 本文はクールな明るい地で読みやすく */
  --surface: #FFFFFF;
  --ink: #14202E;
  --ink-soft: #5A6B7D;
  --line: #D8E2EC;

  --c-notice: #0284C7;      /* お知らせ */
  --c-seminar: #7C3AED;     /* セミナー案内 */
  --c-docs: #059669;        /* 各種資料 */
  --c-videos: #D97706;      /* 各種動画 */

  --l-important: #DC2626;
  --l-update: #D97706;
  --l-normal: #059669;

  --fs-base: 18px;          /* 標準で大きめ */
}
html.fs-large { --fs-base: 21px; }
html.fs-xlarge { --fs-base: 24px; }

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  font-size: var(--fs-base);
  line-height: 1.8;
}
a { color: var(--cyan-deep); }
img { max-width: 100%; }

/* ---------- ヘッダー ---------- */
.site-header { background: var(--navy); color: #fff; }
.header-inner {
  max-width: 1080px; margin: 0 auto; padding: 0.9rem 1rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand { display: flex; align-items: baseline; gap: 0.6rem; text-decoration: none; color: #fff; }
.brand-mark {
  font-family: Orbitron, sans-serif; font-weight: 800; font-size: 1.6rem;
  color: var(--cyan); letter-spacing: 0.08em;
  text-shadow: 0 0 14px rgba(34, 211, 238, 0.55);
}
.brand-text { font-weight: 900; font-size: 1.15rem; letter-spacing: 0.04em; }
.circuit-line {
  height: 4px;
  background: linear-gradient(90deg, var(--cyan) 0%, #3B82F6 35%, transparent 36%, transparent 40%,
    #3B82F6 41%, var(--cyan) 70%, transparent 71%, transparent 75%, var(--cyan) 76%, #3B82F6 100%);
}
.fontsize-btn {
  background: var(--navy-2); color: #fff; border: 1px solid rgba(34,211,238,0.5);
  border-radius: 8px; padding: 0.45rem 0.9rem; font-size: 0.85rem; cursor: pointer;
  font-family: inherit; min-height: 44px;
}
.fontsize-btn:hover, .fontsize-btn:focus-visible { border-color: var(--cyan); outline: 2px solid var(--cyan); outline-offset: 1px; }

/* ---------- カテゴリナビ ---------- */
.global-nav {
  max-width: 1080px; margin: 0 auto; padding: 0.8rem 1rem;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.7rem;
}
.nav-item {
  display: flex; align-items: center; justify-content: center; gap: 0.45rem;
  min-height: 56px; border-radius: 12px; text-decoration: none;
  color: #fff; font-weight: 700; font-size: 0.98rem;
  box-shadow: 0 2px 6px rgba(11, 22, 38, 0.18);
}
.nav-item:hover, .nav-item:focus-visible { filter: brightness(1.12); outline: 3px solid var(--cyan); outline-offset: 2px; }
.nav-icon { font-size: 1.25rem; }
.cat-notice  { background: var(--c-notice); }
.cat-seminar { background: var(--c-seminar); }
.cat-docs    { background: var(--c-docs); }
.cat-videos  { background: var(--c-videos); }
@media (max-width: 640px) {
  .global-nav { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- パンくず ---------- */
.breadcrumb {
  max-width: 1080px; margin: 0 auto; padding: 0.4rem 1rem 0;
  font-size: 0.85rem; color: var(--ink-soft);
}
.breadcrumb a { text-decoration: none; font-weight: 700; }
.crumb-sep { margin: 0 0.5rem; }

/* ---------- 本文 ---------- */
.container { max-width: 1080px; margin: 0 auto; padding: 1rem 1rem 4rem; }
.page-title {
  font-size: 1.5rem; font-weight: 900; margin: 0.8rem 0 1rem;
  padding-left: 0.8rem; border-left: 6px solid var(--cyan);
}
.section-title {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 1.25rem; font-weight: 900; margin: 2.2rem 0 0.8rem;
}
.section-title::after { content: ""; flex: 1; height: 2px; background: linear-gradient(90deg, var(--cyan), transparent); }
.more-link { font-size: 0.9rem; font-weight: 700; white-space: nowrap; }

/* ---------- 検索 ---------- */
.search-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%);
  border-radius: 16px; padding: 1.6rem 1.4rem; margin: 0.6rem 0 1.4rem;
  position: relative; overflow: hidden;
}
.search-hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at 88% 20%, rgba(34,211,238,0.22), transparent 40%),
    radial-gradient(circle at 8% 90%, rgba(59,130,246,0.18), transparent 45%);
}
.search-hero h1 { color: #fff; font-size: 1.2rem; margin: 0 0 0.7rem; position: relative; }
.search-form { display: flex; gap: 0.6rem; position: relative; }
.search-input {
  flex: 1; min-height: 54px; border-radius: 10px; border: 2px solid var(--cyan);
  padding: 0.4rem 1rem; font-size: 1.05rem; font-family: inherit;
}
.search-input:focus { outline: 3px solid rgba(34,211,238,0.6); }
.search-btn {
  min-height: 54px; min-width: 96px; border: none; border-radius: 10px;
  background: var(--cyan); color: var(--navy); font-weight: 900; font-size: 1rem;
  cursor: pointer; font-family: inherit;
}
.search-btn:hover { filter: brightness(1.1); }
.search-suggest {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 20;
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 8px 24px rgba(11,22,38,0.2); overflow: hidden;
}
.search-suggest a {
  display: flex; gap: 0.6rem; align-items: center; padding: 0.6rem 0.9rem;
  text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--line); font-size: 0.95rem;
}
.search-suggest a:last-child { border-bottom: none; }
.search-suggest a:hover, .search-suggest a:focus-visible { background: #EAF6FB; }
.suggest-type { font-size: 0.75rem; font-weight: 700; color: #fff; border-radius: 4px; padding: 0.05rem 0.5rem; white-space: nowrap; }

/* ---------- リスト・カード ---------- */
.item-list { list-style: none; margin: 0; padding: 0; }
.item-list > li { margin: 0 0 0.7rem; }
.item-card {
  display: block; background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; padding: 0.9rem 1.1rem; text-decoration: none; color: var(--ink);
}
a.item-card:hover, a.item-card:focus-visible { border-color: var(--cyan); box-shadow: 0 3px 10px rgba(34,211,238,0.25); }
.item-head { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem; }
.item-date { color: var(--ink-soft); font-size: 0.88rem; font-weight: 700; }
.item-title { font-weight: 700; font-size: 1.02rem; }
.item-body { margin: 0.4rem 0 0; color: var(--ink-soft); font-size: 0.92rem; white-space: pre-line; }
.item-meta { color: var(--ink-soft); font-size: 0.85rem; margin-top: 0.3rem; }

.pinned-card { border: 2px solid var(--l-important); background: #FFF7F6; }

.label {
  display: inline-block; color: #fff; font-size: 0.78rem; font-weight: 700;
  border-radius: 999px; padding: 0.05rem 0.7rem; white-space: nowrap;
}
.label-important { background: var(--l-important); }
.label-update { background: var(--l-update); }
.label-normal { background: var(--l-normal); }
.badge-new {
  display: inline-block; background: var(--cyan-deep); color: #fff;
  font-size: 0.72rem; font-weight: 900; border-radius: 4px; padding: 0.1rem 0.4rem;
}

/* ---------- 資料 ---------- */
.doc-row { display: flex; align-items: center; gap: 0.8rem; }
.doc-icon { font-size: 1.7rem; }
.doc-main { flex: 1; min-width: 0; }
.doc-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.3rem;
  min-height: 46px; padding: 0.3rem 1.1rem; border-radius: 10px;
  font-weight: 700; font-size: 0.92rem; text-decoration: none; cursor: pointer;
  border: 2px solid var(--cyan-deep); color: var(--cyan-deep); background: var(--surface);
  font-family: inherit;
}
.btn:hover, .btn:focus-visible { background: #EAF6FB; }
.btn-primary { background: var(--cyan-deep); color: #fff; }
.btn-primary:hover, .btn-primary:focus-visible { background: #0A5B75; }

/* ---------- 動画 ---------- */
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.video-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.video-frame { position: relative; aspect-ratio: 16 / 9; background: var(--navy); }
.video-frame iframe, .video-frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-info { padding: 0.7rem 0.9rem; }
.video-title { font-weight: 700; font-size: 0.98rem; }

/* ---------- ホームに戻るボタン ---------- */
.home-fab {
  position: fixed; right: 1rem; bottom: 1rem; z-index: 30;
  background: var(--navy); color: #fff; text-decoration: none;
  font-weight: 900; font-size: 0.95rem; border-radius: 999px;
  padding: 0.8rem 1.3rem; border: 2px solid var(--cyan);
  box-shadow: 0 4px 14px rgba(11,22,38,0.35);
}
.home-fab:hover, .home-fab:focus-visible { background: var(--navy-2); outline: 3px solid var(--cyan); }

/* ---------- フッター ---------- */
.site-footer { background: var(--navy); color: #C7D5E4; margin-top: 3rem; padding-bottom: 1.6rem; text-align: center; }
.footer-brand { margin: 1.2rem 0 0.2rem; font-weight: 900; color: #fff; }
.footer-note { margin: 0; font-size: 0.85rem; }

/* ---------- 空表示・ページャ ---------- */
.empty-note {
  background: var(--surface); border: 1px dashed var(--line); border-radius: 12px;
  padding: 1.4rem; text-align: center; color: var(--ink-soft);
}
.pager { display: flex; gap: 0.5rem; justify-content: center; margin: 1.6rem 0; }
.pager a, .pager span {
  min-width: 46px; min-height: 46px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; border: 1px solid var(--line); background: var(--surface);
  text-decoration: none; font-weight: 700;
}
.pager .current { background: var(--navy); color: #fff; border-color: var(--navy); }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
