/* Vizivo yönetim paneli — IBM Plex; beyaz zemin, ince çizgiler, yeşil/sarı/kırmızı vurgu. */
:root {
  --bg: #ffffff; --tile: #f6f6f3; --ink: #121412; --muted: #6b716d; --faint: #9aa09c;
  --rule: #121412; --line: #e4e5e1; --line-2: #d2d4cf;
  --teal: #0e7a63; --teal-soft: #dcefe9; --amber: #b07a12; --amber-rule: #e2b04a; --red: #b3392c; --red-rule: #e48a7f;
  --raw: #c3c7c2; --shadow: 0 6px 22px rgba(18, 20, 18, .12);
  --display: "IBM Plex Sans Condensed", "Arial Narrow", Arial, sans-serif;
  --num: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --body: "IBM Plex Sans", "Segoe UI", Arial, sans-serif;
  --ev-gorev: var(--ink); --ev-tahsilat: var(--teal); --ev-rapor: var(--amber-rule); --ev-gonderi: #7d9bb8;
  --ev-gider: var(--red-rule); --ev-baslangic: var(--teal); --ev-etkinlik: #8a7cc9; --ev-yenileme: var(--amber);
  --ev-asama: var(--ink); --ev-tatil: #c7a0a0;
  color-scheme: light;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 14px/1.5 var(--body); }
