/* ============================================================
   login.css — OptiFlow 로그인 화면 공통 스타일
   MESWeb + AdminWEB 공통 사용
   ============================================================ */

* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:         #0B3647;
  --navy-dk:      #002435;
  --navy-dkr:     #001627;
  --accent:       #7EC8D8;
  --accent2:      #4AAFC4;
  --surface:      #ffffff;
  --surface-muted:#F2F6F8;
  --t-p:          #1A2A30;
  --t-s:          #4A6170;
  --t-m:          #7A96A2;
  --bd:           rgba(11,54,71,0.10);
  --bd-s:         rgba(11,54,71,0.18);
}

html, body { height: 100%; }

body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 13px;
  color: var(--t-p);
  background: #EEF3F5;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ── 전체 쉘 (중앙 정렬 래퍼) ───────────────────────── */
.login-shell {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
}

/* ── 로그인 박스 (좌우 패널 컨테이너) ───────────────── */
.login-box {
  display: flex;
  width: 100%;
  max-width: 960px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 48px rgba(11,54,71,0.16);
}

/* ── 좌측 브랜드 패널 ────────────────────────────── */
.login-left {
  width: 48%;
  background: linear-gradient(180deg, #0B3647 0%, #002435 100%);
  color: #ffffff;
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.login-left::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(126,200,216,0.08) 0%, transparent 50%),
    radial-gradient(circle at 85% 80%, rgba(74,175,196,0.06) 0%, transparent 50%);
  pointer-events: none;
}

