:root {
  --bg: #f3f6fa;
  --surface: #ffffff;
  --ink: #12233b;
  --ink-soft: #5c6d84;
  --ink-faint: #8b9ab0;
  --line: #e3e9f1;
  --brand: #0f766e;
  --brand-2: #0e7490;
  --navy: #0b2138;
  --amber: #f59e0b;
  --blue: #2563eb;
  --green: #15803d;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(16, 38, 66, .06);
  --shadow-md: 0 10px 26px rgba(16, 38, 66, .10);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- 顶部 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 30px;
  color: #fff;
  background: linear-gradient(115deg, #0b2138 0%, #0d3448 52%, #0f766e 100%);
  border-bottom: 3px solid var(--amber);
  box-shadow: 0 8px 24px rgba(8, 30, 50, .18);
}

.brand { display: flex; align-items: center; gap: 14px; min-width: 0; }

.brand-mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: rgba(245, 158, 11, .16);
  border: 1px solid rgba(245, 158, 11, .45);
  color: #fbbf24;
  flex: none;
}
.brand-mark svg { width: 24px; height: 24px; }

.brand-text h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .6px;
  white-space: nowrap;
}
.brand-text h1 span {
  margin-left: 8px;
  font-size: 17px;
  font-weight: 600;
  color: #fcd34d;
  letter-spacing: 2px;
}
.brand-text p {
  margin: 4px 0 0;
  font-size: 12px;
  color: rgba(255, 255, 255, .68);
  letter-spacing: .3px;
  white-space: nowrap;
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 320px;
  max-width: 40vw;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .22);
  color: rgba(255, 255, 255, .8);
  transition: background .15s, border-color .15s;
}
.header-search:focus-within {
  background: rgba(255, 255, 255, .2);
  border-color: rgba(245, 158, 11, .7);
}
.header-search svg { width: 17px; height: 17px; flex: none; }
.header-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: #fff;
  font: inherit;
  font-size: 13px;
}
.header-search input::placeholder { color: rgba(255, 255, 255, .55); }
.header-search input::-webkit-search-cancel-button { filter: invert(1); opacity: .6; }

/* ---------- 布局 ---------- */
main {
  max-width: 1320px;
  margin: 0 auto;
  padding: 26px 30px 60px;
}

.view[hidden] { display: none; }

/* ---------- 主界面滚动公告 ---------- */
.ticker-wrap {
  max-width: 1320px;
  margin: 18px auto 0;
  padding: 0 30px;
}
.ticker-wrap[hidden] { display: none; }
.ticker-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 16px;
  border: 1px solid #fbe0b5;
  border-radius: 12px;
  background: linear-gradient(90deg, #fffaf0 0%, #fff4e2 100%);
}
.ticker-icon { flex: none; width: 17px; height: 17px; color: #ea8a17; }
.ticker-viewport { position: relative; flex: 1; overflow: hidden; }
.ticker-track {
  display: inline-flex;
  white-space: nowrap;
  animation: ticker-scroll 24s linear infinite;
  will-change: transform;
}
.ticker-text {
  padding-right: 80px;
  font-size: 14px;
  letter-spacing: .3px;
  color: #ea8a17;
}
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-33.3333%); }
}

.ticker-admin {
  margin: 18px 0 4px;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}

.section-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 18px;
}
.section-head h2 {
  position: relative;
  margin: 0;
  padding-left: 12px;
  font-size: 17px;
}
.section-head h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  bottom: 2px;
  width: 4px;
  border-radius: 3px;
  background: var(--amber);
}
.section-head p { margin: 0; font-size: 12.5px; color: var(--ink-faint); }

/* ---------- 分层布局 ---------- */
.module-layer[hidden] { display: none; }

