:root { --navy:#172b4d; --ink:#1e293b; --muted:#6b778c; --line:#e5eaf0; --paper:#fff; --bg:#f5f7fa; --teal:#2d8c83; --gold:#c9a66b; --red:#c45b5b; --shadow:0 10px 30px rgba(23,43,77,.07); }
* { box-sizing:border-box; }
body { margin:0; color:var(--ink); background:var(--bg); font-family:'DM Sans',Arial,sans-serif; font-size:15px; }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
.auth-screen { min-height:100vh; display:grid; place-items:center; padding:32px; background:radial-gradient(circle at 14% 5%,rgba(201,166,107,.18) 0,transparent 30%),radial-gradient(circle at 90% 80%,rgba(45,140,131,.12) 0,transparent 33%),linear-gradient(135deg,#f6f8fb 0%,#edf1f6 100%); }
.auth-brand { position:fixed; top:27px; left:42px; display:flex; align-items:center; gap:13px; color:var(--navy); }
.auth-brand strong,.sidebar-brand strong { display:block; font-family:'Playfair Display',serif; font-size:17px; }
.auth-brand small,.sidebar-brand small { display:block; color:var(--muted); font-size:11px; letter-spacing:.08em; text-transform:uppercase; }
.brand-logo { display:block; object-fit:cover; border-radius:50%; box-shadow:0 8px 22px rgba(12,22,42,.22); }
.brand-logo-top { width:54px; height:54px; border:2px solid var(--gold); }
.brand-logo-side { width:43px; height:43px; border:1px solid rgba(201,166,107,.9); flex:0 0 auto; }
.auth-card { position:relative; width:min(430px,100%); padding:34px 40px 40px; background:rgba(255,255,255,.95); border:1px solid rgba(255,255,255,.8); border-top:3px solid var(--gold); border-radius:20px; box-shadow:0 18px 50px rgba(23,43,77,.13); overflow:hidden; }
.auth-card::after { content:""; position:absolute; right:-90px; top:-100px; width:210px; height:210px; border:1px solid rgba(201,166,107,.18); border-radius:50%; box-shadow:0 0 0 18px rgba(201,166,107,.04),0 0 0 36px rgba(201,166,107,.03); }
.auth-card-brand { position:relative; z-index:1; display:flex; align-items:center; gap:12px; padding-bottom:23px; margin-bottom:26px; border-bottom:1px solid var(--line); }
.auth-card-brand img { width:58px; height:58px; border-radius:50%; border:1px solid var(--gold); box-shadow:0 5px 15px rgba(23,43,77,.18); }
.auth-card-brand strong,.auth-card-brand small { display:block; }
.auth-card-brand strong { color:var(--navy); font-family:'Playfair Display',serif; font-size:16px; }
.auth-card-brand small { margin-top:3px; color:var(--muted); font-size:10px; letter-spacing:.06em; text-transform:uppercase; }
.auth-card h2 { margin:0 0 8px; font-family:'Playfair Display',serif; font-size:28px; color:var(--navy); }
.auth-card p { margin:0 0 26px; color:var(--muted); line-height:1.6; }
.auth-foot { position:fixed; bottom:22px; color:var(--muted); font-size:12px; }
.field { display:grid; gap:7px; margin-bottom:15px; }
.field label { color:var(--navy); font-weight:600; font-size:13px; }
.field input,.field select,.field textarea { width:100%; border:1px solid var(--line); border-radius:9px; padding:11px 12px; background:#fff; outline:none; color:var(--ink); }
.field input:focus,.field select:focus,.field textarea:focus { border-color:var(--teal); box-shadow:0 0 0 3px rgba(45,140,131,.12); }
.field textarea { min-height:90px; resize:vertical; }
.button { border:0; border-radius:9px; padding:11px 16px; background:var(--navy); color:#fff; font-weight:600; transition:transform .15s,opacity .15s; }
.button:hover { opacity:.92; transform:translateY(-1px); }
.button.secondary { background:#e7f2f0; color:#216e68; }
.button.ghost { background:transparent; color:var(--navy); border:1px solid var(--line); }
.button.full { width:100%; }
.app-screen { min-height:100vh; display:flex; }
.sidebar { position:relative; width:245px; padding:25px 16px 18px; background:linear-gradient(160deg,#142742 0%,#1b3154 55%,#10233d 100%); color:#dbe6f3; display:flex; flex-direction:column; overflow:hidden; }
.sidebar::after { content:""; position:absolute; right:-100px; bottom:80px; width:230px; height:230px; border:1px solid rgba(201,166,107,.14); border-radius:50%; box-shadow:0 0 0 18px rgba(201,166,107,.035),0 0 0 37px rgba(201,166,107,.025); pointer-events:none; }
.sidebar-brand { display:flex; align-items:center; gap:11px; padding:0 10px 34px; color:#fff; }
.sidebar-brand small { color:#aebcd1; }
.sidebar-brand>div { position:relative; z-index:1; }
.nav-item { width:100%; display:flex; gap:13px; align-items:center; padding:12px 14px; margin:3px 0; border:0; border-radius:9px; background:transparent; color:#b8c8db; text-align:left; }
.nav-item span { width:17px; text-align:center; font-size:18px; }
.nav-item:hover,.nav-item.active { color:#fff; background:rgba(255,255,255,.12); }
.nav-item.active { box-shadow:inset 3px 0 var(--gold); }
.sidebar-bottom { margin-top:auto; }
.security-note { padding:12px 10px; border-top:1px solid rgba(255,255,255,.12); color:#9fb1c9; font-size:11px; line-height:1.5; }
.logout { width:100%; padding:10px; border:0; background:transparent; color:#b8c8db; text-align:left; }
.main-content { flex:1; min-width:0; padding:31px clamp(20px,4vw,56px); }
.topbar { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin-bottom:30px; }
.eyebrow { margin:0 0 6px; color:var(--teal); font-size:11px; font-weight:700; letter-spacing:.12em; text-transform:uppercase; }
h1 { margin:0; color:var(--navy); font-family:'Playfair Display',serif; font-size:32px; }
.user-chip { display:flex; align-items:center; gap:9px; padding:6px 10px 6px 6px; background:#fff; border:1px solid var(--line); border-radius:30px; box-shadow:0 3px 10px rgba(23,43,77,.04); }
.user-chip>span { width:32px; height:32px; display:grid; place-items:center; border-radius:50%; background:#e7f2f0; color:var(--teal); font-weight:700; }
.user-chip strong,.user-chip small { display:block; }
.user-chip strong { font-size:12px; }
.user-chip small { color:var(--muted); font-size:10px; }
.page-actions { display:flex; align-items:center; gap:10px; margin-bottom:18px; }
.page-actions h2 { margin:0 auto 0 0; color:var(--navy); font-size:20px; }
.stats { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; margin-bottom:24px; }
.stat-card,.panel,.empty,.integration-card { background:var(--paper); border:1px solid var(--line); border-radius:13px; box-shadow:var(--shadow); }
.stat-card { padding:20px; }
.stat-card small { color:var(--muted); }
.stat-card strong { display:block; margin-top:9px; color:var(--navy); font-size:30px; font-family:'Playfair Display',serif; }
.grid-2 { display:grid; grid-template-columns:1.15fr .85fr; gap:18px; }
.panel { padding:20px; }
.panel h3 { margin:0 0 16px; color:var(--navy); font-size:16px; }
.panel-header { display:flex; align-items:center; gap:12px; margin-bottom:16px; }
.panel-header h3 { margin:0 auto 0 0; }
.list { display:grid; gap:9px; }
.list-row { display:flex; gap:12px; align-items:center; padding:11px 0; border-bottom:1px solid #eef1f4; }
.list-row:last-child { border-bottom:0; }
.row-actions { display:flex; gap:7px; justify-content:flex-end; white-space:nowrap; }
.list-row>div { min-width:0; flex:1; }
.list-row strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; }
.list-row small { display:block; margin-top:3px; color:var(--muted); font-size:11px; }
.badge { display:inline-flex; align-items:center; padding:4px 8px; border-radius:20px; background:#edf6f4; color:#28766f; font-size:10px; font-weight:700; }
.badge.gold { background:#fbf5e9; color:#9b7638; }
.badge.gray { background:#f0f2f5; color:#697688; }
.empty { padding:36px 22px; text-align:center; color:var(--muted); }
.empty strong { display:block; margin-bottom:7px; color:var(--navy); }
.table-wrap { overflow:auto; background:#fff; border:1px solid var(--line); border-radius:13px; box-shadow:var(--shadow); }
table { width:100%; border-collapse:collapse; min-width:650px; }
th,td { padding:14px 16px; border-bottom:1px solid #eef1f4; text-align:left; font-size:13px; }
th { color:var(--muted); font-size:11px; text-transform:uppercase; letter-spacing:.04em; background:#fbfcfd; }
td strong { color:var(--navy); }
.clickable { cursor:pointer; }
.clickable:hover td { background:#f8fbfb; }
.form-panel { max-width:720px; margin-bottom:18px; }
.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:0 14px; }
.form-grid .wide { grid-column:1/-1; }
.permission-grid { display:grid; grid-template-columns:repeat(2,1fr); gap:8px; padding:12px; border:1px solid var(--line); border-radius:9px; background:#fbfcfd; }
.permission-option { display:flex; align-items:center; gap:8px; padding:8px 9px; border-radius:7px; color:#314154; font-size:12px; cursor:pointer; }
.permission-option:hover { background:#edf6f4; }
.permission-option input { accent-color:var(--teal); }
.detail-head { display:flex; align-items:flex-start; gap:15px; margin-bottom:18px; }
.detail-head h2 { margin:0; color:var(--navy); font-family:'Playfair Display',serif; font-size:25px; }
.detail-head p { margin:5px 0 0; color:var(--muted); }
.document-card { display:flex; align-items:center; gap:12px; padding:12px 0; border-bottom:1px solid #eef1f4; }
.document-card:last-child { border-bottom:0; }
.document-card .doc-icon { width:36px; height:36px; display:grid; place-items:center; border-radius:8px; background:#f1f4f8; color:var(--navy); }
.document-card>div:nth-child(2) { flex:1; min-width:0; }
.document-card strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; }
.document-card small { color:var(--muted); }
.analysis { padding:17px; margin-top:13px; background:#fbfdfd; border-left:3px solid var(--teal); border-radius:8px; }
.analysis pre { white-space:pre-wrap; margin:0; color:#314154; font:inherit; line-height:1.65; }
.notice { padding:12px 14px; margin-bottom:16px; background:#fff9ec; border:1px solid #f3e3b9; border-radius:8px; color:#765c28; font-size:12px; line-height:1.5; }
.integration-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:15px; }
.integration-card { padding:20px; }
.integration-card h3 { margin:0 0 8px; color:var(--navy); font-size:16px; }
.integration-card p { min-height:58px; margin:0 0 15px; color:var(--muted); font-size:13px; line-height:1.5; }
.error-text { margin:10px 0 0; color:var(--red); font-size:12px; }
@media(max-width:900px) { .sidebar { width:72px; padding:20px 10px; } .sidebar-brand>div,.nav-item:not(.active)::after,.nav-item { font-size:0; } .sidebar-brand { justify-content:center; padding:0 0 30px; } .nav-item { justify-content:center; padding:12px 8px; } .nav-item span { font-size:18px; } .security-note,.logout { font-size:0; text-align:center; } .stats { grid-template-columns:repeat(2,1fr); } .grid-2,.integration-grid { grid-template-columns:1fr; } }
@media(max-width:560px) { .main-content { padding:20px 14px; } .topbar { margin-bottom:22px; } h1 { font-size:27px; } .user-chip>div { display:none; } .stats { gap:8px; } .stat-card { padding:14px; } .stat-card strong { font-size:25px; } .form-grid { grid-template-columns:1fr; } .form-grid .wide { grid-column:auto; } .permission-grid { grid-template-columns:1fr; } .row-actions { flex-direction:column; } .auth-brand { top:17px; left:18px; } .auth-brand>div { display:none; } .auth-card { padding:28px 22px; } }
