:root {
  color-scheme: light;

  /* Saadet İstanbul Design Tokens 3.0 — all active UI styles resolve through these tokens. */
  --color-brand-900: #64151d;
  --color-brand-800: #841c25;
  --color-brand-700: #a62631;
  --color-brand-600: #c12a34;
  --color-brand-500: #d0333c;
  --color-brand-100: #f7d6d9;
  --color-brand-50: #fff0f1;
  --color-accent-700: #8f1d28;
  --color-accent-600: #b5222e;
  --color-accent-100: #fbe3e5;
  --color-success-700: #1f6b49;
  --color-success-100: #e3f3eb;
  --color-warning-800: #7a5200;
  --color-warning-100: #fff2cc;
  --color-purple-700: #5f3aa8;
  --color-purple-100: #eee9fa;
  --color-neutral-950: #17212b;
  --color-neutral-800: #303b47;
  --color-neutral-700: #465361;
  --color-neutral-600: #536170;
  --color-neutral-500: #697684;
  --color-neutral-300: #cfd6de;
  --color-neutral-200: #dfe4ea;
  --color-neutral-100: #eceff3;
  --color-neutral-75: #f2f4f6;
  --color-neutral-50: #f7f8fa;
  --color-black: #000000;
  --color-white: #ffffff;

  --color-text: var(--color-neutral-950);
  --color-text-secondary: var(--color-neutral-600);
  --color-text-tertiary: var(--color-neutral-600);
  --color-border: var(--color-neutral-200);
  --color-border-strong: var(--color-neutral-300);
  --color-surface: var(--color-white);
  --color-surface-subtle: var(--color-neutral-50);
  --color-surface-hover: var(--color-neutral-75);
  --color-canvas: #f8f5f5;
  --color-focus: #a62631;
  --color-on-brand: var(--color-white);
  --color-on-accent: var(--color-white);

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;

  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;
  --shadow-xs: 0 1px 2px rgba(23, 33, 43, .06), 0 1px 1px rgba(23, 33, 43, .03);
  --shadow-sm: 0 10px 30px rgba(23, 33, 43, .08), 0 2px 8px rgba(23, 33, 43, .04);
  --shadow-md: 0 24px 64px rgba(23, 33, 43, .18), 0 6px 18px rgba(23, 33, 43, .08);
  --focus-ring: 0 0 0 3px rgba(166, 38, 49, .28);
  --control-height: 42px;
  --target-min: 44px;
  --sidebar-width: 248px;
  --content-max: 1440px;
  --font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-scale: 1.08;

  /* Workspace-level appearance settings and task category colors. */
  --canvas: var(--color-canvas);
  --canvas-text: var(--color-text);
  --canvas-muted: var(--color-text-secondary);
  --event-color: #c53b32;
  --event-contrast: #ffffff;
  --lesson-color: #6846b7;
  --lesson-contrast: #ffffff;

  /* Backwards-compatible aliases used by existing components. */
  --navy-950: var(--color-neutral-950);
  --navy-900: var(--color-brand-900);
  --navy-800: var(--color-brand-800);
  --blue-700: var(--color-brand-600);
  --blue-600: var(--color-brand-500);
  --blue-100: var(--color-brand-100);
  --blue-50: var(--color-brand-50);
  --coral-600: var(--color-accent-700);
  --coral-100: var(--color-accent-100);
  --green-700: var(--color-success-700);
  --green-100: var(--color-success-100);
  --amber-700: var(--color-warning-800);
  --amber-100: var(--color-warning-100);
  --ink: var(--color-text);
  --muted: var(--color-text-secondary);
  --line: var(--color-border);
  --surface: var(--color-surface);
  --shadow: var(--shadow-md);
  --radius: var(--radius-md);
  font-family: var(--font-sans);
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--canvas); }

body { margin: 0; color: var(--ink); background: var(--canvas); }

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .58; }
a { color: inherit; }
[hidden] { display: none !important; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--navy-900);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  color: white;
  background: linear-gradient(145deg, var(--blue-600), var(--blue-700));
  box-shadow: 0 8px 20px rgba(166, 38, 49, .24);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: -.4px;
  overflow: hidden;
}
.brand-mark.has-image { border: 1px solid var(--line); background: white; box-shadow: 0 8px 20px rgba(15, 42, 65, .13); }
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }

.brand strong, .brand small { display: block; }
.brand strong { font-size: 18px; letter-spacing: -.35px; }
.brand small { margin-top: 1px; color: var(--muted); font-size: 11px; letter-spacing: .55px; text-transform: uppercase; }
.brand-light, .brand-light small { color: white; }
.brand-light small { opacity: .62; }

.eyebrow {
  margin: 0 0 8px;
  color: var(--color-brand-100);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.35px;
  text-transform: uppercase;
}
.eyebrow.ink { color: var(--blue-700); }
.muted { color: var(--muted); }

.auth-layout { min-height: 100vh; display: grid; grid-template-columns: minmax(360px, 46%) 1fr; }

