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

:root {
    color-scheme: light;
    --ink: var(--brand-ink);
    --muted: var(--brand-muted);
    --accent: var(--brand-primary);
    --line: var(--brand-line);
}
* { box-sizing: border-box; }
html { min-width: 320px; background: var(--brand-surface-muted); }
body { margin: 0; color: var(--ink); font: 14px/1.6 'DM Sans', 'Segoe UI', sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button, input { font: inherit; }
button { cursor: pointer; }
button, a, input { -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; clip-path: inset(50%); overflow: hidden; white-space: nowrap; }
button:focus-visible, a:focus-visible, input[type="checkbox"]:focus-visible { outline: 3px solid var(--brand-focus); outline-offset: 4px; }
.login-shell { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: 100dvh; }

/* The form comes first, with a fixed reading width and a clear primary action. */
.login-panel { display: flex; flex-direction: column; min-width: 0; padding: 42px clamp(32px, 5vw, 82px) 26px; background: var(--brand-surface-muted); }
.login-panel-header { display: flex; align-items: center; min-height: 42px; }
.login-brand { display: inline-flex; align-items: center; gap: 10px; width: fit-content; color: #253449; text-decoration: none; font-family: 'Manrope', sans-serif; font-size: 28px; font-weight: 800; letter-spacing: -1.6px; line-height: 1; }
.brand-mark { display: grid; place-items: center; width: 33px; height: 35px; border: 1px solid var(--brand-primary); border-radius: 9px; background: var(--brand-primary); color: #fff; font-size: 23px; font-weight: 600; letter-spacing: -.8px; }
.brand-period { color: #9baec4; }
.login-form-area { display: flex; flex: 1; align-items: center; justify-content: center; padding: 64px 0 74px; }
.login-card-wrap { width: 100%; max-width: 368px; }
.login-heading { margin-bottom: 32px; }
.login-overline { display: block; margin-bottom: 14px; color: #8a96a6; font-size: 9px; font-weight: 500; letter-spacing: 1.7px; }
.login-heading h1 { margin: 0; color: #253246; font-family: 'Manrope', sans-serif; font-size: clamp(29px, 2.65vw, 37px); font-weight: 650; line-height: 1.25; letter-spacing: -1.55px; }
.login-heading p { margin: 12px 0 0; color: var(--muted); font-size: 13px; }
.login-form { display: flex; flex-direction: column; gap: 21px; }
.login-field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.login-field > label { width: fit-content; color: #4e5d71; font-size: 12px; font-weight: 500; }
.login-input-wrap { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 49px; padding: 0 14px; border: 1px solid #dce3eb; border-radius: 6px; background: #fff; transition: border-color .16s, box-shadow .16s; }
.login-input-wrap:hover { border-color: #a7b9cf; }
.login-input-wrap:focus-within { border-color: #6589b7; box-shadow: 0 0 0 3px rgb(54 93 142 / 7%); }
.login-input-wrap > i { color: #8b9eb7; font-size: 14px; }
.login-input-wrap input { flex: 1; width: 100%; min-width: 0; height: 48px; padding: 0; border: 0; outline: none; color: #324258; background: transparent; font-size: 14px; font-weight: 400; }
.login-input-wrap input::placeholder { color: #95a0af; font-size: 13px; }
.login-input-wrap input:-webkit-autofill { -webkit-text-fill-color: #324258; -webkit-box-shadow: 0 0 0 40px #fff inset; }
.login-input-wrap.invalid { border-color: #c18483; }
.password-toggle { display: grid; place-items: center; flex: 0 0 auto; width: 36px; height: 38px; margin-right: -7px; padding: 0; border: 0; border-radius: 4px; color: #8c9aaf; background: transparent; font-size: 15px; transition: color .16s, background .16s; }
.password-toggle:hover, .password-toggle[aria-pressed="true"] { color: var(--brand-primary); background: var(--brand-primary-soft); }
.field-hint { display: flex; align-items: center; gap: 6px; color: #947039; font-size: 11px; }
.remember-row { display: flex; align-items: center; align-self: flex-start; gap: 8px; min-height: 25px; margin-top: -2px; color: #738094; font-size: 12px; cursor: pointer; }
.remember-row input { width: 14px; height: 14px; margin: 0; accent-color: var(--brand-primary); cursor: pointer; }
.login-submit { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 48px; margin-top: 1px; padding: 12px 18px; border: 1px solid var(--brand-primary); border-radius: 6px; color: #fff; background: var(--brand-primary); font-size: 13px; font-weight: 500; transition: background .16s, border-color .16s, box-shadow .16s; }
.login-submit:hover:not(:disabled) { border-color: var(--brand-primary-dark); background: var(--brand-primary-dark); box-shadow: 0 4px 12px rgb(41 73 112 / 12%); }
.submit-arrow { font-size: 15px; transition: transform .16s; }
.login-submit:hover .submit-arrow { transform: translateX(3px); }
.login-submit:disabled { cursor: wait; opacity: .8; }
.submit-spinner { display: none; width: 15px; height: 15px; border: 2px solid rgb(255 255 255 / 30%); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.login-submit.is-loading .submit-spinner { display: block; }
.login-submit.is-loading .submit-arrow { display: none; }
.login-help { margin-top: 29px; color: #8793a4; font-size: 11px; text-align: center; }
.login-help > span { color: #5a7596; }
.login-footer-copy { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: #95a0b0; font-size: 9px; }
.login-alert { display: flex; align-items: flex-start; gap: 8px; margin: -10px 0 23px; padding: 12px 13px; border: 1px solid; border-radius: 6px; font-size: 12px; line-height: 1.6; }
.login-alert > i { flex: 0 0 auto; margin-top: 1px; font-size: 14px; }
.login-alert.danger { border-color: #ebd1d0; background: #fcf3f2; color: #9f514d; }
.login-alert.success { border-color: #d8e5dc; background: #f2f8f3; color: #567862; }

@keyframes spin { to { transform: rotate(360deg); } }
@media (min-width: 1700px) {
    .login-shell { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .login-panel { padding-right: max(82px, calc((100vw - 1400px) / 2)); }
    .login-visual { padding-left: 84px; padding-right: max(84px, calc((100vw - 1400px) / 2)); }
}
@media (max-width: 1100px) {
    .login-panel { padding: 34px 36px 24px; }
    .login-visual { padding: 39px 38px 28px; }
}
@media (max-width: 800px) {
    .login-shell { grid-template-columns: 1fr; }
    .login-visual { display: none; }
    .login-panel { min-height: 100dvh; padding: 31px 28px 25px; background: var(--brand-surface-muted); }
    .login-panel-header { min-height: 38px; }
    .login-brand { font-size: 28px; }
    .login-form-area { padding: 65px 0 80px; }
    .login-card-wrap { max-width: 400px; }
    .login-overline { margin-bottom: 13px; font-size: 9px; }
    .login-heading { margin-bottom: 31px; }
    .login-heading h1 { font-size: 33px; }
    .login-heading p { font-size: 13px; }
    .login-field > label { font-size: 13px; }
    .login-input-wrap { min-height: 52px; }
    .login-input-wrap input { height: 50px; font-size: 16px; }
    .login-input-wrap input::placeholder { font-size: 14px; }
    .password-toggle { width: 40px; height: 40px; font-size: 17px; }
    .remember-row { min-height: 30px; font-size: 12px; }
    .remember-row input { width: 16px; height: 16px; }
    .login-submit { min-height: 51px; font-size: 14px; }
    .login-help { margin-top: 27px; font-size: 12px; }
    .login-footer-copy { font-size: 9px; }
}
@media (max-width: 380px) {
    .login-panel { padding: 26px 22px 22px; }
    .login-heading h1 { font-size: 30px; }
    .login-form-area { padding-top: 52px; padding-bottom: 65px; }
    .login-footer-copy { font-size: 8px; }
}
@media (max-height: 740px) and (min-width: 801px) {
    .login-form-area { padding-top: 45px; padding-bottom: 50px; }
    .login-panel { padding-top: 28px; }
}
@media (max-height: 650px) and (max-width: 800px) {
    .login-form-area { padding-top: 45px; padding-bottom: 55px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Accounting workspace illustration: native shapes, no financial sample values. */
.login-panel { position: relative; isolation: isolate; }
.login-panel::before { position: absolute; z-index: -1; right: 0; top: 0; width: 200px; height: 200px; pointer-events: none; background: radial-gradient(ellipse at top right, #eff3f9, transparent 70%); content: ''; }
.login-panel-header { justify-content: space-between; }
.header-ornament { display: flex; align-items: flex-end; gap: 4px; height: 23px; padding: 0 2px; }
.header-ornament > span { width: 4px; height: 10px; border-radius: 2px; background: #d8e3f1; }
.header-ornament > span:nth-child(2) { height: 17px; background: #b3c8e0; }
.header-ornament > span:nth-child(3) { height: 13px; background: #d0ddec; }
.header-ornament > span:nth-child(4) { height: 23px; background: #8ba9cc; }
.login-card-wrap { max-width: 380px; }
.login-overline { display: flex; align-items: center; gap: 9px; color: #8291a7; letter-spacing: 1.15px; }
.login-overline > i { display: grid; place-items: center; width: 25px; height: 25px; border: 1px solid #e1e8f1; border-radius: 7px; color: #6c8caf; background: #f3f6fb; font-size: 12px; }
.login-heading h1 { font-weight: 700; }
.login-input-wrap { border-radius: 8px; box-shadow: 0 1px 2px rgb(23 38 59 / 2%); }
.login-submit { border-radius: 8px; box-shadow: 0 4px 10px rgb(54 93 142 / 9%); }
.login-visual { position: relative; display: flex; flex-direction: column; min-width: 0; gap: 25px; padding: 43px clamp(32px, 4vw, 64px) 30px; overflow: hidden; isolation: isolate; background: var(--brand-navy); color: #eff3f8; }
.login-visual::before { position: absolute; z-index: -2; inset: 0; background: radial-gradient(ellipse at 70% 48%, rgb(79 115 161 / 26%), transparent 67%), linear-gradient(150deg, rgb(9 20 37 / 10%), transparent 70%); content: ''; }
.login-visual::after { position: absolute; z-index: -1; right: -180px; bottom: -360px; width: 650px; height: 650px; border: 1px solid rgb(163 189 223 / 6%); border-radius: 50%; box-shadow: 0 0 0 60px rgb(163 189 223 / 2%); content: ''; pointer-events: none; }
.visual-grid { position: absolute; z-index: -1; inset: 0; opacity: .35; background-image: linear-gradient(rgb(166 190 219 / 6%) 1px, transparent 1px), linear-gradient(90deg, rgb(166 190 219 / 6%) 1px, transparent 1px); background-size: 56px 56px; mask-image: linear-gradient(150deg, transparent 12%, #000 50%, transparent 90%); pointer-events: none; }
.visual-caption { display: flex; align-items: center; justify-content: space-between; gap: 16px; color: #c5d3e6; font-size: 9px; letter-spacing: 2.2px; }
.visual-caption > span:last-child { color: #8198b7; font-size: 8px; letter-spacing: 1.4px; }
.visual-copy { position: relative; margin-top: 22px; padding: 0; }
.visual-eyebrow { display: flex; align-items: center; gap: 7px; margin-bottom: 18px; color: #91abcb; font-size: 8px; letter-spacing: 1.5px; }
.visual-eyebrow i { font-size: 13px; }
.visual-copy h2 { margin: 0; font-family: 'Manrope', sans-serif; font-size: clamp(30px, 3.15vw, 44px); font-weight: 550; line-height: 1.23; letter-spacing: -1.6px; color: #f3f6fb; }
.visual-copy h2 > span { color: #a7bedb; }
.visual-copy p { margin: 18px 0 0; color: #91a8c5; font-size: 12px; line-height: 1.8; }
.visual-art { position: relative; display: block; flex: 1; width: 100%; max-width: 530px; min-height: 345px; max-height: 460px; margin: 0 auto; padding: 0; }
.art-orbit { position: absolute; left: 50%; top: 51%; width: 360px; height: 360px; border: 1px solid rgb(149 177 212 / 11%); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; }
.orbit-inner { width: 260px; height: 260px; border-style: dashed; opacity: .4; }
.art-connectors { position: absolute; inset: 0; width: 100%; height: 100%; }
.ledger-document { position: absolute; z-index: 2; top: 17%; left: 8%; width: 84%; overflow: hidden; border: 1px solid #e5edf7; border-radius: 13px; background: #fff; color: #435570; box-shadow: 0 22px 45px rgb(3 15 31 / 20%); transform: rotate(-4deg); }
.ledger-header { display: flex; align-items: center; gap: 9px; padding: 16px 17px 14px; border-bottom: 1px solid #edf1f7; background: #fff; }
.ledger-symbol { display: grid; place-items: center; width: 30px; height: 31px; flex: 0 0 auto; border: 1px solid #dfe9f5; border-radius: 8px; background: #f0f5fc; color: #6589b7; font-size: 16px; }
.ledger-header strong { display: block; color: #3d5370; font-size: 11px; font-weight: 650; }
.ledger-header small { display: block; margin-top: 2px; color: #95a3b7; font-size: 7px; }
.ledger-more { margin-left: auto; color: #a1b1c7; font-size: 14px; }
.ledger-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 17px; color: #536b8a; font-size: 8px; }
.ledger-period { display: flex; align-items: center; gap: 5px; padding: 4px 6px; border: 1px solid #e3eaf4; border-radius: 4px; color: #8a9db7; font-size: 6px; }
.ledger-table { padding: 0 17px; }
.ledger-table-head, .ledger-table-row { display: grid; grid-template-columns: 1.6fr 1fr 1fr; align-items: center; gap: 10px; }
.ledger-table-head { padding: 7px 8px; border: 1px solid #edf1f7; border-radius: 4px; background: #f6f9fd; color: #8a9cb5; font-size: 6px; }
.ledger-table-head > span:not(:first-child) { text-align: right; }
.ledger-table-row { min-height: 32px; padding: 8px; border-bottom: 1px solid #f0f3f8; font-size: 7px; color: #71839d; }
.ledger-table-row:last-child { border: 0; }
.ledger-table-row > span:first-child { display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.ledger-dot { width: 4px; height: 4px; flex: 0 0 auto; border-radius: 50%; background: #8aaace; }
.ledger-dot.dot-slate { background: #b1bdcf; }
.ledger-number { display: block; justify-self: end; width: 76%; height: 4px; border-radius: 2px; background: #bbcce1; }
.ledger-number.light { width: 55%; background: #e6edf6; }
.ledger-total { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 12px 24px; border-top: 1px solid #eaf0f8; background: #f8fafd; }
.ledger-total > span:first-child { display: inline-flex; align-items: center; gap: 5px; color: #6486af; font-size: 7px; }
.ledger-total i { font-size: 10px; }
.ledger-total .ledger-number { width: 48px; height: 5px; background: #8eaacc; }
.cashflow-card { position: absolute; z-index: 3; left: -1%; bottom: 0; width: 47%; padding: 15px 16px 10px; border: 1px solid #dce7f4; border-radius: 11px; background: #fff; box-shadow: 0 15px 35px rgb(4 19 40 / 20%); transform: rotate(2deg); }
.cashflow-heading { display: flex; align-items: center; gap: 7px; }
.cashflow-icon { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; color: #7597bf; background: #f0f5fb; font-size: 11px; }
.cashflow-heading strong { display: block; color: #506885; font-size: 8px; font-weight: 600; }
.cashflow-heading small { display: block; margin-top: 2px; color: #a0adc0; font-size: 5px; }
.cashflow-card svg { display: block; width: 100%; margin-top: 12px; }
.receipt-card { position: absolute; z-index: 1; top: -1%; right: -2%; width: 27%; padding: 18px 14px 12px; border: 1px solid #e1e9f5; border-radius: 7px 7px 0 0; background: #f3f7fd; color: #8ba1be; transform: rotate(10deg); box-shadow: 0 10px 25px rgb(3 17 38 / 10%); }
.receipt-card::after { position: absolute; left: -1px; right: -1px; bottom: -6px; height: 7px; background: linear-gradient(135deg, #f3f7fd 25%, transparent 25%) -6px 0 / 12px 12px, linear-gradient(225deg, #f3f7fd 25%, transparent 25%) -6px 0 / 12px 12px; content: ''; }
.receipt-icon { margin-bottom: 9px; color: #8eabcd; font-size: 24px; line-height: 1; }
.receipt-card > span { display: block; margin-bottom: 15px; font-size: 7px; }
.receipt-line { height: 3px; margin: 8px 0; border-radius: 2px; background: #c9d7e9; }
.receipt-line.short { width: 65%; }
.receipt-divider { margin-top: 15px; border-top: 1px dashed #d5dfef; }
.receipt-bottom { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 9px; color: #7998be; font-size: 9px; }
.calculator-accessory { position: absolute; right: 0; bottom: 4%; display: grid; place-items: center; width: 51px; height: 55px; border: 1px solid rgb(168 195 229 / 25%); border-radius: 12px; background: linear-gradient(145deg, #385578, #294361); box-shadow: 0 10px 20px rgb(5 19 38 / 15%); color: #b8cce6; font-size: 27px; transform: rotate(-9deg); }
.art-plus { position: absolute; color: #718eaf; font-size: 17px; font-weight: 400; }
.plus-one { left: -2%; top: 13%; }
.plus-two { right: 13%; bottom: -4%; font-size: 11px; }
.visual-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 15px; margin-top: auto; padding-top: 23px; border-top: 1px solid rgb(168 193 224 / 14%); color: #8ea7c7; font-size: 9px; }
.visual-footer > span { display: inline-flex; align-items: center; gap: 7px; }
.visual-footer i { color: #a6bdda; font-size: 13px; }
@media (min-width: 1700px) {
    .login-visual { padding-left: 80px; padding-right: max(80px, calc((100vw - 1400px) / 2)); }
    .visual-art { min-height: 380px; }
}
@media (max-width: 1100px) and (min-width: 801px) {
    .login-visual { padding: 34px 32px 25px; gap: 26px; }
    .visual-copy { margin-top: 10px; }
    .visual-copy h2 { font-size: 34px; }
    .visual-art { min-height: 335px; }
    .visual-caption { font-size: 8px; letter-spacing: 1.5px; }
    .visual-caption > span:last-child { font-size: 6px; }
    .ledger-header { padding: 13px; }
    .ledger-toolbar { padding: 10px 13px; }
    .ledger-table { padding: 0 10px; }
    .receipt-card { padding: 16px 10px 12px; }
}
@media (max-width: 800px) {
    .login-visual { display: none; }
    .login-panel::before { width: 160px; height: 160px; }
    .header-ornament { opacity: .8; }
    .login-card-wrap { max-width: 400px; }
}
@media (max-height: 740px) and (min-width: 801px) {
    .login-visual { gap: 21px; padding-top: 30px; }
    .visual-copy { margin-top: 4px; }
    .visual-copy h2 { font-size: 32px; }
    .visual-eyebrow { margin-bottom: 12px; }
    .visual-copy p { margin-top: 12px; }
    .visual-art { min-height: 320px; }
    .visual-footer { margin-top: auto; padding-top: 18px; }
}
