:root {
  color-scheme: light;
  --ink: #101827;
  --muted: #6f7480;
  --line: #dfe3e8;
  --line-strong: #ccd3dc;
  --panel: #ffffff;
  --field: #f6f3f4;
  --surface: #fbf7f8;
  --navy: #061527;
  --green: #079447;
  --green-soft: #dff8ea;
  --orange: #ff6b00;
  --orange-soft: #fff0e7;
  font-family:
    Inter, Pretendard, "Segoe UI", "Noto Sans KR", system-ui, -apple-system,
    sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: #f6f8fa;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
p {
  margin: 0;
}

.login-shell {
  width: 100%;
  min-height: 100vh;
  background: #f6f8fa;
}

.login-topline {
  display: grid;
  min-height: 78px;
  place-items: center;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.login-topline h1 {
  font-size: 1.26rem;
  font-weight: 950;
  letter-spacing: 0;
}

.auth-panel {
  display: grid;
  gap: 18px;
  width: min(100% - 48px, 620px);
  margin: 24px auto 40px;
  padding: 24px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--panel);
  box-shadow: 0 1px 4px rgba(16, 24, 39, 0.08);
}

.page-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.eyebrow {
  margin-bottom: 6px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0;
}

.page-heading h2 {
  font-size: 1.45rem;
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: 0;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  color: #fff;
  background: var(--green);
  font-size: 0.78rem;
  font-weight: 950;
  white-space: nowrap;
}

.tabs,
.mode-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.tabs {
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f0edef;
}

.tab-button,
.mode-button {
  min-height: 44px;
  border: 0;
  border-radius: 5px;
  color: var(--muted);
  background: transparent;
  font-weight: 900;
}

.tab-button.active {
  color: #fff;
  background: var(--navy);
}

.mode-button {
  border: 1px solid var(--line);
  background: #fff;
}

.mode-button.active {
  border-color: rgba(7, 148, 71, 0.32);
  color: var(--green);
  background: var(--green-soft);
}

.auth-form {
  display: none;
}

.auth-form.active,
.worker-flow.active {
  display: grid;
  gap: 16px;
}

.worker-flow {
  display: none;
}

label {
  display: grid;
  gap: 8px;
  color: #333943;
  font-size: 0.94rem;
  font-weight: 850;
}

input,
select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 14px;
  color: var(--ink);
  background: var(--field);
  outline: none;
}

input:focus,
select:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(7, 148, 71, 0.12);
}

.code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 116px;
  gap: 8px;
}

.primary-button,
.secondary-button,
.google-button {
  min-height: 48px;
  border-radius: 4px;
  border: 0;
  font-weight: 900;
}

.primary-button,
.google-button {
  color: #fff;
  background: var(--navy);
}

.primary-button:hover,
.google-button:hover {
  background: #10233a;
}

.primary-button:disabled,
.secondary-button:disabled,
.google-button:disabled {
  cursor: wait;
  opacity: 0.64;
}

.secondary-button {
  border: 1px solid var(--line-strong);
  color: var(--navy);
  background: #fff;
}

.demo-account {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(138px, 172px) 72px;
  gap: 10px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(7, 148, 71, 0.22);
  border-radius: 5px;
  background: var(--green-soft);
}

.demo-account div {
  display: grid;
  gap: 4px;
}

.demo-account strong {
  color: var(--green);
  font-size: 0.94rem;
}

.demo-account span {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.demo-account select {
  min-height: 42px;
  padding: 0 10px;
}

.admin-copy {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--field);
}

.admin-copy h2 {
  margin: 0;
  font-size: 1.12rem;
}

.google-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

.google-g {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 50%;
  color: var(--navy);
  background: #fff;
  font-weight: 950;
}

.message {
  min-height: 22px;
  color: var(--muted);
  font-weight: 750;
}

.message.error {
  color: var(--orange);
}

@media (max-width: 679px) {
  body {
    background: #f6f8fa;
  }

  .login-shell {
    width: 100%;
    margin: 0 auto;
    border: 0;
    border-radius: 0;
    background: #f6f8fa;
    box-shadow: none;
  }

  .login-topline {
    min-height: 74px;
    border-radius: 0;
    background: #fffafa;
  }

  .auth-panel {
    width: auto;
    margin: 0;
    padding: 18px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }
}

@media (max-width: 460px) {
  .page-heading {
    display: grid;
  }

  .code-row,
  .demo-account {
    grid-template-columns: 1fr;
  }
}
