:root { font-family: "Yu Gothic UI", "Hiragino Kaku Gothic ProN", system-ui, sans-serif; color: #171717; background: #f2f3f5; --red: #e51d2d; --line: #dfe1e5; --muted: #696e75; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.portal-header { min-height: 76px; padding: 13px 24px; display: flex; align-items: center; gap: 24px; background: #fff; border-bottom: 1px solid var(--line); }
.portal-brand { display: flex; align-items: center; gap: 18px; color: #222; text-decoration: none; }
.portal-brand img { width: 142px; height: auto; }
.portal-brand span { padding-left: 18px; border-left: 1px solid var(--line); font-size: .72rem; font-weight: 900; letter-spacing: .18em; }
.portal-header nav { margin-left: auto; display: flex; gap: 7px; }
.portal-header nav a { padding: 9px 13px; border: 1px solid var(--line); border-radius: 8px; color: #333; background: #fff; font-size: .75rem; font-weight: 800; text-decoration: none; }
.portal-header nav a.active, .portal-header nav a:hover { border-color: var(--red); color: #fff; background: var(--red); }
.portal-layout { min-height: calc(100vh - 76px); display: grid; grid-template-columns: 285px minmax(0,1fr); }
.customer-sidebar { padding: 24px 18px; background: #fff; border-right: 1px solid var(--line); }
.sidebar-heading { display: flex; justify-content: space-between; align-items: end; gap: 12px; }
.eyebrow { margin: 0 0 5px; color: var(--red); font-size: .65rem; font-weight: 900; letter-spacing: .18em; }
h1, h2, h3 { margin: 0; }
.sidebar-heading h1 { font-size: 1.18rem; }
.sidebar-heading button { min-height: 35px; padding: 6px 11px; border: 0; border-radius: 7px; color: #fff; background: var(--red); font-size: .75rem; font-weight: 900; }
.search-field { display: grid; gap: 6px; margin-top: 19px; font-size: .72rem; font-weight: 800; }
.search-field input { width: 100%; min-height: 39px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }
.customer-list { display: grid; gap: 7px; margin-top: 14px; }
.customer-card { width: 100%; padding: 11px; display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; text-align: left; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.customer-card strong { font-size: .83rem; }
.customer-card small { color: var(--muted); font-size: .67rem; }
.customer-card .status-dot { width: 9px; height: 9px; margin-top: 4px; border-radius: 50%; background: #aaa; }
.customer-card[data-status="ready"] .status-dot, .customer-card[data-status="active"] .status-dot { background: #2b9a57; }
.customer-card.active { border: 2px solid var(--red); background: #fff8f8; }
.storage-note { margin: 19px 2px 0; padding: 10px; color: #775d20; background: #fff7df; border-radius: 7px; font-size: .66rem; line-height: 1.55; }
.portal-content { min-width: 0; padding: 20px; }
.overview-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.overview-grid article { padding: 16px 18px; display: grid; grid-template-columns: 1fr auto; gap: 3px 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.overview-grid span, .overview-grid small { color: var(--muted); font-size: .7rem; }
.overview-grid strong { grid-row: 1 / 3; grid-column: 2; font-size: 1.7rem; }
.empty-state { margin-top: 16px; padding: 70px 30px; text-align: center; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.empty-state h2 { font-size: 1.35rem; }
.empty-state p:last-child { color: var(--muted); }
.customer-editor { margin-top: 16px; }
.editor-heading { padding: 20px 22px; display: flex; justify-content: space-between; align-items: center; gap: 18px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.editor-heading h2 { font-size: 1.25rem; }
.heading-actions { display: flex; gap: 8px; }
.heading-actions button { min-height: 39px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: .73rem; font-weight: 800; }
.heading-actions .primary { border-color: var(--red); color: #fff; background: var(--red); }
.editor-grid { margin-top: 13px; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; align-items: start; }
.panel { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.panel-title { display: flex; gap: 11px; align-items: start; margin-bottom: 17px; }
.panel-title > span { color: var(--red); font-size: .72rem; font-weight: 900; letter-spacing: .08em; }
.panel-title h3 { font-size: .95rem; }
.panel-title p { margin: 4px 0 0; color: var(--muted); font-size: .7rem; line-height: 1.45; }
.two-columns { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.panel label { display: grid; gap: 6px; color: #34383d; font-size: .72rem; font-weight: 800; }
.panel input, .panel select { width: 100%; min-height: 39px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.url-field { margin-top: 13px; }
.url-field > div { display: grid; grid-template-columns: 1fr auto; }
.url-field input { border-radius: 8px 0 0 8px; background: #f7f8f9; }
.url-field button { min-width: 62px; border: 1px solid var(--line); border-left: 0; border-radius: 0 8px 8px 0; background: #fff; font-size: .7rem; font-weight: 800; }
.field-note { margin: 9px 0 0; color: var(--muted); font-size: .67rem; line-height: 1.5; }
.import-zone { min-height: 78px; place-content: center; text-align: center; border: 2px dashed #c7cbd0; border-radius: 9px; background: #f8f9fa; cursor: pointer; }
.import-zone input, .file-button input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.import-zone strong, .import-zone span { display: block; }
.import-zone span { margin-top: 4px; color: var(--muted); font-size: .65rem; }
.config-summary { margin-top: 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.config-summary div { padding: 9px; border-radius: 8px; background: #f5f6f7; }
.config-summary span, .config-summary strong { display: block; }
.config-summary span { color: var(--muted); font-size: .65rem; }
.config-summary strong { margin-top: 3px; font-size: .76rem; }
.palette-block { margin-top: 10px; }
.palette-block > span { display: block; margin-bottom: 5px; color: var(--muted); font-size: .68rem; font-weight: 800; }
.palette { display: flex; gap: 6px; flex-wrap: wrap; min-height: 25px; }
.color-chip { width: 25px; height: 25px; border: 1px solid rgba(0,0,0,.16); border-radius: 50%; background: var(--color); }
.inline-status, .save-status { min-height: 18px; margin: 10px 0 0; color: #2f7048; font-size: .7rem; }
.file-toolbar { display: grid; grid-template-columns: 130px 1fr; gap: 8px; }
.file-button { min-height: 39px; display: grid !important; place-content: center; border: 1px solid var(--red); border-radius: 8px; color: var(--red) !important; cursor: pointer; }
.folder-path { margin-top: 11px; padding: 8px 10px; overflow: hidden; border-radius: 7px; color: #4d555e; background: #f3f4f5; font: .68rem ui-monospace, monospace; text-overflow: ellipsis; white-space: nowrap; }
.file-list { margin-top: 9px; display: grid; gap: 6px; }
.file-row { padding: 8px 9px; display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 7px; }
.file-row strong { overflow: hidden; font-size: .72rem; text-overflow: ellipsis; white-space: nowrap; }
.file-row span { color: var(--muted); font-size: .63rem; }
.file-row button { border: 0; color: #8a333d; background: transparent; font-size: .67rem; }
.font-master { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; }
.font-master label { padding: 9px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 8px; }
.font-master input { width: 17px; min-height: 17px; accent-color: var(--red); }
.area-fields { margin-top: 13px; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
.checklist { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.checklist label { padding: 9px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 8px; }
.checklist input { width: 17px; min-height: 17px; accent-color: var(--red); }
.save-status { text-align: right; }
@media (max-width: 1080px) { .portal-layout { grid-template-columns: 240px minmax(0,1fr); } .overview-grid { grid-template-columns: 1fr 1fr; } .editor-grid { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .portal-header { flex-wrap: wrap; } .portal-header nav { width: 100%; margin: 0; overflow-x: auto; } .portal-header nav a { flex: 1; text-align: center; white-space: nowrap; } .portal-layout { display: block; } .customer-sidebar { border-right: 0; border-bottom: 1px solid var(--line); } .customer-list { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 520px) { .portal-content { padding: 12px; } .overview-grid, .two-columns, .config-summary, .checklist { grid-template-columns: 1fr; } .customer-list { grid-template-columns: 1fr; } .editor-heading { align-items: start; flex-direction: column; } .heading-actions { width: 100%; } .heading-actions button { flex: 1; } .area-fields { grid-template-columns: 1fr 1fr; } }
