/* ATC Hub — brand: σκούρος καμβάς, κρεμ, χρυσό accent */
:root {
  --bg: #0a0a0b;
  --surface: #131315;
  --surface-2: #1a1a1d;
  --text: #ede7dc;
  --muted: #a29b90;
  --dim: #6f6a62;
  --gold: #d4aa4f;
  --gold-hi: #f0d27a;
  --gold-lo: #9c7a2e;
  --line: rgba(236, 226, 206, 0.14);
  --line-soft: rgba(236, 226, 206, 0.08);
  --ok: #93b285;
  --ok-dim: rgba(147, 178, 133, 0.14);
  --warn: #c98f6b;
  --warn-dim: rgba(201, 143, 107, 0.14);
  --font-sans: 'Inter Tight', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font-sans); font-size: 16px; line-height: 1.5;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: calc(40px + env(safe-area-inset-bottom, 0px));
}
.wrap { max-width: 860px; margin: 0 auto; }
a { color: var(--text); }
a:hover { color: var(--gold-hi); }
code { color: var(--gold-hi); }

/* Header */
header { padding: 22px 0 14px; border-bottom: 1px solid var(--line); }
.eyebrow { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--dim); display: flex; justify-content: space-between; gap: 12px; }
.eyebrow .num { color: var(--gold); }
h1 { font-weight: 300; font-size: 30px; letter-spacing: -.03em; margin: 8px 0 0; line-height: 1.1; }
h1 em { font-style: normal; background: linear-gradient(180deg, var(--gold-hi), var(--gold) 60%, var(--gold-lo));
  -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Nav */
nav { display: flex; gap: 8px; overflow-x: auto; padding: 14px 0; scrollbar-width: none; }
nav::-webkit-scrollbar { display: none; }
nav a { font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .05em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px;
  white-space: nowrap; text-decoration: none; flex: 0 0 auto; }
nav a.on { color: var(--bg); background: var(--gold); border-color: var(--gold); font-weight: 500; }
nav a.out { margin-left: auto; color: var(--dim); }

/* Cards / layout */
main { padding-top: 6px; }
.card { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 16px; margin: 12px 0; }
.card.hero { border-color: var(--line); }
.card.overdue { border-color: var(--warn); }
.klabel { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); margin-bottom: 8px; }
.klabel.gold, .gold-t { color: var(--gold); }
.ok-t { color: var(--ok); }
.warn-t { color: var(--warn); }
.dim { color: var(--dim); }
.note { font-size: 14px; color: var(--muted); margin: 6px 0; overflow-wrap: break-word; }
.mt { margin-top: 10px; }
.inline { display: inline; }