.brand-top {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 2;
}
.brand-logo {
  display: flex;
  align-items: center;
  gap: 2px;
}
.brand-logo .bar-1 { width: 7px; height: 22px; border-radius: 3.5px; background: #7EC8D8; }
.brand-logo .bar-2 { width: 7px; height: 16px; border-radius: 3.5px; background: #4AAFC4; }
.brand-logo .bar-3 { width: 7px; height: 26px; border-radius: 3.5px; background: #ffffff; }
.brand-logo .bar-4 { width: 7px; height: 22px; border-radius: 3.5px; background: #4AAFC4; }
.brand-name {
  display: flex;
  align-items: baseline;
  gap: 1px;
  font-family: Georgia, 'Times New Roman', serif;
}
.brand-name .a { font-size: 26px; font-weight: 700; color: #ffffff; letter-spacing: -0.5px; }
.brand-name .b { font-size: 26px; font-weight: 400; color: #7EC8D8; letter-spacing: -0.5px; }
.brand-app-badge {
  font-size: 10px;
  letter-spacing: 1.8px;
  padding: 3px 10px;
  border-radius: 12px;
  font-weight: 500;
  margin-left: 8px;
  text-transform: uppercase;
}
/* 마크업(Login.cshtml)이 실제로 쓰는 클래스는 .wfx 다 — MESWeb 제품명이 WFX 로 바뀌었는데
   여기 .mes 만 남아 있어 배지 3개가 무스타일로 나가고 있었다(2026-09-19 리뷰 조치 6번). */
.brand-app-badge.wfx   { color: rgba(255,255,255,0.75); background: rgba(126,200,216,0.14); border: 1px solid rgba(126,200,216,0.22); }
.brand-app-badge.admin { color: rgba(255,255,255,0.55); background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15); }

.hero-section {
  margin-top: 32px;
  position: relative;
  z-index: 2;
}
.hero-badge {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 2px;
  padding: 4px 12px;
  border-radius: 12px;
  font-weight: 500;
}
.hero-badge.wfx   { color: #7EC8D8; background: rgba(126,200,216,0.12); border: 1px solid rgba(126,200,216,0.22); }
.hero-badge.admin { color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15); }

.hero-title {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  margin-top: 16px;
  letter-spacing: -0.5px;
}
.hero-title .accent { color: #7EC8D8; }

.hero-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.72);
  line-height: 1.6;
  margin-top: 14px;
  max-width: 420px;
}

/* 흐름도 (MESWeb 전용) */
.flow-diagram { margin-top: 28px; position: relative; z-index: 2; }
.flow-row { display: flex; align-items: center; gap: 6px; }
.flow-node {
  flex: 1;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 10px 8px;
  text-align: center;
  min-width: 0;
}
.flow-node.highlight {
  background: rgba(126,200,216,0.14);
  border-color: rgba(126,200,216,0.3);
}
.flow-node-icon {
  width: 26px;
  height: 26px;
  margin: 0 auto 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.flow-node-label { font-size: 12px; font-weight: 500; color: #ffffff; line-height: 1.2; }
.flow-node-sub   { font-size: 10px; color: rgba(255,255,255,0.55); margin-top: 2px; }
.flow-arrow      { flex-shrink: 0; color: #7EC8D8; font-size: 16px; font-weight: 700; }

/* 가치 목록 (MESWeb/AdminWEB 공용) */
.value-list {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 2;
}
.value-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
}
.value-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(126,200,216,0.14);
  border: 1px solid rgba(126,200,216,0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.value-icon svg { width: 16px; height: 16px; fill: none; stroke: #7EC8D8; stroke-width: 1.8; }
.value-text  { flex: 1; min-width: 0; }
.value-title { font-size: 13px; font-weight: 600; color: #ffffff; line-height: 1.3; }
.value-desc  { font-size: 12px; color: rgba(255,255,255,0.62); margin-top: 3px; line-height: 1.5; }

/* AdminWEB 접근 경고 박스 */
.access-warn {
  margin-top: 16px;
  background: rgba(245,208,122,0.08);
  border: 1px solid rgba(245,208,122,0.22);
  border-radius: 8px;
  padding: 11px 14px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  position: relative;
  z-index: 2;
}
.access-warn svg       { width: 14px; height: 14px; flex-shrink: 0; fill: none; stroke: #F5D07A; stroke-width: 1.8; margin-top: 2px; }
.access-warn-text      { font-size: 12px; color: rgba(255,255,255,0.82); line-height: 1.5; }
.access-warn-text b    { color: #F5D07A; font-weight: 600; }

/* Powered by / CI 로고 영역 (좌측 하단) */
.powered-by-wrap {
  margin-top: auto;
  padding-top: 20px;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.powered-by {
  display: flex;
  align-items: center;
  gap: 12px;
}
.powered-by-label {
  font-size: 10px;
  color: rgba(255,255,255,0.38);
  letter-spacing: 1px;
  text-transform: uppercase;
}
.ci-logo {
  opacity: 0.75;
  transition: opacity 0.2s;
  display: flex;
  align-items: center;
}
.ci-logo:hover { opacity: 1; }
.ci-logo img { height: 26px; width: auto; display: block; }

/* ── 우측 로그인 폼 ───────────────────────────────── */
.login-right {
  flex: 1;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 52px;
  position: relative;
}
.login-card {
  width: 100%;
  max-width: 380px;
}

.login-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--t-p);
  line-height: 1.2;
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.login-title-app {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 10px;
}
.login-title-app.wfx   { color: var(--navy); background: #E3F0F5; }
.login-title-app.admin { color: var(--t-s); background: var(--surface-muted); }

.login-desc {
  font-size: 13px;
  color: var(--t-m);
  margin-top: 8px;
  line-height: 1.5;
}

.form-group { margin-top: 16px; }
.form-label {
  font-size: 12px;
  color: var(--t-s);
  font-weight: 500;
  margin-bottom: 6px;
  display: block;
}
.form-input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--bd-s);
  border-radius: 6px;
  padding: 0 40px 0 12px;
  font-size: 13px;
  background: #ffffff;
  color: var(--t-p);
  outline: none;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.form-input:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(11,54,71,0.1);
}
.input-wrap { position: relative; }
.input-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--t-m);
  pointer-events: none;
}
.input-icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; }

.check-row {
  display: flex;
  align-items: center;
  /* 「사용자 ID 저장」 체크박스를 오른쪽 끝에 붙인다(2026-08-20).
     비밀번호 찾기 링크를 되살릴 때는 정렬을 다시 볼 것 — 둘 다 오른쪽에 붙는다. */
  justify-content: flex-end;
  margin-top: 14px;
  font-size: 12px;
}
.check-label {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--t-s);
  cursor: pointer;
  user-select: none;
}
.check-label input {
  width: 14px;
  height: 14px;
  accent-color: var(--navy);
  cursor: pointer;
}
.forgot-link {
  color: var(--navy);
  text-decoration: none;
  font-weight: 500;
}
.forgot-link:hover { text-decoration: underline; }

.login-btn {
  width: 100%;
  height: 46px;
  margin-top: 20px;
  border: none;
  border-radius: 6px;
  background: var(--navy);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  letter-spacing: 1px;
  transition: background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.login-btn:hover { background: var(--navy-dk); }
.login-btn:active { transform: scale(0.99); }
.login-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }

.divider {
  display: flex;
  align-items: center;
  margin: 20px 0 16px;
  gap: 12px;
}
.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--bd);
}
.divider-text { font-size: 11px; color: var(--t-m); }

.quick-row { display: flex; gap: 8px; }
.quick-btn {
  flex: 1;
  height: 38px;
  border: 1px solid var(--bd-s);
  border-radius: 6px;
  background: #ffffff;
  color: var(--t-s);
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s;
}
.quick-btn:hover {
  background: var(--surface-muted);
  border-color: var(--navy);
  color: var(--navy);
}
.quick-btn svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; }

.signup-box {
  margin-top: 20px;
  padding: 12px 14px;
  background: var(--surface-muted);
  border-radius: 6px;
  font-size: 12px;
  color: var(--t-s);
  text-align: center;
  line-height: 1.5;
}
.signup-box a { color: var(--navy); font-weight: 600; text-decoration: none; }
.signup-box a:hover { text-decoration: underline; }

.admin-notice {
  margin-top: 20px;
  padding: 12px 14px;
  background: #FFF8E6;
  border: 1px solid #F0D88E;
  border-radius: 6px;
  font-size: 12px;
  color: #6B5400;
  line-height: 1.5;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.admin-notice svg { width: 14px; height: 14px; flex-shrink: 0; margin-top: 2px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.bottom-links {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 14px;
  font-size: 11px;
}
.bottom-links a {
  color: var(--t-m);
  text-decoration: none;
  transition: color 0.15s;
}
.bottom-links a:hover { color: var(--navy); }
.bottom-sep { color: var(--bd-s); }

/* ── 페이지 푸터 ──────────────────────────────────── */
.page-footer {
  background: #ffffff;
  border-top: 1px solid var(--bd);
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--t-m);
  gap: 12px;
  flex-shrink: 0;
}
.footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-ci {
  display: flex;
  align-items: center;
  opacity: 0.6;
  text-decoration: none;
}
.footer-ci img { height: 16px; width: auto; display: block; filter: brightness(0.3); }
.footer-sep { color: var(--bd-s); }

/* ── 카드 하나만 두는 화면 (비밀번호 변경) ─────────────
   왼쪽 브랜드 패널이 없어 우측 폼 폭(카드 380px + 좌우 여백 52px)만큼만 연다.
   960px 그대로 두면 흰 판이 화면을 가로질러 카드가 가운데에 떠 보인다. */
.login-box.single { max-width: 484px; }

/* 서버 검증 메시지 — 로그인 화면의 인라인 색(#A32D2D)과 같은 톤 */
.login-validation {
  margin-top: 14px;
  padding: 10px 12px;
  background: #FCEBEB;
  border: 1px solid #F0C4C4;
  border-radius: 6px;
  font-size: 12px;
  color: #A32D2D;
  line-height: 1.5;
}
.login-validation.validation-summary-valid { display: none; }
.login-validation ul { margin: 0; padding-left: 16px; }
.field-validation-message {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  color: #A32D2D;
}
.login-status {
  margin-top: 14px;
  padding: 10px 12px;
  background: #E3F0F5;
  border: 1px solid rgba(11,54,71,0.18);
  border-radius: 6px;
  font-size: 12px;
  color: var(--navy);
}

/* ── 반응형 ──────────────────────────────────────── */
@media (max-width: 960px) {
  .login-shell { padding: 24px 16px; }
  .login-box   { flex-direction: column; }
  .login-left  { width: 100%; padding: 32px 24px; }
  .login-right { padding: 32px 24px; }
  .hero-title  { font-size: 26px; }
  .flow-diagram { display: none; }
}
