:root {
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --tertiary: #86868b;
  --line: #dedee3;
  --line-light: #ececef;
  --paper: #ffffff;
  --surface: #f5f5f7;
  --panel-soft: #fbfbfd;
  --accent: #111111;
  --accent-deep: #000000;
  --accent-soft: #f0f0f2;
  --blue: #1d1d1f;
  --blue-soft: #f5f5f7;
  --green: #1d1d1f;
  --green-soft: #f5f5f7;
  --red: #c9342f;
  --red-soft: #fff2f1;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --shadow: 0 12px 35px rgba(0, 0, 0, 0.08);
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.04);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff 0%, var(--surface) 46%, #ffffff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

button,
input,
select {
  font: inherit;
}

button {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

button:hover {
  border-color: #b8b8bf;
  box-shadow: var(--shadow-sm);
}

button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid #111;
  outline-offset: 2px;
}

button:disabled,
input:disabled,
select:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.primary {
  border-color: var(--accent);
  background: linear-gradient(180deg, #222, #050505);
  color: #fff;
}

.app {
  min-height: 100vh;
}

.login {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
}

.login-box {
  width: min(100%, 360px);
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.login-box h1 {
  margin: 0 0 18px;
  font-size: 24px;
}

.home {
  min-height: 100vh;
  padding: 28px;
  background: var(--surface);
}

.home-main,
.manage-shell {
  width: min(100%, 1040px);
  margin: 0 auto;
}

.app-topbar {
  padding: 18px 0;
}

.top-actions {
  display: flex;
  gap: 8px;
}

.entry-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 28px;
}

.entry-card {
  display: grid;
  place-items: center;
  min-height: 180px;
  border-color: #b9c0ca;
  background: #fff;
  font-size: 30px;
  font-weight: 750;
}

.entry-card:hover {
  border-color: var(--blue);
}

.muted-card {
  color: #98a2b3;
  cursor: default;
}

.manage-shell {
  min-height: 100vh;
  padding: 24px;
}

.manage-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.stat-card {
  display: grid;
  gap: 12px;
  min-height: 138px;
  padding: 20px;
  border: 1px solid rgba(222, 222, 227, 0.88);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(246, 246, 248, 0.92)),
    linear-gradient(90deg, rgba(20, 20, 22, 0.04), rgba(142, 142, 147, 0.08));
  box-shadow: 0 10px 28px rgba(20, 20, 22, 0.06);
}

.stat-card span,
.stat-card small {
  color: var(--muted);
  font-size: 13px;
}

.stat-card strong {
  color: var(--accent-deep);
  font-size: 32px;
  line-height: 1.1;
}

.stat-card em {
  margin-left: 6px;
  color: var(--muted);
  font-size: 15px;
  font-style: normal;
}

.metric,
.manage-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.metric {
  display: grid;
  gap: 4px;
  padding: 18px;
}

.metric strong {
  font-size: 28px;
}

.metric span,
.module-row span,
.user-row span {
  color: var(--muted);
}

.manage-panel {
  margin-top: 16px;
  padding: 16px;
}

.manage-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.manage-tabs button {
  background: #f8fafc;
}

.manage-tabs .active-tab {
  border-color: var(--blue);
  background: #eff6ff;
  color: var(--blue);
  font-weight: 700;
}

.manage-filter,
.settings-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.settings-form button,
.manage-filter button {
  align-self: end;
}

.table-list {
  display: grid;
  gap: 8px;
}

.table-row,
.permission-row {
  display: grid;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font-size: 13px;
}

.invoice-row {
  grid-template-columns: 34px 120px minmax(120px, 1fr) 90px 90px 70px auto auto auto auto;
}

.spec-row {
  grid-template-columns: 1.5fr 70px 90px 90px 70px 70px auto auto;
}

.user-manage-row {
  grid-template-columns: 80px 1fr 100px 70px auto auto;
}

.log-row {
  grid-template-columns: 180px 90px 90px 1fr;
}

.permission-row {
  align-items: stretch;
}

.manage-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 10px 0 14px;
  padding: 10px;
  border: 1px solid rgba(222, 222, 227, 0.72);
  border-radius: 8px;
  background: rgba(246, 246, 248, 0.88);
  color: var(--muted);
  font-size: 13px;
}