a { color: inherit; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px 56px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.n { font-family: var(--num); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }

/* Üst satır */
.top { position: sticky; top: 0; z-index: 20; background: var(--bg); }
.brandrow { display: flex; align-items: center; gap: 18px; padding: 16px 0 12px; border-bottom: 2px solid var(--rule); flex-wrap: wrap; }
.brand img { height: 28px; width: auto; display: block; }
nav.menu { display: flex; gap: 2px; flex: 1; justify-content: flex-end; overflow-x: auto; scrollbar-width: none; }
nav.menu a { padding: 5px 9px; color: var(--muted); text-decoration: none; font-size: 13px; font-weight: 500; white-space: nowrap; }
nav.menu a:hover { color: var(--ink); }
nav.menu a[aria-current="page"] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
.user { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.user form { margin: 0; }
.user button { border: 0; background: none; color: var(--muted); cursor: pointer; padding: 0; font-size: 12px; text-decoration: underline; }
.presence { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.presence i { width: 7px; height: 7px; border-radius: 50%; background: var(--red); }
.presence.on i { background: var(--teal); box-shadow: 0 0 0 3px var(--teal-soft); }

/* Başlık */
main { display: grid; gap: 14px; padding-top: 22px; }
.title { display: flex; align-items: end; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 4px; }
.title h1 { font: 700 clamp(30px, 4.6vw, 42px)/1 var(--display); margin: 0; }
.title p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.ctl { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.seg { display: inline-flex; border: 1px solid var(--rule); border-radius: 4px; overflow: hidden; }
.seg a { padding: 5px 11px; font-size: 12.5px; text-decoration: none; color: var(--ink); }
.seg a + a { border-left: 1px solid var(--rule); }
.seg a[aria-current="true"] { background: var(--ink); color: var(--bg); font-weight: 500; }
.seg a small { opacity: .7; margin-left: 4px; }

/* Kartlar */
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.tiles.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tile { background: var(--tile); border-top: 2px solid var(--rule); padding: 13px 14px 14px; display: grid; gap: 3px; min-width: 0; text-decoration: none; color: inherit; }
.tile .l { font-size: 12.5px; font-weight: 500; }
.tile .v { font: 500 28px/1.15 var(--num); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.tile .s { font-size: 11.5px; color: var(--muted); overflow-wrap: anywhere; }
.tile.amber { border-top-color: var(--amber-rule); } .tile.amber .v { color: var(--amber); }
.tile.teal { border-top-color: var(--teal); } .tile.teal .v { color: var(--teal); }
.tile.red { border-top-color: var(--red-rule); } .tile.red .v { color: var(--red); }
@media (max-width: 760px) { .tiles, .tiles.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } .tile .v { font-size: 22px; } }

/* Sistem şeridi */
.sys { background: var(--tile); border-top: 2px solid var(--teal); padding: 14px; display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; }
.sys.off { border-top-color: var(--red-rule); }
.sys .av { width: 38px; height: 38px; border-radius: 50%; background: var(--teal-soft); display: grid; place-items: center; position: relative; }
.sys .av::before { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--teal); }
.sys.off .av { background: #f6dcd8; } .sys.off .av::before { background: var(--red); }
.sys:not(.off) .av::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--teal); animation: ring 2.4s ease-out infinite; }
@keyframes ring { from { transform: scale(.7); opacity: 1; } to { transform: scale(1.35); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .sys .av::after { animation: none; } }
.sys .l { font-size: 12.5px; font-weight: 500; }
.sys .now { font: 600 18px/1.3 var(--display); margin: 1px 0 0; }
.sys .meta { font-size: 11.5px; color: var(--muted); text-align: right; display: grid; gap: 2px; }
.sys .meta b { color: var(--ink); font-weight: 600; }
@media (max-width: 640px) { .sys { grid-template-columns: auto 1fr; } .sys .meta { grid-column: 1 / -1; text-align: left; } }

/* Paneller */
.row { display: grid; grid-template-columns: 1.6fr 1fr; gap: 12px; }
.row > * { min-width: 0; }
.row.even { grid-template-columns: 1fr 1fr; }
.row.three { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 860px) { .row, .row.even, .row.three { grid-template-columns: 1fr; } }
.panel { background: var(--tile); padding: 14px 14px 12px; min-width: 0; }
.panel h2 { font: 600 15px var(--body); margin: 0; }
.panel .sub { font-size: 12px; color: var(--muted); margin: 1px 0 10px; }
.ph { display: flex; justify-content: space-between; align-items: start; gap: 10px; flex-wrap: wrap; }
.ph a.lnk { font-size: 12px; color: var(--muted); text-decoration: none; }
.ph a.lnk:hover { color: var(--ink); }

/* Grafik */
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart .g { stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 2 3; }
.chart .ax { fill: var(--muted); font: 11px var(--body); }
.chart .gelir { fill: var(--teal); } .chart .gider { fill: var(--red-rule); }
.chart .hedef { stroke: var(--ink); stroke-width: 1.4; stroke-dasharray: 4 3; }
.key { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); flex-wrap: wrap; }
.key .sq { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; vertical-align: middle; }

/* Satış hattı */
.fun { display: grid; gap: 9px; margin-top: 6px; }
.fun .fr { display: grid; grid-template-columns: 80px 1fr 34px; gap: 10px; align-items: center; font-size: 12.5px; }
.fun .tr { height: 18px; background: var(--bg); position: relative; }
.fun .tr i { position: absolute; inset: 0 auto 0 0; background: var(--raw); }
.fun .fr.act .tr i { background: var(--teal); } .fun .fr.set .tr i { background: var(--amber-rule); }
.fun .c { text-align: right; font: 600 14px var(--num); }

/* Listeler */
.feed { list-style: none; margin: 0; padding: 0; }
.feed li { display: grid; grid-template-columns: 10px 1fr auto; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); align-items: start; }
.feed li:first-child { border-top: 0; }
.feed .k { width: 7px; height: 7px; border-radius: 50%; background: var(--faint); margin-top: 6px; }
.feed .k.sistem { background: var(--amber-rule); } .feed .k.claude { background: var(--teal); }
.feed .k.red { background: var(--red); } .feed .k.amber { background: var(--amber-rule); }
.feed b { font-weight: 500; display: block; }
.feed a { text-decoration: none; }
.feed small { color: var(--muted); display: block; font-size: 12px; overflow-wrap: anywhere; }
.feed time { font-size: 11px; color: var(--faint); white-space: nowrap; }

.tbl { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; font-size: 11.5px; font-weight: 500; color: var(--muted); padding: 0 8px 8px; white-space: nowrap; border-bottom: 1px solid var(--rule); }
td { padding: 9px 8px; border-top: 1px solid var(--line); vertical-align: middle; }
tbody tr:first-child td { border-top: 0; }
td a { text-decoration: none; } td a:hover { text-decoration: underline; }
td.r, th.r { text-align: right; }
td small { color: var(--muted); display: block; font-size: 11.5px; }
.pos { color: var(--teal); } .neg { color: var(--red); }

.tag { display: inline-block; padding: 1px 7px; border-radius: 3px; font-size: 11.5px; font-weight: 500; background: var(--bg); color: var(--muted); border: 1px solid var(--line-2); white-space: nowrap; }
.tag.ok { color: var(--teal); border-color: #8cc4b6; background: var(--teal-soft); }
.tag.warn { color: var(--amber); border-color: var(--amber-rule); }
.tag.crit { color: var(--red); border-color: var(--red-rule); }
.tag.ion { color: var(--ink); border-color: var(--ink); }

.task { display: grid; grid-template-columns: 18px 1fr auto; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); align-items: start; }
.task:first-child { border-top: 0; }
.task form { margin: 0; }
.task .cb { width: 15px; height: 15px; margin-top: 3px; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--bg); cursor: pointer; padding: 0; display: block; }
.task.done .cb { background: var(--teal); border-color: var(--teal); }
.task .tt { min-width: 0; text-decoration: none; }
.task small { color: var(--muted); display: block; font-size: 11.5px; }
.task.done .tt b { color: var(--faint); text-decoration: line-through; }
.task.late small.d { color: var(--red); }
.task b { font-weight: 500; }
.who { font-size: 11.5px; color: var(--muted); white-space: nowrap; }

