/* Bugün */
.td-hello { margin: 4px 0 16px; }
.td-hello h1 { margin: 0; font-size: 24px; }
.td-hello p { margin: 6px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
/* A dashboard grid: cards in a row share their height, so the edges line up. The columns follow
   the room the page really has (container queries), not the window, since the side menu takes
   part of it: one column, then two, then three with the weather spanning two. */
.td-wrap { container: dash / inline-size; }
.td-dash { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; align-items: stretch; }
.td-dash > section { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.td-dash > section > .td-card:first-child { flex: 1; }
@container dash (min-width: 640px) {
  .td-dash { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .td-w { grid-column: 1 / -1; }
}
@container dash (min-width: 1040px) {
  .td-dash:not(.two) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .td-w { grid-column: span 2; }
}
/* Inside the weather card: the week beside today once the card is wide enough. */
.td-w { container: wx / inline-size; }
.wx-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; align-items: start; }
.wx-body .wx-days { border-top: 1px solid var(--line); margin-top: 10px; }
@container wx (min-width: 620px) {
  .wx-body { grid-template-columns: minmax(0, 1fr) 270px; gap: 18px; }
  .wx-body .wx-days { margin-top: 0; border-top: 0; border-left: 1px solid var(--line); padding-left: 16px; }
}
@container wx (max-width: 420px) {
  .wx-now { flex-wrap: wrap; }
  .wx-now .d { flex-basis: 100%; }
}
.td-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; min-width: 0; }
.td-card > h2 { margin: 0 0 10px; font-size: 14px; display: flex; align-items: center; gap: 8px; min-height: 30px; }
.td-card > h2 a.meta { color: var(--accent); }
.td-card > h2 .meta { font-weight: 400; margin-left: auto; }
.td-card .state { padding: 24px 8px; }
.wx-now { display: flex; align-items: center; gap: 14px; }
.wx-now .ic { font-size: 46px; line-height: 1; }
.wx-now .t { font-size: 40px; font-weight: 800; line-height: 1; }
.wx-now .d { color: var(--muted); font-size: 13px; line-height: 1.5; }
.wx-tip { margin-top: 12px; background: var(--panel-2); border-radius: 10px; padding: 8px 11px; font-size: 13px; }
.wx-hours { display: grid; grid-auto-flow: column; grid-auto-columns: 52px; gap: 4px; overflow-x: auto; margin-top: 12px; padding-bottom: 6px; scrollbar-width: thin; }
.wx-hours div { text-align: center; font-size: 12px; padding: 6px 0; border-radius: 8px; }
.wx-hours div:first-child { background: var(--panel-2); }
.wx-hours .ic { font-size: 18px; display: block; margin: 3px 0; }
.wx-hours .r { color: var(--accent); font-size: 10px; min-height: 13px; display: block; }
.wx-days { margin-top: 10px; border-top: 1px solid var(--line); }
.wx-day { display: grid; grid-template-columns: 74px 26px 44px 1fr; align-items: center; gap: 8px; padding: 6px 0; font-size: 13px; border-bottom: 1px solid var(--line); }
.wx-day:last-child { border-bottom: 0; }
.wx-day .r { color: var(--accent); font-size: 11px; text-align: right; }
.wx-range { display: flex; align-items: center; gap: 8px; }
.wx-range i { flex: 1; height: 5px; border-radius: 99px; background: var(--panel-3); position: relative; }
.wx-range i b { position: absolute; top: 0; bottom: 0; border-radius: 99px; background: linear-gradient(90deg, #4fb3ff, #f7b733); }
.wx-range span { width: 30px; text-align: right; font-variant-numeric: tabular-nums; }
.wx-range span:first-child { color: var(--muted); }
.wx-place { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.wx-place input { flex: 1 1 180px; padding-left: 12px; }
.wx-found { display: flex; flex-direction: column; gap: 4px; margin-bottom: 10px; }
.wx-found button { text-align: left; background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; color: var(--text); cursor: pointer; }
.wx-found button:hover { border-color: var(--accent); }
.mk-row { display: grid; grid-template-columns: 1fr 70px auto; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mk-row:last-child { border-bottom: 0; }
.mk-row .n { font-weight: 700; font-size: 13px; }
.mk-row .n .meta { display: block; font-weight: 400; }
.mk-row .v { text-align: right; font-variant-numeric: tabular-nums; }
.mk-row .v b { display: block; font-size: 15px; }
.mk-up { color: var(--win); font-size: 12px; }
.mk-down { color: var(--lose); font-size: 12px; }
.mk-flat { color: var(--muted); font-size: 12px; }
.spark { width: 70px; height: 26px; display: block; }
.td-sum { display: flex; flex-direction: column; }
.td-item { display: flex; gap: 12px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--text); cursor: pointer; text-decoration: none; }
.td-item:last-child { border-bottom: 0; }
.td-item:hover { text-decoration: none; }
.td-item:hover .td-t { color: var(--accent); }
.td-item .td-ic { width: 34px; height: 34px; flex: none; border-radius: 9px; background: var(--panel-2); display: grid; place-items: center; font-size: 17px; overflow: hidden; }
.td-item .td-ic img { width: 100%; height: 100%; object-fit: cover; }
.td-item .td-t { font-size: 13px; font-weight: 600; min-width: 0; }
.td-item .td-t .meta { display: block; font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.td-item .td-r { margin-left: auto; text-align: right; font-size: 12px; flex: none; }
.td-hist { display: grid; gap: 10px; }
.td-hist a { display: flex; gap: 12px; color: var(--text); align-items: flex-start; font-size: 13px; line-height: 1.45; }
.td-hist a b { color: var(--accent); flex: none; width: 40px; }
.td-hist img { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; flex: none; margin-left: auto; }

/* Depremler */
.qk-row { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; padding: 9px 12px; border-top: 1px solid var(--line); color: var(--text); }
.qk-row:first-child { border-top: 0; }
.qk-row:hover { background: var(--panel-2); text-decoration: none; }
.qk-row b { font-size: 14px; font-weight: 600; }
.qk-mag { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 15px; background: var(--panel-3); color: var(--muted); }
.qk-mag.m3 { background: color-mix(in srgb, var(--star) 25%, var(--panel)); color: var(--star); }
.qk-mag.m4 { background: color-mix(in srgb, #ff8a3d 30%, var(--panel)); color: #ff8a3d; }
.qk-mag.m5 { background: var(--lose); color: #fff; }
.qk-near { color: var(--accent); font-weight: 600; }
.qk-alert { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; font-size: 13px; }
.qk-alert select { padding-left: 10px; color: var(--text); width: auto; }

/* Günün keşfi: a full row under the dashboard, its parts side by side as room allows. */
.td-disc { grid-column: 1 / -1; }
.disc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; align-items: start; }
.disc-img { display: grid; gap: 6px; color: var(--text); text-decoration: none; border-radius: 10px; overflow: hidden; background: var(--panel-2); }
.disc-img:hover { text-decoration: none; }
.disc-img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.disc-img span { display: grid; gap: 2px; padding: 4px 10px 10px; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.disc-img span b { color: var(--text); font-size: 13px; }
.disc-item { display: grid; gap: 6px; min-width: 0; }
.disc-kicker { font-size: 12px; font-weight: 700; color: var(--accent); }
.disc-kicker .meta { font-weight: 400; }
.disc-title { font-size: 16px; font-weight: 800; }
.disc-text { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.disc-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.disc-list { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 13.5px; line-height: 1.45; }
.disc-list li .meta { display: block; }

/* Rapor */
.rp-kv { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.rp-kv div { display: grid; gap: 2px; }
.rp-kv .mk-up, .rp-kv .mk-down, .rp-kv .mk-flat { font-size: 11.5px; }
.rp-bars { height: 110px; }
.rp-moods { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); gap: 6px; }
.rp-mood { display: grid; justify-items: center; gap: 2px; padding: 6px 0; border-radius: 9px; border: 0; cursor: pointer; color: var(--text);
  background: color-mix(in srgb, var(--mood) 35%, var(--panel-2)); font-size: 18px; min-height: 52px; }
.rp-mood:disabled { opacity: .35; cursor: default; }
.rp-mood small { font-size: 10px; color: var(--muted); }
.rp-habits { display: grid; gap: 8px; }
.rp-habit { display: grid; grid-template-columns: minmax(0, 1fr) auto 44px; gap: 10px; align-items: center; font-size: 13px; }
.rp-habit span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-habit b { text-align: right; font-size: 12px; }
.rp-cells { display: flex; gap: 3px; flex-wrap: wrap; max-width: 260px; }
.rp-cells i { width: 12px; height: 12px; border-radius: 3px; background: var(--panel-3); }
.rp-cells i.on { background: var(--win); }
.rp-cells i.future { visibility: hidden; }