.manage-toolbar button {
  min-height: 32px;
}

.invoice-edit-panel {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid rgba(222, 222, 227, 0.88);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 26px rgba(20, 20, 22, 0.07);
}

.edit-items {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.edit-item-row {
  display: grid;
  grid-template-columns: 1.2fr 1.5fr 70px 90px 90px 90px 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(222, 222, 227, 0.74);
  border-radius: 8px;
  background: var(--panel-soft);
}

.readonly-note {
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.permission-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.inline-check {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-weight: 500;
}

.inline-check input {
  width: 16px;
  min-height: 16px;
}

.empty-state {
  padding: 20px;
  border: 1px dashed var(--line);
  border-radius: 6px;
  color: var(--muted);
  text-align: center;
}

.module-list,
.user-list {
  display: grid;
  gap: 8px;
}

.module-row,
.user-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.user-row {
  grid-template-columns: 80px 1fr 120px 80px;
}

.module-off {
  background: #f8f9fb;
}

label {
  display: grid;
  gap: 6px;
  margin-bottom: 10px;
  color: #344054;
  font-size: 13px;
  font-weight: 650;
}

input,
select {
  width: 100%;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 7px 9px;
}

input[readonly] {
  background: #f8fafc;
}

.ship-options {
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
}

.ship-options legend {
  padding: 0 4px;
  color: #344054;
  font-size: 13px;
  font-weight: 650;
}

.ship-options label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
}

.ship-options input {
  width: 18px;
  min-height: 18px;
}

.error {
  color: var(--accent);
  min-height: 22px;
}

.shell {
  display: grid;
  grid-template-columns: 420px 1fr;
  min-height: 100vh;
}

.sidebar {
  height: 100vh;
  overflow: auto;
  border-right: 1px solid var(--line);
  background: #fff;
  padding: 18px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.topbar h1,
.section-title h2 {
  margin: 0;
}

.role {
  color: var(--muted);
  font-size: 13px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.wide {
  grid-column: 1 / -1;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 16px 0 10px;
}

.items {
  display: grid;
  gap: 10px;
}

.item {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.item .product,
.item .spec,
.item .remark {
  grid-column: 1 / -1;
}

.item .remove {
  grid-column: 1 / -1;
}

.actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.records {
  display: grid;
  gap: 8px;
}

.record {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-size: 13px;
}

.record small {
  display: block;
  color: var(--muted);
}

.cancel-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  margin-left: 6px;
  padding: 0 7px;
  border: 1px solid rgba(180, 35, 24, 0.25);
  border-radius: 999px;
  background: var(--red-soft);
  color: var(--red);
  font-size: 12px;
}

.preview-wrap {
  height: 100vh;
  overflow: auto;
  padding: 28px;
  background: #e9edf2;
}

.preview {
  width: min(100%, 1120px);
  margin: 0 auto;
  background: #fff;
  box-shadow: 0 10px 34px rgba(16, 24, 40, 0.18);
}

.dream-note {
  width: 100%;
  min-height: 650px;
  padding: 38px 34px 40px;
  background: #fff;
  color: #000;
  font-family: "Songti SC", "SimSun", serif;
  font-size: 22px;
}

.dream-title {
  display: grid;
  place-items: center;
  gap: 8px;
  margin-bottom: 54px;
  font-size: 54px;
  font-weight: 700;
  line-height: 1.08;
}

.dream-meta {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
  margin-bottom: 18px;
  font-size: 22px;
}

.hot {
  color: #c51634;
}

.dream-grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  border: 2px solid #000;
  font-size: 22px;
}

.dream-grid th,
.dream-grid td {
  height: 50px;
  border: 2px solid #000;
  padding: 6px 10px;
  text-align: center;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

.dream-grid .left {
  text-align: left;
  padding-left: 18px;
}

.dream-grid .head-row th {
  font-weight: 500;
}

.project-cell {
  width: 58px;
  font-size: 26px;
}

.ship-print {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 80px;
  width: 100%;
  min-height: 44px;
}

.ship-print span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.delivery-note {
  position: relative;
  width: 100%;
  min-height: 560px;
  padding-right: 46px;
  border: 1.5px solid #000;
  background: #fff;
  color: #000;
  font-family: "Songti SC", "SimSun", serif;
  font-size: 20px;
  font-weight: 700;
}

.delivery-copy {
  position: absolute;
  top: 178px;
  right: 8px;
  width: 28px;
  line-height: 1.45;
  text-align: center;
  writing-mode: vertical-rl;
}

.delivery-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 44px;
  border-bottom: 1.5px solid #000;
  text-align: center;
  font-size: 26px;
  line-height: 1.15;
}

.delivery-title b {
  margin-left: 4px;
  color: #e60012;
}

.delivery-grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.delivery-grid th,
.delivery-grid td {
  height: 36px;
  border-right: 1.5px solid #000;
  border-bottom: 1.5px solid #000;
  padding: 2px 6px;
  text-align: center;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

.delivery-grid tr > *:last-child {
  border-right: 0;
}

.meta-grid th {
  width: 92px;
  text-align: right;
}

.meta-grid td:nth-child(2) {
  width: 52%;
  text-align: left;
}

.meta-grid td:nth-child(4) {
  width: 30%;
  text-align: left;
}

.delivery-footer {
  text-align: center;
}

.delivery-footer > div:first-child {
  height: 30px;
  border-bottom: 1.5px solid #000;
  line-height: 30px;
  font-size: 24px;
}

.footer-line {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  min-height: 58px;
}

.footer-line span {
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1.5px solid #000;
}

.footer-line span:last-child {
  border-right: 0;
}

.seal-box {
  color: rgba(180, 35, 24, 0.76);
  border: 2px dashed rgba(180, 35, 24, 0.76) !important;
  margin: 8px;
  font-size: 18px;
}

.brand-mark {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(142, 142, 147, 0.28);
  border-radius: 10px;
  background: linear-gradient(135deg, #ffffff, #f0f0f2);
  color: var(--accent-deep);
  font-weight: 850;
  letter-spacing: 0;
  box-shadow: 0 8px 22px rgba(20, 20, 22, 0.08);
}

.app-brandline,
.login-brand,
.manage-head,
.home-hero {
  display: flex;
  align-items: center;
  gap: 12px;
}

.login {
  background:
    linear-gradient(135deg, rgba(142, 142, 147, 0.12), transparent 36%),
    radial-gradient(circle at 78% 20%, rgba(20, 20, 22, 0.08), transparent 30%),
    var(--surface);
}

.login-box {
  width: min(100%, 390px);
  padding: 30px;
  border-color: rgba(222, 222, 227, 0.88);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.login-brand {
  margin-bottom: 24px;
}

.login-brand h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.18;
}

.login-brand p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}

.home {
  padding: 30px 20px;
}

.home-main,
.manage-shell {
  width: min(100%, 1120px);
}

.app-topbar {
  margin-bottom: 18px;
  padding: 12px 0;
}

.app-topbar h1 {
  font-size: 24px;
  line-height: 1.12;
}

.top-actions button {
  min-width: 72px;
  border-color: rgba(222, 222, 227, 0.95);
  background: rgba(255, 255, 255, 0.78);
}

.home-hero,
.manage-head {
  justify-content: space-between;
  margin: 12px 0 18px;
  padding: 24px;
  border: 1px solid rgba(222, 222, 227, 0.8);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(246, 246, 248, 0.82)),
    linear-gradient(90deg, rgba(20, 20, 22, 0.04), rgba(142, 142, 147, 0.08));
  box-shadow: var(--shadow);
}

.home-hero h2,
.manage-head h2 {
  margin: 4px 0 0;
  font-size: 34px;
  line-height: 1.1;
}

.eyebrow {
  margin: 0;
  color: var(--accent-deep);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.role-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(46, 118, 87, 0.2);
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 13px;
  font-weight: 750;
  white-space: nowrap;
}

.entry-grid {
  gap: 18px;
  margin-top: 18px;
}

.entry-card {
  position: relative;
  justify-items: start;
  min-height: 190px;
  padding: 26px;
  overflow: hidden;
  border-color: rgba(222, 222, 227, 0.9);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 34px rgba(20, 20, 22, 0.08);
}

.entry-card::after {
  content: "";
  position: absolute;
  right: 24px;
  bottom: 24px;
  width: 78px;
  height: 78px;
  border: 1px solid rgba(49, 95, 131, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(49, 95, 131, 0.1) 1px, transparent 1px),
    linear-gradient(rgba(49, 95, 131, 0.1) 1px, transparent 1px);
  background-size: 18px 18px;
}

.entry-card b {
  color: var(--accent);
  font-size: 14px;
}

.entry-card span {
  margin-top: 18px;
  font-size: 34px;
}

.entry-card:hover {
  border-color: rgba(20, 20, 22, 0.28);
  transform: translateY(-2px);
}

.muted-card {
  background: rgba(248, 248, 246, 0.82);
}

.manage-shell {
  padding: 28px 20px 40px;
}

.manage-grid {
  gap: 14px;
}

.metric,
.manage-panel,
.module-row,
.user-row,
.record,
.item,
.table-row,
.permission-row,
.empty-state {
  border-color: rgba(222, 222, 227, 0.88);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 22px rgba(20, 20, 22, 0.05);
}

.metric {
  min-height: 104px;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(246, 246, 248, 0.95)),
    linear-gradient(90deg, rgba(20, 20, 22, 0.04), rgba(142, 142, 147, 0.08));
}

.metric strong {
  color: var(--accent-deep);
  font-size: 32px;
}

.manage-panel {
  margin-top: 18px;
  padding: 18px;
}

.manage-tabs {
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(222, 222, 227, 0.76);
}

.manage-tabs button {
  min-height: 38px;
  border-color: transparent;
  background: var(--panel-soft);
  color: #4f554d;
}

.manage-tabs .active-tab {
  border-color: rgba(20, 20, 22, 0.28);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

label {
  color: #4d5149;
}

input,
select {
  border-color: rgba(222, 222, 227, 0.95);
  background: #ffffff;
  color: var(--ink);
  outline: none;
}

input:focus,
select:focus {
  border-color: rgba(20, 20, 22, 0.46);
  box-shadow: 0 0 0 3px rgba(20, 20, 22, 0.08);
}

input[readonly] {
  background: #f5f5f7;
  color: #6f746d;
}

.shell {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.72), transparent 35%),
    var(--surface);
}