.bars { display: grid; gap: 9px; }
.bar { display: grid; grid-template-columns: 140px 1fr 84px; gap: 10px; align-items: center; font-size: 12.5px; }
.bar .tr { height: 10px; background: var(--bg); }
.bar .tr i { display: block; height: 100%; background: var(--raw); }
.bar.in .tr i { background: var(--teal); } .bar.out .tr i { background: var(--red-rule); }

.btn { border: 1px solid var(--rule); background: var(--bg); border-radius: 4px; padding: 5px 11px; cursor: pointer; font-size: 12.5px; text-decoration: none; display: inline-block; color: var(--ink); white-space: nowrap; }
.btn:hover { background: var(--tile); }
.btn.pri { background: var(--ink); color: var(--bg); font-weight: 500; }
.btn.pri:hover { opacity: .88; }
.btn.danger { color: var(--red); border-color: var(--red-rule); }
.btn.sm { padding: 3px 8px; font-size: 12px; }
.ctl select { border: 1px solid var(--line-2); background: var(--bg); border-radius: 4px; padding: 5px 9px; font-size: 12.5px; }
.empty { color: var(--muted); padding: 14px 0; margin: 0; font-size: 13px; }
.banner { border-left: 3px solid var(--amber-rule); background: var(--tile); padding: 9px 12px; color: var(--muted); font-size: 13px; margin: 0; }
.banner.ok { border-left-color: var(--teal); } .banner.err { border-left-color: var(--red-rule); color: var(--red); }
.msgs { display: grid; gap: 6px; }

/* Formlar */
.formpanel { max-width: 560px; background: var(--bg); border-top: 2px solid var(--rule); padding-top: 14px; }
form.f { display: grid; gap: 11px; }
.fld { display: grid; gap: 4px; }
.fld label { font-size: 12px; font-weight: 500; }
.fld input:not([type=checkbox]), .fld select, .fld textarea { background: var(--bg); border: 1px solid var(--line-2); border-radius: 4px; padding: 8px 10px; width: 100%; }
.fld textarea { min-height: 76px; resize: vertical; }
.fld.cbx { grid-template-columns: 18px 1fr; align-items: start; gap: 8px; }
.fld.cbx input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--teal); }
.fld .help { font-size: 11.5px; color: var(--muted); }
.fld .err, .err { color: var(--red); font-size: 12.5px; margin: 0; }
.cols2 { display: grid; grid-template-columns: 1fr 1fr; gap: 11px 18px; }
@media (max-width: 640px) { .cols2 { grid-template-columns: 1fr; } }
.formbar { display: flex; gap: 8px; justify-content: space-between; padding-top: 6px; flex-wrap: wrap; }

/* Yorum kartı */
.rev { background: var(--tile); padding: 14px; display: grid; gap: 8px; border-top: 2px solid var(--line-2); }
.rev.sensibil, .rev.negativ { border-top-color: var(--red-rule); }
.rev .head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.rev .stars { color: var(--amber); letter-spacing: 1px; font-size: 14px; }
.rev blockquote { margin: 0; font-size: 14px; }
.rev textarea { width: 100%; min-height: 90px; border: 1px solid var(--line-2); border-radius: 4px; padding: 8px 10px; background: var(--bg); resize: vertical; }
.rev .acts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.rev .reply { background: var(--bg); padding: 8px 10px; border-left: 3px solid var(--teal); font-size: 13px; white-space: pre-wrap; }

/* Takvim */
.agenda { list-style: none; margin: 0; padding: 0; }
.agenda li { display: grid; grid-template-columns: 74px 8px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); align-items: start; font-size: 13px; }
.agenda li:first-child { border-top: 0; }
.agenda .d { font: 600 12.5px var(--num); color: var(--muted); white-space: nowrap; }
.agenda .d.today { color: var(--teal); }
.agenda .dot { width: 8px; height: 8px; border-radius: 2px; margin-top: 5px; background: var(--ev-gorev); }
.agenda b { font-weight: 500; display: block; }
.agenda a { text-decoration: none; }
.agenda small { color: var(--muted); font-size: 11.5px; }
.agenda .late b { color: var(--red); }
.t-tahsilat .dot, .sq.t-tahsilat { background: var(--ev-tahsilat); } .t-rapor .dot, .sq.t-rapor { background: var(--ev-rapor); }
.t-gonderi .dot, .sq.t-gonderi { background: var(--ev-gonderi); } .t-gider .dot, .sq.t-gider { background: var(--ev-gider); }
.t-baslangic .dot, .sq.t-baslangic { background: var(--ev-baslangic); border-radius: 50%; } .t-etkinlik .dot, .sq.t-etkinlik { background: var(--ev-etkinlik); }
.t-yenileme .dot, .sq.t-yenileme { background: var(--ev-yenileme); border-radius: 50%; } .t-asama .dot, .sq.t-asama { background: var(--ev-asama); transform: rotate(45deg); }
.t-tatil .dot, .sq.t-tatil { background: var(--ev-tatil); } .sq.t-gorev { background: var(--ev-gorev); }

