
:root { color-scheme: light; --accent:#2457d6; --ink:#162742; --muted:#54647c; --line:#dce5f3; --surface:#fff; --bg:#f4f7fc; --theme-soft:color-mix(in srgb,var(--accent) 10%,white); --theme-ink:color-mix(in srgb,var(--accent) 65%,#111c35); --navy:#111f37; font:16px/1.5 Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
* { box-sizing:border-box; }
body { margin:0; color:var(--ink); background:var(--bg); }
[hidden] { display:none !important; }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
button:disabled { opacity:.55; cursor:not-allowed; }
button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,a:focus-visible { outline:3px solid #769af2; outline-offset:3px; }
h1,h2,h3,p { margin:0; }
svg { width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:1.65; stroke-linecap:round; stroke-linejoin:round; display:inline-block; vertical-align:middle; flex:none; }
.symbols { position:absolute; width:0; height:0; }
.btn,.icon-btn { min-height:42px; border-radius:10px; border:1px solid var(--line); background:var(--surface); color:var(--ink); display:inline-flex; gap:8px; align-items:center; justify-content:center; padding:8px 13px; font-size:.875rem; font-weight:650; white-space:nowrap; }
.btn:hover,.icon-btn:hover { background:var(--theme-soft); }
.primary,.primary:hover { background:var(--accent); color:#fff; border-color:transparent; }
.primary:hover { background:var(--theme-ink); }
.danger { color:#a42339; }
.icon-btn { width:42px; padding:0; flex:none; }
.brand { display:inline-flex; align-items:center; gap:13px; color:inherit; text-decoration:none; line-height:1.08; font-weight:650; font-size:1rem; }
.brand strong { font-size:1.09rem; font-weight:790; }
.brand-mark { display:grid; place-items:center; width:43px; height:43px; background:var(--accent); color:#fff; border-radius:13px; font-weight:850; font-size:1.65rem; box-shadow:0 7px 19px #244da52c; }
.shell { display:grid; grid-template-columns:225px minmax(0,1fr); min-height:100dvh; }
.side { background:var(--navy); color:#fff; padding:29px 18px 19px; display:flex; flex-direction:column; position:sticky; top:0; height:100dvh; }
.side .brand { margin:0 6px 42px; }
.side nav { display:grid; gap:6px; }
.side nav button,.logout { display:flex; width:100%; align-items:center; gap:12px; min-height:46px; padding:9px 12px; background:transparent; border:1px solid transparent; color:#d1dbee; font-size:.94rem; text-align:left; border-radius:10px; }
.side nav button:hover,.logout:hover { background:#ffffff13; color:#fff; }
.side nav button.active { background:color-mix(in srgb,var(--accent) 38%,#192942); border-color:#ffffff21; color:white; font-weight:750; }
.side nav button.active svg { color:#d4e2ff; }
.side-footer { margin-top:auto; display:grid; gap:9px; }
.side-status { color:#c4d1e7; font-size:.81rem; padding:12px; display:flex; align-items:center; gap:7px; border-bottom:1px solid #ffffff20; }
.side-status::before { content:""; width:8px; height:8px; border-radius:100%; background:#e8aa55; flex:none; }
.side-status.ready::before { background:#5cdda5; }
.workspace { min-width:0; }
.top { min-height:70px; padding:0 30px; display:flex; align-items:center; gap:12px; border-bottom:1px solid var(--line); background:var(--surface); }
.breadcrumb { font-weight:700; }
.profile { margin-left:auto; display:flex; align-items:center; gap:9px; font-size:.875rem; font-weight:650; }
.profile-icon,.avatar { width:34px; height:34px; background:var(--theme-soft); color:var(--theme-ink); border-radius:11px; display:grid; place-items:center; font-weight:780; font-size:.82rem; flex:none; }
.mobile-menu,.scrim { display:none; }
main { padding:28px 30px 36px; }
.banner { position:relative; overflow:hidden; color:white; border-radius:17px; padding:30px 28px; background:linear-gradient(105deg,color-mix(in srgb,var(--accent) 52%,#101f48),var(--accent)); display:flex; align-items:center; gap:18px; min-height:135px; }
.banner::after { content:""; position:absolute; pointer-events:none; width:430px; height:430px; border:1px solid #ffffff37; border-radius:50%; right:-125px; top:-240px; box-shadow:0 0 0 25px #ffffff11,0 0 0 51px #ffffff0b,0 0 0 79px #ffffff08; }
.banner > * { position:relative; z-index:1; }
.banner h1,.page-heading h1 { font-size:clamp(1.8rem,3.5vw,2.7rem); font-weight:790; letter-spacing:-.045em; line-height:1.07; }
.banner p { color:#fff; opacity:.87; font-size:.95rem; margin-top:8px; }
.banner .btn { margin-left:auto; box-shadow:0 6px 22px #142c6150; }
.metric-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin:17px 0 24px; }
.metric { background:#fff; border:1px solid var(--line); border-radius:13px; padding:12px 13px; display:grid; grid-template-columns:38px 1fr; align-items:center; column-gap:11px; min-width:0; }
.metric-icon { grid-row:span 2; height:37px; width:37px; border-radius:10px; background:var(--status-bg); color:var(--status); display:grid; place-items:center; }
.metric .value { font-size:1.37rem; font-weight:800; line-height:1.15; }
.metric .label { color:var(--muted); font-size:.88rem; }
.sent { --status:#2e57c3; --status-bg:#e9efff; }
.delivered { --status:#087477; --status-bg:#e0f6f5; }
.read { --status:#6946b6; --status-bg:#f0eaff; }
.replied { --status:#19724a; --status-bg:#e1f6eb; }
.board-tools,.page-heading,.row-head { display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:10px; }
.board-tools { margin-bottom:12px; }
.board-tools h2,.settings-section h2 { font-size:1.28rem; letter-spacing:-.025em; }
.tools { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.search { position:relative; }
.search svg { position:absolute; left:10px; top:10px; color:var(--muted); }
.search input { padding-left:37px; width:min(265px,100%); min-height:42px; }
.board-scroll { overflow-x:auto; padding:2px 0 14px; min-height:375px; }
.board { display:grid; grid-auto-flow:column; grid-auto-columns:minmax(235px, 1fr); gap:12px; }
.column { min-width:0; min-height:350px; background:#edf2fa; border:1px solid var(--line); border-radius:14px; display:flex; flex-direction:column; }
.column h3 { font-size:.95rem; font-weight:750; overflow-wrap:anywhere; }
.column .col-head { display:flex; align-items:center; gap:8px; padding:10px 10px 6px; min-height:49px; }
.col-head .icon-btn { margin-left:auto; min-height:31px; width:31px; border-color:transparent; background:transparent; }
.count { background:#dfe8f7; color:#34445e; border-radius:6px; padding:1px 5px; font-size:.78rem; font-weight:750; }
.filters { display:flex; gap:4px; flex-wrap:wrap; margin:0 10px 9px; }
.status { display:inline-flex; align-items:center; border-radius:5px; padding:1px 5px; color:var(--status); background:var(--status-bg); font-size:.76rem; font-weight:700; }
.col-list { display:grid; align-content:start; gap:6px; overflow:auto; max-height:600px; padding:0 6px 8px; }
.contact-card { display:grid; grid-template-columns:32px minmax(0,1fr); gap:7px; align-items:start; width:100%; text-align:left; background:#fff; border:1px solid #dbe4f3; padding:9px 7px; border-radius:9px; color:var(--ink); }
.contact-card:hover { border-color:#9bb5eb; background:#fafcff; }
.contact-card .avatar { width:32px; height:32px; }
.contact-card .card-top { display:flex; gap:5px; justify-content:space-between; align-items:baseline; }
.contact-card .card-top strong,.ellipsis { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.contact-card .card-top strong { font-size:.86rem; }
.contact-card .card-top time { color:var(--muted); font-size:.74rem; flex:none; }
.preview { color:var(--muted); font-size:.83rem; margin:2px 0; }
.empty { color:var(--muted); padding:14px 12px; font-size:.89rem; }
.thread { display:flex; flex-direction:column; gap:8px; min-height:350px; padding:0 7px 8px; }
.thread-head { display:flex; align-items:center; gap:7px; min-height:38px; }
.thread-head div { min-width:0; }
.thread-head .icon-btn { margin-left:auto; width:29px; min-height:29px; }
.thread-head small,.form-help { color:var(--muted); font-size:.81rem; }
.messages { min-height:190px; max-height:370px; overflow:auto; display:flex; flex-direction:column; align-items:flex-start; gap:7px; background:#f7f9fd; border:1px solid var(--line); border-radius:8px; padding:8px; }
.message { background:#fff; border:1px solid var(--line); border-radius:8px 8px 8px 3px; padding:6px 8px; max-width:93%; font-size:.85rem; white-space:pre-wrap; overflow-wrap:anywhere; }
.message.out { align-self:flex-end; background:var(--theme-soft); border-radius:8px 8px 3px 8px; }
.message time { display:block; color:var(--muted); text-align:right; font-size:.73rem; margin-top:4px; }
.composer { display:flex; align-items:end; gap:5px; }
.composer textarea { min-height:44px; resize:vertical; }
.composer button { width:40px; }
.page-heading { margin-bottom:20px; }
.page-heading p { color:var(--muted); margin-top:7px; }
.list,.settings-section { background:var(--surface); border:1px solid var(--line); border-radius:14px; }
.list { overflow:auto; }
.settings-section { padding:17px; margin-bottom:16px; }
.settings-section .row-head { margin-bottom:13px; }
table { width:100%; border-collapse:collapse; text-align:left; }
th,td { padding:11px 12px; border-bottom:1px solid var(--line); font-size:.9rem; vertical-align:top; }
th { color:#435571; background:#f3f7fd; font-size:.83rem; white-space:nowrap; }
tr:last-child td { border-bottom:none; }
td:last-child { min-width:100px; }
table .tools { flex-wrap:nowrap; }
.pill { display:inline-flex; padding:2px 7px; border-radius:6px; color:#3d5069; background:#edf2fa; font-size:.78rem; font-weight:700; white-space:nowrap; }
.pill.good { color:#0d6940; background:#e5f7ec; }
.pill.warn { color:#853b16; background:#fff0dc; }
.pagination { margin-top:10px; display:flex; flex-wrap:wrap; gap:8px; }
fieldset { border:1px solid var(--line); border-radius:10px; min-width:0; margin:0; padding:8px 10px; display:grid; gap:6px; }
legend { padding:0 5px; font-size:.88rem; font-weight:650; }
label { display:grid; gap:5px; font-weight:650; font-size:.91rem; color:var(--ink); }
label.check { display:flex; gap:8px; align-items:start; font-weight:500; }
input,select,textarea { width:100%; min-height:43px; padding:8px 10px; border:1px solid #c9d6e9; border-radius:8px; color:var(--ink); background:#fff; font-size:1rem; }
input[type=checkbox] { accent-color:var(--accent); width:17px; height:17px; min-height:0; margin:4px 0 0; flex:none; }
input[type=color] { max-width:85px; }
input[type=file] { padding:7px; }
textarea { resize:vertical; }
.form-grid,.modal form { display:grid; gap:11px; }
.two { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.form-error { color:#9a1630; border-radius:7px; background:#fff0f2; padding:6px 8px; font-size:.88rem; }
.form-actions { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:7px; margin-top:3px; }
.modal { width:min(540px,calc(100% - 22px)); padding:0; border:1px solid var(--line); border-radius:15px; color:var(--ink); box-shadow:0 20px 65px #17294c38; max-height:calc(100dvh - 24px); }
.modal::backdrop { background:#12213b68; }
.modal-heading { display:flex; justify-content:space-between; align-items:center; padding:13px 16px; border-bottom:1px solid var(--line); gap:8px; }
.modal-heading h2 { font-size:1.22rem; }
.modal-content { padding:15px 16px 18px; }
.template-preview { background:var(--theme-soft); color:var(--theme-ink); padding:10px; border-radius:7px; font-size:.9rem; white-space:pre-wrap; overflow-wrap:anywhere; }
#toast { z-index:4; position:fixed; bottom:15px; right:15px; background:var(--navy); color:#fff; padding:10px 14px; border-radius:9px; box-shadow:0 8px 22px #17294c38; max-width:min(480px,calc(100vw - 30px)); }
.login-screen { min-height:100dvh; display:grid; grid-template-columns:1fr 1fr; }
.login-cover { position:relative; display:grid; align-content:space-between; gap:80px; padding:clamp(25px,7vw,96px); color:white; background:radial-gradient(ellipse at 89% 92%,#527bf7 0%,#2457d6 31%,#142d68 75%); min-height:100dvh; }
.login-cover h1 { font-size:clamp(2.4rem,5vw,5rem); line-height:1; letter-spacing:-.06em; }
.login-cover p { margin-top:13px; color:#edf3ff; max-width:310px; }
.login-main { display:grid; align-items:center; justify-items:center; padding:26px; }
.login-form { width:min(100%,385px); display:grid; gap:13px; background:white; padding:22px; border:1px solid var(--line); border-radius:15px; box-shadow:0 12px 30px #1627420c; }
.login-form h2 { margin-bottom:3px; letter-spacing:-.03em; font-size:1.58rem; }
@media (max-width:1080px) { .shell { grid-template-columns:182px minmax(0,1fr); } main,.top { padding-left:19px; padding-right:19px; } }
@media (max-width:760px) {
  .shell { display:block; }
  .mobile-menu { display:inline-flex; }
  .side { display:none; position:fixed; left:0; top:0; z-index:7; width:min(250px,90vw); }
  .side.open { display:flex; }
  .scrim:not([hidden]) { display:block; position:fixed; z-index:6; inset:0; background:#12213b68; border:0; }
  .top { min-height:60px; }
  main { padding-top:15px; }
  .banner { padding:17px; gap:12px; align-items:flex-start; flex-direction:column; }
  .banner .btn { margin:0; }
  .metric-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:7px; margin:11px 0 16px; }
  .metric { padding:8px; column-gap:6px; }
  .board { grid-auto-columns:minmax(235px,76vw); scroll-snap-type:x proximity; }
  .column { scroll-snap-align:start; }
  .login-screen { grid-template-columns:1fr; grid-template-rows:auto 1fr; }
  .login-cover { min-height:0; gap:23px; padding:24px; }
  .login-cover h1 { font-size:2.25rem; }
}
@media (max-width:430px) { .two { grid-template-columns:1fr; } .tools .search { flex:1; min-width:145px; } .tools .search input { width:100%; } }

.interest-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(155px,1fr)); gap:8px; }
.interest { padding:10px 11px; border-radius:9px; background:var(--theme-soft); color:var(--theme-ink); display:grid; }
.interest span { font-size:.84rem; }
.contact-card .preview,.thread-head strong { display:block; }
.campaign-image { width:min(230px,100%); max-height:170px; border-radius:10px; object-fit:contain; }
