:root {
  --ink: #111111;
  --muted: #686b66;
  --line: #deded9;
  --paper: #f7f7f3;
  --white: #ffffff;
  --ice: #dfe9ed;
  --danger: #a83131;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.78), rgba(247, 247, 243, 0.72)),
    repeating-linear-gradient(90deg, rgba(17, 17, 17, 0.035) 0 1px, transparent 1px 130px);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  min-height: 42px;
  border: 1px solid var(--ink);
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  text-decoration: none;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: clamp(18px, 4vw, 52px);
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 28px;
}

.admin-header span,
.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  line-height: 1;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(3.4rem, 8vw, 7.5rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 4.2rem);
}

.login-panel,
.panel,
.metric-row article {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 24px 80px rgba(17, 17, 17, 0.08);
}

.login-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.55fr);
  gap: clamp(24px, 5vw, 70px);
  align-items: center;
  padding: clamp(28px, 6vw, 74px);
}

form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
  padding: 13px 14px;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: var(--ink);
}

.is-hidden {
  display: none !important;
}

.dashboard {
  display: grid;
  gap: 22px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.metric-row article {
  box-shadow: none;
  border: 0;
  padding: 24px;
}

.metric-row span {
  display: block;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
}

.metric-row strong {
  display: block;
  margin-top: 12px;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.6rem, 5vw, 5rem);
  line-height: 1;
}

.workspace,
.settings-workspace {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  align-items: start;
}

.panel {
  padding: clamp(20px, 3vw, 34px);
}

.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
  margin-bottom: 24px;
}

.product-list,
.orders,
.email-events {
  display: grid;
  gap: 12px;
}

.product-form,
.settings-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.product-form label:nth-of-type(7),
.product-form label:nth-of-type(8),
.product-form label:nth-of-type(9),
.product-form .inline-check,
.product-form button,
.product-form p,
.settings-form button,
.settings-form p {
  grid-column: 1 / -1;
}

.product-form label:has(textarea),
.settings-form label:has(textarea) {
  grid-column: 1 / -1;
}

.product-row,
.order-card,
.event-row,
.check-grid article {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  background: var(--paper);
}

.product-row {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.product-row strong,
.order-card strong,
.event-row strong,
.check-grid strong {
  display: block;
  font-size: 1.05rem;
}

.product-row span,
.order-card span,
.order-card p,
.event-row span,
.event-row small,
.check-grid span {
  color: var(--muted);
  line-height: 1.6;
}

.contract-panel {
  background: #111111;
  color: var(--white);
}

.contract-panel .eyebrow,
.contract-panel span {
  color: rgba(255, 255, 255, 0.68);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: rgba(255, 255, 255, 0.2);
}

.check-grid article {
  border: 0;
  background: rgba(255, 255, 255, 0.08);
}

.inline-check {
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: none;
  font-size: 0.92rem;
}

.inline-check input {
  width: auto;
}

.order-card {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.38fr);
}

.order-items {
  margin: 10px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.order-actions {
  display: grid;
  gap: 10px;
}

.inline-link {
  justify-self: start;
  min-height: 34px;
  margin-top: 4px;
}

.danger {
  color: var(--danger);
}

@media (max-width: 980px) {
  .admin-header,
  .login-panel,
  .workspace,
  .order-card,
  .metric-row,
  .settings-workspace,
  .check-grid {
    grid-template-columns: 1fr;
  }

  .admin-header,
  .panel-head {
    align-items: stretch;
    flex-direction: column;
  }
}