/* Stats */
.stats { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0 4px; }
.stat { flex: 1 1 140px; background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 12px 14px; min-width: 0; }
.stat b { display: block; font-size: 24px; font-weight: 300; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat span { font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.stat.gold b { color: var(--gold); }
.stat.warn b { color: var(--warn); }
.stat.ok b { color: var(--ok); }

/* Banner */
.banner { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; justify-content: space-between;
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 12px 14px; margin: 14px 0 4px; }
.banner.gold-border { border-color: var(--gold); }
.banner .t { font-family: var(--font-mono); font-size: 12px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }

/* Posts / leads cards */
.post { display: flex; flex-direction: column; gap: 10px; }
.post-top { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; justify-content: space-between; }
.pdate { font-family: var(--font-mono); font-size: 12.5px; color: var(--gold); letter-spacing: .04em; white-space: nowrap; }
.ptitle { font-size: 17px; font-weight: 500; letter-spacing: -.01em; margin: 0; min-width: 0; }
.ptitle.big { font-size: 21px; }
.ptitle a { text-decoration: none; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .05em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 4px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.chip.type { color: var(--text); }
.chip.need { color: var(--warn); border-color: transparent; background: var(--warn-dim); }
.chip.dim-chip { color: var(--dim); }
.chip.st-new { color: var(--muted); }
.chip.st-contacted { color: var(--muted); }
.chip.st-interest { color: var(--ok); }
.chip.st-meeting, .chip.st-client { color: var(--gold); border-color: var(--gold); }
.chip.st-later { color: var(--muted); border-style: dashed; }
.chip.st-dead { color: var(--dim); text-decoration: line-through; }
.chip.ps-draft { color: var(--muted); }
.chip.ps-approved { color: var(--ok); border-color: transparent; background: var(--ok-dim); }
.chip.ps-published { color: var(--dim); border-style: dashed; }
.chip.ps-skipped { color: var(--dim); text-decoration: line-through; }
/* Social: ροή δύο εγκρίσεων */
.chip.ps-idea { color: var(--gold); border-color: var(--gold); }
.chip.ps-idea_rejected { color: var(--dim); text-decoration: line-through; border-style: dashed; }
.chip.ps-todo { color: var(--warn); border-color: transparent; background: var(--warn-dim); }
.post.st-idea { border-left: 2px solid var(--gold); }
.post.st-idea_rejected { opacity: .7; }
.brief { font-family: var(--font-sans); font-size: 13px; color: var(--muted); white-space: pre-wrap; overflow-wrap: break-word;
  border-left: 2px solid var(--gold-lo); padding-left: 12px; margin: 2px 0 4px; }
.warn-note { color: var(--warn); font-size: 13px; }
details.reject { display: inline-block; }
details.reject > summary { list-style: none; }
details.reject > summary::-webkit-details-marker { display: none; }
details.reject[open] > summary { border-color: var(--warn); color: var(--warn); }
.reject-form { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.reject-form input[type=text] { flex: 1 1 240px; font: inherit; font-size: 13px; padding: 7px 10px; border-radius: 6px;
  background: var(--surface-2); color: var(--text); border: 1px solid var(--line); }
.btn.danger { border-color: var(--warn); color: var(--warn); }
.btn.danger:hover { background: var(--warn-dim); }
details.week.ideas { border: 1px solid var(--gold-lo); border-radius: 10px; padding: 6px 12px 12px; margin-bottom: 12px; }

/* Phone */
.phone { font-family: var(--font-mono); letter-spacing: .03em; color: var(--text); text-decoration: none; user-select: all; }
.phone.big { font-size: 22px; color: var(--gold-hi); }

/* Prep box */
.prep { border-left: 2px solid var(--gold-lo); padding-left: 12px; margin: 6px 0; }

/* Buttons */
.btn { font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em; border-radius: 6px; padding: 9px 14px;
  cursor: pointer; background: var(--surface-2); color: var(--text); border: 1px solid var(--line); text-decoration: none; display: inline-block; }
.btn:hover { border-color: var(--gold); color: var(--text); }
.btn.primary { background: var(--gold); border-color: var(--gold); color: var(--bg); font-weight: 500; }
.btn.primary:hover { background: var(--gold-hi); }
.btn.ghost { background: transparent; color: var(--dim); }
.btn.ok-btn { border-color: var(--ok); color: var(--ok); }
.btn.sm { padding: 6px 10px; font-size: 11px; }
.btn.wide { width: 100%; margin-top: 14px; }
.btn[disabled] { opacity: .4; cursor: default; }
.btn:focus-visible, nav a:focus-visible, .fld:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.outs { display: flex; flex-wrap: wrap; gap: 6px; }
.btn.out { font-size: 11.5px; padding: 8px 10px; }

/* Forms */
label { display: block; font-size: 13px; color: var(--muted); margin: 6px 0; }
label.chk { display: flex; align-items: center; gap: 8px; }
.fld { background: var(--surface-2); border: 1px solid var(--line); color: var(--text); border-radius: 6px;
  padding: 10px; font-family: var(--font-sans); font-size: 15px; width: 100%; margin-top: 3px; }
.fld::placeholder { color: var(--dim); }
.fld.auto { width: auto; margin-top: 0; }
.fld.grow { flex: 1 1 140px; }
.mono-area { font-family: var(--font-mono); font-size: 12.5px; }
.fgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.filterbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 4px; align-items: center; }
.logform { display: flex; flex-direction: column; gap: 10px; }
.mono { font-family: var(--font-mono); font-size: 13px; }

/* Weeks / details */
details.week { border-top: 1px solid var(--line); padding: 4px 0 10px; }
details.week > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline;
  justify-content: space-between; gap: 10px; padding: 12px 0 4px; flex-wrap: wrap; }
details.week > summary::-webkit-details-marker { display: none; }
details.subdetails > summary { cursor: pointer; list-style: none; }
.wk-title { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.wk-title .count { color: var(--dim); margin-left: 8px; }
.wk-meta { font-family: var(--font-mono); font-size: 11px; color: var(--dim); }
.wk-bar { padding: 8px 0 2px; }
details.cap summary { cursor: pointer; }
.capfull { font-family: var(--font-sans); font-size: 14px; color: var(--muted); white-space: pre-wrap;
  overflow-wrap: break-word; border-left: 2px solid var(--line); padding-left: 12px; margin: 8px 0; }

/* Table */
.table-card { padding-bottom: 8px; }
.tscroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--dim); text-align: left; padding: 8px 10px 8px 0; border-bottom: 1px solid var(--line); }
td { padding: 9px 10px 9px 0; border-bottom: 1px solid var(--line-soft); vertical-align: baseline; }
td a { text-decoration: none; }
.pager { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding-top: 10px; }

/* Payments */
.payrow { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; border-top: 1px solid var(--line-soft); padding-top: 8px; }

/* Google widgets */
.gcols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 640px) { .gcols { grid-template-columns: 1fr; } }
.gcols .card { margin: 0; min-width: 0; }
.taskrow { display: flex; align-items: baseline; gap: 10px; margin: 7px 0; font-size: 14px; color: var(--muted); }
.taskrow .tick { background: transparent; border: 1px solid var(--line); color: var(--dim); border-radius: 50%;
  width: 24px; height: 24px; line-height: 1; cursor: pointer; flex: 0 0 auto; }