.sidebar {
  border-right-color: rgba(222, 222, 227, 0.9);
  background: rgba(255, 255, 255, 0.92);
}

.sidebar .app-topbar {
  align-items: flex-start;
}

.sidebar .top-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.section-title h2 {
  font-size: 18px;
}

.ship-options {
  border-color: rgba(222, 222, 227, 0.95);
  background: var(--panel-soft);
}

.item {
  padding: 12px;
  background: var(--panel-soft);
}

.item .remove {
  min-height: 34px;
  border-color: rgba(180, 35, 24, 0.22);
  background: var(--red-soft);
  color: var(--red);
  font-weight: 850;
}

.actions {
  position: sticky;
  bottom: 0;
  z-index: 2;
  margin: 16px -18px 16px;
  padding: 12px 18px;
  border-top: 1px solid rgba(222, 222, 227, 0.86);
  border-bottom: 1px solid rgba(222, 222, 227, 0.6);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
}

.record small {
  margin-top: 4px;
}

.preview-wrap {
  background:
    linear-gradient(135deg, rgba(49, 95, 131, 0.12), transparent 38%),
    #e9e2d8;
}

.preview {
  box-shadow: 0 18px 45px rgba(48, 38, 26, 0.24);
}

.manage-filter,
.settings-form {
  padding: 14px;
  border: 1px solid rgba(222, 222, 227, 0.72);
  border-radius: 8px;
  background: var(--panel-soft);
}