/* Yol haritası */
.phase { background: var(--tile); padding: 14px; display: grid; gap: 10px; border-top: 2px solid var(--line-2); }
.phase.devam { border-top-color: var(--teal); } .phase.bitti { border-top-color: var(--faint); opacity: .85; }
.phase h3 { font: 700 22px/1.1 var(--display); margin: 0; }
.pg { height: 6px; background: var(--bg); position: relative; }
.pg i { position: absolute; inset: 0 auto 0 0; background: var(--teal); }
.pg.amber i { background: var(--amber-rule); }
.goal { display: grid; grid-template-columns: 150px 1fr 90px; gap: 10px; align-items: center; font-size: 12.5px; }
@media (max-width: 640px) { .goal { grid-template-columns: 1fr; } }

/* Bağlantılar */
.conns { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.conn { background: var(--tile); padding: 12px 14px; display: grid; gap: 4px; border-top: 2px solid var(--line-2); }
.conn.ok { border-top-color: var(--teal); } .conn.sorun { border-top-color: var(--red-rule); } .conn.kapali { border-top-color: var(--line-2); }
.conn.deneme { border-top-color: var(--amber-rule); }
.conn b { font-weight: 600; } .conn small { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }

/* Giriş */
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; background: var(--tile); }
.login .card { background: var(--bg); width: min(380px, 100%); border-top: 2px solid var(--rule); padding: 24px; display: grid; gap: 14px; box-shadow: var(--shadow); }
.login h1 { font: 700 28px/1.1 var(--display); margin: 0; }
.login p { margin: 0; color: var(--muted); font-size: 13px; }
.login .kod input { font: 600 26px var(--num); letter-spacing: .3em; text-align: center; }
.login ol { margin: 0; padding-left: 20px; font-size: 13px; display: grid; gap: 6px; }
.login code { background: var(--tile); padding: 1px 5px; font-size: 12px; overflow-wrap: anywhere; }

/* Claude asistanı */
.as-ac { position: fixed; right: 18px; bottom: 18px; z-index: 45; display: flex; align-items: center; gap: 8px; border: 0; border-radius: 999px; padding: 10px 16px 10px 12px; background: var(--ink); color: var(--bg); font-weight: 500; cursor: pointer; box-shadow: var(--shadow); }
.as-ac i { width: 10px; height: 10px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 3px var(--teal-soft); }
.asistan { position: fixed; right: 18px; bottom: 72px; z-index: 46; width: min(400px, calc(100vw - 32px)); height: min(600px, calc(100vh - 100px)); background: var(--bg); border-top: 2px solid var(--teal); box-shadow: var(--shadow); display: grid; grid-template-rows: auto 1fr auto; }
.asistan[hidden] { display: none; }
.as-bas { display: flex; justify-content: space-between; align-items: start; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.as-bas h2 { font: 700 20px/1 var(--display); margin: 0; }
.as-bas p { margin: 2px 0 0; font-size: 11.5px; color: var(--muted); }
.as-bas .lnk { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 12px; padding: 0; text-decoration: underline; }
.as-liste { overflow-y: auto; padding: 12px 14px; display: grid; gap: 8px; align-content: start; background: var(--tile); }
.as-m { padding: 8px 11px; font-size: 13.5px; white-space: pre-wrap; overflow-wrap: anywhere; max-width: 92%; border-radius: 6px; }
.as-m.user { background: var(--ink); color: var(--bg); justify-self: end; }
.as-m.assistant { background: var(--bg); justify-self: start; border: 1px solid var(--line); }
.as-m.bekle { color: var(--muted); font-style: italic; }
.as-m.hata { background: #f9e6e3; color: var(--red); justify-self: stretch; }
.as-kart { background: var(--bg); border-left: 3px solid var(--teal); padding: 9px 11px; display: grid; gap: 6px; font-size: 13px; }
.as-kart small { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.as-kart b { font-weight: 500; }
.as-kart.bitti { border-left-color: var(--line-2); }
.as-yaz { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); align-items: end; }
.as-yaz textarea { resize: none; min-height: 42px; max-height: 140px; border: 1px solid var(--line-2); border-radius: 4px; padding: 8px 10px; }
.as-yaz small { grid-column: 1 / -1; color: var(--faint); font-size: 11px; }
@media (max-width: 640px) { .asistan { right: 8px; left: 8px; width: auto; bottom: 66px; height: calc(100vh - 90px); } }
