:root {
  --deep: #21382c;
  --green: #315b46;
  --green-light: #90b19a;
  --green-soft: #e4eee6;
  --paper: #fffdf8;
  --ink: #243129;
  --muted: #6c786f;
  --line: #d9d5cb;
  --danger: #8a4038;
  --danger-soft: #f5e2de;
  --shadow: 0 22px 70px rgba(31, 53, 42, 0.18);
}

* { box-sizing: border-box; }
body.login-page {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 15%, rgba(144, 177, 154, 0.28), transparent 32%),
    radial-gradient(circle at 82% 82%, rgba(180, 122, 37, 0.12), transparent 28%),
    linear-gradient(145deg, #eef2e9, #f8f3e9 54%, #e7ede5);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
}
.login-shell {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 28px 18px;
}
.login-card {
  width: min(100%, 460px);
  padding: 34px;
  border: 1px solid rgba(217, 213, 203, 0.92);
  border-top: 5px solid var(--green);
  border-radius: 22px;
  background: rgba(255, 253, 248, 0.96);
  box-shadow: var(--shadow);
}
.login-brand { display: flex; align-items: center; gap: 12px; }
.login-symbol {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 15px;
  color: var(--deep);
  background: linear-gradient(135deg, #d9eadc, var(--green-light));
  font-size: 22px;
  font-weight: 800;
}
.login-brand p {
  margin: 0 0 3px;
  color: var(--green);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
}
.login-brand h1 { margin: 0; font-size: 19px; line-height: 1.35; }
.login-intro { margin: 30px 0 22px; }
.login-intro h2 { margin: 0 0 8px; font-size: 27px; }
.login-intro p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.login-error {
  display: grid;
  gap: 3px;
  margin-bottom: 18px;
  padding: 12px 14px;
  border: 1px solid #e8c8c2;
  border-radius: 11px;
  color: var(--danger);
  background: var(--danger-soft);
  font-size: 13px;
  line-height: 1.5;
}
.login-error strong { font-size: 12px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-bottom: 20px; padding: 4px; border-radius: 12px; background: var(--green-soft); }
.auth-tabs button { min-height: 44px; border: 0; border-radius: 9px; color: var(--green); background: transparent; font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; }
.auth-tabs button[aria-selected="true"] { color: #fff; background: var(--green); }
.auth-tabs button:focus-visible { outline: 3px solid rgba(49, 91, 70, 0.3); outline-offset: 2px; }
.panel-description { margin: 0 0 18px; color: var(--muted); font-size: 13px; line-height: 1.7; }
.login-form { display: grid; gap: 17px; }
.field { display: grid; gap: 7px; }
.field label { font-size: 13px; font-weight: 800; }
.field input {
  width: 100%;
  min-height: 48px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--ink);
  background: #fff;
  font-size: 16px;
  outline: none;
  transition: border-color 0.16s, box-shadow 0.16s;
}
.field textarea, .field select {
  width: 100%;
  min-height: 48px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-size: 16px;
}
.field select { padding-right: 2.75rem; }
.field textarea { min-height: 105px; resize: vertical; line-height: 1.55; }
.field small { color: var(--muted); font-size: 11px; font-weight: 400; line-height: 1.5; }
.consent { display: flex; grid-template-columns: auto 1fr; align-items: flex-start; gap: 9px; font-size: 12px; font-weight: 400; line-height: 1.5; }
.consent input { flex: 0 0 auto; width: 18px; height: 18px; margin: 0; }
.remember { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.remember input { width: 18px; height: 18px; margin: 0; }
.oauth-divider { display: flex; align-items: center; gap: 12px; margin: 22px 0 14px; color: var(--muted); font-size: 12px; }
.oauth-divider::before, .oauth-divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }
.google-submit { display: grid; place-items: center; width: 100%; min-height: 46px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #fff; font-size: 14px; font-weight: 800; text-decoration: none; }
.google-submit:hover { border-color: var(--green-light); background: var(--green-soft); }
.oauth-unavailable { margin: 18px 0 0; color: var(--muted); font-size: 12px; text-align: center; }
.auth-link { margin: 18px 0 0; text-align: center; }
.auth-link a { color: var(--green); font-size: 13px; font-weight: 800; }
.field input:focus {
  border-color: var(--green-light);
  box-shadow: 0 0 0 4px rgba(111, 149, 121, 0.16);
}
.login-submit {
  width: 100%;
  min-height: 49px;
  margin-top: 3px;
  border: 0;
  border-radius: 11px;
  color: #fff;
  background: var(--green);
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
}
.login-submit:hover { background: #294d3b; }
.login-submit:focus-visible { outline: 3px solid rgba(49, 91, 70, 0.25); outline-offset: 2px; }
.security-note { margin: 20px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; text-align: center; }

@media (max-width: 520px) {
  .login-shell { align-items: start; padding-top: 8vh; }
  .login-card { padding: 26px 20px; border-radius: 18px; }
  .login-brand h1 { font-size: 17px; }
  .login-intro { margin-top: 25px; }
  .login-intro h2 { font-size: 24px; }
}
.auth-help-link { margin:14px 0 0; text-align:center; font-size:13px; }.auth-help-link a { color:#315b46; font-weight:800; }
