/* Teams Meeting Assistant – Layout & Komponenten (Bootstrap 5.3 Ergänzungen) */
:root {
  --tma-accent: #4f46e5;
  --tma-accent-2: #7c3aed;
  --tma-sidebar-w: 240px;
  --bs-primary: #4f46e5;
  --bs-primary-rgb: 79, 70, 229;
  --bs-link-color: #4f46e5;
  --bs-link-color-rgb: 79, 70, 229;
  --bs-link-hover-color: #4338ca;
}
[data-bs-theme="dark"] {
  --bs-primary: #818cf8;
  --bs-primary-rgb: 129, 140, 248;
  --bs-link-color: #a5b4fc;
  --bs-link-color-rgb: 165, 180, 252;
  --bs-body-bg: #0f1220;
  --bs-tertiary-bg: #161a2c;
}
body { background: var(--bs-tertiary-bg); }
.btn-primary { --bs-btn-bg: var(--tma-accent); --bs-btn-border-color: var(--tma-accent); --bs-btn-hover-bg: #4338ca; --bs-btn-hover-border-color: #4338ca; --bs-btn-active-bg: #3730a3; }
.btn-outline-primary { --bs-btn-color: var(--bs-primary); --bs-btn-border-color: var(--bs-primary); --bs-btn-hover-bg: var(--tma-accent); --bs-btn-hover-border-color: var(--tma-accent); --bs-btn-active-bg: var(--tma-accent); --bs-btn-active-border-color: var(--tma-accent); }
.nav-pills { --bs-nav-pills-link-active-bg: var(--tma-accent); }
.text-bg-primary { background-color: var(--tma-accent) !important; }
.progress-bar { background-color: var(--tma-accent); }

/* Shell */
.app-topbar { background: var(--bs-body-bg); border-bottom: 1px solid var(--bs-border-color); }
.brand-dot { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 9px; color: #fff; background: linear-gradient(135deg, var(--tma-accent), var(--tma-accent-2)); font-size: .95rem; }
.brand-dot-lg { width: 44px; height: 44px; border-radius: 12px; font-size: 1.3rem; }
.avatar { display: inline-flex; width: 26px; height: 26px; border-radius: 50%; align-items: center; justify-content: center; background: var(--tma-accent); color: #fff; font-size: .8rem; font-weight: 600; }
.app-shell { display: flex; min-height: calc(100vh - 57px); }
.app-sidebar { width: var(--tma-sidebar-w); background: var(--bs-body-bg); border-right: 1px solid var(--bs-border-color); }
@media (min-width: 992px) {
  .app-sidebar { position: sticky; top: 57px; height: calc(100vh - 57px); flex: 0 0 var(--tma-sidebar-w); overflow-y: auto; }
  .app-sidebar .offcanvas-body { display: flex; height: 100%; }
}
.app-sidebar .nav-link { color: var(--bs-body-color); border-radius: .5rem; padding: .5rem .75rem; font-size: .93rem; }
.app-sidebar .nav-link:hover { background: var(--bs-secondary-bg); }
.app-sidebar .nav-link.active { color: #fff; }
.sidebar-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--bs-secondary-color); }
.app-main { flex: 1; min-width: 0; padding: 1.5rem; }
@media (max-width: 575.98px) { .app-main { padding: 1rem .75rem; } }

/* Karten */
.card { border-color: var(--bs-border-color-translucent); border-radius: .75rem; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.card-header { background: transparent; }
.stat-card { transition: transform .1s, box-shadow .1s; color: var(--bs-body-color); }
.stat-card:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(16, 24, 40, .08); }
.stat-icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; font-size: 1.25rem; }
.date-chip { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 44px; min-width: 44px; height: 44px; border-radius: 10px; background: var(--bs-secondary-bg); line-height: 1; }
.date-chip span { font-weight: 700; font-size: 1.05rem; }
.date-chip small { font-size: .68rem; color: var(--bs-secondary-color); }
.project-card:hover { border-color: var(--bs-primary); }
tr[data-href] { cursor: pointer; }

/* Login */
.login-bg { background: radial-gradient(1200px 600px at 10% 0%, rgba(79, 70, 229, .18), transparent), radial-gradient(900px 500px at 100% 100%, rgba(124, 58, 237, .15), transparent), var(--bs-tertiary-bg); }
.login-card { width: 100%; max-width: 440px; border-radius: 1rem; }

/* Transkript */
.transcript .seg { padding: .6rem 1rem; }
.seg-time { width: 64px; min-width: 64px; font-variant-numeric: tabular-nums; padding-top: .15rem; }
.seg-text { white-space: pre-wrap; }
.seg-hl { background: rgba(250, 204, 21, .18); }
.seg .seg-edit { opacity: 0; transition: opacity .1s; }
.seg:hover .seg-edit, .seg .seg-edit:focus { opacity: 1; }
@media (hover: none) { .seg .seg-edit { opacity: 1; } }
mark { padding: 0 .1em; border-radius: .2em; }
.protocol-md h4, .protocol-md h5 { margin-top: 1rem; font-size: 1.05rem; font-weight: 600; }
.protocol-md h4:first-child, .protocol-md h5:first-child { margin-top: 0; }

/* Entwurfsprüfung */
.review-table td { padding: .6rem .5rem; }
.review-table tr.row-deleted { opacity: .4; text-decoration: line-through; }

/* Kanban */
.kanban { display: grid; grid-template-columns: repeat(6, minmax(240px, 1fr)); gap: .75rem; overflow-x: auto; padding-bottom: 1rem; }
@media (max-width: 767.98px) { .kanban { grid-template-columns: 1fr; } }
.kanban-col { background: var(--bs-secondary-bg); border-radius: .75rem; padding: .5rem; min-height: 200px; display: flex; flex-direction: column; transition: background .1s, box-shadow .1s; }
.kanban-col.drop-target { box-shadow: inset 0 0 0 2px var(--bs-primary); }
.kanban-head { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: .85rem; padding: .25rem .4rem .5rem; }
.kanban-list { display: flex; flex-direction: column; gap: .5rem; flex: 1; min-height: 60px; }
.kanban-card { position: relative; background: var(--bs-body-bg); border: 1px solid var(--bs-border-color-translucent); border-left: 4px solid var(--bs-secondary-border-subtle); border-radius: .6rem; padding: .6rem .7rem; box-shadow: 0 1px 2px rgba(16, 24, 40, .05); }
.kanban-card[draggable="true"] { cursor: grab; }
.kanban-card.dragging { opacity: .5; }
.kanban-card.prio-hoch { border-left-color: #dc2626; }
.kanban-card.prio-normal { border-left-color: var(--tma-accent); }
.kanban-card.prio-niedrig { border-left-color: #94a3b8; }
.kanban-card.kanban-error { outline: 2px solid #dc2626; }

/* Kalender */
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); overflow: hidden; }
.cal-head { padding: .4rem; font-size: .8rem; font-weight: 600; text-align: center; border-bottom: 1px solid var(--bs-border-color); background: var(--bs-secondary-bg); }
.cal-cell { min-height: 110px; padding: .3rem; border-right: 1px solid var(--bs-border-color-translucent); border-bottom: 1px solid var(--bs-border-color-translucent); overflow: hidden; }
.cal-cell:nth-child(7n) { border-right: 0; }
.cal-other { background: var(--bs-tertiary-bg); color: var(--bs-secondary-color); }
.cal-today .cal-day { background: var(--tma-accent); color: #fff; border-radius: 50%; width: 1.6rem; height: 1.6rem; display: inline-flex; align-items: center; justify-content: center; }
.cal-day { font-size: .8rem; font-weight: 600; margin-bottom: .2rem; }
.cal-item { display: block; font-size: .72rem; padding: .1rem .3rem; border-radius: .3rem; margin-bottom: .15rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-decoration: none; }
.cal-meeting { background: rgba(79, 70, 229, .12); color: var(--bs-body-color); }
.cal-task { background: rgba(245, 158, 11, .15); color: var(--bs-body-color); }
.cal-task.st-erledigt { background: rgba(22, 163, 74, .14); text-decoration: line-through; }
@media (max-width: 767.98px) { .cal-cell { min-height: 70px; } .cal-item { font-size: .62rem; } }

/* Horizontal scrollbare Tabs ohne sichtbare Scrollleiste */
.tabs-scroll { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.tabs-scroll::-webkit-scrollbar { display: none; }
