  :root {
    --bg: #f5f5f7;
    --surface: #ffffff;
    --border: rgba(0, 0, 0, 0.08);
    --text: #1d1d1f;
    --muted: #6e6e73;
    --accent: #0071e3;
    --accent-hover: #0077ed;
    --down: #d70015;
    --radius-lg: 20px;
    --radius-md: 12px;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.06), 0 1px 3px rgba(0, 0, 0, 0.04);
    --font: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Inter', system-ui, sans-serif;
    --font-display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Inter', system-ui, sans-serif;
  }
  [data-theme="dark"] {
    --bg: #000000;
    --surface: #1c1c1e;
    --border: rgba(255, 255, 255, 0.1);
    --text: #f5f5f7;
    --muted: #98989d;
    --accent: #0a84ff;
    --accent-hover: #409cff;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
  }
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { height: 100%; }
  body {
    font-family: var(--font);
    background: var(--bg); color: var(--text);
    min-height: 100dvh;
    display: flex; align-items: center; justify-content: center;
    padding:
      max(32px, env(safe-area-inset-top, 0px))
      max(20px, env(safe-area-inset-right, 0px))
      max(32px, env(safe-area-inset-bottom, 0px))
      max(20px, env(safe-area-inset-left, 0px));
    -webkit-font-smoothing: antialiased;
    overflow-y: auto;
  }
  .card {
    width: 100%; max-width: 400px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 36px 28px 32px;
    box-shadow: var(--shadow);
  }
  @media (max-width: 390px) {
    body {
      padding:
        max(16px, env(safe-area-inset-top, 0px))
        max(12px, env(safe-area-inset-right, 0px))
        max(16px, env(safe-area-inset-bottom, 0px))
        max(12px, env(safe-area-inset-left, 0px));
    }
    .card { border-radius: 14px; padding: 24px 16px 20px; }
    .brand { gap: 12px; margin-bottom: 22px; }
    .brand-logo { width: 52px; height: 52px; }
    h2 { font-size: 1.2rem; }
    .sub { font-size: .84rem; margin-bottom: 20px; }
  }
  .brand { display: flex; align-items: center; gap: 14px; margin-bottom: 28px; }
  .brand-logo {
    width: 64px; height: 64px; flex-shrink: 0;
    border-radius: 14px; object-fit: cover;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  }
  .brand-name {
    font-family: var(--font-display);
    font-size: .98rem; font-weight: 600; letter-spacing: -0.02em;
  }
  .brand-sub { font-size: .74rem; color: var(--muted); margin-top: 2px; }
  h2 {
    font-family: var(--font-display);
    font-size: 1.35rem; font-weight: 700; letter-spacing: -0.03em; margin-bottom: 6px;
  }
  .sub { font-size: .88rem; color: var(--muted); margin-bottom: 24px; line-height: 1.5; }
  .field { margin-bottom: 14px; }
  .field label {
    display: block; font-size: .68rem; font-weight: 600;
    letter-spacing: .04em; text-transform: uppercase;
    color: var(--muted); margin-bottom: 6px;
  }
  .field input, .field select {
    width: 100%; border-radius: var(--radius-md);
    padding: 0 14px; height: 48px;
    font: inherit; font-size: 1rem; color: var(--text);
    background: var(--bg); border: 1px solid var(--border);
    transition: border-color .2s;
    -webkit-appearance: none; appearance: none;
  }
  .field input::placeholder { color: var(--muted); opacity: .65; }
  .field input:focus, .field select:focus {
    outline: none; border-color: var(--accent);
  }
  .field select { cursor: pointer; }
  .field select:disabled { opacity: .5; cursor: wait; }
  .field-note { font-size: .72rem; color: var(--muted); margin-top: 6px; }
  .btn-submit {
    width: 100%; height: 48px; border: none; border-radius: 980px;
    background: var(--accent); color: #fff;
    font: inherit; font-size: .94rem; font-weight: 600;
    cursor: pointer; margin-top: 20px;
    transition: background .2s, transform .1s;
    -webkit-tap-highlight-color: transparent;
  }
  .btn-submit:hover:not(:disabled) { background: var(--accent-hover); }
  .btn-submit:active:not(:disabled) { transform: scale(0.98); }
  .btn-submit:disabled { opacity: .4; cursor: not-allowed; }
  .err {
    display: none; margin-bottom: 16px; padding: 12px 14px;
    background: rgba(215, 0, 21, 0.06); border: 1px solid rgba(215, 0, 21, 0.18);
    border-radius: var(--radius-md); font-size: .86rem; color: var(--down); line-height: 1.45;
  }
  .err.show { display: block; }