/* ============================================================
   拾贝集 · 文创产品制作管理系统
   海洋手作风：沙滩暖沙 / 贝壳珠白 / 海水蓝绿 / 珊瑚橙 / 沙金
   ============================================================ */

:root {
  --sand: #f3ead9;          /* 沙滩 */
  --sand-deep: #ece0c9;
  --pearl: #fdfbf6;         /* 贝壳珠白 */
  --ink: #2b4650;           /* 深海墨 */
  --ink-soft: #5a7078;
  --ink-faint: #93a3a6;
  --sea: #2e6f7e;           /* 海水蓝绿 */
  --sea-deep: #1d4e5c;
  --sea-foam: #6fa598;      /* 海沫绿 */
  --coral: #d96f4e;         /* 珊瑚橙 */
  --coral-soft: #e5926f;
  --sand-gold: #cfa96f;     /* 沙金 */
  --line: #e3d5ba;
  --line-soft: #ede2cc;
  --ok: #5d8a6a;
  --warn: #bd8c36;
  --danger: #b2503a;
  --radius: 10px;
  --shadow: 0 8px 28px rgba(43, 70, 80, 0.10);
  --shadow-soft: 0 3px 12px rgba(43, 70, 80, 0.07);
  --font-serif: "Noto Serif SC", "Songti SC", "STSong", "STKaiti", "KaiTi", serif;
  --font-sans: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --wave-light: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120' preserveAspectRatio='none'%3E%3Cpath d='M0,64 C240,104 480,20 720,56 C960,92 1200,28 1440,64 L1440,120 L0,120 Z' fill='%232e6f7e' fill-opacity='0.07'/%3E%3C/svg%3E");
  --wave-mid: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120' preserveAspectRatio='none'%3E%3Cpath d='M0,80 C260,40 520,108 780,72 C1040,36 1240,96 1440,60 L1440,120 L0,120 Z' fill='%232e6f7e' fill-opacity='0.10'/%3E%3C/svg%3E");
  --wave-sidebar: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 80' preserveAspectRatio='none'%3E%3Cpath d='M0,44 C70,64 130,24 200,42 C270,60 330,28 400,46 L400,80 L0,80 Z' fill='%23f6efe0' fill-opacity='0.10'/%3E%3C/svg%3E");
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body { height: 100%; }

body {
  font-family: var(--font-sans);
  color: var(--ink);
  background:
    var(--wave-light) no-repeat bottom / 100% 150px,
    var(--wave-mid) no-repeat bottom / 100% 190px,
    radial-gradient(1100px 500px at 88% -8%, rgba(111, 165, 152, 0.16), transparent 62%),
    radial-gradient(900px 480px at -12% 108%, rgba(207, 169, 111, 0.14), transparent 60%),
    linear-gradient(180deg, #eef3ef 0%, var(--sand) 34%, #efe3cb 100%);
  background-attachment: fixed, fixed, fixed, fixed, fixed;
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, .serif { font-family: var(--font-serif); letter-spacing: 0.04em; }

a { color: var(--sea); text-decoration: none; }

button { font-family: inherit; cursor: pointer; }

/* ---------- 通用组件 ---------- */

.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 18px; border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--pearl); color: var(--ink);
  font-size: 13px; transition: all 0.2s ease;
}
.btn:hover { border-color: var(--sea); color: var(--sea); box-shadow: var(--shadow-soft); }
.btn-primary {
  background: linear-gradient(135deg, var(--sea), var(--sea-deep));
  border-color: var(--sea-deep); color: #f2f6f2;
}
.btn-primary:hover { filter: brightness(1.08); color: #fff; }
.btn-clay { background: linear-gradient(135deg, var(--coral), #c05a3a); border-color: #c05a3a; color: #fdf6ee; }
.btn-clay:hover { filter: brightness(1.06); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--ink-soft); }
.btn-ghost:hover { color: var(--coral); box-shadow: none; }
.btn-sm { padding: 4px 12px; font-size: 12px; border-radius: 6px; }
.btn-danger-ghost { background: transparent; border-color: transparent; color: var(--danger); }
.btn-danger-ghost:hover { background: rgba(178, 80, 58, 0.08); box-shadow: none; }

.card {
  background: var(--pearl);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  padding: 22px 24px;
}

.tag {
  display: inline-block; padding: 2px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.03em;
  border: 1px solid var(--line); color: var(--ink-soft);
  background: var(--sand);
}
/* 角色标签 - 配色区分明显且美观 */
.tag-developer { color: #3730a3; border-color: rgba(55, 48, 163, 0.35); background: rgba(79, 70, 229, 0.1); font-weight: 600; }
.tag-owner { color: #86198f; border-color: rgba(134, 25, 143, 0.35); background: rgba(147, 51, 234, 0.1); font-weight: 600; }
.tag-manager { color: #065f46; border-color: rgba(6, 95, 70, 0.35); background: rgba(5, 150, 105, 0.1); font-weight: 500; }
.tag-employee { color: #92400e; border-color: rgba(146, 64, 14, 0.35); background: rgba(217, 119, 6, 0.1); font-weight: 500; }
.tag-dai { color: var(--sea); border-color: rgba(46, 111, 126, 0.35); background: rgba(46, 111, 126, 0.08); }
.tag-ok { color: var(--ok); border-color: rgba(93, 138, 106, 0.4); background: rgba(93, 138, 106, 0.09); }
.tag-warn { color: var(--warn); border-color: rgba(189, 140, 54, 0.4); background: rgba(189, 140, 54, 0.09); }
.tag-clay { color: var(--coral); border-color: rgba(217, 111, 78, 0.42); background: rgba(217, 111, 78, 0.09); }
.tag-coral { color: #b85338; border-color: rgba(184, 83, 56, 0.45); background: rgba(184, 83, 56, 0.10); }
.tag-gold { color: #a8834a; border-color: rgba(207, 169, 111, 0.55); background: rgba(207, 169, 111, 0.12); }
.tag-muted { color: #7a8a8e; border-color: rgba(122, 138, 142, 0.4); background: rgba(122, 138, 142, 0.09); }

/* ---------- 表单 ---------- */

.field { margin-bottom: 16px; }
.field-row { display: flex; gap: 12px; margin-bottom: 16px; }
.field-row .field { margin-bottom: 0; flex: 1; }
.field label {
  display: block; font-size: 13px; color: var(--ink-soft);
  margin-bottom: 6px; font-family: var(--font-serif); letter-spacing: 0.06em;
}
.field label .req { color: var(--coral); margin-left: 2px; }
.input, .select, .textarea {
  width: 100%; padding: 9px 12px;
  border: 1px solid var(--line); border-radius: 8px;
  background: #fffef9; color: var(--ink);
  font-size: 14px; font-family: var(--font-sans);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none; border-color: var(--sea);
  box-shadow: 0 0 0 3px rgba(46, 111, 126, 0.12);
}
.textarea { resize: vertical; min-height: 80px; }
.select-sm { width: auto; min-width: 104px; padding: 5px 26px 5px 10px; font-size: 12.5px; border-radius: 6px; cursor: pointer; }
.status-pick { background: var(--pearl); border-color: var(--line); color: var(--ink); }
.status-pick:hover { border-color: var(--sea); box-shadow: 0 0 0 3px rgba(46, 111, 126, 0.08); }
.status-pick:focus { border-color: var(--sea); box-shadow: 0 0 0 3px rgba(46, 111, 126, 0.12); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.form-grid .full { grid-column: 1 / -1; }

/* ---------- 表格 ---------- */

.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th {
  text-align: left; padding: 10px 14px;
  font-family: var(--font-serif); font-weight: 600; letter-spacing: 0.06em;
  color: var(--sea-deep); border-bottom: 2px solid var(--line);
  white-space: nowrap; background: rgba(46, 111, 126, 0.05);
}
.table td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.table tbody tr:hover { background: rgba(111, 165, 152, 0.08); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- 登录页 ---------- */

.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 24px; position: relative; overflow: hidden;
  background:
    radial-gradient(700px 320px at 50% -6%, rgba(111, 165, 152, 0.25), transparent 65%),
    linear-gradient(180deg, #e9f1ec 0%, var(--sand) 55%, #ecdDBD 100%);
}
.login-waves { position: absolute; left: 0; right: 0; bottom: 0; pointer-events: none; line-height: 0; }
.login-waves svg { width: 100%; height: 170px; display: block; }
.login-deco { position: absolute; pointer-events: none; }
.login-card {
  width: 100%; max-width: 420px; position: relative; z-index: 1;
  background: rgba(253, 251, 246, 0.94); border: 1px solid var(--line);
  border-radius: 18px; box-shadow: var(--shadow);
  padding: 44px 40px 36px;
  backdrop-filter: blur(4px);
}
.login-brand { text-align: center; margin-bottom: 8px; }
.login-brand .seal {
  display: inline-flex; align-items: center; justify-content: center;
  width: 66px; height: 66px; border-radius: 50% 50% 46% 54% / 56% 56% 44% 44%;
  background: linear-gradient(150deg, var(--coral-soft), var(--coral) 55%, #b95535);
  color: #fdf3e6; font-family: var(--font-serif);
  font-size: 22px; font-weight: 700; letter-spacing: 0.08em;
  box-shadow: 0 10px 22px rgba(217, 111, 78, 0.32), inset 0 -6px 12px rgba(255, 255, 255, 0.22);
  margin-bottom: 14px;
}
.login-brand h1 { font-size: 26px; color: var(--ink); letter-spacing: 0.24em; }
.login-brand p { color: var(--ink-faint); font-size: 12.5px; margin-top: 4px; letter-spacing: 0.14em; }

.login-tabs {
  display: flex; gap: 0; border-bottom: 1px solid var(--line);
  margin: 22px 0 18px;
}
.tab-btn {
  flex: 1; padding: 10px 0; background: transparent; border: none;
  font-size: 14px; color: var(--ink-faint); letter-spacing: 0.15em;
  cursor: pointer; position: relative; transition: color 0.2s;
  font-family: inherit;
}
.tab-btn.active { color: var(--coral); font-weight: 600; }
.tab-btn.active::after {
  content: ""; position: absolute; bottom: -1px; left: 20%; right: 20%;
  height: 2px; background: var(--coral); border-radius: 2px;
}
.auth-form { display: none; }
.auth-form.active { display: block; }

.login-divider {
  display: flex; align-items: center; gap: 12px;
  color: var(--ink-faint); font-size: 12px; margin: 22px 0 18px;
}
.login-divider::before, .login-divider::after {
  content: ""; flex: 1; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}
.quick-accounts { display: flex; gap: 8px; margin-bottom: 18px; }
.quick-accounts button {
  flex: 1; padding: 7px 4px; font-size: 12px;
  border: 1px dashed var(--line); border-radius: 8px;
  background: transparent; color: var(--ink-soft);
  transition: all 0.2s;
}
.quick-accounts button:hover { border-color: var(--sea); color: var(--sea); background: rgba(46, 111, 126, 0.06); }
.login-error {
  display: none; background: rgba(178, 80, 58, 0.09); color: var(--danger);
  border: 1px solid rgba(178, 80, 58, 0.25); border-radius: 8px;
  padding: 8px 12px; font-size: 12.5px; margin-bottom: 14px;
}
.login-error.show { display: block; }
.btn-login { width: 100%; padding: 11px; font-size: 15px; letter-spacing: 0.3em; font-family: var(--font-serif); }

/* ---------- 布局 ---------- */

.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: 232px; flex-shrink: 0;
  background:
    var(--wave-sidebar) no-repeat bottom / 100% 90px,
    linear-gradient(180deg, #173b46 0%, var(--sea-deep) 46%, #265f6d 100%);
  color: #cfe0da; display: flex; flex-direction: column;
  position: fixed; top: 0; bottom: 0; left: 0; z-index: 40;
  transition: transform 0.28s ease;
}
.sidebar-brand {
  padding: 24px 22px 18px; border-bottom: 1px solid rgba(243, 234, 217, 0.12);
  display: flex; align-items: center; gap: 12px;
}
.sidebar-brand .shell-mark { flex-shrink: 0; filter: drop-shadow(0 3px 6px rgba(0,0,0,0.25)); }
.sidebar-brand h2 { color: #f4eddc; font-size: 19px; letter-spacing: 0.22em; }
.sidebar-brand p { font-size: 11px; color: rgba(207, 224, 218, 0.6); letter-spacing: 0.1em; margin-top: 2px; }
.sidebar-nav { flex: 1; padding: 14px 12px; overflow-y: auto; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 14px; margin-bottom: 4px; border-radius: 8px;
  color: rgba(219, 233, 226, 0.85); font-size: 13.5px;
  transition: all 0.18s; letter-spacing: 0.05em;
}
.nav-item svg { width: 17px; height: 17px; flex-shrink: 0; opacity: 0.85; }
.nav-item:hover { background: rgba(243, 234, 217, 0.10); color: #f6f1e2; }
.nav-item.active {
  background: rgba(207, 169, 111, 0.20); color: #f0dcb2;
  box-shadow: inset 2px 0 0 var(--sand-gold);
}
.sidebar-foot {
  padding: 16px 18px 22px; border-top: 1px solid rgba(243, 234, 217, 0.12);
  font-size: 12px; color: rgba(207, 224, 218, 0.62);
}
.sidebar-foot .who { display: flex; align-items: center; gap: 9px; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(207, 169, 111, 0.28); color: #f0dcb2;
  font-family: var(--font-serif); font-size: 14px;
}
.sidebar-foot .name { color: #f2ecd9; font-size: 13px; }
.sidebar-foot .role { font-size: 11px; color: rgba(207, 224, 218, 0.52); }

.main { flex: 1; margin-left: 232px; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  height: 58px; display: flex; align-items: center; gap: 14px;
  padding: 0 26px; border-bottom: 1px solid var(--line-soft);
  background: rgba(243, 234, 217, 0.85); backdrop-filter: blur(6px);
  position: sticky; top: 0; z-index: 30;
}
.topbar .page-title { font-size: 17px; font-family: var(--font-serif); letter-spacing: 0.1em; color: var(--ink); }
.topbar .spacer { flex: 1; }
.topbar .today { font-size: 12.5px; color: var(--ink-faint); }
.hamburger {
  display: none; width: 38px; height: 38px; border: 1px solid var(--line);
  border-radius: 8px; background: var(--pearl); align-items: center; justify-content: center;
}
.hamburger svg { width: 18px; height: 18px; stroke: var(--ink); }

.content { padding: 26px; max-width: 1240px; width: 100%; margin: 0 auto; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h2 { font-size: 22px; color: var(--ink); letter-spacing: 0.08em; }
.page-head .sub { color: var(--ink-faint); font-size: 12.5px; margin-top: 3px; }
.page-head .actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- 看板 ---------- */

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.stat-card { position: relative; overflow: hidden; padding: 20px 22px; }
.stat-card .label { font-size: 12.5px; color: var(--ink-faint); letter-spacing: 0.08em; font-family: var(--font-serif); }
.stat-card .value { font-size: 30px; font-family: var(--font-serif); color: var(--ink); margin-top: 6px; line-height: 1.2; }
.stat-card .value small { font-size: 13px; color: var(--ink-faint); margin-left: 4px; font-family: var(--font-sans); }
.stat-card .hint { font-size: 12px; color: var(--ink-faint); margin-top: 4px; }
.stat-card::after {
  content: ""; position: absolute; right: -18px; top: -18px;
  width: 74px; height: 74px; border-radius: 50%;
  background: radial-gradient(circle, rgba(111, 165, 152, 0.18), transparent 70%);
}
.stat-card.c-dai { border-top: 3px solid var(--sea); }
.stat-card.c-clay { border-top: 3px solid var(--coral); }
.stat-card.c-qing { border-top: 3px solid var(--sea-foam); }
.stat-card.c-gold { border-top: 3px solid var(--sand-gold); }

.dash-grid { display: grid; grid-template-columns: 3fr 2fr; gap: 16px; margin-bottom: 20px; }
.card h3.card-title {
  font-size: 15px; color: var(--sea-deep); letter-spacing: 0.08em;
  padding-bottom: 12px; margin-bottom: 14px; border-bottom: 1px solid var(--line-soft);
  display: flex; align-items: center; justify-content: space-between;
}
.card h3.card-title .more { font-size: 12px; color: var(--ink-faint); font-family: var(--font-sans); }

.chart-box { width: 100%; }
.chart-box svg { width: 100%; height: auto; display: block; }
.legend { display: flex; gap: 16px; font-size: 12px; color: var(--ink-soft); margin-top: 8px; flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; }

/* 表头筛选/排序（共享 .data-table） */
.data-table th { vertical-align: top; }
.data-table .th-filter { min-width: 150px; }
.data-table .th-label { font-size: 13px; color: var(--sea-deep); }
.data-table .th-sortable { cursor: pointer; user-select: none; display: inline-flex; align-items: center; gap: 5px; transition: color 0.15s; }
.data-table .th-sortable:hover { color: var(--coral); }
.sort-arrow { font-size: 11px; color: var(--ink-faint); }
.sort-arrow.active { color: var(--sea); font-weight: 700; }
.data-table .th-ctrl { margin-top: 7px; display: flex; align-items: center; gap: 6px; }
.data-table .th-ctrl .input, .data-table .th-ctrl .select { padding: 5px 8px; font-size: 12.5px; border-radius: 6px; }
.data-table .th-ctrl input[type=date] { width: 132px; }
.data-table .th-ctrl .select { max-width: 100%; }
.data-table .th-ctrl .tilde { color: var(--ink-faint); font-size: 12px; }
.data-table th.num .th-label { justify-content: flex-end; }
.data-table .th-ctrl .input { width: 100%; }

.progress {
  height: 7px; background: var(--sand-deep); border-radius: 999px; overflow: hidden; min-width: 90px;
}
.progress > i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--sea), var(--sea-foam)); }

/* ---------- 项目卡片/列表 ---------- */

.stage-list { border: 1px dashed var(--line); border-radius: 8px; padding: 4px 14px 10px; margin-bottom: 16px; background: rgba(243, 234, 217, 0.5); }
.stage-row { display: grid; grid-template-columns: 1.4fr 1fr 0.8fr 34px; gap: 10px; align-items: center; padding: 10px 0 0; }
.stage-head { font-size: 12px; color: var(--ink-faint); padding-top: 10px; }

.step-list .step-row { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.step-list .step-no {
  width: 24px; height: 24px; border-radius: 50%; flex-shrink: 0;
  background: var(--sand-deep); color: var(--ink-soft);
  font-size: 12px; display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-serif);
}

.detail-block { margin-bottom: 18px; }
.detail-block .dt { font-size: 12px; color: var(--ink-faint); font-family: var(--font-serif); letter-spacing: 0.1em; margin-bottom: 5px; }
.detail-block .dd { color: var(--ink); white-space: pre-wrap; }

/* ---------- 筛选栏 ---------- */

.filter-bar {
  display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end;
  padding: 16px 18px; margin-bottom: 16px;
}
.filter-bar .field { margin-bottom: 0; min-width: 150px; }
.filter-bar .field label { font-size: 12px; margin-bottom: 4px; }

.summary-strip { display: flex; gap: 26px; flex-wrap: wrap; padding: 14px 20px; margin-bottom: 16px; }
.summary-strip .item .k { font-size: 12px; color: var(--ink-faint); font-family: var(--font-serif); letter-spacing: 0.08em; }
.summary-strip .item .v { font-size: 20px; font-family: var(--font-serif); color: var(--coral); }
.summary-strip .item .v small { font-size: 12px; color: var(--ink-faint); font-family: var(--font-sans); }

/* ---------- 空状态 ---------- */

.empty { text-align: center; padding: 48px 20px; color: var(--ink-faint); }
.empty .glyph { font-family: var(--font-serif); font-size: 34px; color: var(--line); margin-bottom: 8px; letter-spacing: 0.2em; }

/* ---------- 上报成功页 ---------- */

.report-done { text-align: center; padding: 40px 20px; }
.report-done .seal-ok {
  width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%;
  background: rgba(93, 138, 106, 0.13); color: var(--ok);
  display: flex; align-items: center; justify-content: center;
}
.report-done .seal-ok svg { width: 30px; height: 30px; }

/* ---------- 模态 ---------- */

.modal-mask {
  position: fixed; inset: 0; background: rgba(43, 70, 80, 0.45);
  z-index: 90; display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal {
  background: var(--pearl); border-radius: 14px; box-shadow: var(--shadow);
  width: 100%; max-width: 560px; max-height: 88vh; overflow-y: auto;
  padding: 26px 28px; border: 1px solid var(--line);
}
.modal h3 { font-size: 17px; color: var(--ink); margin-bottom: 18px; letter-spacing: 0.08em; }

/* ---------- Toast ---------- */

#toast-root { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 120; }
.toast {
  background: var(--ink); color: #f3ead9; padding: 10px 22px;
  border-radius: 999px; font-size: 13px; box-shadow: var(--shadow);
  margin-bottom: 8px; animation: toast-in 0.25s ease; letter-spacing: 0.05em;
}
.toast.ok { background: var(--sea); }
.toast.err { background: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

.sidebar-mask { display: none; }

/* ---------- 响应式 ---------- */

@media (max-width: 1080px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: none; box-shadow: 0 0 60px rgba(0,0,0,0.3); }
  .sidebar-mask.show {
    display: block; position: fixed; inset: 0; z-index: 35;
    background: rgba(43, 70, 80, 0.4);
  }
  .main { margin-left: 0; }
  .hamburger { display: inline-flex; }
  .content { padding: 18px 14px; }
  .form-grid { grid-template-columns: 1fr; }
  .stage-row { grid-template-columns: 1fr 1fr; }
  .stage-row .input { width: 100%; }
}

@media (max-width: 560px) {
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { padding: 14px 16px; }
  .stat-card .value { font-size: 22px; }
  .card { padding: 16px; }
  .login-card { padding: 34px 24px 28px; }
  .topbar { padding: 0 14px; }
  .topbar .today { display: none; }
}
