:root {
  color-scheme: light;
  --brand-900: #5b2308;
  --brand-700: #8a3f12;
  --brand-500: #c26720;
  --surface: #ffffff;
  --page: #f5f6f8;
  --text: #16181d;
  --muted: #69707d;
  --border: #e7e9ee;
  --success: #15a568;
  --radius-xl: 28px;
  --shadow-xl: 0 24px 80px rgba(34, 20, 12, 0.16);
}

* { box-sizing: border-box; }

html, body {
  min-height: 100%;
  margin: 0;
}

body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 10% 10%, rgba(194, 103, 32, .15), transparent 26rem),
    linear-gradient(145deg, #faf7f4, var(--page));
}

button, input { font: inherit; }

.page-shell { min-height: 100vh; }

.auth-screen,
.error-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.auth-panel,
.error-card {
  width: min(100%, 460px);
  background: rgba(255,255,255,.9);
  border: 1px solid rgba(255,255,255,.8);
  border-radius: var(--radius-xl);
  padding: clamp(26px, 6vw, 46px);
  box-shadow: var(--shadow-xl);
  backdrop-filter: blur(18px);
}

.brand-mark {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: linear-gradient(145deg, var(--brand-500), var(--brand-900));
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  box-shadow: 0 12px 30px rgba(138, 63, 18, .3);
}

.eyebrow {
  margin: 28px 0 8px;
  color: var(--brand-700);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(34px, 7vw, 48px);
  letter-spacing: -.04em;
}

.subtle {
  color: var(--muted);
  line-height: 1.7;
}

.auth-form {
  display: grid;
  gap: 16px;
  margin-top: 30px;
}

.auth-form label {
  display: grid;
  gap: 8px;
  color: #3f4651;
  font-size: 14px;
  font-weight: 700;
}

.auth-form input {
  width: 100%;
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #f7f8fa;
}

.auth-form button {
  min-height: 52px;
  border: 0;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--brand-500), var(--brand-900));
  color: #fff;
  font-weight: 800;
  opacity: .55;
}

.foundation-status {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 24px;
  padding: 16px;
  border: 1px solid #d8efe4;
  border-radius: 15px;
  color: #28734f;
  background: #f0fbf6;
  font-size: 13px;
  line-height: 1.55;
}

.status-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 5px rgba(21,165,104,.12);
}

.error-card { text-align: center; }
.error-code { color: var(--brand-700); font-weight: 900; font-size: 56px; margin: 0; }
.error-card a { display: inline-block; margin-top: 20px; color: var(--brand-700); font-weight: 800; }
