/* ローダー・遷移オーバーレイ・リセット・共通トークンは common.css を参照 */
:root{
  --f:'Noto Sans JP',sans-serif;
  --r:12px; --sh:0 4px 24px rgba(25,35,76,.10);
}
html{ scroll-behavior:smooth; }
body{
  font-family:var(--f);
  background:linear-gradient(145deg,#b8c8de 0%,#cdd8eb 40%,#bfcce0 100%);
  min-height:100vh; color:#1a1a1a;
}
body::before{
  content:''; position:fixed; inset:0;
  background-image:url('../images/nitech_gakko_picture.webp');
  background-size:cover; background-position:center;
  opacity:.12; pointer-events:none; z-index:0;
}

/* ── Header ── */
.site-header{
  background:rgba(19,35,76,.90);
  backdrop-filter:blur(32px); -webkit-backdrop-filter:blur(32px);
  padding:14px 28px; display:flex; align-items:center; gap:10px;
  position:sticky; top:0; z-index:100;
  border-bottom:1px solid rgba(255,255,255,.08);
}
.header-logo{
  color:#fff; font-size:15px; font-weight:700;
  text-decoration:none; display:flex; align-items:center; gap:10px;
}
.header-logo img{ width:26px; height:26px; filter:brightness(0) invert(1); }
.header-sep{ color:rgba(255,255,255,.25); font-size:18px; margin:0 2px; }
.header-title{ color:rgba(255,255,255,.7); font-size:13px; font-weight:400; }

/* ── Main ── */
.main{
  position:relative; z-index:1;
  max-width:860px; margin:0 auto; padding:36px 20px 80px;
}
.back-link{
  display:inline-flex; align-items:center; gap:6px;
  color:var(--navy); font-size:13px; text-decoration:none;
  margin-bottom:24px; opacity:.55; transition:opacity .18s;
}
.back-link:hover{ opacity:.9; }

/* ── Search card ── */
.card{
  background:rgba(255,255,255,.80);
  backdrop-filter:blur(40px); -webkit-backdrop-filter:blur(40px);
  border:1px solid rgba(255,255,255,.92);
  border-radius:var(--r);
  padding:28px 28px 24px;
  margin-bottom:20px;
  box-shadow:var(--sh);
}
.card-title{
  font-size:19px; font-weight:700; color:var(--navy);
  margin-bottom:7px;
  padding-left:14px;
  border-left:3px solid var(--gold);
  line-height:1.4;
}
.card-desc{
  font-size:13px; color:#404040; line-height:1.85;
  margin-bottom:22px; padding-left:14px;
}

/* ── Search input ── */
.search-wrap{
  position:relative; margin-bottom:0; display:flex;
}
.search-input{
  flex:1; padding:13px 16px 13px 44px;
  border:1.5px solid rgba(25,35,76,.16);
  border-radius:8px;
  background:rgba(255,255,255,.95);
  font-family:var(--f); font-size:14px; color:#1a1a1a;
  outline:none;
  transition:border-color .18s, box-shadow .18s;
  box-shadow:inset 0 1px 3px rgba(0,0,0,.04);
}
.search-input:focus{
  border-color:rgba(25,35,76,.55);
  box-shadow:inset 0 1px 3px rgba(0,0,0,.04), 0 0 0 3px rgba(25,35,76,.07);
}
.search-input::placeholder{ color:#bbb; }
.search-icon{
  position:absolute; left:14px; top:50%; transform:translateY(-50%);
  width:16px; height:16px; color:var(--navy); opacity:.28; pointer-events:none;
}
.search-stats{
  font-size:12px; color:#999; margin-top:9px; padding-left:2px;
  letter-spacing:.01em;
}

/* ── Tags ── */
.tag{
  display:inline-flex; align-items:center;
  font-size:12px; font-weight:700;
  padding:4px 12px; letter-spacing:.06em;
  border-radius:4px;
}
.tag-jiko{ background:#2563EB; color:#fff; }
.tag-sozo{ background:#D97706; color:#fff; }

/* ── Count badge ── */
.badge{
  font-size:11px; font-weight:700; padding:3px 11px;
  background:var(--navy); color:#fff;
  letter-spacing:.04em; border-radius:20px;
}
.badge.zero{ background:#bbb; }

/* ── Table ── */
.table-wrap{ overflow-x:auto; }
table{ width:100%; border-collapse:collapse; font-size:13px; }
th{
  background:rgba(25,35,76,.055); color:var(--navy);
  font-size:13px; font-weight:700; letter-spacing:.05em;
  padding:9px 14px; text-align:left;
  border-bottom:1.5px solid rgba(25,35,76,.10); white-space:nowrap;
}
td{
  padding:11px 14px; border-bottom:1px solid rgba(0,0,0,.05);
  vertical-align:top; line-height:1.7;
}
tr:last-child td{ border-bottom:none; }
tr:hover td:not(.year-cell){ background:rgba(25,35,76,.025); transition:background .1s; }
.td-sub{ color:#3a3a3a; font-size:12px; line-height:1.6; }
.th-year{ width:28px; padding:0; border-right:1px solid rgba(25,35,76,.08); }
.year-cell{
  writing-mode:vertical-rl; text-orientation:upright;
  font-size:12px; font-weight:700; letter-spacing:.08em;
  text-align:center; vertical-align:middle;
  width:30px; padding:6px 0;
  border-right:1px solid rgba(0,0,0,.07);
  white-space:nowrap;
}
.year-1{ background:rgba(70,120,200,.13);  color:#2a4a8c; border-right-color:rgba(70,120,200,.25); }
.year-2{ background:rgba(30,160,130,.12);  color:#1a5f4e; border-right-color:rgba(30,160,130,.25); }
.year-3{ background:rgba(200,168,75,.18);  color:#7a5a08; border-right-color:rgba(200,168,75,.35); }
.year-4{ background:rgba(190,70,70,.12);   color:#7a2828; border-right-color:rgba(190,70,70,.25); }
tr.year-start > td{ border-top:2px solid rgba(25,35,76,.11); }
.semester-badge{
  display:inline-block; vertical-align:middle;
  font-size:10px; font-weight:700; white-space:nowrap;
  color:rgba(25,35,76,.6); background:rgba(25,35,76,.08);
  padding:2px 7px; border-radius:20px;
  margin-left:8px; letter-spacing:.04em;
}
/* 科目名の前に置く場合：左マージンを右マージンへ */
.semester-badge--lead{ margin-left:0; margin-right:8px; }
/* 前期＝赤寄り / 後期＝青寄り（ほんのり） */
.semester-badge--spring{
  color:rgba(168,52,52,.7); background:rgba(184,64,64,.10);
}
.semester-badge--fall{
  color:rgba(40,72,150,.7); background:rgba(48,84,168,.10);
}

/* ── States ── */
.state-msg{
  text-align:center; padding:52px 20px;
  font-size:14px; color:#aaa; line-height:1.9;
}
.state-msg .icon{ font-size:34px; display:block; margin-bottom:12px; opacity:.5; }

/* ── Dept group（分野ありの学科をまとめる外枠） ── */
.dept-group{
  background:rgba(255,255,255,.75);
  backdrop-filter:blur(40px); -webkit-backdrop-filter:blur(40px);
  border:1px solid rgba(255,255,255,.88);
  border-radius:var(--r);
  margin-bottom:20px;
  overflow:hidden;
  box-shadow:var(--sh);
}
.dept-group-header{
  display:flex; align-items:center; gap:10px;
  background:rgba(19,35,76,.80);
  color:rgba(255,255,255,.88);
  font-size:14px; font-weight:700;
  padding:10px 20px; letter-spacing:.09em;
}
.dept-group-header::before{
  content:''; display:block; flex-shrink:0;
  width:3px; height:15px;
  background:var(--gold); border-radius:2px;
}

/* ── Dept section（各分野 or 情報工学科単体） ── */
.dept-section{
  background:rgba(255,255,255,.75);
  backdrop-filter:blur(40px); -webkit-backdrop-filter:blur(40px);
  border:1px solid rgba(255,255,255,.88);
  border-radius:var(--r);
  margin-bottom:20px;
  overflow:hidden;
  box-shadow:var(--sh);
}
/* グループ内ではガラス効果・枠・余白をリセット */
.dept-group .dept-section{
  background:none; backdrop-filter:none; -webkit-backdrop-filter:none;
  border:none; border-radius:0; margin:0; box-shadow:none; overflow:visible;
}
.dept-group .dept-section + .dept-section{
  border-top:2px solid rgba(25,35,76,.13);
}
.dept-group .dept-header{
  background:rgba(25,35,76,.04);
}
.dept-group .dept-bunya{
  padding-left:10px;
  border-left:2px solid rgba(200,168,75,.7);
}

.dept-header{
  display:flex; align-items:center; justify-content:space-between;
  flex-wrap:wrap; gap:10px;
  padding:12px 20px;
  background:rgba(25,35,76,.025);
  border-bottom:1px solid rgba(25,35,76,.07);
}
.dept-name-wrap{ display:flex; align-items:center; }
.dept-gakka--solo{ font-size:16.5px; font-weight:700; color:var(--navy); }
.dept-bunya{ font-size:16.5px; font-weight:700; color:var(--navy); }
.dept-meta{ display:flex; align-items:center; gap:8px; flex-shrink:0; }
.dept-section .table-wrap{ padding:2px 16px 16px; }

/* ── Global note ── */
.global-note{
  font-size:12px; color:#777; line-height:1.85;
  margin-top:4px; padding:13px 18px;
  background:rgba(255,255,255,.48);
  border:1px solid rgba(255,255,255,.65);
  border-radius:8px;
  backdrop-filter:blur(20px);
}
