@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Noto+Sans+SC:wght@400;500;700;900&display=swap');

:root {
  --orange: #e76528;
  --green: #143c32;
  --green-soft: #224d42;
  --cream: #f5f0e7;
  --paper: #fbf9f5;
  --ink: #282623;
  --muted: #736d65;
  --line: #d7d0c4;
  --sans: 'Noto Sans SC', Arial, sans-serif;
  --mono: 'DM Mono', monospace;
  scrollbar-color: #8b9d95 var(--cream);
  scrollbar-width: thin;
}

* { box-sizing: border-box; }
html { min-width: 320px; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: var(--paper); }
body::-webkit-scrollbar, *::-webkit-scrollbar { width: 10px; height: 10px; }
body::-webkit-scrollbar-track, *::-webkit-scrollbar-track { background: var(--cream); }
body::-webkit-scrollbar-thumb, *::-webkit-scrollbar-thumb { background: #8b9d95; border: 2px solid var(--cream); }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }

.product-actions { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 28px; }
.product-cta, .product-link { min-height: 46px; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; }
.product-cta { padding: 12px 18px; color: #fff; background: var(--orange); }
.product-cta:hover { background: #ce5420; }
.product-link { color: #fff; border-bottom: 1px solid rgba(255,255,255,.55); }
.product-context { margin-top: 14px; color: #b8c8bf; font-size: 12px; }

.portal-body { min-height: 100vh; background: var(--cream); }
.portal-header { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 max(28px, calc((100% - 1200px) / 2)); color: #fff; background: var(--green); border-bottom: 1px solid rgba(255,255,255,.14); }
.portal-brand img { display: block; width: 128px; filter: brightness(0) invert(1); }
.portal-back { min-height: 44px; display: inline-flex; align-items: center; font-size: 13px; color: #d1ddd7; }
.portal-back:hover { color: #fff; }

.login-shell { min-height: calc(100vh - 76px); display: grid; grid-template-columns: minmax(0, 7fr) minmax(390px, 5fr); }
.portal-story { position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 690px; padding: 92px max(48px, calc((100vw - 1200px) / 2)) 64px max(48px, calc((100vw - 1200px) / 2)); color: #fff; background: var(--green); overflow: hidden; }
.portal-story::after { content: ''; position: absolute; width: 270px; height: 270px; right: -75px; bottom: -75px; border: 1px solid rgba(231,101,40,.8); border-radius: 50%; }
.portal-kicker { margin: 0 0 24px; color: #f19a67; font: 500 11px/1.5 var(--mono); letter-spacing: .12em; }
.portal-story h1 { max-width: 690px; margin: 0; font-size: clamp(42px, 5.2vw, 74px); line-height: 1.14; letter-spacing: -.055em; font-weight: 700; }
.portal-story h1 em { display: block; color: var(--orange); font-style: normal; }
.portal-lede { max-width: 610px; margin: 28px 0 0; color: #c8d6cf; font-size: 16px; line-height: 1.9; }
.portal-rail { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 66px; border-top: 1px solid rgba(255,255,255,.22); }
.portal-rail span { padding: 17px 12px 0 0; color: #edf3ef; font-size: 13px; border-right: 1px solid rgba(255,255,255,.16); }
.portal-rail span:not(:first-child) { padding-left: 14px; }
.portal-rail span:last-child { border-right: 0; }

.login-side { display: flex; align-items: center; padding: 64px clamp(30px, 5vw, 76px); background: var(--paper); }
.login-card { width: min(460px, 100%); margin: auto; }
.demo-label { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 24px; color: var(--orange); font: 500 11px/1.5 var(--mono); letter-spacing: .1em; }
.demo-label::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--orange); }
.login-card h2 { margin: 0; color: var(--green); font-size: 31px; line-height: 1.3; letter-spacing: -.035em; }
.login-intro { margin: 14px 0 30px; color: var(--muted); font-size: 14px; line-height: 1.8; }
.login-form { display: grid; gap: 18px; }
.field { display: grid; gap: 8px; }
.field label { color: var(--green); font-size: 13px; font-weight: 700; }
.field input { width: 100%; min-height: 48px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 0; color: var(--ink); background: #fff; font: 15px var(--sans); }
.password-wrap { position: relative; }
.password-wrap input { padding-right: 72px; }
.password-toggle { position: absolute; top: 5px; right: 5px; min-width: 58px; min-height: 38px; border: 0; color: var(--green); background: var(--cream); font: 12px var(--sans); cursor: pointer; }
.official-login { min-height: 48px; border: 1px solid #bcb5aa; color: #8a837a; background: #eae5dc; font: 700 13px var(--sans); cursor: not-allowed; }
.demo-enter { min-height: 50px; display: inline-flex; align-items: center; justify-content: space-between; gap: 24px; padding: 13px 17px; color: #fff; background: var(--orange); font-size: 14px; font-weight: 700; }
.demo-enter:hover { background: #ce5420; }
.login-boundary { margin: 4px 0 0; padding-top: 18px; color: #7b746c; font-size: 12px; line-height: 1.7; border-top: 1px solid var(--line); }
.login-preview { margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line); }
.login-preview strong { display: block; margin-bottom: 10px; color: var(--green); font-size: 13px; }
.login-preview p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.8; }

@media (max-width: 850px) {
  .login-shell { display: block; }
  .portal-story { min-height: 520px; padding: 68px 28px 52px; }
  .portal-story h1 { font-size: clamp(39px, 11vw, 58px); }
  .portal-rail { grid-template-columns: repeat(2, 1fr); gap: 0; }
  .portal-rail span { min-height: 58px; border-bottom: 1px solid rgba(255,255,255,.16); }
  .portal-rail span:nth-child(2) { border-right: 0; }
  .login-side { padding: 54px 28px 70px; }
}

@media (max-width: 520px) {
  .portal-header { min-height: 66px; padding: 0 20px; }
  .portal-brand img { width: 110px; }
  .portal-back { font-size: 12px; }
  .portal-story { min-height: 500px; padding: 58px 22px 42px; }
  .portal-story h1 { font-size: 40px; }
  .portal-lede { font-size: 14px; }
  .portal-rail { margin-top: 48px; }
  .login-side { padding: 46px 22px 64px; }
  .login-card h2 { font-size: 27px; }
  .product-actions { align-items: stretch; flex-direction: column; gap: 12px; }
  .product-link { align-self: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

@media (forced-colors: active) {
  .demo-label::before, .demo-enter, .product-cta { forced-color-adjust: auto; }
}