.taskrow .tick:hover { border-color: var(--ok); color: var(--ok); }

/* Nav search */
.navsearch { flex: 0 0 auto; margin-left: auto; }
.navsearch input { background: var(--surface-2); border: 1px solid var(--line); color: var(--text);
  border-radius: 999px; padding: 7px 14px; font-family: var(--font-mono); font-size: 12px; width: 130px; }
.navsearch input::placeholder { color: var(--dim); }
.navsearch input:focus { width: 180px; outline: 2px solid var(--gold); outline-offset: 1px; }
nav a.out { margin-left: 0; }

/* Flash */
.flash { background: var(--surface-2); border: 1px solid var(--gold); color: var(--text); border-radius: 8px;
  padding: 10px 14px; margin: 12px 0; font-size: 14px; }

/* Footer */
footer { margin-top: 36px; border-top: 1px solid var(--line); padding-top: 14px; }
footer .row { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }

/* Login */
.login-body { display: flex; min-height: 100vh; align-items: center; justify-content: center; }
.login-box { width: min(380px, 92vw); background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; padding: 28px; }
.login-box h1 { margin-bottom: 10px; }

@media (max-width: 520px) {
  h1 { font-size: 26px; }
  .fgrid { grid-template-columns: 1fr; }
  .card { padding: 14px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* --- Instagram grid (Social) --- */
.igrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.igitem { position: relative; display: block; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--surface); border: 1px solid var(--line-soft); }
.igitem img { width: 100%; height: 100%; object-fit: cover; display: block; }
.igph { display: flex; align-items: center; justify-content: center; height: 100%; font-family: var(--font-mono); font-size: 10px; color: var(--dim); }
.igmeta { position: absolute; left: 0; right: 0; bottom: 0; padding: 3px 6px; font-family: var(--font-mono); font-size: 10px; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.72)); }

/* --- Media attached σε post --- */
.pmedia { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 6px 0 2px; }
.pmedia img { width: 44px; height: 44px; object-fit: cover; border-radius: 6px; border: 1px solid var(--line-soft); }