.table-row,
.permission-row {
  padding: 12px;
}

.table-row button,
.permission-row button {
  min-height: 32px;
}

/* 2026 UI refactor: black-white-gray Apple-like system */
.brand-logo,
.top-logo,
.login-logo,
.note-logo,
.watermark-logo {
  display: block;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.top-logo {
  width: 78px;
  height: 78px;
  margin: -8px 4px -8px 0;
}

.login-logo {
  width: 148px;
  height: 126px;
  margin: 0 auto 4px;
}

.login {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 245, 247, 0.86)),
    var(--surface);
}

.login::before {
  content: "";
  position: absolute;
  left: -12%;
  bottom: 2%;
  width: 54%;
  height: 28%;
  border-top: 1px solid rgba(120, 120, 128, 0.22);
  border-radius: 50%;
  transform: rotate(8deg);
}

.login-watermark {
  position: absolute;
  right: -42px;
  top: 48px;
  width: 470px;
  opacity: 0.045;
  pointer-events: none;
}

.watermark-logo {
  width: 100%;
  height: auto;
}

.login-box {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  padding: 38px 44px 34px;
  border: 1px solid rgba(210, 210, 215, 0.88);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(16px);
}

.login-brand {
  display: block;
  margin-bottom: 26px;
  text-align: center;
}