.auth-story {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100vh;
  padding: clamp(34px, 5vw, 72px);
  overflow: hidden;
  color: white;
  background:
    radial-gradient(circle at 80% 15%, rgba(208, 51, 60, .3), transparent 31%),
    radial-gradient(circle at 12% 85%, rgba(181, 34, 46, .2), transparent 28%),
    linear-gradient(150deg, #241015 0%, #64151d 55%, #841c25 100%);
}

.auth-story::after {
  content: "";
  position: absolute;
  right: -125px;
  bottom: 70px;
  width: 350px;
  height: 350px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 50%;
  box-shadow: 0 0 0 45px rgba(255,255,255,.025), 0 0 0 90px rgba(255,255,255,.015);
}

.story-copy { position: relative; z-index: 1; max-width: 570px; }
.story-copy h1 { max-width: 550px; margin: 0; font-size: clamp(38px, 4.6vw, 68px); line-height: 1.01; letter-spacing: -2.3px; }
.story-copy > p:not(.eyebrow) { max-width: 520px; margin: 26px 0; color: #c7d8e7; font-size: 17px; line-height: 1.7; }
.feature-list { display: grid; gap: 13px; margin: 30px 0 0; padding: 0; list-style: none; color: #e3edf5; }
.feature-list li { display: flex; align-items: center; gap: 10px; }
.feature-list span { display: grid; place-items: center; width: 23px; height: 23px; border-radius: 50%; color: white; background: rgba(193,42,52,.82); font-size: 12px; font-weight: 900; }
.auth-foot { position: relative; z-index: 1; margin: 0; color: #8fa6b9; font-size: 12px; }

.auth-panel { display: grid; place-items: center; min-height: 100vh; padding: 40px; background: #f7f9fb; }
.auth-card { display: grid; gap: 22px; width: min(430px, 100%); padding: 40px; border: 1px solid var(--line); border-radius: 24px; background: white; box-shadow: var(--shadow); }
.auth-card h2 { margin: 0; font-size: 31px; letter-spacing: -.9px; }
.auth-card p { margin-bottom: 0; line-height: 1.55; }
.invite-summary { padding: 17px 18px; border: 1px solid var(--color-brand-100); border-radius: 14px; background: var(--blue-50); }
.invite-summary h2 { margin: 3px 0 6px; font-size: 23px; }
.invite-summary p { margin: 0; color: var(--muted); }

label { display: grid; gap: 8px; color: #31465b; font-size: 13px; font-weight: 700; }
label small { color: var(--muted); font-weight: 500; }
input, select, textarea {
  width: 100%;
  min-height: 45px;
  padding: 10px 12px;
  border: 1px solid #cbd8e2;
  border-radius: 10px;
  outline: 0;
  color: var(--ink);
  background: white;
  transition: border .15s, box-shadow .15s;
}
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--blue-600); box-shadow: 0 0 0 3px rgba(193,42,52,.14); }

.member-field { min-width: 0; margin: 0; padding: 12px; border: 1px solid #cbd8e2; border-radius: 10px; }
.member-field legend { padding: 0 5px; color: #31465b; font-size: 13px; font-weight: 700; }
.member-field legend small { margin-left: 5px; color: var(--muted); font-weight: 500; }
.member-checklist { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 245px), 1fr)); gap: 8px; max-height: 220px; overflow: auto; }
.member-option { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 9px 10px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; }
.member-option input[type="checkbox"] { appearance: auto; flex: 0 0 18px; width: 18px; height: 18px; min-width: 18px; min-height: 18px; margin: 0; padding: 0; border: 0; border-radius: 4px; box-shadow: none; accent-color: var(--blue-700); }
.member-option:has(input:checked) { border-color: #9cc9e8; background: var(--blue-50); }
.member-option:focus-within { border-color: var(--blue-600); box-shadow: 0 0 0 3px rgba(193,42,52,.12); }
.member-option span { min-width: 0; overflow-wrap: anywhere; line-height: 1.35; }
.member-option small { display: inline; margin-left: 4px; }
.recurrence-days-field { min-width: 0; margin: 0; padding: 12px; border: 1px solid #cbd8e2; border-radius: 10px; background: #f8fafc; }
.recurrence-days-field legend { padding: 0 5px; color: #31465b; font-size: 13px; font-weight: 700; }
.recurrence-days-field legend small { margin-left: 5px; color: var(--muted); font-weight: 500; }
.weekday-checklist { display: grid; grid-template-columns: repeat(7, minmax(54px, 1fr)); gap: 8px; }
.weekday-option { display: flex; min-width: 0; align-items: center; justify-content: center; gap: 6px; padding: 9px 7px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; }
.weekday-option input[type="checkbox"] { appearance: auto; flex: 0 0 17px; width: 17px; height: 17px; min-width: 17px; min-height: 17px; margin: 0; padding: 0; border: 0; box-shadow: none; accent-color: var(--blue-700); }
.weekday-option:has(input:checked) { border-color: #68a9d8; color: var(--blue-700); background: var(--blue-50); }
.weekday-option span { font-size: 12px; font-weight: 800; }

.button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}
.button.primary { color: white; background: var(--blue-700); box-shadow: 0 6px 16px rgba(17,103,177,.19); }
.button.primary:hover { background: #0c5b9f; }
.button.secondary { color: var(--blue-700); border-color: #c6dceb; background: white; }
.button.secondary:hover { background: var(--blue-50); }
.button.ghost { color: var(--muted); background: transparent; }
.button.danger { color: var(--coral-600); border-color: #f1c9c1; background: white; }
.button.small { min-height: 34px; padding: 6px 11px; font-size: 12px; }
.button.wide { width: 100%; }
.form-error { margin: -8px 0 0 !important; padding: 10px 12px; border-radius: 9px; color: #9d3323; background: var(--coral-100); font-size: 13px; }
.form-message { margin: -8px 0 0 !important; padding: 10px 12px; border-radius: 9px; color: var(--green-700); background: var(--green-100); font-size: 13px; }
.form-note { margin: -6px 0 0 !important; text-align: center; color: var(--muted); font-size: 12px; }
.auth-options { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: -8px; }
.password-visibility { display: inline-flex; width: fit-content; grid-template-columns: 18px auto; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; cursor: pointer; }
.password-visibility input[type="checkbox"] { appearance: auto; width: 18px; height: 18px; min-width: 18px; min-height: 18px; margin: 0; padding: 0; border: 0; box-shadow: none; accent-color: var(--blue-700); }
.text-button { padding: 2px 0; border: 0; color: var(--blue-700); background: transparent; font-size: 12px; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.text-button:hover { color: #0c5b9f; }

.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  z-index: 30;
  inset: 0 auto 0 0;
  display: flex;
  flex-direction: column;
  width: 246px;
  padding: 28px 20px 20px;
  border-right: 1px solid var(--line);
  background: white;
}
.sidebar > .brand { margin: 0 10px 38px; }
.nav { display: grid; gap: 5px; }
.nav-item {
  display: flex;
  width: 100%;
  min-height: 45px;
  align-items: center;
  gap: 12px;
  padding: 10px 13px;
  border: 0;
  border-radius: 10px;
  color: #52677c;
  background: transparent;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
}
.nav-item span { width: 19px; color: #8396a8; text-align: center; font-size: 17px; }
.nav-item:hover { color: var(--navy-900); background: var(--blue-50); }
.nav-item.active { color: var(--blue-700); background: var(--blue-100); }
.nav-item.active span { color: var(--blue-700); }
.nav-item.quiet { margin-top: 9px; border-top: 1px solid var(--line); border-radius: 0; }
.sidebar-bottom { margin-top: auto; }
.user-card { display: flex; align-items: center; gap: 10px; padding: 12px 10px; border-radius: 12px; background: #f7f9fb; }
.user-card .avatar { flex: 0 0 auto; }
.user-card strong, .user-card small { display: block; max-width: 138px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-card strong { font-size: 12px; }
.user-card small { margin-top: 3px; color: var(--muted); font-size: 10px; }

.avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: white; background: var(--navy-800); font-size: 11px; font-weight: 800; }
.avatar.blue { background: var(--blue-700); }
.avatar.coral { background: var(--coral-600); }
.avatar.green { background: var(--green-700); }

.workspace { min-height: 100vh; margin-left: 246px; }
.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  min-height: 92px;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  padding: 18px clamp(24px, 3.4vw, 52px);
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.93);
  backdrop-filter: blur(10px);
}
.topbar h1 { margin: 0; font-size: 25px; letter-spacing: -.65px; }
.topbar .eyebrow { margin-bottom: 4px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.date-chip { padding: 9px 12px; border-radius: 10px; color: var(--muted); background: #f3f6f8; font-size: 12px; font-weight: 700; }
.content { max-width: 1520px; margin: 0 auto; padding: 32px clamp(24px, 3.4vw, 52px) 60px; outline: none; }

.page-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.page-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.page-intro h2 { margin: 0 0 7px; font-size: 22px; }
.page-intro p { margin: 0; color: var(--muted); line-height: 1.5; }
.content > .page-intro h2 { color: var(--canvas-text); }
.content > .page-intro p { color: var(--canvas-muted); }
.filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.filter-button { padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: white; font-size: 12px; font-weight: 750; }
.filter-button.active { color: var(--blue-700); border-color: #b9d7ec; background: var(--blue-100); }
.task-filter-panel { display: grid; grid-template-columns: minmax(220px, 1.5fr) repeat(3, minmax(150px, 1fr)) auto; gap: 12px; align-items: end; margin-top: 14px; padding: 16px; }
.task-filter-actions { display: flex; flex-wrap: wrap; gap: 7px; padding-bottom: 1px; }
.task-view-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 18px 0 10px; }
.task-view-toolbar > span { color: var(--muted); font-size: 12px; }
.task-calendar-panel { overflow: hidden; }
.calendar-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.calendar-toolbar strong, .calendar-toolbar span { display: block; }
.calendar-toolbar strong { font-size: 15px; text-transform: capitalize; }
.calendar-toolbar span { margin-top: 3px; color: var(--muted); font-size: 11px; }
.calendar-nav { display: flex; align-items: center; gap: 6px; }
.calendar-scroll { overflow-x: auto; }
.task-calendar { display: grid; grid-template-columns: repeat(7, minmax(140px, 1fr)); min-width: 980px; background: var(--line); gap: 1px; }
.task-calendar.week { min-width: 840px; }
.calendar-weekday { padding: 9px 10px; color: var(--muted); background: #f7f9fb; font-size: 10px; font-weight: 850; letter-spacing: .45px; text-align: center; text-transform: uppercase; }
.calendar-day { min-height: 128px; padding: 9px; background: white; }
.task-calendar.week .calendar-day { min-height: 300px; }
.calendar-day.outside { background: #f7f9fb; }
.calendar-day.outside > * { opacity: .68; }
.calendar-day.today { box-shadow: inset 0 0 0 2px var(--blue-600); }
.calendar-day > header { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.calendar-day > header span { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; font-size: 11px; font-weight: 850; }
.calendar-day.today > header span { color: white; background: var(--blue-700); }
.calendar-day > header small { color: var(--muted); font-size: 9px; text-transform: capitalize; }
.calendar-day-tasks { display: grid; gap: 5px; }
.calendar-task { display: grid; width: 100%; gap: 2px; padding: 6px 7px; overflow: hidden; border: 0; border-left: 3px solid var(--blue-600); border-radius: 5px; color: var(--blue-700); background: var(--blue-100); text-align: left; }
.calendar-task span, .calendar-task small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.calendar-task span { font-size: 10px; font-weight: 850; }
.calendar-task small { opacity: .8; font-size: 8px; }
.calendar-task.progress { color: var(--amber-700); border-left-color: var(--amber-700); background: var(--amber-100); }
.calendar-task.done { color: var(--green-700); border-left-color: var(--green-700); background: var(--green-100); }
.calendar-task.late { color: var(--coral-600); border-left-color: var(--coral-600); background: var(--coral-100); }
.calendar-task.event { padding: 7px 8px; color: white; border-left-color: color-mix(in srgb, var(--event-color) 72%, black); background: var(--event-color); box-shadow: 0 4px 10px rgba(35,50,65,.18); }
.calendar-task.lesson { padding: 7px 8px; color: white; border-left-color: color-mix(in srgb, var(--lesson-color) 72%, black); background: var(--lesson-color); box-shadow: 0 4px 10px rgba(35,50,65,.18); }

.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 24px; }
.stat-card { position: relative; width: 100%; min-height: 128px; padding: 20px; overflow: hidden; appearance: none; border: 1px solid var(--line); border-radius: var(--radius); color: inherit; background: white; font: inherit; text-align: left; }
.stat-card::after { content: ""; position: absolute; right: -23px; top: -23px; width: 75px; height: 75px; border-radius: 50%; background: var(--blue-100); }
.stat-card.coral::after { background: var(--coral-100); }
.stat-card.green::after { background: var(--green-100); }
.stat-card.amber::after { background: var(--amber-100); }
.stat-label { color: var(--muted); font-size: 12px; font-weight: 700; }
.stat-value { display: block; margin: 12px 0 2px; color: var(--navy-900); font-size: 31px; font-weight: 850; letter-spacing: -1px; }
.stat-sub { color: #8b9aaa; font-size: 11px; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(290px, .8fr); gap: 20px; }
.stack { display: grid; align-content: start; gap: 20px; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: white; box-shadow: 0 4px 16px rgba(15,42,65,.035); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 19px 20px; border-bottom: 1px solid var(--line); }
.panel-head h3 { margin: 0; font-size: 15px; }
.panel-head p { margin: 3px 0 0; color: var(--muted); font-size: 11px; }
.panel-body { padding: 8px 20px; }
.panel-body.flush { padding: 0; }

.meeting-list, .task-list, .activity-list { display: grid; }
.meeting-row, .task-row, .activity-row { display: grid; align-items: center; gap: 15px; padding: 16px 20px; border-bottom: 1px solid #edf1f4; }
.meeting-row:last-child, .task-row:last-child, .activity-row:last-child { border-bottom: 0; }
.meeting-row { grid-template-columns: 61px minmax(0, 1fr) auto; }
.date-box { display: grid; place-items: center; min-height: 58px; border-radius: 11px; color: var(--navy-900); background: var(--blue-50); }
.date-box strong { font-size: 22px; line-height: 1; }
.date-box span { margin-top: -5px; color: var(--blue-700); font-size: 10px; font-weight: 850; text-transform: uppercase; }
.row-title { overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.row-meta { display: flex; flex-wrap: wrap; gap: 5px 12px; margin-top: 7px; color: var(--muted); font-size: 11px; }
.row-meta span { display: inline-flex; align-items: center; gap: 4px; }
.row-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 7px; }

.badge { display: inline-flex; width: fit-content; align-items: center; gap: 5px; padding: 5px 8px; border-radius: 999px; color: var(--blue-700); background: var(--blue-100); font-size: 10px; font-weight: 800; }
.badge.green { color: var(--green-700); background: var(--green-100); }
.badge.coral { color: var(--coral-600); background: var(--coral-100); }
.badge.amber { color: var(--amber-700); background: var(--amber-100); }
.badge.event { color: color-mix(in srgb, var(--event-color) 78%, black); background: color-mix(in srgb, var(--event-color) 13%, white); }
.badge.lesson { color: color-mix(in srgb, var(--lesson-color) 78%, black); background: color-mix(in srgb, var(--lesson-color) 13%, white); }
.badge.repeat { color: #4f5f70; background: #edf1f5; }
.badge.stale { color: #6b4e13; background: #fff1bd; }
.badge.gray { color: #5b6976; background: #eef2f5; }
.badge.dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

.task-row { grid-template-columns: auto minmax(0, 1fr) auto; }
.task-check { display: grid; place-items: center; width: 25px; height: 25px; border: 1.5px solid #b8c7d3; border-radius: 8px; color: transparent; background: white; font-size: 13px; font-weight: 900; }
.task-check.done { color: white; border-color: var(--green-700); background: var(--green-700); }
.task-check.in-progress { color: white; border-color: var(--amber-700); background: var(--amber-700); }
.task-check.blocked { color: white; border-color: var(--coral-600); background: var(--coral-600); }
.task-row.done .row-title { color: #8795a2; text-decoration: line-through; }
.task-row.in-progress { background: #fffdf7; }
.task-row.blocked { background: #fff8f6; }
.assignee { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.assignee .avatar { width: 24px; height: 24px; font-size: 8px; }
.task-progress-note { max-width: 820px; margin: 9px 0 0; padding: 9px 11px; border-left: 3px solid var(--amber-700); border-radius: 0 8px 8px 0; color: #526170; background: #fff8e6; font-size: 11px; line-height: 1.55; white-space: pre-wrap; }
.task-next-action, .task-blocker-note { max-width: 820px; margin: 7px 0 0; padding: 8px 11px; border-radius: 8px; color: #42566a; background: #eef7ff; font-size: 11px; line-height: 1.5; white-space: pre-wrap; }
.task-next-action { border-left: 3px solid var(--blue-700); }
.task-blocker-note { color: #7b372b; border-left: 3px solid var(--coral-600); background: #fff0ec; }
.progress-history-section { display: grid; gap: 9px; min-width: 0; }
.progress-history { display: grid; gap: 8px; max-height: 290px; overflow: auto; padding-right: 4px; }
.progress-history-item { display: grid; gap: 6px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; background: #f8fafc; }
.progress-history-item.legacy { border-style: dashed; }
.progress-history-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.progress-history-item p { margin: 0; color: #42566a; font-size: 12px; line-height: 1.55; white-space: pre-wrap; }
.progress-history-item time, .progress-history-item small { color: var(--muted); font-size: 10px; }
.progress-history-empty { margin: 0; padding: 14px; border: 1px dashed var(--line); border-radius: 10px; color: var(--muted); text-align: center; font-size: 11px; }

.privacy-banner { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; padding: 14px 16px; border: 1px solid #cfe3d8; border-radius: 12px; color: #235d43; background: #eef9f3; }
.privacy-banner > span { display: grid; flex: 0 0 28px; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: white; background: var(--green-700); }
.privacy-banner strong { font-size: 12px; }
.privacy-banner p { margin: 3px 0 0; font-size: 11px; line-height: 1.45; }
.personal-note-filter { display: flex; align-items: end; gap: 10px; margin-bottom: 16px; padding: 14px 16px; }
.personal-note-filter label { flex: 1; }
.personal-note-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.personal-note-card { display: grid; min-height: 220px; grid-template-rows: auto 1fr auto; gap: 14px; padding: 18px; }
.personal-note-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.personal-note-card h3 { margin: 0 0 4px; font-size: 15px; }
.personal-note-card time { color: var(--muted); font-size: 9px; }
.personal-note-card > p { max-height: 220px; margin: 0; overflow: auto; color: #42566a; font-size: 12px; line-height: 1.6; white-space: pre-wrap; }
.personal-note-card footer { display: flex; justify-content: flex-end; gap: 7px; padding-top: 11px; border-top: 1px solid var(--line); }
.privacy-lock { flex: none; padding: 5px 8px; border-radius: 999px; color: var(--green-700); background: var(--green-100); font-size: 9px; font-weight: 800; }
.privacy-note { margin: 2px 0 0; padding: 10px 12px; border-radius: 9px; color: var(--green-700); background: var(--green-100); font-size: 11px; }

.activity-row { grid-template-columns: auto 1fr; padding-left: 0; padding-right: 0; }
.activity-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--blue-600); box-shadow: 0 0 0 5px var(--blue-100); }
.activity-row p { margin: 0; font-size: 12px; line-height: 1.5; }
.activity-row time { display: block; margin-top: 3px; color: #91a0ae; font-size: 10px; }

.progress-card { padding: 20px; }
.progress-top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.progress-top strong { font-size: 20px; }
.progress-top span { color: var(--muted); font-size: 11px; }
.progress-track { height: 8px; overflow: hidden; border-radius: 99px; background: #e8eef3; }
.progress-track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--blue-700), var(--blue-600)); }

.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { padding: 14px 16px; border-bottom: 1px solid #edf1f4; text-align: left; vertical-align: middle; }
.data-table th { color: #768798; background: #fbfcfd; font-size: 10px; letter-spacing: .55px; text-transform: uppercase; }
.data-table td { font-size: 12px; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fbfdff; }
.table-person { display: flex; min-width: 170px; align-items: center; gap: 10px; }
.table-person strong, .table-person small { display: block; }
.table-person small { margin-top: 3px; color: var(--muted); }
.table-actions { display: flex; justify-content: flex-end; gap: 6px; }

.empty { display: grid; place-items: center; min-height: 210px; padding: 30px; text-align: center; }
.empty-icon { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 13px; border-radius: 16px; color: var(--blue-700); background: var(--blue-100); font-size: 22px; }
.empty h3 { margin: 0 0 6px; font-size: 15px; }
.empty p { max-width: 380px; margin: 0 0 16px; color: var(--muted); font-size: 12px; line-height: 1.55; }

.settings-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.settings-card { padding: 22px; }
.settings-card h3 { margin: 0 0 6px; font-size: 16px; }
.settings-card > p { margin: 0 0 20px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.settings-form { display: grid; gap: 14px; }
.settings-inline { grid-template-columns: repeat(3, minmax(180px, 1fr)); align-items: end; }
.settings-inline .span-3 { grid-column: 1 / -1; }
.settings-inline .form-error, .settings-inline .button { grid-column: 1 / -1; }
.settings-check { display: flex; min-height: 45px; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #f8fafc; }
.settings-check input[type="checkbox"] { appearance: auto; flex: 0 0 18px; width: 18px; height: 18px; min-width: 18px; min-height: 18px; margin: 0; padding: 0; accent-color: var(--blue-700); }
.settings-card.wide { grid-column: 1 / -1; }
.appearance-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .8fr); gap: 20px; align-items: start; }
.appearance-logo { display: grid; gap: 10px; }
.logo-preview { display: grid; min-height: 112px; place-items: center; padding: 16px; border: 1px dashed var(--color-border-strong); border-radius: 12px; background: var(--blue-50); }
.logo-preview img { display: block; max-width: 240px; max-height: 80px; object-fit: contain; }
.logo-preview span { color: var(--muted); font-size: 12px; }
.logo-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.color-field { display: grid; grid-template-columns: 1fr 58px; align-items: center; gap: 12px; }
.color-field input[type="color"] { width: 58px; height: 45px; min-height: 45px; padding: 4px; cursor: pointer; }
.account-lines { display: grid; gap: 0; }
.account-line { display: flex; justify-content: space-between; gap: 20px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
.account-line:last-child { border-bottom: 0; }
.account-line span { color: var(--muted); }

.modal {
  width: clamp(680px, 78vw, 920px);
  max-width: calc(100vw - 30px);
  max-height: min(880px, calc(100vh - 30px));
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 20px;
  color: var(--ink);
  background: white;
  box-shadow: 0 24px 90px rgba(7,27,46,.34);
}
.modal::backdrop { background: rgba(7, 27, 46, .6); backdrop-filter: blur(3px); }
.modal > form, .modal:not(.detail-modal) { padding: 24px; }
.modal.compact { width: min(510px, calc(100vw - 30px)); }
.detail-modal { width: min(910px, calc(100vw - 30px)); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 23px; }
.modal-head h2 { margin: 0; font-size: 23px; letter-spacing: -.55px; }
.icon-button { display: grid; place-items: center; flex: 0 0 auto; width: 39px; height: 39px; padding: 0; border: 1px solid var(--line); border-radius: 10px; color: var(--muted); background: white; font-size: 20px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px; }
.span-2 { grid-column: 1 / -1; }
.event-option { display: flex; align-items: flex-start; gap: 11px; padding: 13px 14px; border: 1px solid #f0c5bf; border-radius: 11px; background: #fff7f5; cursor: pointer; }
.event-option input[type="checkbox"] { appearance: auto; flex: 0 0 18px; width: 18px; height: 18px; min-width: 18px; min-height: 18px; margin: 1px 0 0; padding: 0; border: 0; box-shadow: none; accent-color: var(--coral-600); }
.event-option span, .event-option strong, .event-option small { display: block; }
.event-option span { min-width: 0; }
.event-option strong { color: #8f2b22; }
.event-option small { margin-top: 4px; color: var(--muted); font-weight: 500; line-height: 1.45; }
.event-option:has(input:checked) { border-color: #d96a5e; background: #ffebe7; box-shadow: 0 0 0 3px rgba(216,84,61,.08); }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.copy-field { display: flex; gap: 8px; }
.copy-field input { min-width: 0; }

.detail-header { padding: 26px 28px 22px; color: white; background: linear-gradient(145deg, var(--navy-950), var(--navy-800)); }
.detail-header .modal-head { margin-bottom: 18px; }
.detail-header h2 { max-width: 670px; color: white; font-size: 26px; }
.detail-header .eyebrow { color: var(--color-brand-100); }
.detail-header .icon-button { color: white; border-color: rgba(255,255,255,.24); background: rgba(255,255,255,.08); }
.detail-meta { display: flex; flex-wrap: wrap; gap: 9px 22px; color: #c8d8e5; font-size: 12px; }
.detail-meta strong { color: white; }
.detail-body { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(250px, .75fr); gap: 0; }
.detail-main { padding: 26px 28px; }
.detail-aside { padding: 26px 24px; border-left: 1px solid var(--line); background: #f8fafc; }
.detail-section + .detail-section { margin-top: 27px; }
.detail-section h3 { margin: 0 0 12px; font-size: 14px; }
.meeting-purpose-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 25px; }
.meeting-purpose-grid article { padding: 14px; border: 1px solid var(--color-brand-100); border-radius: 12px; background: var(--blue-50); }
.meeting-purpose-grid span { color: var(--blue-700); font-size: 10px; font-weight: 850; letter-spacing: .5px; text-transform: uppercase; }
.meeting-purpose-grid p { margin: 7px 0 0; color: #314b61; font-size: 12px; line-height: 1.55; white-space: pre-wrap; }
.agenda-list { display: grid; gap: 8px; margin: 0; padding: 0; counter-reset: agenda; list-style: none; }
.agenda-list li { display: grid; grid-template-columns: 24px 1fr; gap: 8px; color: #3e5265; font-size: 12px; line-height: 1.5; }
.agenda-list li::before { counter-increment: agenda; content: counter(agenda); display: grid; place-items: center; width: 21px; height: 21px; border-radius: 6px; color: var(--blue-700); background: var(--blue-100); font-size: 9px; font-weight: 900; }
.agenda-item-list { display: grid; gap: 9px; }
.agenda-item { display: grid; grid-template-columns: auto minmax(0, 1fr) minmax(150px, auto); align-items: center; gap: 11px; padding: 12px; border: 1px solid var(--line); border-radius: 11px; background: white; }
.agenda-item.decided { border-color: #b7dfc7; background: #f4fbf7; }
.agenda-item.carried { border-color: #e6d49d; background: #fffaf0; }
.agenda-item.discussing { border-color: #b9d9ee; background: #f4faff; }
.agenda-number { display: grid; width: 25px; height: 25px; place-items: center; border-radius: 7px; color: var(--blue-700); background: var(--blue-100); font-size: 10px; font-weight: 900; }
.agenda-item strong, .agenda-item small { display: block; }
.agenda-item strong { font-size: 12px; line-height: 1.45; }
.agenda-item small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.agenda-item label { gap: 4px; color: var(--muted); font-size: 9px; }
.agenda-item select { min-height: 36px; padding: 7px 28px 7px 9px; font-size: 10px; }
.carried-section { padding: 15px; border: 1px solid #ead9aa; border-radius: 12px; background: #fffaf0; }
.carried-section > .muted { margin: -5px 0 12px; }
.carried-task-list { display: grid; gap: 8px; }
.carried-task { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 12px; border: 1px solid #eadfbf; border-radius: 10px; background: white; }
.carried-task strong, .carried-task small { display: block; }
.carried-task strong { font-size: 11px; }
.carried-task small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.carried-task > div:last-child { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.decision-list { display: grid; gap: 10px; }
.decision-card { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.decision-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.decision-card-head p { flex: 1; margin: 0; font-size: 12px; font-weight: 700; line-height: 1.55; }
.decision-card-head .button { flex: 0 0 auto; }
.decision-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 10px; }
.decision-card-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 7px; }
.decision-form { display: grid; gap: 13px; padding: 17px; border: 1px solid var(--color-brand-100); border-radius: 13px; background: var(--blue-50); }
.decision-form h3 { margin: 0; font-size: 14px; }
.decision-form .form-grid { gap: 11px; }
.detail-aside dl { display: grid; gap: 14px; margin: 0; }
.detail-aside dt { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase; }
.detail-aside dd { margin: 4px 0 0; font-size: 12px; line-height: 1.5; }
.detail-actions { display: grid; gap: 8px; margin-top: 25px; }

.nav-count { min-width: 20px; margin-left: auto; padding: 2px 6px; border-radius: 999px; color: white; background: var(--coral-600); font-size: 9px; text-align: center; }
.template-picker { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 10px; padding: 12px; border: 1px solid var(--color-brand-100); border-radius: 12px; background: var(--blue-50); }
.template-panel { margin-bottom: 18px; }
.template-list { display: grid; gap: 9px; padding: 10px 0; }
.template-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 14px; border: 1px solid var(--line); border-radius: 11px; background: #fbfdff; }
.template-card strong, .template-card span, .template-card small { display: block; }
.template-card strong { font-size: 13px; }
.template-card span { margin-top: 4px; color: #42566a; font-size: 11px; }
.template-card small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.template-card > div:last-child { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }

.archive-filter { display: grid; grid-template-columns: minmax(210px, 1.5fr) repeat(4, minmax(130px, 1fr)) auto; align-items: end; gap: 11px; margin-bottom: 18px; padding: 16px; }
.archive-filter-actions { display: flex; gap: 7px; }
.archive-view-toolbar { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin: 0 0 12px; }
.archive-view-toolbar > span { color: var(--muted); font-size: 11px; font-weight: 700; }
.view-switch { display: flex; gap: 6px; }
.decision-archive { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; }
.archive-card { display: grid; align-content: start; gap: 13px; padding: 18px; }
.archive-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.archive-card h3 { margin: 5px 0 0; font-size: 15px; line-height: 1.45; }
.archive-card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.archive-card-grid div { padding: 10px; border-radius: 9px; background: #f6f9fb; }
.archive-card-grid span, .archive-card-grid strong { display: block; }
.archive-card-grid span { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.archive-card-grid strong { margin-top: 4px; overflow-wrap: anywhere; font-size: 11px; }
.archive-card footer { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.decision-list-table { min-width: 980px; }
.decision-list-table td:first-child { min-width: 260px; max-width: 420px; line-height: 1.45; }
.decision-list-table td:nth-child(2) { min-width: 190px; }
.decision-list-table td:nth-child(3) { min-width: 130px; }
.decision-list-table td:nth-child(4) { min-width: 170px; }
.decision-list-table td:nth-child(3) span, .decision-list-table td:nth-child(3) small { display: block; }
.decision-list-table td:nth-child(3) small { margin-top: 4px; color: var(--muted); }

.reminder-panel .panel-body { padding: 18px 20px; }
.reminder-list { display: grid; gap: 9px; }
.reminder-list.compact .reminder-row { grid-template-columns: auto minmax(0, 1fr); }
.reminder-list.compact .reminder-actions { grid-column: 2; justify-content: flex-start; }
.reminder-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 13px; border: 1px solid var(--line); border-left: 4px solid var(--blue-600); border-radius: 11px; background: white; }
.reminder-row.coral { border-left-color: var(--coral-600); background: #fffafa; }
.reminder-row.amber { border-left-color: #d99b28; background: #fffdf8; }
.reminder-icon { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 10px; color: var(--blue-700); background: var(--blue-100); font-weight: 900; }
.reminder-row strong { font-size: 12px; }
.reminder-row p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.reminder-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }

.history-filter { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(160px, .5fr) auto auto; align-items: end; gap: 10px; margin-bottom: 18px; padding: 16px; }
.history-list { display: grid; }
.history-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) auto; align-items: center; gap: 15px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.history-row:last-child { border-bottom: 0; }
.history-type, .trash-type { width: fit-content; padding: 5px 8px; border-radius: 999px; color: var(--blue-700); background: var(--blue-100); font-size: 9px; font-weight: 850; }
.history-row strong { font-size: 12px; }
.history-row p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.history-row time { color: #42566a; font-size: 10px; text-align: right; }
.history-row time small { display: block; margin-top: 3px; color: var(--muted); }

.safety-banner { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; padding: 14px 16px; border: 1px solid #efd59a; border-radius: 12px; color: #6e4b0b; background: #fffaf0; }
.safety-banner > span { display: grid; flex: 0 0 28px; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: white; background: var(--amber-700); }
.safety-banner strong { font-size: 12px; }
.safety-banner p { margin: 3px 0 0; font-size: 11px; line-height: 1.45; }
.trash-list { display: grid; }
.trash-row { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.trash-row:last-child { border-bottom: 0; }
.trash-row strong { font-size: 12px; }
.trash-row p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.trash-row > div:last-child { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }

.meeting-preparation { padding: 16px; border: 1px solid var(--color-brand-100); border-radius: 13px; background: var(--color-brand-50); }
.section-heading h3 { margin-bottom: 4px; }
.section-heading p { margin: 0 0 12px; font-size: 10px; }
.preparation-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.preparation-stats article { padding: 10px; border: 1px solid #d9e6ef; border-radius: 10px; background: white; text-align: center; }
.preparation-stats strong, .preparation-stats span { display: block; }
.preparation-stats strong { color: var(--navy-900); font-size: 19px; }
.preparation-stats span { margin-top: 2px; color: var(--muted); font-size: 9px; }
.preparation-empty { margin: 0; padding: 12px; border: 1px dashed #c9d9e5; border-radius: 9px; text-align: center; }

.toast-region { position: fixed; z-index: 100; right: 18px; top: 18px; display: grid; gap: 8px; width: min(370px, calc(100vw - 36px)); }
.toast { display: flex; align-items: center; justify-content: space-between; gap: 13px; padding: 13px 15px; border: 1px solid #c7dde9; border-radius: 12px; color: #17435b; background: #f1f9fd; box-shadow: 0 12px 30px rgba(7,27,46,.16); font-size: 12px; font-weight: 700; animation: toast-in .2s ease-out; }
.toast.error { color: #8e321f; border-color: #f0c9c0; background: #fff5f2; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-7px); } }

.mobile-only, .sidebar-scrim { display: none; }

/* Seçilen görünüm ölçeği, arayüzdeki yazıların tamamına tutarlı biçimde uygulanır. */
body { font-size: calc(16px * var(--font-scale)); }
label, .button, .nav-item, .row-title { font-size: calc(13px * var(--font-scale)); }
.eyebrow, .brand small, .row-meta, .assignee, .panel-head p, .detail-meta { font-size: calc(11px * var(--font-scale)); }
.badge, .date-box span, .decision-footer, .detail-aside dt, .user-card small { font-size: calc(10px * var(--font-scale)); }
.brand strong { font-size: calc(18px * var(--font-scale)); }
.settings-card h3 { font-size: calc(16px * var(--font-scale)); }
.settings-card > p, .account-line, .empty p, .agenda-list li, .detail-aside dd, .decision-card-head p, .toast { font-size: calc(12px * var(--font-scale)); }
.modal-head h2 { font-size: calc(23px * var(--font-scale)); }
.detail-section h3, .decision-form h3 { font-size: calc(14px * var(--font-scale)); }

@media (max-width: 1100px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .date-chip { display: none; }
  .task-filter-panel { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-filter-actions { align-self: end; }
  .archive-filter { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .archive-filter-actions { align-self: end; }
}

@media (max-width: 820px) {
  .auth-layout { grid-template-columns: 1fr; }
  .auth-story { min-height: 340px; padding: 30px; }
  .story-copy { margin: 55px 0 30px; }
  .story-copy h1 { font-size: clamp(34px, 10vw, 52px); }
  .feature-list, .auth-foot { display: none; }
  .auth-panel { min-height: auto; padding: 28px 18px 50px; }
  .auth-card { padding: 26px; box-shadow: 0 10px 35px rgba(15,42,65,.08); }

  .sidebar { transform: translateX(-102%); transition: transform .2s ease; box-shadow: 20px 0 60px rgba(7,27,46,.2); }
  .app-shell.menu-open .sidebar { transform: translateX(0); }
  .sidebar-scrim { position: fixed; z-index: 25; inset: 0; border: 0; background: rgba(7,27,46,.45); }
  .app-shell.menu-open .sidebar-scrim { display: block; }
  .workspace { margin-left: 0; }
  .mobile-only { display: grid; }
  .topbar { min-height: 76px; padding: 13px 17px; }
  .topbar > div:nth-child(2) { flex: 1; }
  .topbar .eyebrow { display: none; }
  .topbar h1 { font-size: 20px; }
  .topbar-actions .button.secondary { display: none; }
  .topbar-actions .button { min-height: 39px; padding: 8px 11px; }
  .content { padding: 22px 16px 45px; }
  .page-intro { align-items: flex-start; flex-direction: column; }
  .page-actions { width: 100%; justify-content: flex-start; }
  .task-view-toolbar { align-items: flex-start; flex-direction: column; }
  .settings-grid { grid-template-columns: 1fr; }
  .appearance-grid { grid-template-columns: 1fr; }
  .settings-inline { grid-template-columns: 1fr; }
  .settings-card.wide { grid-column: 1; }
  .detail-body { grid-template-columns: 1fr; }
  .detail-aside { border-top: 1px solid var(--line); border-left: 0; }
  .meeting-purpose-grid { grid-template-columns: 1fr; }
  .agenda-item { grid-template-columns: auto minmax(0, 1fr); }
  .agenda-item label, .agenda-item > .badge { grid-column: 2; }
  .history-row { grid-template-columns: 100px minmax(0, 1fr); }
  .history-row time { grid-column: 2; text-align: left; }
  .trash-row { grid-template-columns: 85px minmax(0, 1fr); }
  .trash-row > div:last-child { grid-column: 2; justify-content: flex-start; }
}

@media print {
  body * { visibility: hidden !important; }
  #meeting-detail-dialog, #meeting-detail-dialog * { visibility: visible !important; }
  #meeting-detail-dialog { position: absolute; inset: 0; width: 100%; max-width: none; max-height: none; margin: 0; overflow: visible; border: 0; box-shadow: none; }
  #meeting-detail-dialog::backdrop { display: none; }
  #meeting-detail-dialog .icon-button, #meeting-detail-dialog .detail-actions, #meeting-detail-dialog .decision-form, #meeting-detail-dialog .button { display: none !important; }
  #meeting-detail-dialog .detail-header { color: #111; background: white; border-bottom: 2px solid #222; }
  #meeting-detail-dialog .detail-header h2, #meeting-detail-dialog .detail-header strong, #meeting-detail-dialog .detail-header .eyebrow { color: #111; }
  #meeting-detail-dialog .detail-meta { color: #333; }
  #meeting-detail-dialog .detail-body { grid-template-columns: minmax(0, 1fr) 230px; }
  #meeting-detail-dialog .detail-main, #meeting-detail-dialog .detail-aside { padding: 18px; }
  #meeting-detail-dialog .detail-aside { background: white; }
  #meeting-detail-dialog .agenda-item, #meeting-detail-dialog .decision-card, #meeting-detail-dialog .carried-task { break-inside: avoid; }
  #meeting-detail-dialog select { appearance: none; border: 0; background: transparent; }
}

@media (max-width: 570px) {
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
  .stat-card { min-height: 112px; padding: 15px; }
  .stat-value { font-size: 26px; }
  .meeting-row { grid-template-columns: 53px minmax(0, 1fr); padding: 13px 14px; }
  .meeting-row .row-actions { grid-column: 2; }
  .task-row { grid-template-columns: auto minmax(0, 1fr); padding: 13px 14px; }
  .task-row > .row-actions { grid-column: 2; }
  .panel-head { padding: 16px; }
  .form-grid { grid-template-columns: 1fr; }
  .member-checklist { grid-template-columns: 1fr; }
  .weekday-checklist { grid-template-columns: repeat(4, minmax(54px, 1fr)); }
  .span-2 { grid-column: 1; }
  .modal > form, .modal:not(.detail-modal) { padding: 19px; }
  .detail-header, .detail-main { padding: 21px 19px; }
  .detail-aside { padding: 21px 19px; }
  .decision-card-head { align-items: stretch; flex-direction: column; }
  .decision-card-head .button { width: 100%; }
  .topbar-actions .button.primary { font-size: 0; }
  .topbar-actions .button.primary::after { content: "+ Toplantı"; font-size: 12px; }
  .page-intro .button { width: 100%; }
  .page-actions .button { width: 100%; }
  .task-filter-panel { grid-template-columns: 1fr; }
  .personal-note-filter { align-items: stretch; flex-direction: column; }
  .personal-note-filter .button { width: 100%; }
  .task-filter-actions .button { flex: 1; }
  .calendar-toolbar { align-items: flex-start; flex-direction: column; }
  .calendar-nav { width: 100%; justify-content: space-between; }
  .task-calendar { min-width: 770px; grid-template-columns: repeat(7, minmax(110px, 1fr)); }
  .task-calendar.week { min-width: 770px; }
  .data-table th, .data-table td { padding: 12px; }
  .template-picker, .archive-filter, .history-filter { grid-template-columns: 1fr; }
  .template-card, .reminder-row { align-items: stretch; flex-direction: column; }
  .template-card { display: grid; }
  .template-card > div:last-child, .reminder-actions { justify-content: flex-start; }
  .reminder-row { grid-template-columns: auto minmax(0, 1fr); }
  .reminder-actions { grid-column: 2; }
  .archive-card-grid, .preparation-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .history-row, .trash-row { grid-template-columns: 1fr; }
  .history-row time, .trash-row > div:last-child { grid-column: 1; }
}

/* --------------------------------------------------------------------------
   Saadet İstanbul Interface 3.0
   Linear'ın yoğun çalışma alanı yaklaşımı ile Notion'ın sakin içerik
   hiyerarşisini birleştiren, tek token sistemine bağlı sunum katmanı.
   -------------------------------------------------------------------------- */

html { scroll-behavior: smooth; }
body { min-height: 100vh; font-weight: 450; -webkit-font-smoothing: antialiased; }
::selection { color: var(--color-on-brand); background: var(--color-brand-600); }

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid var(--color-focus);
  outline-offset: 2px;
  box-shadow: var(--focus-ring);
}

.skip-link {
  position: fixed;
  z-index: 120;
  top: var(--space-3);
  left: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-sm);
  color: var(--color-on-brand);
  background: var(--color-brand-900);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform .16s ease;
}
.skip-link:focus { transform: translateY(0); }

.brand { gap: var(--space-3); color: var(--color-text); }
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--color-brand-500), var(--color-brand-700));
  box-shadow: var(--shadow-xs);
}
.brand strong { color: inherit; font-weight: 800; letter-spacing: -.45px; }
.brand small { color: var(--color-text-tertiary); font-weight: 700; letter-spacing: .7px; }
.brand-light, .brand-light strong, .brand-light small { color: var(--color-white); }
.brand-light small { opacity: .78; }
.institution-brand { min-height: 80px; }
.institution-brand .institution-brand-mark {
  width: 224px;
  height: 80px;
  border-color: color-mix(in srgb, var(--color-white) 20%, transparent);
  border-radius: var(--radius-md);
  background: var(--color-brand-500);
  box-shadow: 0 18px 42px color-mix(in srgb, var(--color-neutral-950) 24%, transparent);
}
.institution-brand .institution-brand-mark img { object-fit: cover; object-position: center; }
.sidebar .brand-mark img { object-fit: contain; }

.eyebrow {
  margin-bottom: var(--space-2);
  color: var(--color-brand-100);
  font-weight: 800;
  letter-spacing: 1px;
}
.eyebrow.ink { color: var(--color-brand-700); }
.muted { color: var(--color-text-secondary); }

/* Authentication */
.auth-layout { grid-template-columns: minmax(390px, 44%) 1fr; background: var(--color-surface); }
.auth-story {
  padding: clamp(var(--space-8), 5vw, 72px);
  background:
    radial-gradient(circle at 82% 14%, color-mix(in srgb, var(--color-brand-500) 32%, transparent), transparent 32%),
    radial-gradient(circle at 10% 88%, color-mix(in srgb, var(--color-accent-600) 18%, transparent), transparent 30%),
    linear-gradient(148deg, var(--color-neutral-950), var(--color-brand-900));
}
.auth-story::after { border-color: color-mix(in srgb, var(--color-white) 13%, transparent); }
.story-copy h1 { font-weight: 750; letter-spacing: -2.6px; }
.story-copy > p:not(.eyebrow) { color: color-mix(in srgb, var(--color-white) 78%, var(--color-brand-100)); }
.feature-list { color: color-mix(in srgb, var(--color-white) 90%, var(--color-brand-100)); }
.feature-list span { background: var(--color-brand-600); }
.auth-foot { color: color-mix(in srgb, var(--color-white) 58%, var(--color-brand-100)); }
.auth-panel { padding: var(--space-10); background: var(--color-neutral-50); }
.auth-card {
  gap: var(--space-5);
  width: min(420px, 100%);
  padding: var(--space-8);
  border-color: var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
}
.auth-card h2 { color: var(--color-text); font-weight: 750; letter-spacing: -1px; }
.auth-options { min-height: 32px; }
.text-button { min-height: 32px; color: var(--color-brand-700); text-underline-offset: 4px; }

/* Inputs and actions */
label { color: var(--color-neutral-700); font-weight: 700; }
input, select, textarea {
  min-height: var(--control-height);
  padding: 9px var(--space-3);
  border-color: var(--color-border-strong);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  background: var(--color-surface);
  box-shadow: var(--shadow-xs);
}
input:hover, select:hover, textarea:hover { border-color: var(--color-neutral-500); }
input:focus, select:focus, textarea:focus {
  border-color: var(--color-focus);
  outline: 3px solid transparent;
  box-shadow: var(--focus-ring);
}
input::placeholder, textarea::placeholder { color: var(--color-text-tertiary); opacity: 1; }

.button {
  min-height: var(--control-height);
  padding: 8px var(--space-4);
  border-radius: var(--radius-sm);
  font-weight: 750;
  letter-spacing: -.05px;
  transition: background-color .14s ease, border-color .14s ease, color .14s ease, transform .14s ease;
}
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button.primary { color: var(--color-on-brand); background: var(--color-brand-600); box-shadow: var(--shadow-xs); }
.button.primary:hover { background: var(--color-brand-700); }
.button.secondary { color: var(--color-neutral-800); border-color: var(--color-border-strong); background: var(--color-surface); box-shadow: var(--shadow-xs); }
.button.secondary:hover { color: var(--color-brand-700); border-color: var(--color-brand-100); background: var(--color-brand-50); }
.button.ghost { color: var(--color-text-secondary); }
.button.ghost:hover { color: var(--color-text); background: var(--color-surface-hover); }
.button.danger { color: var(--color-accent-700); border-color: var(--color-accent-100); background: var(--color-surface); }
.button.danger:hover { color: var(--color-on-accent); border-color: var(--color-accent-700); background: var(--color-accent-700); }
.button.small { min-height: 36px; padding: 6px var(--space-3); }
.icon-button { min-width: var(--target-min); width: var(--target-min); height: var(--target-min); border-radius: var(--radius-sm); }
.icon-button:hover { color: var(--color-brand-700); border-color: var(--color-brand-100); background: var(--color-brand-50); }
.form-error { color: var(--color-accent-700); background: var(--color-accent-100); }
.form-message { color: var(--color-success-700); background: var(--color-success-100); }

/* Application frame */
.sidebar {
  width: var(--sidebar-width);
  padding: var(--space-5) var(--space-3) var(--space-3);
  border-color: var(--color-border);
  background: var(--color-neutral-50);
}
.sidebar > .brand { min-height: 48px; margin: 0 var(--space-2) var(--space-6); padding: 0 var(--space-2); }
.nav { gap: 2px; }
.nav-item {
  min-height: var(--target-min);
  gap: var(--space-3);
  padding: 9px var(--space-3);
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  font-weight: 650;
}
.nav-item .nav-icon {
  display: grid;
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  place-items: center;
  color: var(--color-text-tertiary);
}
.nav-icon svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.nav-item:hover { color: var(--color-text); background: var(--color-neutral-100); }
.nav-item.active {
  color: var(--color-brand-700);
  border-color: var(--color-brand-100);
  background: var(--color-surface);
  box-shadow: var(--shadow-xs);
}
.nav-item.active .nav-icon { color: var(--color-brand-600); }
.nav-item.quiet { margin-top: var(--space-2); border-top-color: var(--color-border); }
.sidebar-bottom { padding-top: var(--space-4); }
.user-card { padding: var(--space-3); border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-surface); }
.user-card strong { color: var(--color-text); }
.avatar { background: var(--color-brand-800); }
.avatar.blue { background: var(--color-brand-600); }
.avatar.coral { background: var(--color-accent-700); }
.avatar.green { background: var(--color-success-700); }

.workspace { margin-left: var(--sidebar-width); }
.topbar {
  min-height: 68px;
  gap: var(--space-5);
  padding: 10px clamp(var(--space-6), 3vw, var(--space-10));
  border-color: var(--color-border);
  background: color-mix(in srgb, var(--color-surface) 94%, transparent);
  backdrop-filter: blur(14px);
}
.topbar h1 { color: var(--color-text); font-size: 20px; font-weight: 760; letter-spacing: -.55px; }
.topbar .eyebrow { margin-bottom: 2px; }
.topbar-actions { gap: var(--space-2); }
.date-chip { padding: 8px var(--space-3); border: 1px solid var(--color-border); border-radius: var(--radius-sm); color: var(--color-text-secondary); background: var(--color-surface-subtle); }
.content { max-width: var(--content-max); padding: var(--space-8) clamp(var(--space-6), 3vw, var(--space-10)) var(--space-12); }

/* Page hierarchy */
.page-intro { align-items: center; margin-bottom: var(--space-5); }
.page-intro h2 { margin-bottom: var(--space-1); color: var(--canvas-text); font-size: 22px; font-weight: 740; letter-spacing: -.55px; }
.page-intro p { color: var(--canvas-muted); font-size: 13px; }
.page-actions { gap: var(--space-2); }
.dashboard-intro { padding-bottom: var(--space-2); }
.dashboard-intro-copy { display: grid; gap: var(--space-1); }
.workspace-kicker { display: inline-flex; width: fit-content; align-items: center; gap: var(--space-2); color: var(--canvas-muted); font-size: 11px; font-weight: 750; }
.workspace-kicker::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--color-success-700); box-shadow: 0 0 0 3px var(--color-success-100); }
.dashboard-shortcuts { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-2); }

.stats-grid { gap: var(--space-3); margin-bottom: var(--space-5); }
.stat-card {
  display: grid;
  min-height: 118px;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto 1fr auto;
  gap: 0 var(--space-3);
  padding: var(--space-4);
  border-color: var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-xs);
}
.stat-card::after { display: none; }
.stat-icon {
  display: grid;
  grid-column: 2;
  grid-row: 1 / 3;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: var(--radius-sm);
  color: var(--color-brand-700);
  background: var(--color-brand-50);
}
.stat-icon svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.9; }
.stat-card.coral .stat-icon { color: var(--color-accent-700); background: var(--color-accent-100); }
.stat-card.green .stat-icon { color: var(--color-success-700); background: var(--color-success-100); }
.stat-card.amber .stat-icon { color: var(--color-warning-800); background: var(--color-warning-100); }
.stat-label { grid-column: 1; color: var(--color-text-secondary); font-weight: 700; }
.stat-value { grid-column: 1; margin: 8px 0 0; color: var(--color-text); font-size: 29px; font-weight: 760; letter-spacing: -1.1px; }
.stat-sub { grid-column: 1 / -1; align-self: end; color: var(--color-text-tertiary); }

.dashboard-grid { grid-template-columns: minmax(0, 1.55fr) minmax(300px, .72fr); gap: var(--space-4); }
.stack { gap: var(--space-4); }
.panel { border-color: var(--color-border); border-radius: var(--radius-md); background: var(--color-surface); box-shadow: var(--shadow-xs); }
.panel-head { min-height: 62px; padding: var(--space-4); border-color: var(--color-border); }
.panel-head h3 { color: var(--color-text); font-weight: 730; letter-spacing: -.2px; }
.panel-head p { color: var(--color-text-secondary); }
.panel-body { padding: var(--space-2) var(--space-4); }
.panel-kicker { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--color-text-secondary); font-size: 11px; font-weight: 700; }
.panel-kicker::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--color-brand-500); }

/* Lists, tables and content cards */
.meeting-row, .task-row, .activity-row { gap: var(--space-4); padding: var(--space-4); border-color: var(--color-neutral-100); }
.meeting-row:hover, .task-row:hover { background: var(--color-surface-hover); }
.date-box { min-height: 54px; border: 1px solid var(--color-brand-100); border-radius: var(--radius-sm); color: var(--color-text); background: var(--color-brand-50); }
.date-box span { color: var(--color-brand-700); }
.row-title { color: var(--color-text); font-weight: 730; }
.row-meta { color: var(--color-text-secondary); }
.row-actions { gap: var(--space-2); }

.badge { border: 1px solid transparent; border-radius: var(--radius-pill); color: var(--color-brand-700); background: var(--color-brand-50); }
.badge.green { color: var(--color-success-700); background: var(--color-success-100); }
.badge.coral { color: var(--color-accent-700); background: var(--color-accent-100); }
.badge.amber, .badge.stale { color: var(--color-warning-800); background: var(--color-warning-100); }
.badge.event { color: var(--event-contrast); background: var(--event-color); }
.badge.lesson { color: var(--lesson-contrast); background: var(--lesson-color); }
.badge.repeat, .badge.gray { color: var(--color-neutral-700); background: var(--color-neutral-100); }

.task-check { min-width: 30px; width: 30px; height: 30px; border-color: var(--color-border-strong); border-radius: var(--radius-sm); }
.task-check.done { border-color: var(--color-success-700); background: var(--color-success-700); }
.task-check.in-progress { border-color: var(--color-warning-800); background: var(--color-warning-800); }
.task-check.blocked { border-color: var(--color-accent-700); background: var(--color-accent-700); }
.task-row.in-progress { background: color-mix(in srgb, var(--color-warning-100) 36%, var(--color-white)); }
.task-row.blocked { background: color-mix(in srgb, var(--color-accent-100) 40%, var(--color-white)); }
.task-progress-note { color: var(--color-neutral-700); border-color: var(--color-warning-800); background: color-mix(in srgb, var(--color-warning-100) 62%, var(--color-white)); }
.task-next-action { color: var(--color-neutral-700); border-color: var(--color-brand-600); background: var(--color-brand-50); }
.task-blocker-note { color: var(--color-accent-700); border-color: var(--color-accent-700); background: var(--color-accent-100); }

.activity-dot { background: var(--color-brand-500); box-shadow: 0 0 0 4px var(--color-brand-100); }
.activity-row time { color: var(--color-text-tertiary); }
.progress-card { padding: var(--space-4); }
.progress-track { height: 7px; background: var(--color-neutral-100); }
.progress-track i { background: linear-gradient(90deg, var(--color-brand-700), var(--color-brand-500)); }

.table-wrap { border-radius: inherit; }
.data-table th, .data-table td { border-color: var(--color-neutral-100); }
.data-table th { color: var(--color-text-secondary); background: var(--color-surface-subtle); }
.data-table tbody tr:hover { background: var(--color-surface-hover); }
.filter-button { min-height: 36px; border-color: var(--color-border-strong); border-radius: var(--radius-sm); color: var(--color-text-secondary); background: var(--color-surface); }
.filter-button:hover { color: var(--color-text); background: var(--color-surface-hover); }
.filter-button.active { color: var(--color-brand-700); border-color: var(--color-brand-100); background: var(--color-brand-50); }
.task-filter-panel, .archive-filter, .history-filter, .personal-note-filter { border-color: var(--color-border); background: var(--color-surface); }

.empty { min-height: 190px; }
.empty-icon { border-radius: var(--radius-md); color: var(--color-brand-700); background: var(--color-brand-50); }
.empty h3 { color: var(--color-text); }

/* Calendar */
.calendar-toolbar { border-color: var(--color-border); }
.task-calendar { gap: 1px; background: var(--color-border); }
.calendar-weekday, .calendar-day.outside { color: var(--color-text-secondary); background: var(--color-surface-subtle); }
.calendar-day { background: var(--color-surface); }
.calendar-day.today { box-shadow: inset 0 0 0 2px var(--color-focus); }
.calendar-day.today > header span { color: var(--color-on-brand); background: var(--color-brand-600); }
.calendar-task { color: var(--color-brand-700); border-color: var(--color-brand-600); background: var(--color-brand-50); }
.calendar-task.progress { color: var(--color-warning-800); border-color: var(--color-warning-800); background: var(--color-warning-100); }
.calendar-task.done { color: var(--color-success-700); border-color: var(--color-success-700); background: var(--color-success-100); }
.calendar-task.late { color: var(--color-accent-700); border-color: var(--color-accent-700); background: var(--color-accent-100); }
.calendar-task.event { color: var(--event-contrast); border-color: color-mix(in srgb, var(--event-color) 72%, var(--color-neutral-950)); background: var(--event-color); box-shadow: var(--shadow-xs); }
.calendar-task.lesson { color: var(--lesson-contrast); border-color: color-mix(in srgb, var(--lesson-color) 72%, var(--color-neutral-950)); background: var(--lesson-color); box-shadow: var(--shadow-xs); }

/* Notes, reminders, settings and audit */
.personal-note-card, .archive-card, .template-card, .reminder-row, .progress-history-item { border-color: var(--color-border); background: var(--color-surface); box-shadow: var(--shadow-xs); }
.personal-note-card > p, .template-card span, .progress-history-item p { color: var(--color-neutral-700); }
.privacy-banner { color: var(--color-success-700); border-color: var(--color-success-100); background: var(--color-success-100); }
.privacy-lock, .privacy-note { color: var(--color-success-700); background: var(--color-success-100); }
.reminder-row { border-left-color: var(--color-brand-600); }
.reminder-row.coral { border-left-color: var(--color-accent-700); background: color-mix(in srgb, var(--color-accent-100) 32%, var(--color-white)); }
.reminder-row.amber { border-left-color: var(--color-warning-800); background: color-mix(in srgb, var(--color-warning-100) 34%, var(--color-white)); }
.reminder-icon { color: var(--color-brand-700); background: var(--color-brand-50); }
.settings-card { padding: var(--space-5); }
.settings-check { border-color: var(--color-border); border-radius: var(--radius-sm); background: var(--color-surface-subtle); }
.logo-preview { border-color: var(--color-border-strong); border-radius: var(--radius-md); background: var(--color-brand-50); }
.account-line { border-color: var(--color-border); }
.safety-banner { color: var(--color-warning-800); border-color: var(--color-warning-100); background: var(--color-warning-100); }
.history-type, .trash-type { color: var(--color-brand-700); background: var(--color-brand-50); }

/* Meeting detail and dialogs */
.modal { border: 1px solid var(--color-border); border-radius: var(--radius-lg); color: var(--color-text); background: var(--color-surface); box-shadow: var(--shadow-md); }
.modal::backdrop { background: color-mix(in srgb, var(--color-neutral-950) 64%, transparent); backdrop-filter: blur(4px); }
.modal-head { margin-bottom: var(--space-5); }
.modal-head h2 { color: var(--color-text); font-weight: 750; }
.detail-header { background: linear-gradient(145deg, var(--color-neutral-950), var(--color-brand-900)); }
.detail-aside { border-color: var(--color-border); background: var(--color-surface-subtle); }
.meeting-purpose-grid article, .decision-form, .meeting-preparation, .template-picker { border-color: var(--color-brand-100); background: var(--color-brand-50); }
.meeting-purpose-grid span { color: var(--color-brand-700); }
.meeting-purpose-grid p, .agenda-list li { color: var(--color-neutral-700); }
.agenda-item, .decision-card, .carried-task { border-color: var(--color-border); background: var(--color-surface); }
.agenda-item.decided { border-color: var(--color-success-100); background: color-mix(in srgb, var(--color-success-100) 48%, var(--color-white)); }
.agenda-item.carried, .carried-section { border-color: var(--color-warning-100); background: color-mix(in srgb, var(--color-warning-100) 40%, var(--color-white)); }
.agenda-item.discussing { border-color: var(--color-brand-100); background: var(--color-brand-50); }
.agenda-number { color: var(--color-brand-700); background: var(--color-brand-50); }
.event-option { border-color: var(--color-border); border-radius: var(--radius-sm); background: var(--color-surface-subtle); }
.event-option strong { color: var(--color-text); }
.event-option:has(input:checked) { border-color: var(--color-brand-500); background: var(--color-brand-50); box-shadow: var(--focus-ring); }

.toast { color: var(--color-brand-900); border-color: var(--color-brand-100); border-radius: var(--radius-md); background: var(--color-brand-50); box-shadow: var(--shadow-sm); }
.toast.error { color: var(--color-accent-700); border-color: var(--color-accent-100); background: var(--color-accent-100); }

@media (max-width: 1120px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .archive-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 840px) {
  :root { --sidebar-width: min(312px, calc(100vw - 48px)); }
  .sidebar { box-shadow: var(--shadow-md); }
  .workspace { margin-left: 0; }
  .topbar { min-height: 64px; padding: 10px var(--space-4); }
  .topbar h1 { font-size: 18px; }
  .content { padding: var(--space-6) var(--space-4) var(--space-10); }
  .sidebar-scrim { background: color-mix(in srgb, var(--color-neutral-950) 54%, transparent); }
  .page-intro { align-items: flex-start; }
  .dashboard-shortcuts { width: 100%; justify-content: flex-start; }
  .dashboard-shortcuts .button { flex: 1; }
  .modal { max-height: calc(100dvh - 20px); }
}

@media (max-width: 640px) {
  .auth-story { min-height: 290px; padding: var(--space-6); }
  .institution-brand .institution-brand-mark { width: 196px; height: 70px; }
  .story-copy { margin: var(--space-10) 0 var(--space-5); }
  .story-copy h1 { font-size: clamp(32px, 10vw, 44px); letter-spacing: -1.8px; }
  .auth-panel { padding: var(--space-5) var(--space-4) var(--space-10); }
  .auth-card { padding: var(--space-6); }
  .topbar-actions { gap: var(--space-1); }
  .topbar-actions .button { min-width: 44px; min-height: 44px; }
  .content { padding-inline: var(--space-3); }
  .page-intro { gap: var(--space-4); }
  .page-intro h2 { font-size: 20px; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-card { min-height: 116px; }
  .stat-value { font-size: 26px; }
  .meeting-row, .task-row { padding: var(--space-3); }
  .row-actions { justify-content: flex-start; }
  .panel-head { align-items: flex-start; }
  .panel-head .button { min-height: 36px; }
  .archive-filter, .history-filter, .task-filter-panel { grid-template-columns: 1fr; }
  .modal { width: calc(100vw - 16px); max-width: none; border-radius: var(--radius-md); }
  .modal > form, .modal:not(.detail-modal) { padding: var(--space-4); }
  .modal-actions { position: sticky; bottom: 0; margin-inline: calc(var(--space-4) * -1); padding: var(--space-3) var(--space-4); background: var(--color-surface); }
}

@media (max-width: 390px) {
  .stats-grid { grid-template-columns: 1fr; }
  .stat-card { min-height: 104px; }
  .auth-options { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media (forced-colors: active) {
  .button, .nav-item, .panel, .stat-card, .task-check, input, select, textarea { border: 1px solid ButtonText; }
  .nav-item.active, .filter-button.active { outline: 2px solid Highlight; outline-offset: -2px; }
  .workspace-kicker::before, .activity-dot { background: CanvasText; }
}

/* --------------------------------------------------------------------------
   Saadet İstanbul Premium Refinement 3.0.0
   -------------------------------------------------------------------------- */

.app-shell {
  background:
    radial-gradient(circle at 74% -8%, color-mix(in srgb, var(--color-brand-100) 62%, transparent), transparent 28%),
    radial-gradient(circle at 100% 38%, color-mix(in srgb, var(--color-accent-100) 24%, transparent), transparent 20%),
    var(--canvas);
}

.sidebar {
  border-right-color: color-mix(in srgb, var(--color-white) 10%, transparent);
  color: var(--color-white);
  background:
    radial-gradient(circle at 20% 2%, color-mix(in srgb, var(--color-brand-500) 24%, transparent), transparent 28%),
    linear-gradient(180deg, var(--color-neutral-950) 0%, var(--color-brand-900) 58%, var(--color-neutral-950) 100%);
  box-shadow: 12px 0 40px color-mix(in srgb, var(--color-neutral-950) 14%, transparent);
}

.sidebar::after {
  content: "";
  position: absolute;
  inset: 0 0 0 auto;
  width: 1px;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--color-brand-500) 52%, transparent), transparent);
  pointer-events: none;
}

.sidebar .brand { color: var(--color-white); }
.sidebar .brand small { color: color-mix(in srgb, var(--color-white) 72%, var(--color-brand-100)); }
.sidebar .brand-mark:not(.has-image) {
  color: var(--color-brand-900);
  background: var(--color-white);
  box-shadow: 0 10px 24px color-mix(in srgb, var(--color-black) 24%, transparent);
}
.sidebar .brand-mark.has-image { border-color: color-mix(in srgb, var(--color-white) 24%, transparent); }

.sidebar .nav-item {
  color: color-mix(in srgb, var(--color-white) 76%, var(--color-brand-100));
  border-color: transparent;
}
.sidebar .nav-item .nav-icon { color: color-mix(in srgb, var(--color-white) 56%, var(--color-brand-100)); }
.sidebar .nav-item:hover {
  color: var(--color-white);
  background: color-mix(in srgb, var(--color-white) 9%, transparent);
}
.sidebar .nav-item:hover .nav-icon { color: var(--color-brand-100); }
.sidebar .nav-item.active {
  color: var(--color-white);
  border-color: color-mix(in srgb, var(--color-white) 14%, transparent);
  background: linear-gradient(90deg, color-mix(in srgb, var(--color-brand-500) 34%, transparent), color-mix(in srgb, var(--color-white) 10%, transparent));
  box-shadow: inset 3px 0 0 var(--color-brand-500), 0 8px 24px color-mix(in srgb, var(--color-black) 18%, transparent);
}
.sidebar .nav-item.active .nav-icon { color: var(--color-white); }
.sidebar .nav-item.quiet { border-top-color: color-mix(in srgb, var(--color-white) 14%, transparent); }
.sidebar .nav-count { color: var(--color-white); background: var(--color-accent-700); }

.sidebar .user-card {
  border-color: color-mix(in srgb, var(--color-white) 14%, transparent);
  background: color-mix(in srgb, var(--color-white) 9%, transparent);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--color-white) 8%, transparent);
}
.sidebar .user-card strong { color: var(--color-white); }
.sidebar .user-card small { color: color-mix(in srgb, var(--color-white) 66%, var(--color-brand-100)); }
.sidebar .user-card .avatar { color: var(--color-brand-900); background: var(--color-white); }

.topbar {
  min-height: 74px;
  padding-block: 12px;
  border-bottom-color: color-mix(in srgb, var(--color-border) 78%, transparent);
  background: color-mix(in srgb, var(--color-white) 97%, transparent);
  box-shadow: 0 8px 26px color-mix(in srgb, var(--color-neutral-950) 7%, transparent);
}
.topbar h1 { font-size: 21px; }
.topbar .eyebrow { color: var(--color-brand-700); }
.topbar .date-chip { border-color: var(--color-border); background: var(--color-surface); box-shadow: var(--shadow-xs); }

.content { padding-top: var(--space-6); }

.dashboard-intro {
  position: relative;
  min-height: 142px;
  align-items: center;
  margin-bottom: var(--space-5);
  padding: var(--space-6) var(--space-8);
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--color-brand-500) 38%, var(--color-brand-900));
  border-radius: var(--radius-lg);
  color: var(--color-white);
  background:
    radial-gradient(circle at 84% 15%, color-mix(in srgb, var(--color-brand-500) 46%, transparent), transparent 24%),
    radial-gradient(circle at 64% 130%, color-mix(in srgb, var(--color-accent-600) 34%, transparent), transparent 34%),
    linear-gradient(120deg, var(--color-neutral-950), var(--color-brand-900) 58%, var(--color-brand-700));
  box-shadow: 0 24px 60px color-mix(in srgb, var(--color-brand-900) 22%, transparent), inset 0 1px 0 color-mix(in srgb, var(--color-white) 12%, transparent);
}
.dashboard-intro::after {
  content: "";
  position: absolute;
  right: -62px;
  bottom: -120px;
  width: 290px;
  height: 290px;
  border: 1px solid color-mix(in srgb, var(--color-white) 13%, transparent);
  border-radius: 50%;
  box-shadow: 0 0 0 38px color-mix(in srgb, var(--color-white) 4%, transparent), 0 0 0 76px color-mix(in srgb, var(--color-white) 3%, transparent);
  pointer-events: none;
}
.dashboard-intro-copy, .dashboard-shortcuts { position: relative; z-index: 1; }
.dashboard-intro h2 { font-size: clamp(25px, 2.2vw, 33px); letter-spacing: -1px; }
.content > .dashboard-intro h2 { color: var(--color-white); }
.dashboard-intro p { font-size: 14px; }
.content > .dashboard-intro p { color: color-mix(in srgb, var(--color-white) 84%, var(--color-brand-100)); }
.dashboard-intro .workspace-kicker { color: var(--color-brand-100); }
.dashboard-intro .workspace-kicker::before { background: var(--color-white); box-shadow: 0 0 0 4px color-mix(in srgb, var(--color-brand-500) 48%, transparent); }
.dashboard-intro .button.secondary {
  color: var(--color-white);
  border-color: color-mix(in srgb, var(--color-white) 28%, transparent);
  background: color-mix(in srgb, var(--color-white) 10%, transparent);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--color-white) 12%, transparent);
}
.dashboard-intro .button.secondary:hover { color: var(--color-white); border-color: color-mix(in srgb, var(--color-white) 46%, transparent); background: color-mix(in srgb, var(--color-white) 17%, transparent); }

.stats-grid { gap: var(--space-4); }
.stat-card {
  min-height: 128px;
  padding: var(--space-5);
  overflow: hidden;
  border-color: color-mix(in srgb, var(--color-border) 88%, var(--color-white));
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, var(--color-white), color-mix(in srgb, var(--color-surface-subtle) 72%, var(--color-white)));
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.stat-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--color-brand-500), var(--color-brand-700));
}
.stat-card.amber::before { background: linear-gradient(180deg, color-mix(in srgb, var(--color-warning-800) 54%, var(--color-white)), var(--color-warning-800)); }
.stat-card.coral::before { background: linear-gradient(180deg, var(--color-accent-600), var(--color-accent-700)); }
.stat-card.green::before { background: linear-gradient(180deg, color-mix(in srgb, var(--color-success-700) 62%, var(--color-white)), var(--color-success-700)); }
.stat-card:hover { transform: translateY(-3px); border-color: var(--color-brand-100); box-shadow: 0 18px 42px color-mix(in srgb, var(--color-neutral-950) 11%, transparent); }
.stat-icon { width: 40px; height: 40px; border-radius: 12px; box-shadow: inset 0 0 0 1px color-mix(in srgb, currentColor 10%, transparent); }
.stat-value { font-size: 32px; }

.dashboard-grid { grid-template-columns: minmax(0, 1.62fr) minmax(320px, .75fr); gap: var(--space-5); }
.stack { gap: var(--space-5); }
.panel {
  overflow: hidden;
  border-color: color-mix(in srgb, var(--color-border) 88%, var(--color-white));
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.panel-head { min-height: 72px; padding: var(--space-4) var(--space-5); background: linear-gradient(180deg, var(--color-white), color-mix(in srgb, var(--color-surface-subtle) 44%, var(--color-white))); }
.panel-head h3 { margin-top: 2px; font-size: 16px; }
.panel-kicker { color: var(--color-brand-700); }

.meeting-row, .task-row { padding: var(--space-4) var(--space-5); transition: background-color .15s ease; }
.meeting-row:hover, .task-row:hover { background: color-mix(in srgb, var(--color-brand-50) 54%, var(--color-white)); }
.task-row { grid-template-columns: auto minmax(0, 1fr); align-items: start; }
.task-row > :nth-child(2) { min-width: 0; }
.task-row > .row-actions { grid-column: 2; justify-content: flex-start; }
.row-title { overflow: visible; font-size: 13px; line-height: 1.45; text-overflow: clip; white-space: normal; }
.row-meta { line-height: 1.5; }
.date-box { box-shadow: inset 0 1px 0 var(--color-white); }

.task-row.in-progress,
.task-row.blocked {
  position: relative;
  background: var(--color-white);
}
.task-row.in-progress::before,
.task-row.blocked::before {
  content: "";
  position: absolute;
  inset: 10px auto 10px 0;
  width: 3px;
  border-radius: var(--radius-pill);
}
.task-row.in-progress::before { background: var(--color-warning-800); }
.task-row.blocked::before { background: var(--color-accent-700); }
.task-row.in-progress:hover { background: color-mix(in srgb, var(--color-warning-100) 28%, var(--color-white)); }
.task-row.blocked:hover { background: color-mix(in srgb, var(--color-accent-100) 28%, var(--color-white)); }
.task-progress-note, .task-next-action, .task-blocker-note { max-width: none; }

.progress-card {
  padding: var(--space-5);
  border-color: var(--color-brand-100);
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--color-brand-100) 74%, transparent), transparent 48%),
    var(--color-white);
}
.progress-top strong { color: var(--color-brand-700); font-size: 24px; }
.progress-track { height: 9px; box-shadow: inset 0 1px 2px color-mix(in srgb, var(--color-neutral-950) 10%, transparent); }
.progress-track i { box-shadow: 0 2px 8px color-mix(in srgb, var(--color-brand-500) 36%, transparent); }

.reminder-summary .panel-body { padding: var(--space-3); }
.reminder-row,
.reminder-row.coral,
.reminder-row.amber {
  border-color: var(--color-border);
  border-left-color: var(--color-accent-700);
  border-radius: var(--radius-md);
  background: var(--color-white);
  box-shadow: var(--shadow-xs);
}
.reminder-row:hover { border-color: var(--color-brand-100); box-shadow: var(--shadow-sm); }
.reminder-icon { border: 1px solid var(--color-brand-100); border-radius: 12px; }

.filter-button, .button, input, select, textarea { box-shadow: var(--shadow-xs); }
.button.primary { background: linear-gradient(180deg, var(--color-brand-500), var(--color-brand-600)); box-shadow: 0 7px 18px color-mix(in srgb, var(--color-brand-700) 24%, transparent), inset 0 1px 0 color-mix(in srgb, var(--color-white) 18%, transparent); }
.button.primary:hover { background: linear-gradient(180deg, var(--color-brand-600), var(--color-brand-700)); }
.modal { box-shadow: 0 34px 100px color-mix(in srgb, var(--color-neutral-950) 34%, transparent); }

.personal-note-card, .archive-card, .template-card, .settings-card { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.personal-note-card:hover, .archive-card:hover, .template-card:hover { transform: translateY(-2px); border-color: var(--color-brand-100); box-shadow: var(--shadow-sm); }

@media (max-width: 1120px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-grid > .stack:last-child { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-grid > .stack:last-child > :last-child:nth-child(odd) { grid-column: 1 / -1; }
}

@media (max-width: 840px) {
  .sidebar { box-shadow: 20px 0 70px color-mix(in srgb, var(--color-neutral-950) 42%, transparent); }
  .topbar { min-height: 68px; }
  .content { padding-top: var(--space-4); }
  .dashboard-intro { min-height: 156px; padding: var(--space-5); }
  .dashboard-grid > .stack:last-child { grid-template-columns: 1fr; }
  .dashboard-grid > .stack:last-child > * { grid-column: 1; }
}

@media (max-width: 640px) {
  .dashboard-intro { align-items: flex-start; min-height: 210px; padding: var(--space-5); }
  .dashboard-intro::after { right: -130px; bottom: -150px; }
  .dashboard-intro h2 { font-size: 26px; }
  .dashboard-shortcuts { justify-content: stretch; }
  .dashboard-shortcuts .button { flex: 1 1 130px; }
  .stats-grid { gap: var(--space-3); }
  .stat-card { min-height: 122px; padding: var(--space-4); }
  .stat-icon { width: 34px; height: 34px; }
  .stat-value { font-size: 28px; }
  .panel { border-radius: var(--radius-md); }
  .panel-head { min-height: 66px; padding: var(--space-4); }
  .task-row, .meeting-row { padding: var(--space-4); }
}

@media (max-width: 390px) {
  .dashboard-intro { min-height: 228px; }
  .stats-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .stat-card:hover, .personal-note-card:hover, .archive-card:hover, .template-card:hover { transform: none; }
}

@media (forced-colors: active) {
  .sidebar { background: Canvas; color: CanvasText; }
  .sidebar .brand, .sidebar .brand small, .sidebar .nav-item, .sidebar .nav-item .nav-icon, .sidebar .user-card strong, .sidebar .user-card small { color: CanvasText; }
  .dashboard-intro { color: CanvasText; background: Canvas; }
  .content > .dashboard-intro h2, .content > .dashboard-intro p, .dashboard-intro .workspace-kicker, .dashboard-intro .button.secondary { color: CanvasText; }
  .stat-card, .panel, .reminder-row { border: 1px solid CanvasText; }
}
