/* ========== 设计系统变量 ========== */
:root {
  --primary: #3b6cf5;
  --primary-600: #2f5ae0;
  --primary-700: #2849b8;
  --primary-soft: #eaf0ff;
  --primary-soft2: #f3f6ff;
  --indigo: #6366f1;

  --green: #16a34a;
  --green-soft: #e7f7ed;
  --red: #ef4444;
  --red-soft: #fdeaea;
  --orange: #f59e0b;
  --orange-soft: #fef3e2;
  --cyan: #0ea5e9;
  --cyan-soft: #e6f6fe;
  --purple: #8b5cf6;
  --purple-soft: #f1ecfe;

  --ink: #1f2733;
  --ink-2: #44505f;
  --ink-3: #6b7785;
  --ink-4: #9aa5b1;
  --line: #e8ecf1;
  --line-2: #f0f3f7;
  --bg: #f5f7fb;
  --card: #ffffff;

  --radius-s: 8px;
  --radius: 14px;
  --radius-l: 20px;
  --shadow-s: 0 1px 2px rgba(20, 32, 60, .06);
  --shadow: 0 6px 20px rgba(28, 45, 84, .07);
  --shadow-l: 0 16px 40px rgba(28, 45, 84, .14);

  --sidebar-w: 248px;
  --topbar-h: 68px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  font-size: 14px;
  line-height: 1.5;
}
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; font-size: 14px; color: var(--ink); }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
ul { list-style: none; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #d6dce5; border-radius: 8px; }
::-webkit-scrollbar-track { background: transparent; }

/* ========== 布局 ========== */
.app { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: #fff;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
}
.sidebar__brand {
  display: flex; align-items: center; gap: 12px;
  padding: 20px 22px;
}
.brand__logo {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--indigo));
  color: #fff; font-weight: 800; font-size: 20px;
  display: grid; place-items: center;
  box-shadow: 0 6px 16px rgba(59, 108, 245, .35);
}
.brand__text { display: flex; flex-direction: column; }
.brand__title { font-weight: 700; font-size: 16px; }
.brand__sub { font-size: 11px; color: var(--ink-4); }