.login-brand h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 0;
}

.login-brand p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.field-shell {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--ink);
  font-size: 15px;
}

.input-shell {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.94);
  overflow: hidden;
}

.input-shell input {
  min-height: 50px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.input-shell button {
  min-height: 34px;
  margin-right: 8px;
  border: 0;
  color: var(--muted);
  background: transparent;
}

.input-icon {
  color: var(--tertiary);
  text-align: center;
}

.login-box .primary {
  width: 100%;
  min-height: 54px;
  margin-top: 4px;
  border-radius: var(--radius-md);
  font-size: 17px;
  font-weight: 800;
}

.login-note {
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.error {
  color: var(--red);
  font-size: 13px;
}

.home {
  padding: 0 24px 44px;
  background: transparent;
}

.home-main,
.manage-shell {
  width: min(100%, 1360px);
}

.app-topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  align-items: center;
  min-height: 96px;
  margin-bottom: 28px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(222, 222, 227, 0.72);
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(18px);
}

.app-brandline {
  align-items: center;
}

.app-topbar h1 {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
}

.role {
  margin-top: 4px;
  color: var(--muted);
}

.top-actions {
  padding: 6px;
  border: 1px solid var(--line-light);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-sm);
}

.top-actions button {
  min-width: 78px;
  min-height: 38px;
  border-color: transparent;
  background: transparent;
}

.top-actions button:hover {
  border-color: var(--line);
  background: #fff;
}

.home-hero,
.manage-head {
  min-height: 218px;
  padding: 44px;
  overflow: hidden;
  border: 1px solid var(--line-light);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-md);
}

.home-hero::after,
.manage-head::after {
  content: "";
  position: absolute;
}

.home-hero {
  position: relative;
}

.home-hero::before,
.manage-head::before {
  content: "";
  position: absolute;
  inset: 0 0 auto auto;
  width: 360px;
  height: 220px;
  background: url("./assets/logo-rumeng.jpg") center / contain no-repeat;
  opacity: 0.035;
  pointer-events: none;
}

.home-hero h2,
.manage-head h2 {
  font-size: clamp(42px, 5vw, 58px);
  font-weight: 900;
  letter-spacing: 0;
}

.eyebrow {
  color: #2c2c2e;
  font-size: 13px;
  letter-spacing: 3px;
}

.hero-copy {
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.role-pill {
  min-height: 40px;
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.entry-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin-top: 28px;
}

.entry-card {
  align-content: start;
  justify-items: start;
  min-height: 278px;
  padding: 34px;
  border: 1px solid var(--line-light);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-sm);
}

.entry-card b {
  color: var(--muted);
  font-size: 16px;
}

.entry-card span {
  margin-top: 28px;
  font-size: 38px;
  font-weight: 900;
}

