/* ==========================================================================
   auth-gov.css — หน้าเข้าสู่ระบบแบบทางการ (โหลดต่อจาก auth.css)
   โทนน้ำเงินกรมท่า + ทอง ตามตราสัญลักษณ์กรมปศุสัตว์
   ลบไฟล์นี้ (และบรรทัด <link> ใน auth.html) ได้ทันทีหากต้องการกลับไปหน้าตาเดิม
   ========================================================================== */
:root {
  --gov-navy: #0a2a5c;
  --gov-navy-2: #123b7a;
  --gov-navy-deep: #061a3d;
  --gov-gold: #b8892b;
  --gov-gold-light: #e0bd6a;
  --gov-gold-soft: #f8f1e0;

  --bg: #eef1f5;
  --bg-accent: #dfe5ee;
  --line: #d9dee6;
  --line-strong: #aab4c3;
  --ink: #111d33;
  --ink-2: #2b3850;
  --muted: #566176;
  --primary: var(--gov-navy);
  --primary-hover: var(--gov-navy-deep);
  --primary-soft: #e7edf7;
  --primary-ring: rgba(11, 74, 162, .25);
  --link: #0b4aa2;
  --success: #17703a;
  --danger: #b42318;
  --shadow: 0 1px 2px rgba(10, 30, 60, .06), 0 1rem 2.5rem -1.25rem rgba(10, 30, 60, .35);
}
html[data-theme="dark"] {
  --gov-gold: #d6ad55;
  --gov-gold-light: #e8c77c;
  --gov-gold-soft: #2a2414;
  --bg: #0a1222;
  --bg-accent: #0f1b33;
  --surface: #111b2e;
  --surface-2: #15213a;
  --line: #26344f;
  --line-strong: #44557a;
  --ink: #e8edf5;
  --ink-2: #c6d0df;
  --muted: #a3b0c5;
  --primary: #2f5fb3;
  --primary-hover: #4272c4;
  --primary-soft: #182a4d;
  --link: #9dbcf2;
}

body.auth-page {
  background:
    linear-gradient(180deg, var(--bg-accent) 0, var(--bg) 22rem),
    var(--bg);
}

/* ---------- แถบชื่อหน่วยงาน ---------- */
.auth-gov {
  flex: none;
  color: #fff;
  background: linear-gradient(90deg, var(--gov-navy-deep) 0%, var(--gov-navy) 55%, var(--gov-navy-2) 100%);
  box-shadow: inset 0 -3px 0 var(--gov-gold);
}
html[data-theme="dark"] .auth-gov { background: linear-gradient(90deg, #06132c 0%, #0b2149 100%); }
.auth-gov__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  width: min(72rem, 100%);
  margin: 0 auto;
  padding: 0.7rem 1rem 0.85rem;
}
.auth-page a.auth-gov__org { display: flex; align-items: center; gap: 0.8rem; min-width: 0; color: #fff; text-decoration: none; }
.auth-gov__org img {
  flex: none;
  width: 3rem; height: 3rem;
  padding: 0.15rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 2px var(--gov-gold-light);
  object-fit: contain;
}
.auth-gov__org span { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.auth-gov__org strong { font-size: 1.15rem; font-weight: 700; letter-spacing: .01em; }
.auth-gov__org small { color: var(--gov-gold-light); font-size: .78rem; }

/* เครื่องมือ (ขนาดตัวอักษร/ธีม) อยู่ในแถบ */
.auth-gov .auth-tools {
  position: static;
  flex: none;
  padding: 0.2rem;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 0.375rem;
  background: rgba(255, 255, 255, .08);
  box-shadow: none;
}
.auth-gov .auth-tools button { min-width: 2.2rem; height: 2.2rem; border-radius: 0.25rem; color: #fff; }
.auth-gov .auth-tools button:hover { color: #fff; background: rgba(255, 255, 255, .16); }
.auth-gov .auth-tools button.is-active { border-color: var(--gov-gold-light); color: var(--gov-gold-light); }
.auth-gov .auth-tools .sep { background: rgba(255, 255, 255, .25); }

/* ---------- การ์ด ---------- */
.auth-shell { padding-top: 2.25rem; }
.auth-card {
  border-radius: 0.5rem;
  border-top: 4px solid var(--primary);
}
html[data-theme="dark"] .auth-card { border-top-color: var(--gov-gold); }
.auth-brand { border-bottom: 1px solid var(--line); box-shadow: 0 1px 0 0 transparent; position: relative; }
.auth-brand::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 3.5rem; height: 3px;
  background: var(--gov-gold);
}
.auth-brand img { width: 3.5rem; height: 3.5rem; }
.auth-brand__text strong { color: var(--primary); font-size: 1.08rem; font-weight: 700; }
html[data-theme="dark"] .auth-brand__text strong { color: var(--ink); }
.auth-heading h1 { color: var(--ink); font-weight: 700; }

.auth-progress li { border-top-width: 3px; }
.auth-progress li span { border-radius: 0.25rem; }

.auth-input input { border-width: 1.5px; border-radius: 0.375rem; }
.auth-otp__cells span { border-radius: 0.375rem; }
.auth-alert { border-radius: 0.375rem; }

.auth-btn {
  border-radius: 0.375rem;
  box-shadow: inset 0 -3px 0 var(--gov-gold), 0 6px 16px -10px rgba(6, 26, 61, .8);
  letter-spacing: .01em;
}
.auth-btn:focus-visible { box-shadow: inset 0 -3px 0 var(--gov-gold), 0 0 0 4px var(--primary-ring); }
.auth-btn--ghost { box-shadow: none; }

/* ---------- ส่วนท้าย ---------- */
.auth-footer { color: var(--muted); }
.auth-footer p:first-child { color: var(--ink-2); }

@media (max-width: 480px) {
  .auth-gov__inner { flex-wrap: wrap; padding: 0.6rem 0.75rem 0.75rem; }
  .auth-gov__org img { width: 2.5rem; height: 2.5rem; }
  .auth-gov__org strong { font-size: 1.02rem; }
  .auth-gov__org small { font-size: .7rem; }
  .auth-gov .auth-tools { margin: 0 0 0 auto; }
  .auth-shell { padding-top: 1rem; }
  .auth-card { border-radius: 0.5rem; }
}
