/* The login page (office and back office): brand and numbers on the left, the sign-in panel on the right */
.lg {
  --lg-accent: #f7602b; --lg-accent-deep: #e2521f; --lg-ink: #1a1210; --lg-muted: #6c757d; --lg-soft: #75665e;
  --lg-line: #d7dce2; --lg-panel: #ffffff; --lg-field: #ffffff; --lg-bg1: #fff8f3; --lg-bg2: #fdeee4; --lg-blob: rgba(247, 96, 43, .16);
  position: fixed; inset: 0; z-index: 60; display: grid; grid-template-columns: 1fr minmax(380px, 420px);
  font-family: "Bai Jamjuree", "Leelawadee UI", "Noto Sans Thai", Thonburi, sans-serif; font-weight: 300; color: var(--lg-ink);
  background: var(--lg-panel); overflow: auto;
}
.lg.dark {
  --lg-accent: #ff7a45; --lg-accent-deep: #ff6a2e; --lg-ink: #f4ece8; --lg-muted: #a39a95; --lg-soft: #b8a89f;
  --lg-line: #3a3330; --lg-panel: #191513; --lg-field: #221d1b; --lg-bg1: #140f0d; --lg-bg2: #1e1512; --lg-blob: rgba(255, 122, 69, .14);
}
.lg[hidden] { display: none !important; }
.lg * { box-sizing: border-box; }
.lg-brand { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--lg-bg1), var(--lg-bg2)); display: grid; place-items: center; padding: 40px; min-height: 100%; }
.lg-blob { position: absolute; border-radius: 50%; filter: blur(60px); background: var(--lg-blob); pointer-events: none; }
.lg-blob.a { width: 420px; height: 420px; left: -140px; top: -140px; }
.lg-blob.b { width: 520px; height: 520px; right: -200px; bottom: -220px; }
.lg-hero { position: relative; display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; max-width: 560px; }
.lg-logo { max-width: min(420px, 80%); max-height: 150px; object-fit: contain; }
.lg-word { position: relative; font-weight: 700; font-size: clamp(38px, 5.4vw, 68px); line-height: 1.05; letter-spacing: -.5px; color: var(--lg-ink); padding: 0 6px; }
.lg-word .w2 { color: var(--lg-accent); }
.lg-word .mark { display: inline-block; width: .5em; height: .5em; border-radius: .14em; background: linear-gradient(135deg, #ffb02e, var(--lg-accent)); transform: skewX(-18deg) translateY(-.55em); margin-left: .12em; }
.lg-tag { margin: 0; color: var(--lg-muted); font-size: 15px; line-height: 1.6; white-space: pre-line; }
.lg-stats { display: flex; gap: 40px; justify-content: center; margin-top: 14px; }
.lg-stats div { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 70px; }
.lg-stats b { font-size: 24px; font-weight: 600; color: var(--lg-accent); }
.lg-stats span { font-size: 12px; color: #858585; }
.lg.dark .lg-stats span { color: var(--lg-muted); }

.lg-panel { position: relative; background: var(--lg-panel); border-left: 1px solid rgba(0, 0, 0, .06); display: grid; place-items: center; padding: 48px 48px 32px; }
.lg.dark .lg-panel { border-left-color: rgba(255, 255, 255, .06); }
.lg-theme { position: absolute; top: 12px; right: 14px; width: 42px; height: 32px; border-radius: 8px; border: 0; background: none; color: #595959; cursor: pointer; display: grid; place-items: center; }
.lg-theme:hover { background: rgba(127, 127, 127, .12); }
.lg.dark .lg-theme { color: var(--lg-muted); }
.lg-theme svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; }
.lg-box { width: 100%; max-width: 323px; display: flex; flex-direction: column; }
.lg-title { font-size: 22px; font-weight: 700; color: var(--lg-ink); }
.lg-sub { font-size: 13px; color: var(--lg-muted); margin-top: 4px; }
.lg-gbtn { margin-top: 28px; min-height: 46px; display: flex; justify-content: center; }
.lg-gbtn > div { width: 100%; }
.lg-or { display: flex; align-items: center; gap: 12px; margin: 26px 0 6px; font-size: 12px; color: var(--lg-soft); }
.lg-or::before, .lg-or::after { content: ""; flex: 1; height: 1px; background: var(--lg-line); }
.lg form { display: flex; flex-direction: column; margin-top: 10px; }
#lg-gwrap + form { margin-top: 0; }
.lg-label { font-size: 12px; font-weight: 600; letter-spacing: .4px; text-transform: uppercase; color: var(--lg-ink); margin: 20px 0 8px; }
.lg-input { width: 100%; height: 46px; border: 1px solid var(--lg-line); border-radius: 10px; background: var(--lg-field); color: var(--lg-ink); font: inherit; font-size: 14.7px; font-weight: 400; padding: 0 14px; outline: none; transition: border-color .15s, box-shadow .15s; }
.lg-input::placeholder { color: #8b8f95; }
.lg-input:focus { border-color: var(--lg-accent); box-shadow: 0 0 0 3px rgba(247, 96, 43, .14); }
.lg-pw { position: relative; }
.lg-pw .lg-input { padding-right: 52px; }
.lg-eye { position: absolute; right: 2px; top: 1px; width: 50px; height: 44px; border: 0; background: none; color: #777; cursor: pointer; display: grid; place-items: center; }
.lg-eye svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lg-btn { margin-top: 26px; height: 46px; border-radius: 999px; border: 0; background: var(--lg-accent); color: #fff; font: inherit; font-size: 14.4px; font-weight: 600; cursor: pointer; display: flex; gap: 10px; align-items: center; justify-content: center; transition: background .15s, transform .05s; }
.lg-btn:hover { background: var(--lg-accent-deep); }
.lg-btn:active { transform: translateY(1px); }
.lg-btn:disabled { opacity: .6; cursor: default; }
.lg-btn svg, .lg-outline svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.lg-outline { margin-top: 28px; height: 46px; border-radius: 999px; border: 1px solid #dadce0; background: var(--lg-panel); color: var(--lg-accent); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; display: flex; gap: 10px; align-items: center; justify-content: center; }
.lg.dark .lg-outline { border-color: var(--lg-line); }
.lg-outline:hover { border-color: var(--lg-accent); }
.lg-err { margin: 14px 0 0; padding: 9px 12px; border-radius: 10px; background: #fdecea; color: #c0392b; font-size: 13px; font-weight: 400; line-height: 1.5; }
.lg.dark .lg-err { background: #3a1f1a; color: #ff9f8f; }
.lg-ok { background: #e3f8ec; color: #137a46; }
.lg-note { margin: 14px 0 0; text-align: center; font-size: 12px; color: #444; }
.lg.dark .lg-note { color: var(--lg-muted); }
.lg-note a { color: var(--lg-accent); text-decoration: none; font-weight: 500; cursor: pointer; }
.lg-note a:hover { text-decoration: underline; }
.lg-hr { border: 0; height: 1px; background: var(--lg-line); margin: 26px 0 18px; width: 100%; }
.lg-copy { margin: 0; text-align: center; font-size: 12px; color: #444; }
.lg.dark .lg-copy { color: var(--lg-muted); }
.lg-code { margin-top: 12px; display: flex; flex-direction: column; }
.lg-code[hidden] { display: none; }

@media (max-width: 860px) {
  .lg { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .lg-brand { min-height: 0; padding: 36px 20px 28px; }
  .lg-word { font-size: 36px; }
  .lg-logo { max-height: 90px; }
  .lg-hero { gap: 12px; }
  .lg-stats { gap: 24px; margin-top: 4px; }
  .lg-stats b { font-size: 20px; }
  .lg-panel { border-left: 0; border-top: 1px solid rgba(0, 0, 0, .06); padding: 28px 20px 24px; place-items: start center; }
  .lg-theme { top: 8px; right: 8px; }
  .lg-input { font-size: 16px; }
}
