:root {
    --navy: #062e59;
    --navy-deep: #032342;
    --blue: #0868dc;
    --blue-soft: #eaf3ff;
    --teal: #12b7aa;
    --green: #109b68;
    --orange: #ef7b35;
    --red: #e45656;
    --text: #17233a;
    --muted: #69758b;
    --line: #dbe3ee;
    --surface: #ffffff;
    --background: #f5f8fc;
    --shadow: 0 8px 28px rgba(21, 49, 83, .07);
}

* { box-sizing: border-box; }
html { font-size: 16px; }
body { margin: 0; color: var(--text); background: var(--background); font-family: "Noto Sans KR", "Malgun Gothic", sans-serif; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, [tabindex]:focus-visible { outline: 3px solid rgba(8, 104, 220, .28); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.eyebrow { color: var(--blue); font-size: 12px; font-weight: 800; letter-spacing: .11em; }
.button { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 8px; padding: 0 18px; border: 1px solid transparent; border-radius: 8px; font-weight: 750; }
.button--primary { color: #fff; background: var(--blue); box-shadow: 0 5px 14px rgba(8, 104, 220, .2); }
.button--primary:hover { background: #075fc8; }
.button--secondary { color: #1556a5; border-color: #b7cceb; background: #fff; }
.button--excel { color: #147b42; border-color: #84c59d; background: #fff; }
.button--danger { color: #fff; background: var(--red); }
.button--small { min-height: 32px; padding: 0 11px; font-size: 11px; }
.button--wide { width: 100%; }
.panel { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); }
.panel-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.panel-header h2, .panel-header p { margin: 0; }
.panel-header h2 { font-size: 16px; }
.panel-header p { margin-top: 5px; color: var(--muted); font-size: 12px; }
.link-button { padding: 0; border: 0; color: var(--blue); background: transparent; }

/* 로그인 */
.login-body { min-height: 100vh; background: #fff; }
.login-shell { display: grid; min-height: 100vh; grid-template-columns: minmax(420px, 1.05fr) minmax(460px, .95fr); }
.login-visual { position: relative; display: flex; overflow: hidden; padding: 52px 64px; color: #fff; background: linear-gradient(145deg, var(--navy-deep), #06447d); flex-direction: column; justify-content: space-between; }
.login-visual::after { position: absolute; right: -150px; bottom: -170px; width: 510px; height: 510px; border: 1px solid rgba(52, 211, 199, .3); border-radius: 50%; content: ""; box-shadow: 0 0 0 80px rgba(12, 132, 197, .08), 0 0 0 160px rgba(12, 132, 197, .05); }
.login-brand, .brand { display: flex; flex-direction: column; }
.login-brand strong, .brand strong { color: #fff; line-height: 1; letter-spacing: .035em; }
.login-brand b, .brand b { color: #38d0c2; line-height: 1; letter-spacing: .16em; }
.login-brand small, .brand small { color: #c8deed; font-weight: 700; letter-spacing: .08em; }
.login-brand strong { font-size: 31px; }.login-brand b { margin-top: 8px; font-size: 27px; }.login-brand small { margin-top: 13px; font-size: 17px; }
.login-message { position: relative; z-index: 1; width: min(580px, 90%); margin: auto 0; }
.login-message .eyebrow { color: #58d7cc; }
.login-message h1 { margin: 20px 0; font-size: clamp(38px, 4vw, 62px); line-height: 1.24; letter-spacing: -.055em; }
.login-message p { width: min(520px, 100%); margin: 0; color: #c3d6e8; font-size: 17px; line-height: 1.85; }
.login-visual__grid { position: absolute; inset: auto 0 0; height: 32%; opacity: .11; background-image: linear-gradient(rgba(255,255,255,.3) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.3) 1px, transparent 1px); background-size: 44px 44px; transform: perspective(500px) rotateX(58deg) scale(1.3); transform-origin: bottom; }
.login-panel { display: grid; padding: 50px; place-items: center; }
.login-card { width: min(420px, 100%); }
.login-card__heading { margin-bottom: 30px; }
.login-card__heading h2 { margin: 0 0 10px; font-size: 32px; letter-spacing: -.04em; }
.login-card__heading p { margin: 0; color: var(--muted); }
.mobile-brand { display: none; }
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.field span { font-size: 14px; font-weight: 700; }
.field input, .field select { width: 100%; height: 50px; padding: 0 15px; border: 1px solid #cdd8e5; border-radius: 8px; background: #fff; outline: none; }
.field input:focus, .field select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(8,104,220,.1); }
.field small { color: var(--muted); font-size: 11px; }
.alert { margin-bottom: 18px; padding: 12px 14px; border-radius: 8px; font-size: 13px; }
.alert--error { color: #b33b3b; border: 1px solid #f1c7c7; background: #fff1f1; }
.alert--success { color: #14744f; border: 1px solid #a9dec9; background: #eefaf5; }

/* 공통 앱 레이아웃 */
.app-shell { display: grid; min-height: 100vh; grid-template-columns: 182px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; z-index: 30; display: flex; height: 100vh; color: #fff; background: linear-gradient(180deg, var(--navy-deep), var(--navy)); flex-direction: column; }
.brand { height: 128px; align-items: flex-start; justify-content: center; padding-left: 21px; border-bottom: 1px solid rgba(255,255,255,.1); }
.brand strong { font-size: 19px; }
.brand b { margin-top: 5px; font-size: 18px; }
.brand small { margin-top: 9px; font-size: 13px; }
.side-nav { display: grid; padding: 12px 0; gap: 2px; }
.side-nav__item { display: flex; height: 58px; align-items: center; gap: 12px; padding: 0 18px; border-left: 3px solid transparent; color: #d7e4f1; font-size: 14px; }
.side-nav__item:hover, .side-nav__item.is-active { border-left-color: #55b7ff; color: #fff; background: rgba(28, 112, 190, .32); }
.side-nav__icon { display: grid; width: 25px; height: 25px; place-items: center; font-size: 21px; }
.sidebar-user { display: flex; align-items: center; gap: 10px; margin: auto 10px 12px; padding: 13px; border: 1px solid rgba(255,255,255,.18); border-radius: 9px; background: rgba(0,0,0,.08); }
.avatar { display: grid; width: 32px; height: 32px; border-radius: 50%; color: #25527f; background: #e8f3ff; place-items: center; font-weight: 800; }
.sidebar-user > span:last-child { display: grid; min-width: 0; gap: 3px; }
.sidebar-user strong { font-size: 13px; }
.sidebar-user small { color: #b7cbe0; font-size: 11px; }
.sidebar-account-link { margin-top: 3px; color: #8fd4ff; font-size: 10px; }
.sidebar-account-link:hover { color: #fff; }
.logout-form { padding: 0 15px 22px; }
.logout-form button { width: 100%; padding: 10px; border: 0; color: #e1edf7; background: transparent; text-align: left; }
.main-area { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; height: 65px; align-items: stretch; padding: 0 24px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); }
.top-tabs { display: flex; height: 100%; align-items: stretch; gap: 8px; }
.top-tabs__item { display: flex; position: relative; align-items: center; padding: 0 20px; color: #3f4652; font-size: 15px; }
.top-tabs__item.is-active { color: var(--blue); font-weight: 750; }
.top-tabs__item.is-active::after { position: absolute; right: 0; bottom: 0; left: 0; height: 3px; background: var(--blue); content: ""; }
.notification-button { position: relative; width: 44px; margin-left: auto; border: 0; color: #3a4d65; background: transparent; font-size: 25px; }
.notification-button span { position: absolute; top: 13px; right: 4px; display: grid; width: 18px; height: 18px; border: 2px solid #fff; border-radius: 50%; color: #fff; background: var(--blue); place-items: center; font-size: 10px; }
.mobile-menu { display: none; border: 0; background: transparent; font-size: 24px; }
.page-content { padding: 34px 32px 52px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.page-heading h1 { margin: 6px 0 7px; font-size: 30px; letter-spacing: -.04em; }
.page-heading p { margin: 0; color: var(--muted); font-size: 14px; }
.page-heading__actions { display: flex; align-items: center; gap: 8px; }

/* 업로드 대시보드 */
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 20px; }
.workspace-column, .summary-column { display: grid; align-content: start; gap: 20px; }
.upload-card { display: grid; min-height: 245px; place-items: center; align-content: center; gap: 8px; padding: 26px; border: 1px solid #ccd9e8; border-radius: 12px; background: #fff; box-shadow: var(--shadow); outline: none; text-align: center; transition: .2s ease; }
.upload-card:hover, .upload-card:focus, .upload-card.is-dragging { border-color: var(--blue); background: #f7fbff; box-shadow: 0 0 0 4px rgba(8,104,220,.08); }
.upload-card__icon { display: grid; width: 64px; height: 64px; margin-bottom: 7px; border: 1px solid #b9c8da; border-radius: 12px; color: var(--blue); background: var(--blue-soft); place-items: center; font-size: 32px; }
.upload-card strong { font-size: 18px; }
.upload-card p { margin: 0; color: var(--muted); font-size: 13px; }
.upload-card__note { margin-top: 7px; color: #8b95a7; font-size: 11px; }
.processing-panel { min-width: 0; overflow: hidden; }
.processing-panel .panel-header { padding: 20px 20px 15px; }
.filter-group { display: flex; gap: 6px; }
.chip { padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; color: #667489; background: #fff; font-size: 11px; }
.chip.is-active { color: #fff; border-color: var(--blue); background: var(--blue); }
.table-wrap { width: 100%; overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; white-space: nowrap; }
.data-table th, .data-table td { padding: 12px 13px; border-top: 1px solid #e5ebf2; font-size: 12px; text-align: left; }
.data-table th { color: #5a6678; background: #f8fafc; font-size: 11px; font-weight: 700; }
.data-table tbody tr:hover { background: #fafcff; }
.status { display: inline-flex; padding: 5px 9px; border-radius: 6px; font-size: 11px; font-weight: 700; }
.status--success { color: #078052; background: #e9f8f2; }
.status--warning { color: #d76322; background: #fff0e7; }
.status--info { color: #0868d4; background: #eaf3ff; }
.status--muted { color: #7a8594; background: #f0f3f6; }
.status-icon { display: grid; width: 25px; height: 25px; border-radius: 6px; place-items: center; font-weight: 800; }
.status-icon--ready { color: #df5b34; background: #fff0ea; }
.status-icon--waiting { color: #0b6fd6; background: #edf5ff; }
.status-icon--done { color: #0b8a62; background: #e9f8f2; }
.table-action { padding: 5px 9px; border: 1px solid #b9cce4; border-radius: 6px; color: var(--blue); background: #fff; font-size: 11px; }
.table-action:disabled { cursor: default; color: #8e98a6; border-color: #d9e0e8; }
.table-actions { display: flex; align-items: center; gap: 6px; }
.table-footer { display: flex; align-items: center; justify-content: space-between; padding: 12px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.pagination { display: flex; gap: 4px; }
.pagination button { width: 28px; height: 28px; border: 1px solid var(--line); border-radius: 5px; color: #647085; background: #fff; }
.pagination .is-current { color: #fff; border-color: var(--blue); background: var(--blue); }
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.metric-card { display: grid; min-height: 150px; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: var(--shadow); grid-template-columns: auto 1fr; grid-template-rows: auto 1fr; align-items: center; gap: 8px 10px; }
.metric-card > span:nth-child(2) { color: #4a5669; font-size: 13px; }
.metric-card strong { grid-column: 2; align-self: start; font-size: 30px; }
.metric-card small { margin-left: 4px; color: var(--muted); font-size: 12px; font-weight: 500; }
.metric-icon { display: grid; width: 48px; height: 48px; border-radius: 11px; grid-row: 1 / 3; place-items: center; font-size: 24px; font-weight: 800; }
.metric-icon--blue { color: var(--blue); background: #e9f4ff; }.metric-icon--orange { color: var(--orange); background: #fff0e7; }.metric-icon--red { color: #ef5a42; background: #ffefea; }.metric-icon--teal { color: var(--teal); background: #e8f8f7; }
.activity-panel { padding: 18px; }
.activity-list { display: grid; margin: 15px 0 0; padding: 0; list-style: none; }
.activity-list li { display: flex; align-items: flex-start; gap: 10px; padding: 14px 2px; border-top: 1px solid #edf1f5; }
.activity-list li div { display: grid; gap: 5px; }
.activity-list strong { font-size: 12px; }.activity-list small { color: var(--muted); font-size: 11px; }
.activity-dot { width: 8px; height: 8px; margin-top: 5px; border-radius: 50%; flex: 0 0 auto; }.activity-dot--green { background: var(--green); }.activity-dot--blue { background: var(--blue); }.activity-dot--orange { background: var(--orange); }

/* OCR 검토 모달 */
.modal { position: fixed; z-index: 100; display: none; inset: 0; }
.modal.is-open { display: grid; place-items: center; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(5, 19, 38, .72); }
.modal-open { overflow: hidden; }
.review-modal { position: relative; display: grid; overflow: hidden; width: min(1240px, calc(100vw - 48px)); max-height: calc(100vh - 48px); border-radius: 12px; background: #fff; box-shadow: 0 24px 70px rgba(0,0,0,.28); grid-template-rows: auto minmax(0, 1fr) auto; }
.review-modal__header, .review-modal__footer { display: flex; align-items: center; justify-content: space-between; padding: 17px 22px; border-bottom: 1px solid var(--line); }
.review-modal__header h2 { margin: 3px 0 0; font-size: 20px; }
.modal-close { width: 38px; height: 38px; border: 0; border-radius: 50%; color: #4f5d70; background: #f3f6f9; font-size: 25px; }
.powerplanner-modal { position: relative; overflow: hidden; width: min(500px, calc(100vw - 32px)); border-radius: 12px; background: #fff; box-shadow: 0 24px 70px rgba(0,0,0,.28); }
.powerplanner-modal__header { display: flex; align-items: center; justify-content: space-between; padding: 19px 22px; border-bottom: 1px solid var(--line); }
.powerplanner-modal__header h2 { margin: 4px 0 0; font-size: 20px; }
.powerplanner-form { display: grid; gap: 16px; padding: 22px; }
.powerplanner-form__description { margin: 0 0 2px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.powerplanner-field { display: grid; gap: 7px; }
.powerplanner-field span, .powerplanner-target > span { color: #46546a; font-size: 12px; font-weight: 750; }
.powerplanner-field input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid #cbd6e3; border-radius: 7px; color: var(--text); background: #fff; outline: none; }
.powerplanner-field input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(8,104,220,.09); }
.powerplanner-target { display: grid; padding: 14px; border: 1px solid #d4e2f3; border-radius: 8px; background: #f6faff; grid-template-columns: 90px 1fr; gap: 5px 10px; }
.powerplanner-target strong { color: var(--blue); font-size: 14px; }
.powerplanner-target small { grid-column: 2; color: var(--muted); font-size: 10px; }
.powerplanner-security { margin: 0; padding: 11px 12px; border-radius: 7px; color: #4c6078; background: #f2f5f8; font-size: 11px; line-height: 1.55; }
.powerplanner-modal__footer { display: flex; justify-content: flex-end; gap: 8px; padding-top: 3px; }
.powerplanner-modal__footer .button:disabled { cursor: not-allowed; opacity: .55; }
.review-layout { display: grid; min-height: 0; grid-template-columns: minmax(360px, .85fr) minmax(500px, 1.15fr); }
.document-preview { min-height: 0; padding: 14px; border-right: 1px solid var(--line); background: #f3f6fa; }
.preview-toolbar { display: flex; align-items: center; gap: 7px; margin-bottom: 10px; }
.preview-toolbar button, .preview-toolbar span { min-width: 32px; padding: 6px 9px; border: 1px solid #d8e0ea; border-radius: 5px; color: #536177; background: #fff; font-size: 11px; }
.preview-toolbar .preview-page { margin-left: auto; }
.bill-preview { position: relative; height: calc(100% - 44px); min-height: 500px; padding: 28px; border: 1px solid #cbd4df; color: #252e3a; background: #fff; font-family: "Malgun Gothic", sans-serif; }
.bill-preview img { width: 100%; height: 100%; object-fit: contain; }
.bill-preview__brand { display: flex; align-items: center; justify-content: space-between; padding-bottom: 18px; border-bottom: 2px solid #394657; color: #104b8a; font-size: 18px; font-weight: 800; }.bill-preview__brand strong { color: #151d29; font-size: 23px; }
.bill-highlight { width: 72%; margin-top: 25px; padding: 9px; border: 2px dashed #2584e5; background: #f6fbff; font-size: 13px; }.bill-highlight--green { margin-top: 7px; border-color: #28aa79; }.bill-highlight--orange { margin-top: 7px; border-color: #ed8a38; }
.bill-amount { display: grid; width: 62%; margin: 30px 0 0 auto; padding: 18px; border: 1px solid #64748b; text-align: right; }.bill-amount strong { margin-top: 7px; font-size: 22px; }
.bill-lines { height: 180px; margin-top: 28px; background: repeating-linear-gradient(to bottom, #fff 0 27px, #dfe4ea 28px 29px); }
.extracted-data { min-width: 0; overflow-y: auto; padding: 22px; }
.review-section-title { display: flex; justify-content: space-between; gap: 15px; margin-bottom: 15px; }.review-section-title h3, .review-section-title p { margin: 0; }.review-section-title h3 { font-size: 15px; }.review-section-title p { margin-top: 4px; color: var(--muted); font-size: 11px; }.confidence-legend { color: var(--green); font-size: 11px; }
.extracted-form { display: grid; gap: 8px; }
.extracted-form label { display: grid; position: relative; align-items: center; grid-template-columns: 110px minmax(0,1fr) auto 48px; gap: 8px; }
.extracted-form label > span { color: #4e596b; font-size: 12px; }.extracted-form input { width: 100%; height: 36px; padding: 0 11px; border: 1px solid #d5dee9; border-radius: 6px; outline: none; }.extracted-form input:focus { border-color: var(--blue); }.extracted-form em { color: #677386; font-size: 11px; font-style: normal; }.confidence { font-size: 11px; text-align: right; }.confidence--high { color: var(--green); }.confidence--low { color: #e59a19; }
.field-warning { padding-bottom: 27px; }.field-warning input { border-color: #efc35d; background: #fffaf0; }.field-warning b { position: absolute; right: 56px; bottom: 3px; color: #b77b0f; font-size: 10px; font-weight: 600; }
.season-grid { display: grid; margin-top: 18px; grid-template-columns: repeat(3, 1fr); gap: 8px; }.season-grid h3 { grid-column: 1 / -1; margin: 0 0 3px; font-size: 13px; }.season-grid div { display: grid; gap: 5px; }.season-grid span { color: #637087; font-size: 10px; }.season-grid input { width: 100%; height: 35px; padding: 0 9px; border: 1px solid #d5dee9; border-radius: 5px; }
.workflow-steps { display: flex; margin-top: 21px; border: 1px solid #dce4ed; border-radius: 8px; background: #f8fafc; }.workflow-steps span { position: relative; flex: 1; padding: 13px 6px 13px 17px; color: #8993a2; font-size: 10px; }.workflow-steps span::before { position: absolute; left: 7px; color: #a9b2bf; content: "○"; }.workflow-steps .is-done { color: var(--green); }.workflow-steps .is-done::before { content: "●"; }.workflow-steps .is-current { color: var(--blue); font-weight: 700; }.workflow-steps .is-current::before { content: "●"; }
.review-modal__footer { border-top: 1px solid var(--line); border-bottom: 0; }.review-modal__footer > div { display: flex; gap: 8px; }.check-field { color: #536075; font-size: 12px; }

/* 계산시트 */
.calculation-toolbar { display: grid; align-items: end; margin-bottom: 16px; padding: 16px; grid-template-columns: 230px 280px 180px 1fr; gap: 14px; }
.calculation-toolbar label { display: grid; gap: 7px; }.calculation-toolbar label > span { font-size: 11px; font-weight: 700; }.calculation-toolbar input, .calculation-toolbar select { width: 100%; height: 40px; padding: 0 11px; border: 1px solid #cbd6e3; border-radius: 7px; color: #334055; background: #fff; }.input-with-icon { position: relative; }.input-with-icon input { padding-right: 34px; }.input-with-icon b { position: absolute; top: 9px; right: 11px; color: #66758a; }
.toolbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }.flow-complete { padding: 10px 12px; border: 1px solid #c8d4e2; border-radius: 7px; color: #42516a; font-size: 11px; }.flow-complete::first-letter { color: var(--green); }
.calculation-layout { display: grid; align-items: start; grid-template-columns: minmax(0, 1fr) 310px; gap: 15px; }.calculation-main { min-width: 0; }.calculation-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 15px; }.calculation-kpis article { display: grid; min-height: 118px; align-content: center; gap: 11px; padding: 17px; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: var(--shadow); }.calculation-kpis span { color: #586578; font-size: 12px; }.calculation-kpis strong { color: #16223a; font-size: 24px; }.calculation-kpis article:first-child strong { color: #148447; }.calculation-kpis small { margin-left: 4px; color: #738094; font-size: 11px; font-weight: 500; }
.spreadsheet-panel { overflow: hidden; }.spreadsheet-wrap { overflow: auto; }.spreadsheet { width: 100%; min-width: 950px; border-collapse: separate; border-spacing: 0; white-space: nowrap; }.spreadsheet th, .spreadsheet td { height: 39px; padding: 6px 8px; border-right: 1px solid #ccd7e3; border-bottom: 1px solid #ccd7e3; font-size: 10px; text-align: right; }.spreadsheet th { color: #344054; background: #f3f7fb; font-weight: 750; text-align: center; }.spreadsheet thead { position: sticky; top: 0; z-index: 1; }.spreadsheet th:first-child, .spreadsheet td:first-child { position: sticky; left: 0; z-index: 1; text-align: center; }.spreadsheet thead th:first-child { z-index: 2; }.season-winter td { background: #eaf6fb; }.season-winter td:first-child { background: #eaf6fb; }.season-spring td { background: #fff9dc; }.season-spring td:first-child { background: #fff9dc; }.season-summer td { background: #e4f2fb; }.season-summer td:first-child { background: #e4f2fb; }.spreadsheet .selected-cell { position: relative; outline: 2px solid var(--blue); outline-offset: -2px; background: #fff !important; }.selected-cell sup { margin-left: 4px; color: var(--blue); }.spreadsheet tfoot th, .spreadsheet tfoot td { color: #17233a; background: #fff; font-weight: 800; }.spreadsheet-legend { display: flex; gap: 18px; padding: 13px 15px; color: #66758a; font-size: 10px; }.spreadsheet-legend span { display: flex; align-items: center; gap: 5px; }.spreadsheet-legend i { width: 12px; height: 12px; border: 1px solid #c8d3de; }.legend-winter { background: #eaf6fb; }.legend-spring { background: #fff9dc; }.legend-summer { background: #e4f2fb; }
.formula-panel { overflow: hidden; }.formula-panel .panel-header { padding: 16px; border-bottom: 1px solid var(--line); }.formula-panel section { padding: 16px; border-bottom: 1px solid #e6ebf1; }.formula-panel h3 { margin: 0 0 11px; font-size: 13px; }.formula-panel pre { margin: 0; padding: 13px; border: 1px solid #d7e0ea; border-radius: 7px; color: #465369; background: #f8fafc; font-family: inherit; font-size: 10px; line-height: 1.8; white-space: pre-wrap; }.formula-panel dl { display: grid; margin: 0; gap: 9px; }.formula-panel dl div { display: flex; justify-content: space-between; font-size: 11px; }.formula-panel dt { color: var(--muted); }.formula-panel dd { margin: 0; font-weight: 700; }.validation-success { padding: 11px; border-radius: 7px; color: var(--green); background: #ecf9f4; font-size: 11px; font-weight: 700; }.formula-actions { display: grid; padding: 16px; grid-template-columns: 1fr 1fr; gap: 8px; }

/* 설정 */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }.settings-card { display: grid; align-items: center; padding: 20px; grid-template-columns: auto 1fr auto; gap: 17px; }.settings-card__icon { display: grid; width: 50px; height: 50px; border-radius: 11px; color: var(--blue); background: var(--blue-soft); place-items: center; font-size: 20px; font-weight: 800; }.settings-card h2, .settings-card p { margin: 0; }.settings-card h2 { font-size: 16px; }.settings-card p { margin: 7px 0; color: var(--muted); font-size: 12px; line-height: 1.6; }.settings-meta { color: var(--green); font-size: 10px; }.settings-meta--warning { color: var(--orange); }.role-panel { margin-top: 18px; overflow: hidden; }.role-panel .panel-header { padding: 20px; }.role-table-wrap { overflow-x: auto; }.role-table td, .role-table th { font-size: 12px; }.permission-yes { color: var(--green); font-weight: 700; }.permission-no { color: #8c96a6; }
.account-form-panel { width: min(560px, 100%); padding: 24px; }
.account-form-panel .panel-header { margin: -4px 0 22px; }
.account-management-grid { display: grid; align-items: start; grid-template-columns: minmax(320px, 420px) minmax(0, 1fr); gap: 18px; }
.account-list-panel { min-width: 0; overflow: hidden; }
.account-list-panel .panel-header { padding: 20px; }
.account-table form { margin: 0; }
.account-actions, .account-edit-buttons { display: flex; align-items: center; gap: 7px; }
.account-edit-buttons { margin-top: 22px; justify-content: flex-end; }

/* OCR 결과 */
.ocr-result-grid { display: grid; align-items: start; grid-template-columns: minmax(320px, .65fr) minmax(0, 1.35fr); gap: 16px; }
.ocr-result-panel { min-width: 0; overflow: hidden; }
.ocr-result-panel .panel-header { padding: 20px; border-bottom: 1px solid var(--line); }
.ocr-field-list { display: grid; margin: 0; }
.ocr-field-list div { display: grid; padding: 14px 20px; border-top: 1px solid #edf1f5; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; }
.ocr-field-list div:first-child { border-top: 0; }
.ocr-field-list dt { color: var(--muted); font-size: 12px; }
.ocr-field-list dd { margin: 0; color: var(--text); font-size: 13px; font-weight: 700; word-break: break-word; }
.ocr-raw-text { overflow: auto; max-height: 68vh; margin: 0; padding: 20px; color: #334055; background: #f8fafc; font-family: "Malgun Gothic", monospace; font-size: 12px; line-height: 1.75; white-space: pre-wrap; word-break: break-word; }

/* 상태 */
.status-body { display: grid; min-height: 100vh; place-items: center; }.status-card { width: min(440px, calc(100% - 32px)); padding: 42px; border: 1px solid var(--line); border-radius: 15px; background: #fff; box-shadow: var(--shadow); text-align: center; }.status-code { color: var(--blue); font-size: 46px; font-weight: 800; }.status-card h1 { margin: 8px 0; }.status-card p { margin: 0 0 24px; color: var(--muted); }

@media (max-width: 1260px) {
    .dashboard-grid { grid-template-columns: 1fr; }.summary-column { grid-template-columns: 1fr 1fr; }.activity-panel { min-height: 100%; }.calculation-toolbar { grid-template-columns: 1fr 1fr 1fr; }.toolbar-actions { grid-column: 1 / -1; justify-content: flex-start; }.calculation-layout { grid-template-columns: 1fr; }.formula-panel { display: grid; grid-template-columns: repeat(3, 1fr); }.formula-panel .panel-header, .formula-actions { grid-column: 1 / -1; }
}

@media (max-width: 860px) {
    .login-shell { grid-template-columns: 1fr; }.login-visual { display: none; }.login-panel { padding: 28px; }.mobile-brand { display: inline-block; margin-bottom: 30px; color: var(--navy); font-weight: 850; }
    .app-shell { grid-template-columns: 1fr; }.sidebar { position: fixed; left: -210px; width: 182px; transition: left .2s ease; }.sidebar.is-open { left: 0; box-shadow: 15px 0 40px rgba(0,0,0,.2); }.mobile-menu { display: block; }.topbar { padding: 0 12px; }.top-tabs__item { padding: 0 10px; font-size: 13px; }.page-content { padding: 24px 16px 40px; }.page-heading { align-items: stretch; flex-direction: column; }.page-heading__actions { flex-wrap: wrap; }.page-heading--action .button { align-self: flex-start; }.summary-column { grid-template-columns: 1fr; }.review-modal { width: calc(100vw - 20px); max-height: calc(100vh - 20px); }.review-layout { overflow-y: auto; grid-template-columns: 1fr; }.document-preview { min-height: 500px; border-right: 0; border-bottom: 1px solid var(--line); }.review-modal__footer { gap: 12px; align-items: stretch; flex-direction: column; }.review-modal__footer > div { justify-content: flex-end; }
    .calculation-toolbar { grid-template-columns: 1fr; }.toolbar-actions { grid-column: auto; flex-wrap: wrap; justify-content: flex-start; }.calculation-kpis { grid-template-columns: 1fr 1fr; }.formula-panel { grid-template-columns: 1fr; }.formula-panel .panel-header, .formula-actions { grid-column: auto; }.settings-grid, .account-management-grid, .ocr-result-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .top-tabs__item { padding: 0 7px; font-size: 11px; }.notification-button { width: 35px; }.metric-grid, .calculation-kpis { grid-template-columns: 1fr; }.metric-card { min-height: 110px; }.filter-group { display: none; }.processing-panel .panel-header { align-items: flex-start; }.review-modal__header { padding: 13px 15px; }.extracted-data { padding: 15px; }.extracted-form label { grid-template-columns: 85px minmax(0,1fr) 40px; }.extracted-form label em { display: none; }.field-warning b { right: 45px; }.workflow-steps { overflow-x: auto; }.workflow-steps span { min-width: 100px; }.settings-card { grid-template-columns: auto 1fr; }.settings-card .button { grid-column: 1 / -1; }
}