.sidebar__nav { flex: 1; padding: 8px 12px; overflow-y: auto; }
.nav-group__label {
  font-size: 11px; color: var(--ink-4); font-weight: 600;
  padding: 14px 12px 6px; letter-spacing: .5px;
}
.nav-item {
  display: flex; align-items: center; gap: 12px;
  width: 100%; padding: 11px 12px; border-radius: 10px;
  color: var(--ink-2); font-size: 14px; font-weight: 500;
  margin-bottom: 2px; transition: .16s; position: relative;
}
.nav-item:hover { background: var(--primary-soft2); color: var(--primary); }
.nav-item.active { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.nav-item.active::before {
  content: ""; position: absolute; left: -12px; top: 50%; transform: translateY(-50%);
  width: 3px; height: 18px; background: var(--primary); border-radius: 0 3px 3px 0;
}
.nav-item svg { width: 19px; height: 19px; }
.nav-item__badge {
  margin-left: auto; background: var(--red); color: #fff;
  font-size: 11px; font-weight: 700; min-width: 18px; height: 18px;
  border-radius: 9px; display: grid; place-items: center; padding: 0 5px;
}

.sidebar__user {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px; border-top: 1px solid var(--line); margin: 4px;
}
.sidebar__user-info { display: flex; flex-direction: column; overflow: hidden; }
.sidebar__user-name { font-weight: 600; font-size: 13px; }
.sidebar__user-role { font-size: 11px; color: var(--ink-4); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.main {
  flex: 1; margin-left: var(--sidebar-w);
  display: flex; flex-direction: column; min-width: 0;
}

.topbar {
  height: var(--topbar-h); flex-shrink: 0;
  background: rgba(255,255,255,.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 26px; position: sticky; top: 0; z-index: 30;
}
.topbar__left { display: flex; align-items: center; gap: 12px; }
.topbar__title h1 { font-size: 19px; font-weight: 700; }
.topbar__title p { font-size: 12px; color: var(--ink-4); margin-top: 1px; }
.topbar__right { display: flex; align-items: center; gap: 8px; }
.topbar__avatar { margin-left: 6px; }
.topbar__bell { position: relative; }
.badge-dot {
  position: absolute; top: 4px; right: 4px;
  background: var(--red); color: #fff; font-size: 10px; font-weight: 700;
  min-width: 16px; height: 16px; border-radius: 8px; padding: 0 4px;
  display: grid; place-items: center; border: 2px solid #fff;
}

.iconbtn {
  width: 38px; height: 38px; border-radius: 10px;
  display: grid; place-items: center; color: var(--ink-3);
  transition: .16s;
}
.iconbtn:hover { background: var(--line-2); color: var(--ink); }

.content { padding: 24px 26px 60px; flex: 1; max-width: 1280px; width: 100%; }

.avatar {
  border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--primary), var(--indigo));
  color: #fff; font-weight: 600; flex-shrink: 0;
}
.avatar--sm { width: 34px; height: 34px; font-size: 13px; }
.avatar--md { width: 40px; height: 40px; font-size: 15px; }
.avatar--xs { width: 26px; height: 26px; font-size: 11px; }
.avatar.c2 { background: linear-gradient(135deg, #f59e0b, #f97316); }
.avatar.c3 { background: linear-gradient(135deg, #16a34a, #10b981); }
.avatar.c4 { background: linear-gradient(135deg, #8b5cf6, #d946ef); }
.avatar.c5 { background: linear-gradient(135deg, #0ea5e9, #06b6d4); }
.avatar.c6 { background: linear-gradient(135deg, #ef4444, #f43f5e); }

/* 底部导航 (移动端) */
.tabbar { display: none; }

/* ========== 通用组件 ========== */
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-s);
}
.card--pad { padding: 18px; }

.section-title {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px;
}
.section-title h2 { font-size: 16px; font-weight: 700; }
.section-title .link { color: var(--primary); font-size: 13px; font-weight: 500; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 10px 18px; border-radius: 10px; font-size: 14px; font-weight: 600;
  transition: .16s; white-space: nowrap;
}
.btn svg { width: 17px; height: 17px; }
.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px rgba(59,108,245,.28); }
.btn--primary:hover { background: var(--primary-600); }
.btn--ghost { background: var(--line-2); color: var(--ink-2); }
.btn--ghost:hover { background: #e7ecf3; }
.btn--outline { border: 1px solid var(--line); background: #fff; color: var(--ink-2); }
.btn--outline:hover { border-color: var(--primary); color: var(--primary); }
.btn--danger { background: var(--red-soft); color: var(--red); }
.btn--danger:hover { background: #fbdada; }
.btn--sm { padding: 7px 13px; font-size: 13px; border-radius: 8px; }
.btn--block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600;
}
.tag svg { width: 13px; height: 13px; }
.tag--blue { background: var(--primary-soft); color: var(--primary); }
.tag--green { background: var(--green-soft); color: var(--green); }
.tag--red { background: var(--red-soft); color: var(--red); }
.tag--orange { background: var(--orange-soft); color: var(--orange); }
.tag--cyan { background: var(--cyan-soft); color: var(--cyan); }
.tag--purple { background: var(--purple-soft); color: var(--purple); }
.tag--gray { background: var(--line-2); color: var(--ink-3); }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 20px; font-size: 13px;
  background: var(--line-2); color: var(--ink-2); border: 1px solid transparent;
  transition: .14s; cursor: pointer;
}
.chip:hover { border-color: #d4dbe6; }
.chip.active { background: var(--primary); color: #fff; }
.chip--person {
  background: var(--primary-soft); color: var(--primary); cursor: default;
}
.chip--person .x { cursor: pointer; opacity: .6; }
.chip--person .x:hover { opacity: 1; }

/* 表单 */
.field { margin-bottom: 18px; }
.field__label {
  display: block; font-size: 13px; font-weight: 600; color: var(--ink-2);
  margin-bottom: 7px;
}
.field__label .req { color: var(--red); margin-right: 2px; }
.field__hint { font-size: 12px; color: var(--ink-4); margin-top: 5px; }
.input, .select, .textarea {
  width: 100%; padding: 11px 13px; border: 1px solid var(--line);
  border-radius: 10px; background: #fff; transition: .16s; outline: none;
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.input::placeholder, .textarea::placeholder { color: var(--ink-4); }
.textarea { resize: vertical; min-height: 88px; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7785' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; padding-right: 36px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }

/* 开关 */
.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex-shrink: 0; }
.switch input { display: none; }
.switch .slider { position: absolute; inset: 0; background: #cfd6e0; border-radius: 24px; transition: .2s; }
.switch .slider::before { content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + .slider { background: var(--green); }
.switch input:checked + .slider::before { transform: translateX(18px); }

/* 单选 */
.radio-group { display: flex; gap: 18px; align-items: center; }
.radio { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; font-size: 14px; }
.radio input { display: none; }
.radio .dot { width: 18px; height: 18px; border: 2px solid #cfd6e0; border-radius: 50%; display: grid; place-items: center; transition: .14s; }
.radio input:checked + .dot { border-color: var(--primary); }
.radio input:checked + .dot::after { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--primary); }

/* 空状态 */
.empty { text-align: center; padding: 48px 20px; color: var(--ink-4); }
.empty svg { width: 56px; height: 56px; stroke-width: 1.4; margin-bottom: 12px; opacity: .5; }
.empty p { font-size: 14px; }

/* ========== 工作台 ========== */
.hero {
  background: linear-gradient(120deg, #3b6cf5, #6366f1 60%, #8b5cf6);
  border-radius: var(--radius-l); padding: 26px 28px; color: #fff;
  display: flex; justify-content: space-between; align-items: center;
  position: relative; overflow: hidden; margin-bottom: 22px;
}
.hero::after {
  content: ""; position: absolute; right: -40px; top: -60px;
  width: 240px; height: 240px; border-radius: 50%;
  background: rgba(255,255,255,.12);
}
.hero::before {
  content: ""; position: absolute; right: 80px; bottom: -90px;
  width: 180px; height: 180px; border-radius: 50%;
  background: rgba(255,255,255,.08);
}
.hero__text { position: relative; z-index: 1; }
.hero__hi { font-size: 22px; font-weight: 800; margin-bottom: 6px; }
.hero__sub { font-size: 13px; opacity: .9; max-width: 440px; }
.hero__actions { position: relative; z-index: 1; display: flex; gap: 10px; }
.hero .btn--primary { background: #fff; color: var(--primary); box-shadow: 0 8px 20px rgba(0,0,0,.15); }
.hero .btn--ghost { background: rgba(255,255,255,.2); color: #fff; backdrop-filter: blur(4px); }
.hero .btn--ghost:hover { background: rgba(255,255,255,.3); }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 22px; }
.stat {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; display: flex; align-items: center; gap: 14px; box-shadow: var(--shadow-s);
  transition: .16s; cursor: pointer;
}
.stat:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.stat__icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.stat__icon svg { width: 23px; height: 23px; }
.stat__num { font-size: 24px; font-weight: 800; line-height: 1.1; }
.stat__label { font-size: 12px; color: var(--ink-4); margin-top: 2px; }

.cols { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; align-items: start; }

/* 会议列表项 */
.meet-item {
  display: flex; gap: 14px; padding: 15px; border-radius: var(--radius);
  border: 1px solid var(--line); background: #fff; transition: .16s; cursor: pointer;
  margin-bottom: 10px; box-shadow: var(--shadow-s);
}
.meet-item:hover { border-color: #cdd8 ; box-shadow: var(--shadow); transform: translateY(-1px); }
.meet-item__time {
  width: 58px; flex-shrink: 0; text-align: center; padding-top: 2px;
  border-right: 1px solid var(--line-2);
}
.meet-item__hh { font-size: 17px; font-weight: 800; color: var(--ink); }
.meet-item__dd { font-size: 11px; color: var(--ink-4); margin-top: 2px; }
.meet-item__body { flex: 1; min-width: 0; }
.meet-item__title { font-weight: 700; font-size: 15px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.meet-item__meta { display: flex; gap: 14px; flex-wrap: wrap; color: var(--ink-3); font-size: 12px; margin-top: 7px; }
.meet-item__meta span { display: inline-flex; align-items: center; gap: 5px; }
.meet-item__meta svg { width: 14px; height: 14px; }
.meet-item__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; }
.avatar-stack { display: flex; }
.avatar-stack .avatar { margin-left: -8px; border: 2px solid #fff; }
.avatar-stack .avatar:first-child { margin-left: 0; }
.avatar-stack .more { background: #eef1f6; color: var(--ink-3); font-size: 11px; }

/* 待办 */
.todo-item { display: flex; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line-2); }
.todo-item:last-child { border-bottom: none; }
.todo-item__icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.todo-item__icon svg { width: 18px; height: 18px; }
.todo-item__main { flex: 1; min-width: 0; }
.todo-item__title { font-weight: 600; font-size: 13.5px; }
.todo-item__desc { font-size: 12px; color: var(--ink-4); margin-top: 3px; }

/* ========== 步骤条 ========== */
.steps { display: flex; align-items: center; margin-bottom: 26px; }
.step { display: flex; align-items: center; gap: 10px; }
.step__num {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
  background: #fff; border: 2px solid var(--line); color: var(--ink-4);
  font-weight: 700; font-size: 13px; flex-shrink: 0; transition: .2s;
}
.step__label { font-size: 14px; font-weight: 600; color: var(--ink-4); }
.step__line { flex: 1; height: 2px; background: var(--line); margin: 0 14px; min-width: 30px; border-radius: 2px; }
.step.active .step__num { background: var(--primary); border-color: var(--primary); color: #fff; box-shadow: 0 4px 10px rgba(59,108,245,.35); }
.step.active .step__label { color: var(--primary); }
.step.done .step__num { background: var(--green); border-color: var(--green); color: #fff; }
.step.done .step__label { color: var(--ink); }
.step.done + .step__line, .step.active + .step__line { background: linear-gradient(90deg, var(--green), var(--line)); }

/* 会议类型选择卡 */
.type-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.type-card {
  border: 2px solid var(--line); border-radius: var(--radius); padding: 18px;
  cursor: pointer; transition: .16s; background: #fff; position: relative;
}
.type-card:hover { border-color: #c5d0e8; }
.type-card.active { border-color: var(--primary); background: var(--primary-soft2); }
.type-card.active::after {
  content: "✓"; position: absolute; top: 12px; right: 12px;
  width: 22px; height: 22px; background: var(--primary); color: #fff;
  border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 700;
}
.type-card__icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 12px; }
.type-card__icon svg { width: 24px; height: 24px; }
.type-card__title { font-weight: 700; font-size: 15px; }
.type-card__desc { font-size: 12px; color: var(--ink-4); margin-top: 5px; line-height: 1.5; }

/* 文件上传 */
.upload {
  border: 1.5px dashed var(--line); border-radius: var(--radius); padding: 22px;
  text-align: center; color: var(--ink-4); transition: .16s; cursor: pointer; background: #fafbfd;
}
.upload:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft2); }
.upload svg { width: 30px; height: 30px; margin-bottom: 8px; }
.file-list { margin-top: 12px; }
.file-row {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px;
  background: var(--line-2); border-radius: 10px; margin-bottom: 8px; font-size: 13px;
}
.file-row svg { width: 18px; height: 18px; color: var(--primary); flex-shrink: 0; }
.file-row .name { flex: 1; }
.file-row .size { color: var(--ink-4); font-size: 12px; }

.form-foot { display: flex; justify-content: flex-end; gap: 12px; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }

/* ========== 会议室预定 ========== */
.filter-bar { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 6px; margin-bottom: 18px; }
.filter-row { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-bottom: 1px solid var(--line-2); }
.filter-row:last-child { border-bottom: none; }
.filter-row__icon { width: 32px; height: 32px; border-radius: 9px; background: var(--primary-soft); color: var(--primary); display: grid; place-items: center; flex-shrink: 0; }
.filter-row__icon svg { width: 17px; height: 17px; }
.filter-tabs { display: flex; gap: 8px; flex-wrap: wrap; flex: 1; }
.filter-tab {
  padding: 7px 16px; border-radius: 9px; font-size: 13.5px; font-weight: 500;
  color: var(--ink-2); transition: .14s; background: transparent;
}
.filter-tab:hover { background: var(--line-2); }
.filter-tab.active { background: var(--primary); color: #fff; font-weight: 600; box-shadow: 0 4px 10px rgba(59,108,245,.25); }
.filter-time { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.filter-time .input { width: auto; min-width: 130px; }

.legend { display: flex; gap: 18px; margin-bottom: 14px; font-size: 12.5px; color: var(--ink-3); flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }

.room-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.room-card {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 14px;
  background: #fff; cursor: pointer; transition: .16s; position: relative; text-align: center;
  box-shadow: var(--shadow-s);
}
.room-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.room-card.occupied { background: var(--red-soft); border-color: #f6cccc; }
.room-card.free { background: var(--green-soft); border-color: #c7ebd4; }
.room-card.selected { background: var(--primary); border-color: var(--primary); box-shadow: 0 10px 24px rgba(59,108,245,.35); }
.room-card.selected .room-card__no, .room-card.selected .room-card__cap, .room-card.selected svg { color: #fff; }
.room-card__cap { font-size: 12px; font-weight: 600; margin-bottom: 6px; color: var(--ink-3); }
.room-card.occupied .room-card__cap { color: var(--red); }
.room-card.free .room-card__cap { color: var(--green); }
.room-card__fig { display: grid; place-items: center; margin: 4px 0 10px; height: 46px; }
.room-card__fig svg { width: 44px; height: 44px; stroke-width: 1.6; }
.room-card.occupied svg { color: #e87878; }
.room-card.free svg { color: #4cb877; }
.room-card__no { font-weight: 800; font-size: 17px; }
.room-card__status { position: absolute; top: 8px; right: 8px; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 20px; }
.room-card.occupied .room-card__status { background: var(--red); color: #fff; }
.room-card.free .room-card__status { background: var(--green); color: #fff; }

/* 房间详情面板 */
.room-detail { display: grid; grid-template-columns: 200px 1fr; gap: 20px; }
.room-detail__img {
  border-radius: var(--radius); height: 150px; background: linear-gradient(135deg, #dbe6ff, #eef2ff);
  display: grid; place-items: center; color: var(--primary); overflow: hidden;
}
.room-detail__img svg { width: 56px; height: 56px; stroke-width: 1.2; }
.room-detail__info { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 24px; }
.detail-cell__label { font-size: 12px; color: var(--ink-4); margin-bottom: 4px; display: flex; align-items: center; gap: 5px; }
.detail-cell__label::before { content: ""; width: 3px; height: 12px; background: var(--orange); border-radius: 2px; }
.detail-cell__value { font-weight: 600; font-size: 14px; }

/* 时间轴预定 */
.booking-tl { margin-top: 4px; }
.booking-tl__row { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.booking-tl__row:last-child { border-bottom: none; }
.booking-tl__time { font-weight: 700; color: var(--primary); min-width: 110px; display: flex; align-items: center; gap: 6px; }
.booking-tl__time svg { width: 15px; height: 15px; }

/* ========== 会议详情 ========== */
.detail-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.detail-title { font-size: 22px; font-weight: 800; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.detail-meta-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px 28px; margin-top: 6px; }
.dm { display: flex; gap: 10px; }
.dm__icon { width: 36px; height: 36px; border-radius: 10px; background: var(--primary-soft); color: var(--primary); display: grid; place-items: center; flex-shrink: 0; }
.dm__icon svg { width: 18px; height: 18px; }
.dm__label { font-size: 12px; color: var(--ink-4); }
.dm__value { font-weight: 600; font-size: 14px; margin-top: 1px; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tab {
  padding: 12px 16px; font-size: 14px; font-weight: 600; color: var(--ink-3);
  border-bottom: 2px solid transparent; transition: .14s; white-space: nowrap;
}
.tab:hover { color: var(--ink); }
.tab.active { color: var(--primary); border-bottom-color: var(--primary); }

.person-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.person-card { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; }
.person-card__name { font-weight: 600; font-size: 13.5px; }
.person-card__dept { font-size: 11px; color: var(--ink-4); }
.person-card__check { margin-left: auto; }

.timeline { position: relative; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.tl-node { position: relative; padding-bottom: 22px; }
.tl-node:last-child { padding-bottom: 0; }
.tl-node::before { content: ""; position: absolute; left: -23px; top: 3px; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--line); }
.tl-node.done::before { border-color: var(--green); background: var(--green); }
.tl-node.active::before { border-color: var(--primary); background: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
.tl-node__title { font-weight: 700; font-size: 14px; }
.tl-node__time { font-size: 12px; color: var(--ink-4); margin: 2px 0 4px; }
.tl-node__desc { font-size: 13px; color: var(--ink-2); }

/* 材料 */
.material-row { display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; }
.material-row__icon { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.material-row__icon svg { width: 22px; height: 22px; }

/* 签到进度 */
.signin-stat { display: flex; align-items: center; gap: 22px; padding: 18px; background: var(--primary-soft2); border-radius: var(--radius); margin-bottom: 18px; }
.ring { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.ring__inner { width: 64px; height: 64px; border-radius: 50%; background: #fff; display: grid; place-items: center; flex-direction: column; }
.ring__num { font-size: 20px; font-weight: 800; color: var(--primary); }
.ring__label { font-size: 10px; color: var(--ink-4); }

/* 纪要编辑 */
.minutes-editor { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.minutes-toolbar { display: flex; gap: 4px; padding: 8px; border-bottom: 1px solid var(--line); background: #fafbfd; flex-wrap: wrap; }
.minutes-toolbar button { width: 32px; height: 32px; border-radius: 7px; color: var(--ink-3); display: grid; place-items: center; font-weight: 700; }
.minutes-toolbar button:hover { background: var(--line-2); color: var(--ink); }
.minutes-body { padding: 18px; min-height: 220px; outline: none; line-height: 1.7; }
.minutes-body:focus { background: #fff; }
.minutes-body h3 { margin: 16px 0 8px; font-size: 15px; }
.minutes-body p { margin-bottom: 8px; }
.minutes-body ul { list-style: disc; padding-left: 22px; margin-bottom: 8px; }

/* 待办分工表 */
.task-table { width: 100%; border-collapse: collapse; }
.task-table th, .task-table td { padding: 11px 12px; text-align: left; font-size: 13px; border-bottom: 1px solid var(--line-2); }
.task-table th { font-size: 12px; color: var(--ink-4); font-weight: 600; background: #fafbfd; }
.task-table tr:hover td { background: #fafbfd; }

/* ========== 弹层 ========== */
.modal-root { position: fixed; inset: 0; z-index: 100; pointer-events: none; }
.modal-mask { position: absolute; inset: 0; background: rgba(20,30,55,.45); opacity: 0; transition: .2s; backdrop-filter: blur(2px); }
.modal-mask.show { opacity: 1; }
.modal {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -46%);
  background: #fff; border-radius: var(--radius-l); box-shadow: var(--shadow-l);
  width: min(560px, calc(100vw - 32px)); max-height: 86vh; display: flex; flex-direction: column;
  opacity: 0; transition: .22s;
}
.modal.show { transform: translate(-50%, -50%); opacity: 1; }
.modal__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal__title { font-size: 17px; font-weight: 700; }
.modal__body { padding: 22px; overflow-y: auto; }
.modal__foot { padding: 16px 22px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 12px; }

/* 选人 */
.picker-search { position: relative; margin-bottom: 14px; }
.picker-search .input { padding-left: 38px; }
.picker-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-4); width: 17px; height: 17px; }
.dept-block { margin-bottom: 14px; }
.dept-block__name { font-size: 12px; color: var(--ink-4); font-weight: 600; margin-bottom: 8px; }
.pick-person { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; cursor: pointer; transition: .12s; }
.pick-person:hover { background: var(--line-2); }
.pick-person.checked { background: var(--primary-soft); }
.pick-person__check { width: 20px; height: 20px; border: 2px solid #cfd6e0; border-radius: 6px; display: grid; place-items: center; margin-left: auto; flex-shrink: 0; transition: .12s; }
.pick-person.checked .pick-person__check { background: var(--primary); border-color: var(--primary); color: #fff; }
.pick-person__check svg { width: 13px; height: 13px; opacity: 0; }
.pick-person.checked .pick-person__check svg { opacity: 1; }

/* Toast */
.toast-root { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 10px; align-items: center; pointer-events: none; }
.toast {
  background: var(--ink); color: #fff; padding: 11px 20px; border-radius: 10px;
  font-size: 14px; font-weight: 500; box-shadow: var(--shadow-l);
  display: flex; align-items: center; gap: 8px;
  opacity: 0; transform: translateY(-12px); transition: .25s; max-width: 90vw;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast svg { width: 18px; height: 18px; }
.toast--success { background: #1f9254; }
.toast--error { background: #d33; }
.toast--info { background: var(--primary-600); }

/* 杂项 */
.pill-tabs { display: inline-flex; background: var(--line-2); border-radius: 12px; padding: 4px; gap: 4px; margin-bottom: 18px; flex-wrap: wrap; }
.pill-tab { padding: 8px 16px; border-radius: 9px; font-size: 13.5px; font-weight: 600; color: var(--ink-3); transition: .14s; }
.pill-tab.active { background: #fff; color: var(--primary); box-shadow: var(--shadow-s); }
.divider { height: 1px; background: var(--line); margin: 18px 0; }
.mb0 { margin-bottom: 0 !important; }
.mt16 { margin-top: 16px; }
.text-muted { color: var(--ink-4); }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap8 { gap: 8px; }
.gap12 { gap: 12px; }
.wrap { flex-wrap: wrap; }

/* 服务项 */
.service-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 28px; }
.service-item { display: flex; align-items: center; gap: 10px; }
.service-item label { flex-shrink: 0; width: 92px; font-size: 13px; color: var(--ink-2); font-weight: 500; }
.service-item .input { flex: 1; }
.service-item .unit { color: var(--ink-4); font-size: 13px; }

/* 会议服务锁定（领导未参会） */
.service-block--locked {
  opacity: .78;
  cursor: not-allowed;
  position: relative;
}
.service-block--locked .switch { pointer-events: none; }
.service-block--locked h2 { color: var(--ink-4); }
.service-block[data-tip] { position: relative; }
.service-block[data-tip]:hover::after {
  content: attr(data-tip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%);
  background: var(--ink);
  color: #fff;
  font-size: 12px;
  line-height: 1.4;
  padding: 8px 12px;
  border-radius: 8px;
  white-space: nowrap;
  pointer-events: none;
  z-index: 5;
  box-shadow: var(--shadow);
}
.service-block[data-tip]:hover::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--ink);
  pointer-events: none;
  z-index: 5;
}

/* 更多安全设置 */
.sec-more-link {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 12px; padding: 0; border: none; background: none;
  color: var(--primary); font-size: 13.5px; font-weight: 500; cursor: pointer;
}
.sec-more-link svg { width: 16px; height: 16px; }
.sec-more-link:hover { color: var(--primary-600); }

.sec-modal { display: flex; gap: 0; min-height: 320px; margin: -4px -2px; }
.sec-modal__nav {
  width: 132px; flex-shrink: 0; border-right: 1px solid var(--line);
  padding: 8px 0; display: flex; flex-direction: column; gap: 4px;
}
.sec-nav {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 14px; border: none; background: none;
  color: var(--ink-3); font-size: 13.5px; font-weight: 500; text-align: left; cursor: pointer;
}
.sec-nav svg { width: 16px; height: 16px; flex-shrink: 0; }
.sec-nav:hover { background: var(--line-2); color: var(--ink); }
.sec-nav.active { background: var(--primary-soft); color: var(--primary); font-weight: 600; }

.sec-modal__main { flex: 1; padding: 4px 8px 4px 20px; overflow-y: auto; }
.sec-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 0; border-bottom: 1px solid var(--line-2);
}
.sec-row:last-of-type { border-bottom: none; }
.sec-row__label { font-size: 14px; color: var(--ink-2); flex-shrink: 0; min-width: 88px; }
.sec-row .select { width: min(280px, 100%); }

.sec-checks { padding-top: 8px; display: flex; flex-direction: column; gap: 14px; }
.sec-check {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  font-size: 14px; color: var(--ink-2);
}
.sec-check input { width: 16px; height: 16px; accent-color: var(--primary); flex-shrink: 0; }
.sec-info { display: inline-flex; color: var(--ink-4); vertical-align: middle; }
.sec-info svg { width: 15px; height: 15px; }

/* ========== 响应式 ========== */
@media (max-width: 900px) {
  :root { --topbar-h: 56px; }
  .sidebar { display: none; }
  .main { margin-left: 0; padding-bottom: 70px; }
  .content { padding: 16px 14px 40px; }
  .topbar { padding: 0 14px; }
  .topbar__title h1 { font-size: 17px; }
  .topbar__title p { display: none; }

  .tabbar {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
    background: rgba(255,255,255,.96); backdrop-filter: blur(12px);
    border-top: 1px solid var(--line); padding: 6px 4px 8px;
    justify-content: space-around;
  }
  .tab-btn {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    color: var(--ink-4); font-size: 10.5px; font-weight: 500; flex: 1; padding: 4px 0; position: relative;
  }
  .tab-btn svg { width: 22px; height: 22px; }
  .tab-btn.active { color: var(--primary); }
  .tab-btn.active svg { stroke-width: 2.4; }
  .tab-btn__badge { position: absolute; top: 0; right: 50%; margin-right: -20px; background: var(--red); color: #fff; font-size: 9px; font-weight: 700; min-width: 15px; height: 15px; border-radius: 8px; display: grid; place-items: center; padding: 0 4px; border: 1.5px solid #fff; }
  .tab-fab {
    margin-top: -22px; width: 50px; height: 50px; border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--indigo)); color: #fff;
    box-shadow: 0 8px 18px rgba(59,108,245,.4); display: grid; place-items: center; flex: 0 0 auto;
  }
  .tab-fab svg { width: 26px; height: 26px; stroke-width: 2.4; }

  .stat-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .cols { grid-template-columns: 1fr; }
  .grid-2, .grid-3, .grid-4, .field-row, .type-cards, .service-grid, .detail-meta-grid, .room-detail__info { grid-template-columns: 1fr; }
  .room-detail { grid-template-columns: 1fr; }
  .hero { flex-direction: column; align-items: flex-start; gap: 16px; padding: 22px; }
  .hero__actions { width: 100%; }
  .hero__actions .btn { flex: 1; }
  .hero__hi { font-size: 19px; }
  .steps { overflow-x: auto; }
  .step__label { font-size: 13px; }
  .mobile-back { display: grid !important; }
  .room-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
  .form-foot { flex-direction: column-reverse; }
  .form-foot .btn { width: 100%; }
  .detail-title { font-size: 19px; }
  .modal { width: calc(100vw - 24px); }
}

@media (min-width: 901px) {
  .topbar__menu { display: none; }
}