/* --- Pipeline (kanban) --- */
.kb { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 14px; align-items: flex-start; -webkit-overflow-scrolling: touch; }
.kcol { flex: 0 0 238px; min-width: 238px; background: rgba(255,255,255,.015); border: 1px solid var(--line-soft); border-radius: 10px; }
.khead { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 9px 11px; border-bottom: 1px solid var(--line-soft); font-family: var(--font-mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; }
.khead .kmeta { color: var(--gold); font-size: 11px; white-space: nowrap; }
.kbody { display: flex; flex-direction: column; gap: 8px; padding: 9px; min-height: 70px; border-radius: 0 0 10px 10px; }
.kbody.over { outline: 1px dashed var(--gold); outline-offset: -4px; background: rgba(212,170,79,.05); }
.kcard { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 8px; padding: 8px 10px; cursor: grab; }
.kcard.dragging { opacity: .45; }
.kcard .kname { font-weight: 500; font-size: 14px; display: block; overflow-wrap: anywhere; }
.kcard .krow { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; margin-top: 3px; }
.kmove { width: 100%; margin-top: 7px; background: transparent; color: var(--dim); border: 1px solid var(--line-soft); border-radius: 6px; padding: 3px 6px; font-family: var(--font-mono); font-size: 11px; }
.kmore { padding: 2px 2px 4px; }

/* --- Χρονολόγιο & αρχεία --- */
.tlform { display: flex; gap: 8px; margin-bottom: 10px; }
.tlrow { display: flex; gap: 8px; align-items: baseline; padding: 5px 0; border-bottom: 1px solid var(--line-soft); font-size: 13.5px; }
.tlrow:last-child { border-bottom: 0; }
.tlic { flex: 0 0 20px; text-align: center; }
.tlts { flex: 0 0 76px; color: var(--dim); font-size: 11px; }
.tltx { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.tl-convert .tltx { color: var(--gold); }
.filerow { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 4px 0; }

/* --- Στοιχεία επαφής lead (lead_facts) --- */
.facts { margin: 10px 0 6px; padding: 10px 12px; border: 1px solid var(--line-soft); border-radius: 8px; background: rgba(255,255,255,.02); }
.facts.compact { padding: 8px 12px; }
.facts .klabel { margin-bottom: 4px; }
.factrow { display: flex; gap: 8px; align-items: baseline; padding: 4px 0; border-bottom: 1px solid var(--line-soft); font-size: 14px; }
.factrow:last-of-type { border-bottom: 0; }
.fic { flex: 0 0 22px; text-align: center; }
.ftx { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.flabel { color: var(--dim); font-size: 12px; margin-right: 6px; }
.f-note .ftx { color: var(--muted); font-style: italic; }
.f-person .ftx { color: var(--text); font-weight: 600; }
.f-hours .ftx { font-family: var(--font-mono); font-size: 13px; }
.factform { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.factform .fld.flbl { flex: 0 1 150px; }
.fic-sm { margin-left: 6px; text-decoration: none; font-size: 14px; }
td.nowrap { white-space: nowrap; }

/* --- Φίλτρα status στο Social --- */
.sfilters { flex-wrap: wrap; gap: 6px; margin: 16px 0 10px; }
.sfilters .btn { white-space: nowrap; }
.pmedia a { display: block; line-height: 0; border-radius: 6px; transition: transform .12s; }
.pmedia a:hover { transform: scale(1.6); position: relative; z-index: 5; }

/* --- Lightbox --- */
.lb { position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; background: rgba(5,5,6,.94); backdrop-filter: blur(4px); }
.lb.on { display: flex; }
.lb-img { max-width: min(92vw, 640px); max-height: 88vh; object-fit: contain; border-radius: 10px; box-shadow: 0 10px 60px rgba(0,0,0,.6); }
.lb-x, .lb-prev, .lb-next { position: fixed; z-index: 101; background: rgba(255,255,255,.07); color: #ede7dc; border: 1px solid rgba(255,255,255,.14); border-radius: 50%; width: 44px; height: 44px; font-size: 22px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.lb-x { top: 14px; right: 14px; font-size: 16px; }
.lb-prev { left: 10px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 10px; top: 50%; transform: translateY(-50%); }
.lb-x:hover, .lb-prev:hover, .lb-next:hover { background: rgba(212,170,79,.25); }
.lb-count { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; color: #ede7dc; background: rgba(255,255,255,.07); padding: 4px 12px; border-radius: 999px; }

/* --- Pipeline mini (dashboard) --- */
.kmini { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; margin: 2px 0 14px; padding: 10px 14px; background: rgba(255,255,255,.015); border: 1px solid var(--line-soft); border-radius: 10px; text-decoration: none; color: inherit; }
.kmini .kmi { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .04em; color: var(--dim); white-space: nowrap; }
.kmini .kmi b { color: var(--fg, #ede7dc); font-weight: 500; }
.kmini .kmi em { font-style: normal; color: var(--gold); }
.kmini .arrow { margin-left: auto; color: var(--gold); }
.kmini:hover { border-color: var(--gold); }

/* --- Προσφορές --- */
.orow { display: flex; gap: 8px; margin-bottom: 8px; align-items: flex-start; }
.orow .onum { flex: 0 0 92px; }
.orow textarea { min-height: 42px; resize: vertical; }

/* --- Πίνακας τριμήνων (Προσφορές) --- */
.qtable { width: 100%; border-collapse: collapse; margin-top: 6px; }
.qtable th { text-align: left; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); padding: 6px 8px; border-bottom: 1px solid var(--line-soft); }
.qtable th.r, .qtable td.r { text-align: right; white-space: nowrap; }
.qtable td { padding: 5px 8px; font-size: 13.5px; border-bottom: 1px solid var(--line-soft); }
.qtable tr.qm td:first-child { padding-left: 18px; }
.qtable tr.dimrow td { color: var(--dim); }
.qtable tr.qsum td { font-weight: 500; color: var(--gold); background: rgba(212,170,79,.05); }
.qtable tr.ytotal td { font-weight: 600; border-top: 2px solid var(--gold); border-bottom: 0; padding-top: 9px; font-size: 14.5px; }

/* --- Βιβλίο Εσόδων-Εξόδων --- */
.payrow.overdue { background: rgba(224,122,95,.08); border-radius: 6px; }
.payrow.overdue .mono { color: var(--warn); }
a.plain { color: inherit; text-decoration: none; }
a.plain:hover { color: var(--gold); }

/* --- Εβδομαδιαίο ημερολόγιο (dashboard) --- */
.wkcal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; }
.wkday { background: rgba(255,255,255,.015); border: 1px solid var(--line-soft); border-radius: 8px; padding: 7px 8px; min-height: 86px; min-width: 0; }
.wkday.is-today { border-color: var(--gold); background: rgba(212,170,79,.05); }
.wkhead { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .07em; text-transform: uppercase; color: var(--dim); margin-bottom: 6px; }
.wkday.is-today .wkhead { color: var(--gold); }
.wkit { display: block; font-size: 11.5px; line-height: 1.35; padding: 3px 0; border-bottom: 1px dashed var(--line-soft); color: inherit; text-decoration: none; overflow-wrap: anywhere; }
.wkit:last-child { border-bottom: 0; }
.wkit.need { color: var(--warn); }
.wkit.gold { color: var(--gold); }
a.wkit:hover { color: var(--gold); }
.wkempty { color: var(--line-soft); text-align: center; padding-top: 10px; }
@media (max-width: 860px) { .wkcal { grid-template-columns: 1fr 1fr; } .wkday { min-height: 0; } .wkday:last-child { grid-column: span 2; } }

/* --- Μίνι τρίμηνα --- */
.qmini { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 860px) { .qmini { grid-template-columns: 1fr; } }
a.plainlink { color: inherit; text-decoration: none; display: block; }
a.plainlink:hover { border-color: var(--gold); }

/* ===== Desktop (≥1100px): sidebar + πλατύ περιεχόμενο — το mobile μένει ως έχει ===== */
@media (min-width: 1100px) {
  body { padding-left: 24px; padding-right: 24px; }
  .wrap {
    max-width: 1460px;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr);
    grid-template-rows: auto 1fr auto;
    grid-template-areas: "hdr main" "nav main" "ftr main";
    column-gap: 0;
  }
  header { grid-area: hdr; border-bottom: 0; padding: 28px 24px 6px 0; }
  .eyebrow { flex-direction: column; gap: 2px; align-items: flex-start; }
  h1 { font-size: 25px; }
  nav {
    grid-area: nav; flex-direction: column; align-items: stretch; gap: 5px;
    padding: 18px 24px 18px 0; overflow: visible;
    position: sticky; top: 0; align-self: start; max-height: 100vh; overflow-y: auto;
  }
  nav a { border-color: transparent; border-radius: 8px; padding: 10px 13px; font-size: 13px; }
  nav a:hover { border-color: var(--line); }
  nav a.on { border-color: var(--gold); }
  nav .navsearch { margin: 10px 0 4px; }
  nav .navsearch input { width: 100%; }
  nav a.out { margin-left: 0; margin-top: 16px; border-top: 1px solid var(--line-soft); border-radius: 0 0 8px 8px; padding-top: 15px; }
  main { grid-area: main; padding: 28px 0 20px 44px; border-left: 1px solid var(--line-soft); min-width: 0; }
  footer { grid-area: ftr; margin: 0; border-top: 0; padding: 0 24px 26px 0; }
  footer .row { flex-direction: column; gap: 2px; align-items: flex-start; font-size: 12px; color: var(--dim); }

  /* Πλατύτερη αξιοποίηση χώρου */
  .stats .stat b { font-size: 27px; }
  .kcol { flex: 0 0 256px; min-width: 256px; }
  .card { padding: 18px 20px; }
  .igrid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
}

/* --- MFA QR --- */
.qrbox { display: inline-block; background: #ffffff; padding: 12px; border-radius: 10px; line-height: 0; margin: 4px 0 8px; }

/* --- Ζώνες κερδοφορίας (προσφορές) --- */
.chip.pz-ok { color: var(--ok); border-color: var(--ok); background: var(--ok-dim); }
.chip.pz-low { color: var(--warn); border-color: var(--warn); background: var(--warn-dim); }
.chip.pz-loss { color: #e05a5a; border-color: #e05a5a; background: rgba(224,90,90,.14); font-weight: 600; }
.pcout { margin-top: 6px; padding: 10px 12px; background: rgba(255,255,255,.015); border: 1px solid var(--line-soft); border-radius: 8px; }

/* --- Κινητό: πίνακες τριμήνων να χωράνε ΧΩΡΙΣ οριζόντιο σκρολ --- */
@media (max-width: 640px) {
  main { overflow-x: hidden; }
  .qtable { font-size: 12px; }
  .qtable th { padding: 5px 3px; font-size: 9px; letter-spacing: .02em; }
  .qtable td { padding: 6px 3px; font-size: 12px; }
  .qtable td .mono, .qtable td.mono { font-size: 11.5px; letter-spacing: -.02em; }
  .qtable tr.qm td:first-child { padding-left: 9px; }
  .qtable tr.ytotal td { font-size: 12px; }
  .payrow { flex-wrap: wrap; }
  .gcols { grid-template-columns: 1fr; }
}

/* --- Portal πελατών --- */
.pwrap { max-width: 720px; margin: 0 auto; }
.pnav-user { font-family: var(--font-mono); font-size: 12.5px; color: var(--muted); padding: 8px 14px 8px 0; flex: 1 1 auto; }
.pchat { display: flex; flex-direction: column; gap: 10px; max-height: 420px; overflow-y: auto; padding: 4px 2px; }
.pmsg { max-width: 85%; }
.pmsg.me { align-self: flex-end; text-align: right; }
.pmsg.atc { align-self: flex-start; }
.pmsg-b { display: inline-block; text-align: left; padding: 9px 13px; border-radius: 12px; font-size: 14.5px; background: var(--surface-2); border: 1px solid var(--line-soft); overflow-wrap: anywhere; }
.pmsg.me .pmsg-b { background: rgba(212,170,79,.14); border-color: rgba(212,170,79,.35); }
.pmsg-t { font-family: var(--font-mono); font-size: 10.5px; color: var(--dim); margin-top: 3px; }

/* --- Portal: κεφαλίδα με logo, footer μίας γραμμής, ματάκι κωδικού --- */
.phead { text-align: center; padding: 30px 0 14px; border-bottom: 1px solid var(--line); }
.phead .plogo { width: 150px; height: auto; display: inline-block; transition: transform .2s ease; }
.phead a:hover .plogo { transform: scale(1.04); }
.phead h1 { margin-top: 8px; }
.pheadsub { justify-content: center; margin-top: 6px; letter-spacing: .12em; font-size: 10.5px; }
.pwrap nav { justify-content: space-between; }
.pfoot { margin-top: 36px; border-top: 1px solid var(--line); padding-top: 16px;
  display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline; gap: 4px 10px;
  font-family: var(--font-mono); font-size: 12px; }
.pfoot a { color: var(--dim); text-decoration: none; white-space: nowrap; }
.pfoot a:hover { color: var(--gold); }
.pdot { color: var(--line); }
@media (max-width: 480px) { .pfoot { font-size: 11px; gap: 3px 8px; } .pdot { display: none; } .pfoot a { flex: 1 1 100%; text-align: center; padding: 3px 0; } }
.pwd-wrap { position: relative; display: block; }
.pwd-wrap .fld { padding-right: 46px; width: 100%; }
.pwd-eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  background: none; border: 0; cursor: pointer; font-size: 17px; opacity: .65; padding: 6px; line-height: 1; }
.pwd-eye:hover { opacity: 1; }

/* ---- Portal: υγεία site + σκορ Google (PSI gauges) ---- */
.phealth { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px;
  margin-bottom: 12px; font-size: 14px; border: 1px solid transparent; }
.phealth.ok { background: var(--ok-dim); border-color: rgba(147,178,133,.3); color: var(--text); }
.phealth.warn { background: var(--warn-dim); border-color: rgba(201,143,107,.35); color: var(--text); }
.phealth .phico { font-size: 20px; line-height: 1; }
.psirow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 10px; }
.psic { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.psic > span { font-size: 11px; color: var(--muted); text-align: center; letter-spacing: .02em; }
.psig { --p: 0; --c: var(--ok); width: 62px; height: 62px; border-radius: 50%;
  background: conic-gradient(var(--c) calc(var(--p) * 1%), rgba(237,231,220,.09) 0);
  display: grid; place-items: center; animation: psiIn .6s ease; }
.psig::before { content: ""; grid-area: 1/1; width: 48px; height: 48px; border-radius: 50%; background: var(--surface); }
.psig b { grid-area: 1/1; font-family: var(--font-mono); font-size: 16px; z-index: 1; color: var(--c); }
.psig.g { --c: var(--ok); }
.psig.o { --c: var(--gold); }
.psig.r { --c: #e05a5a; }
@keyframes psiIn { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (max-width: 480px) { .psirow { grid-template-columns: repeat(2, 1fr); row-gap: 14px; } }

/* ---- Portal: sparkline πορείας ---- */
.spark { width: 100%; max-width: 320px; height: 54px; display: block; }

/* ---- Portal: συχνές ερωτήσεις ---- */
.faqi { border-top: 1px solid var(--line-soft); padding: 10px 0; }
.faqi:first-of-type { border-top: 0; }
.faqi summary { cursor: pointer; font-weight: 500; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faqi summary::-webkit-details-marker { display: none; }
.faqi summary::after { content: "+"; color: var(--gold); font-family: var(--font-mono); transition: transform .2s; }
.faqi[open] summary::after { transform: rotate(45deg); }
.faqi p { margin: 8px 0 0; }
.faqedit { border-top: 1px solid var(--line-soft); padding: 12px 0; }
.faqedit:first-child { border-top: 0; padding-top: 0; }

/* Προσφορές — προεπισκόπηση email */
.mailpreview { width: 100%; height: 1280px; border: 1px solid var(--line); border-radius: 10px; background: #e9e6df; display: block; }
@media (max-width: 640px) { .mailpreview { height: 1560px; } }