.module-layer[data-layer="1"] {
  padding: 20px;
  border: 1px solid #f0e4c5;
  border-radius: 18px;
  background: linear-gradient(135deg, #fffaf0 0%, #f4fbf9 100%);
  box-shadow: var(--shadow-sm);
}

.module-layer[data-layer="1"] .module-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.module-layer + .module-layer { margin-top: 28px; }

.layer-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.layer-badge {
  align-self: center;
  padding: 3px 10px;
  border-radius: 999px;
  background: #fef3c7;
  color: #b45309;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .5px;
}
.module-layer[data-layer="2"] .layer-badge { background: #eef2f7; color: #556476; }

.layer-head h3 { margin: 0; font-size: 15.5px; }
.layer-head p { margin: 0; font-size: 12px; color: var(--ink-faint); }

.module-card.primary {
  padding: 22px;
  border-color: #eedcb4;
}
.module-card.primary::before {
  opacity: 1;
  background: linear-gradient(180deg, var(--amber), #f97316);
}
.module-card.primary .mc-idx {
  background: #fef3c7;
  color: #b45309;
}
.module-card.primary .mc-logo {
  width: 52px;
  height: 52px;
  border-radius: 14px;
}
.module-card.primary .mc-logo svg { width: 27px; height: 27px; }
.module-card.primary .mc-titles h3 { font-size: 18px; }
.module-card.primary .mc-titles p { color: #b45309; }
.module-card.primary:hover { border-color: #e7cd8f; }

/* ---------- 模块卡片 ---------- */
.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(252px, 1fr));
  gap: 16px;
}

.module-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  text-align: left;
  font: inherit;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  overflow: hidden;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.module-card::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--brand), var(--brand-2));
  opacity: 0;
  transition: opacity .16s;
}
.module-card:hover {
  transform: translateY(-3px);
  border-color: #c9e0da;
  box-shadow: var(--shadow-md);
}
.module-card:hover::before { opacity: 1; }
.module-card:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.mc-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.mc-logo {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex: none;
}
.mc-logo svg { width: 23px; height: 23px; }
.mc-top-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}
.mc-idx {
  padding: 2px 7px;
  border-radius: 999px;
  background: #f2f5f9;
  color: var(--ink-faint);
  font-size: 10.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.mc-total { font-size: 11.5px; color: var(--ink-faint); }

.mc-titles h3 {
  margin: 0;
  font-size: 15.5px;
  font-weight: 700;
  line-height: 1.35;
}
.mc-titles p {
  margin: 3px 0 0;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.mc-pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.mc-pills span {
  padding: 4px 9px;
  border-radius: 8px;
  background: #f2f5f9;
  font-size: 11px;
  color: var(--ink-soft);
}
.mc-pills b { margin-left: 4px; color: var(--ink); font-weight: 700; }

.empty-hint {
  padding: 40px 0;
  text-align: center;
  font-size: 13px;
  color: var(--ink-faint);
}

/* ---------- 模块详情 ---------- */
.module-bar {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: color .15s, border-color .15s, background .15s;
}
.back-btn svg { width: 15px; height: 15px; }
.back-btn:hover { color: var(--brand); border-color: #bfe0d8; background: #f4fbf9; }

.module-bar-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.module-logo {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  flex: none;
}
.module-logo svg { width: 22px; height: 22px; }
.module-bar-title h2 { margin: 0; font-size: 20px; }
.module-bar-title span { font-size: 12.5px; color: var(--ink-faint); }

.area-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.area-card {
  display: flex;
  flex-direction: column;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.area-head {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.area-dot {
  width: 9px;
  height: 9px;
  margin-top: 5px;
  border-radius: 50%;
  flex: none;
  background: var(--brand);
}
.area-dot.materials { background: var(--blue); }
.area-dot.templates { background: var(--amber); }
.area-dot.cases { background: var(--green); }

.area-titles { flex: 1; min-width: 0; }
.area-titles h3 { margin: 0; font-size: 14.5px; }
.area-titles p {
  margin: 3px 0 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--ink-faint);
}

.area-count {
  flex: none;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f2f5f9;
  color: var(--ink-soft);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

/* 上传区 */
.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  margin-top: 14px;
  padding: 18px 12px;
  border: 1.5px dashed #cfd9e6;
  border-radius: 12px;
  background: #fafcfe;
  text-align: center;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.dropzone:hover,
.dropzone.dragover {
  border-color: var(--brand);
  background: #f0faf8;
}
.dropzone.uploading { opacity: .72; pointer-events: none; }
.dropzone svg {
  width: 26px;
  height: 26px;
  color: var(--brand);
  opacity: .8;
}
.dz-text { font-size: 13px; color: var(--ink); }
.dz-hint { font-size: 10.5px; color: var(--ink-faint); line-height: 1.5; }

.dz-progress {
  width: 100%;
  height: 4px;
  margin-top: 6px;
  border-radius: 999px;
  background: #e4eaf2;
  overflow: hidden;
}
.dz-bar {
  width: 0;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  transition: width .18s ease;
}

/* 文件列表 */
.file-list {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fcfdff;
  transition: border-color .15s, background .15s;
}
.file-item:hover { border-color: #cddff0; background: #fff; }

.ext-badge {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: #64748b;
  color: #fff;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .4px;
  flex: none;
  overflow: hidden;
}
.ext-badge.pdf { background: #dc2626; }
.ext-badge.doc, .ext-badge.docx { background: #2563eb; }
.ext-badge.xls, .ext-badge.xlsx, .ext-badge.csv { background: #16a34a; }
.ext-badge.ppt, .ext-badge.pptx { background: #ea580c; }
.ext-badge.png, .ext-badge.jpg, .ext-badge.jpeg, .ext-badge.gif, .ext-badge.webp, .ext-badge.bmp, .ext-badge.svg { background: #7c3aed; }
.ext-badge.mp4, .ext-badge.mov, .ext-badge.webm, .ext-badge.avi { background: #0891b2; }
.ext-badge.mp3, .ext-badge.wav, .ext-badge.m4a { background: #db2777; }
.ext-badge.txt, .ext-badge.md { background: #475569; }

.file-info { min-width: 0; }
.file-name {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-name:hover { color: var(--brand); text-decoration: underline; }
.file-meta {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}

.file-actions { display: flex; gap: 2px; flex: none; }
.icon-btn {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-faint);
  cursor: pointer;
  transition: color .15s, background .15s;
}
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn:hover { color: var(--brand); background: #eef7f5; }
.icon-btn.danger:hover { color: #dc2626; background: #fdeeee; }

.file-empty {
  padding: 16px 8px;
  border-radius: 10px;
  background: #f8fafc;
  text-align: center;
  font-size: 11.5px;
  color: var(--ink-faint);
  line-height: 1.6;
}

/* ---------- 账号与登录 ---------- */
.header-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.account-area { display: flex; align-items: center; gap: 8px; }

.login-btn {
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .4);
  background: rgba(255, 255, 255, .14);
  color: #fff;
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.login-btn:hover { background: var(--amber); border-color: var(--amber); color: #3b2600; }

.user-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .2);
}
.user-name {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12.5px;
}
.role-badge {
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
}
.role-badge.admin { background: #fbbf24; color: #3b2600; }
.role-badge.member { background: rgba(255, 255, 255, .22); color: #e2e8f0; }
.coin-badge { font-size: 11px; color: #fcd34d; white-space: nowrap; }
.coin-badge b { font-variant-numeric: tabular-nums; }

.ghost-btn {
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .28);
  background: transparent;
  color: rgba(255, 255, 255, .86);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.ghost-btn:hover { background: rgba(255, 255, 255, .14); color: #fff; }

/* 未登录 / 非管理员的上传提示 */
.upload-locked {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  padding: 18px 12px;
  border: 1.5px dashed #dfe6ef;
  border-radius: 12px;
  background: #f8fafc;
  color: var(--ink-faint);
  font-size: 11.5px;
  text-align: center;
}
.upload-locked svg { width: 20px; height: 20px; }

/* 弹窗 */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(11, 33, 56, .55);
}
.modal-backdrop[hidden] { display: none; }
.modal {
  width: 100%;
  max-width: 400px;
  max-height: calc(100vh - 40px);
  overflow: auto;
  padding: 22px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(8, 30, 50, .3);
}
.modal.wide { max-width: 760px; }
.modal h3 { margin: 0 0 16px; font-size: 17px; }

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
  font-size: 12.5px;
  color: var(--ink-soft);
}
.field[hidden] { display: none; }
.field input,
.field select {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbfcfe;
  font: inherit;
  font-size: 13px;
  color: var(--ink);
  outline: none;
  transition: border-color .15s, background .15s;
}
.field input:focus,
.field select:focus { border-color: var(--brand); background: #fff; }
.field textarea {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbfcfe;
  font: inherit;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  outline: none;
  resize: vertical;
  min-height: 96px;
  transition: border-color .15s, background .15s;
}
.field textarea:focus { border-color: var(--brand); background: #fff; }
.char-count { align-self: flex-end; font-size: 12px; color: var(--ink-faint); }
.char-count b { color: var(--brand); font-weight: 600; }
.message-contact { margin-top: 18px; }
.message-row {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbfcfe;
}
.message-row .message-meta { margin-bottom: 4px; font-size: 12px; color: var(--ink-faint); }
.message-row .message-body {
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  white-space: pre-wrap;
  word-break: break-word;
}

.form-error { min-height: 16px; margin: 0 0 10px; font-size: 12px; color: #dc2626; }
.form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 4px;
}
.form-footer .form-error { margin: 0; flex: 1; }

.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 14px; }
.btn {
  padding: 9px 18px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.btn:hover { border-color: #cfd9e6; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: #0d655e; border-color: #0d655e; }

/* 账号表单与账号列表 */
.account-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 14px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.account-form .form-footer { grid-column: 1 / -1; }

.account-list { margin-top: 16px; display: flex; flex-direction: column; gap: 6px; }
.list-hint { margin: 12px 0 0; font-size: 12px; color: var(--ink-faint); }
.account-row {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) 84px 64px 108px;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 12px;
}
.account-row.head {
  color: var(--ink-faint);
  font-size: 11px;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}
.account-row:not(.head):nth-child(odd) { background: #f8fafc; }
.account-row.clickable { cursor: pointer; transition: background .15s, box-shadow .15s; }
.account-row.clickable:hover { background: #ecf6f4; box-shadow: inset 0 0 0 1px #cdeae4; }
.account-row .role-badge.admin { background: #fef3c7; color: #b45309; }
.account-row .role-badge.member { background: #eef2f7; color: #556476; }
.account-name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-password {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.account-pwd-empty { color: var(--ink-faint); font-style: italic; }
.account-coins { font-variant-numeric: tabular-nums; }
.account-date { color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.account-empty { padding: 18px; text-align: center; font-size: 12px; color: var(--ink-faint); }

/* 关于账号弹窗 */
.about-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 13px;
  line-height: 1.75;
  color: var(--ink);
}
.about-content p { margin: 0; }
.about-content strong { color: var(--ink); font-weight: 600; }
.about-contact {
  padding: 12px 14px;
  border-radius: 10px;
  background: linear-gradient(135deg, #fff1f2 0%, #fff7ed 100%);
  border: 1px solid #fecaca;
  font-size: 13px;
}
.about-contact b {
  font-size: 15px;
  color: #be123c;
  letter-spacing: .5px;
}
.about-contact span {
  display: inline-block;
  margin-top: 4px;
  padding: 1px 8px;
  border-radius: 999px;
  background: rgba(190, 18, 60, .1);
  color: #be123c;
  font-size: 11.5px;
  font-weight: 600;
}

/* ---------- 提示 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translate(-50%, 16px);
  z-index: 50;
  padding: 10px 20px;
  border-radius: 999px;
  background: rgba(11, 33, 56, .92);
  color: #fff;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s, transform .2s;
  max-width: calc(100vw - 40px);
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 响应式 ---------- */
@media (max-width: 1100px) {
  .area-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .site-header { flex-wrap: wrap; gap: 12px; padding: 14px 18px; }
  .header-right { width: 100%; flex-direction: column; align-items: stretch; gap: 10px; }
  .header-search { width: 100%; max-width: none; }
  .account-area { justify-content: flex-end; flex-wrap: wrap; }
  .brand-text p { white-space: normal; }
  main { padding: 20px 16px 48px; }
  .ticker-wrap { padding: 0 16px; }
  .area-grid { grid-template-columns: 1fr; }
  .module-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
  .area-card { padding: 14px; }
  .file-item { grid-template-columns: auto minmax(0, 1fr); }
  .file-actions { grid-column: 1 / -1; justify-content: flex-end; }
  .account-form { grid-template-columns: 1fr; }
  .account-row { grid-template-columns: minmax(0, 1fr) 76px 56px; }
  .account-row .account-password,
  .account-row .account-date,
  .account-row.head span:nth-child(2),
  .account-row.head span:last-child { display: none; }
}
