/* Trang đăng nhập dùng chung: /login (cổng thông tin) và /admin/auth/login (quản trị) */
:root {
  --green-900: #0f3d2a;
  --green-700: #1b6b45;
  --green-600: #22804f;
  --green-500: #2e9e62;
  --green-50:  #eef7f1;
  --ink:       #1d2a24;
  --muted:     #66756d;
  --line:      #d7e2dc;
  --danger:    #c0392b;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: "Be Vietnam Pro", "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: #f4f7f5;
  -webkit-font-smoothing: antialiased;
}
.auth {
  min-height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(380px, 1fr);
}

/* --- Cột ảnh --- */
.auth-hero {
  position: relative;
  color: #fff;
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    linear-gradient(160deg, rgba(15,61,42,.88) 0%, rgba(27,107,69,.70) 55%, rgba(15,61,42,.92) 100%),
    url("../img/puhoat_bg.jpg") center / cover no-repeat;
}
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: #fff; }
.brand img { width: 56px; height: 56px; border-radius: 50%; background: #fff; padding: 2px; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.brand small { display: block; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; opacity: .8; }
.brand strong { font-size: 17px; font-weight: 600; }
.hero-copy h1 { font-size: 34px; line-height: 1.25; margin: 0 0 14px; font-weight: 700; max-width: 520px; }
.hero-copy p { margin: 0; max-width: 480px; line-height: 1.6; opacity: .88; }
.hero-foot { font-size: 13px; opacity: .75; }

/* --- Cột form --- */
.auth-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  background: #fff;
}
.card { width: 100%; max-width: 380px; }
.card .mobile-brand { display: none; }
.card h2 { margin: 0 0 6px; font-size: 26px; font-weight: 700; }
.card .sub { margin: 0 0 28px; color: var(--muted); font-size: 14px; }

.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; }
.control { position: relative; }
.control .fa { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #8a9a91; width: 16px; text-align: center; }
.control input {
  width: 100%;
  height: 46px;
  padding: 0 44px 0 42px;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfdfc;
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.control input:focus { outline: none; border-color: var(--green-500); background: #fff; box-shadow: 0 0 0 4px rgba(46,158,98,.15); }
.control .toggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  border: 0; background: transparent; color: #8a9a91; cursor: pointer;
  width: 36px; height: 36px; border-radius: 8px;
}
.control .toggle:hover { background: var(--green-50); color: var(--green-700); }
.control .toggle .fa { position: static; transform: none; }
.field.has-error input { border-color: var(--danger); }
.field .error { color: var(--danger); font-size: 13px; margin-top: 6px; }

.row { display: flex; align-items: center; justify-content: space-between; margin: 4px 0 24px; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); cursor: pointer; user-select: none; }
.check input { width: 17px; height: 17px; accent-color: var(--green-600); margin: 0; }

.btn {
  width: 100%; height: 48px; border: 0; border-radius: 10px; cursor: pointer;
  font: inherit; font-size: 15px; font-weight: 600; color: #fff;
  background: linear-gradient(135deg, var(--green-600), var(--green-700));
  box-shadow: 0 6px 18px rgba(27,107,69,.28);
  transition: transform .1s, box-shadow .15s, filter .15s;
}
.btn:hover { filter: brightness(1.06); box-shadow: 0 8px 22px rgba(27,107,69,.34); }
.btn:active { transform: translateY(1px); }
.btn .fa { margin-right: 8px; }

.back { display: inline-flex; align-items: center; gap: 6px; margin-top: 26px; color: var(--muted); font-size: 14px; text-decoration: none; }
.back:hover { color: var(--green-700); }

@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; }
  .auth-hero { display: none; }
  .auth-panel {
    min-height: 100vh;
    background:
      linear-gradient(180deg, rgba(15,61,42,.92), rgba(27,107,69,.85)),
      url("../img/puhoat_bg.jpg") center / cover no-repeat;
  }
  .card { background: #fff; padding: 28px 22px; border-radius: 16px; box-shadow: 0 18px 50px rgba(0,0,0,.25); }
  .card .mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; font-weight: 600; color: var(--green-700); }
  .card .mobile-brand img { width: 42px; height: 42px; }
}