.entry-card small {
  margin-top: 18px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.entry-card::after {
  opacity: 0.34;
  filter: grayscale(1);
}

.entry-card:hover {
  border-color: #c7c7cc;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.muted-card {
  background: rgba(245, 245, 247, 0.65);
  color: var(--tertiary);
}

.shell {
  grid-template-columns: 410px minmax(0, 1fr);
  background: linear-gradient(180deg, #fff, var(--surface));
}

.sidebar {
  padding: 18px 20px 24px;
  border-right: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
}

.sidebar .app-topbar {
  position: sticky;
  top: 0;
  flex-wrap: wrap;
  align-items: flex-start;
  min-height: 86px;
  margin: -18px -20px 18px;
  padding: 12px 20px;
}

.sidebar .app-brandline {
  width: 100%;
}

.sidebar .app-topbar h1 {
  white-space: nowrap;
}

.sidebar .top-actions {
  display: grid;
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 10px;
  padding: 6px;
}

.sidebar .top-actions button {
  min-width: 0;
}

.sidebar .top-logo {
  width: 70px;
  height: 70px;
}

label {
  color: var(--ink);
  font-weight: 700;
}

input,
select {
  min-height: 42px;
  border-color: var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.96);
}

input:focus,
select:focus {
  border-color: #111;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.08);
}

input[readonly] {
  background: #f5f5f7;
  color: var(--muted);
}

.ship-options,
.item,
.record,
.metric,
.manage-panel,
.table-row,
.permission-row,
.module-row,
.user-row,
.empty-state {
  border-color: var(--line-light);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-sm);
}

.section-title {
  margin-top: 22px;
}

.section-title h2 {
  font-size: 20px;
  font-weight: 850;
}

.actions {
  margin: 18px -20px 16px;
  border-color: var(--line-light);
}

.preview-wrap {
  padding: 44px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(245, 245, 247, 0.88)),
    var(--surface);
}

.preview {
  border-radius: var(--radius-lg);
  box-shadow: 0 28px 65px rgba(0, 0, 0, 0.16);
}

.dream-note {
  padding: 44px 34px 40px;
}

.dream-title {
  grid-template-columns: auto 1fr;
  place-items: center;
  justify-content: center;
  max-width: 760px;
  margin: 0 auto 42px;
}

.note-logo {
  width: 148px;
  height: 148px;
  margin-right: 28px;
}

.note-title-text {
  display: grid;
  gap: 8px;
  text-align: center;
}

.manage-shell {
  padding: 0 28px 48px;
}

.manage-head {
  position: relative;
  min-height: 160px;
  margin-top: 10px;
}

.manage-grid,
.stats-grid {
  gap: 20px;
  margin-top: 22px;
}

.metric,
.stat-card {
  min-height: 128px;
  padding: 26px;
  border-color: var(--line-light);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-sm);
}

.metric strong,
.stat-card strong {
  color: #050505;
  font-size: 40px;
  font-weight: 900;
}

.metric span,
.stat-card span,
.stat-card small {
  color: var(--muted);
}

.manage-panel {
  margin-top: 22px;
  padding: 20px;
}

.manage-tabs {
  gap: 10px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line-light);
}

.manage-tabs button {
  min-height: 46px;
  padding: 0 18px;
  border-color: transparent;
  background: transparent;
}

.manage-tabs .active-tab {
  border-color: #111;
  background: #111;
  color: #fff;
}

.manage-filter,
.settings-form,
.manage-toolbar {
  border-color: var(--line-light);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.88);
}

.manage-filter {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 18px;
}

.manage-toolbar {
  padding: 14px 16px;
}

.table-row {
  min-height: 58px;
  padding: 12px 14px;
}

.cancel-badge {
  border-color: rgba(201, 52, 47, 0.18);
  background: #fff4f3;
  color: var(--red);
}

@media (max-width: 980px) {
  .app-topbar,
  .home-hero,
  .manage-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .home-hero h2,
  .manage-head h2 {
    font-size: 28px;
  }

  .entry-card {
    min-height: 150px;
  }

  .entry-card span {
    font-size: 30px;
  }

  .edit-item-row {
    grid-template-columns: 1fr;
  }

  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar,
  .preview-wrap {
    height: auto;
  }

  .entry-grid,
  .manage-grid,
  .stats-grid,
  .manage-filter,
  .settings-form,
  .permission-grid {
    grid-template-columns: 1fr;
  }

  .user-row,
  .invoice-row,
  .spec-row,
  .user-manage-row,
  .log-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media print {
  @page {
    size: A4 landscape;
    margin: 8mm;
  }

  .sidebar,
  .topbar,
  .actions {
    display: none !important;
  }

  .shell,
  .preview-wrap,
  .preview {
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
    padding: 0;
    overflow: visible;
    background: #fff;
    box-shadow: none;
  }
}
