/* Media Space — warm accents on calm graphite surfaces. */
:root {
  color-scheme: dark;
  --bg: #191c24;
  --surface: #222631;
  --ink: #e9eaf0;
  --muted: #9ca5b8;
  --border: #353b49;
  --orange: #ec916e;
  --orange-dark: #d77e5b;
  --sidebar: #13161e;
  --shadow: 0 12px 45px #0002;
}
body { background: var(--bg); }
::selection { background: #a75f42; color: #fff3e8; }
input:not([type=checkbox]):not([type=radio]), select, textarea {
  background: #191e28; border-color: #3a4252; color: var(--ink);
}
input::placeholder, textarea::placeholder { color: #7f899d; }
input:hover, select:hover, textarea:hover { border-color: #66718a; }
input:disabled, select:disabled, textarea:disabled { background: #1c212b; color: #a4aec1; }
input:focus, select:focus, textarea:focus { border-color: var(--orange); outline-color: #ec916e24; }
.button.primary { background: var(--orange); color: #261c19; box-shadow: 0 3px 12px #0002; }
.button.primary:hover { background: #f3a180; }
.button.secondary, .button.subtle { background: #272d39; border-color: #41495a; color: #d6dbe6; }
.button.secondary:hover, .button.subtle:hover { background: #333b4a; color: #fff0e9; }
.button.danger-ghost { color: #eda19c; }
.button.danger-ghost:hover { color: #ffc4bd; }
.button.danger { background: #bc535a; color: white; }
.icon-button { color: #a7b0c2; }
.icon-button:hover { background: #323a49; color: #f3f4fa; }
.field-hint, .auth-subtitle, .auth-note, .optional, .profile-login { color: #a0a9bc; }
.form-error { background: #40282a; border-color: #704349; color: #ffc0ae; }
.sidebar { background: var(--sidebar); }
.workspace-badge { background: #1c212c; border-color: #303847; }
.nav-item.active { background: #372c29; color: #f2baa0; }
.nav-item.active:hover { background: #46332c; }
.nav-item:hover { background: #252c39; }
.sidebar-bottom { border-color: #2d3441; }
.sidebar-note p { color: #a9b0c1; }
.topbar { background: #1b1f29; border-color: #303744; }
.breadcrumb, .breadcrumb strong { color: #a9b2c5; }
.breadcrumb > span { color: #626c80; }
.workspace-private { color: #929db2; }
.heading-eyebrow { color: #96a0b5; }
.page-heading p { color: #a6aec1; }
.example-banner { background: #302820; border-color: #514032; color: #d6b691; }
.example-banner > button { color: #e7c2a1; }
.period-buttons .icon-button { color: #a9b2c5; }
.view-switch { background: #141923; border-color: #333b4a; }
.view-switch > button { color: #9fa9bd; }
.view-switch > button.selected { background: #343d4d; color: #f6ede8; box-shadow: 0 2px 5px #0002; }
.search-field > input { background: #222834; }
.search-field > i, .assignee-filter > i { color: #9ca9c0; }
.assignee-filter > select { background: #222834; color: #c4ccda; }
.type-chip { background: #222834; border-color: #3a4251; color: #8994aa; }
.type-integration { --type-bg:#382f25; --type-border:#594735; --type-text:#e9bd88; --type-dot:#d9a16a; --event-bg:#413426; }
.type-filming { --type-bg:#273147; --type-border:#3c4c6b; --type-text:#b4c9f4; --type-dot:#91ade3; --event-bg:#2d3a54; }
.type-editing { --type-bg:#342b43; --type-border:#514164; --type-text:#cfb2ed; --type-dot:#b697d8; --event-bg:#3b3050; }
.type-publication { --type-bg:#253a31; --type-border:#365b49; --type-text:#a4d3b8; --type-dot:#83bb9e; --event-bg:#294136; }
.type-collaboration { --type-bg:#3d2c36; --type-border:#5c414f; --type-text:#edb6cb; --type-dot:#d598b2; --event-bg:#47303e; }
.type-task { --type-bg:#2c3341; --type-border:#414b5e; --type-text:#c0cce1; --type-dot:#9baecc; --event-bg:#303b4d; }
.calendar-scroll { background: #212630; border-color: #3b4352; }
.weekday-row { background: #242a36; border-color: #394150; color: #b3bed2; }
.weekday-row > .weekend { color: #8995ad; }
.calendar-week { border-color: #343c4a; }
.day-cell { border-color: #343c4a; }
.day-cell.weekend { background: #1e242f; }
.day-cell.other-month { background: #1b202a; }
.day-cell:hover { background: #2c3039; }
.day-cell.selected-day { background: #342b29; box-shadow: inset 0 0 0 1px #b67d5e; }
.day-cell .day-number { color: #b9c3d5; }
.day-cell.other-month .day-number { color: #657087; }
.day-cell.today .day-number { color: #251c19; background: var(--orange); }
.week-day-month { color: #9ca9be; }
.calendar-event { color: var(--type-text); }
.calendar-event:hover { filter: brightness(1.16); }
.calendar-footer { color: #98a4bb; }
.agenda-panel, .team-card { border-color: #343c4a; }
.agenda-decoration { border-color: #414a5c; color: #bac4d8; }
.eyebrow { color: #9aa5bc; }
.agenda-panel > p { color: #9eaac0; }
.agenda-event { background: #222934; border-color: #394354; }
.agenda-event:hover { background: #293240; border-color: #5a6881; box-shadow: 0 4px 10px #0002; }
.agenda-event-date, .agenda-assignee { color: #a7b4cc; }
.done-badge { background: #2d4538; color: #b5d8bf; }
.progress-badge { background: #44334f; color: #d4b7e5; }
.more-events, .team-member small { color: #9eabc3; }
.agenda-reset { color: #edac8b; }
.team-card-heading .icon-button { background: #282f3c; border-color: #454e60; }
.calendar-tip { background: #252b39; }
.calendar-tip strong { color: #c2bddb; }
.calendar-tip p { color: #a5acc3; }
.agenda-empty > strong, .agenda-empty > p, .calendar-empty p, .empty-page p { color: #a6b1c8; }
.event-list-row { border-color: #343d4c; }
.event-list-row:hover { background: #29303d; }
.list-date > small, .list-event-title > small, .list-status { color: #a6b2c9; }
.list-status.in_progress { color: #d0b1e8; }
.list-status.done { color: #a5d0b8; }
.settings-info, .users-table-wrap, .role-cards article { background: #222934; border-color: #3a4455; }
.settings-info > i { background: #3a304a; color: #c8b3e4; }
.settings-info p, .role-cards p { color: #adb7ca; }
.users-table th { background: #262e3c; border-color: #3b4659; color: #aebbd2; }
.users-table td { border-color: #343e4f; }
.user-cell small { color: #9eacc6; }
.you-label { background: #333d4f; color: #b9c5db; }
.role-tag { background: #343e50; color: #c2cde0; }
.role-admin { background: #40334f; color: #d2b8e9; }
.role-editor { background: #2e3d58; color: #b6cbf1; }
.access-status { color: #acd1bb; }
.access-status.disabled { color: #c5acb3; }
.avatar { border-color: #222934; }
.topbar-right .avatar { border-color: #333b4b; }
.loading-state { color: #aab6cd; }
dialog { background: #232934; box-shadow: 0 20px 100px #0006; }
dialog::backdrop { background: #070a12a8; backdrop-filter: none; -webkit-backdrop-filter: none; }
.dialog-heading, .dialog-footer { border-color: #3a4353; }
.dialog-footer { background: #1e242e; }
.category-option { background: #1c222d; border-color: #414b5e; color: #a9b4c9; }
.permission-fieldset { border-color: #424d60; }
.permission-fieldset > p, .permission-fieldset h4 { color: #a4b0c8; }
.toggle { background: #485064; border-color: #5e6a83; }
.toggle:before { background: #e4e8f2; }
.toggle:checked { background: var(--orange); border-color: var(--orange); }
.toggle:checked:before { background: #39251c; }
.confirm-dialog .dialog-body { color: #bdc7dc; }
.toast { background: #3c4558; color: #f7f0e9; border: 1px solid #69758b; }
.auth-body { background: #151820; }
.auth-shell { background: #222732; box-shadow: 0 25px 90px #0003; }
.auth-story { background: #141922; }
.pill-label { background: #3a2c26; color: #e5b08e; }
.setup-examples { background: #1b202b; border-color: #3d475a; }
@media(max-width:620px) {
  .sidebar { border-color: #303849; }
  .auth-body { background: #222732; }
}

/* One shared calendar for both endpoints; no browser date popovers. */
.event-date-section { position: relative; }
.event-date-section > legend { font-size: 14px; margin-bottom: 17px; }
.event-date-fields { display: grid; grid-template-columns: 1fr; gap: 12px; }
.event-date-fields.has-range { grid-template-columns: 1fr 1fr; }
.date-input-wrap { position: relative; display: block; }
.date-input-wrap > i { position: absolute; top: 13px; left: 12px; color: #a9b4cb; pointer-events: none; }
.date-input-wrap svg { height: 16px; width: 16px; }
.date-input-wrap input { padding-left: 37px !important; cursor: pointer; }
.date-input-wrap input.date-active { border-color: #b97e61; background: #2f2928; }
.date-input-wrap input:disabled { cursor: default; }
.event-date-picker { margin-top: 12px; padding: 13px 14px 11px; border: 1px solid #3b4455; border-radius: 11px; background: #1b212c; }
.mini-calendar-header { display: flex; align-items: center; justify-content: space-between; gap: 7px; padding-bottom: 11px; }
.mini-month-control { display: flex; align-items: center; gap: 7px; }
.mini-month-control > strong { font-size: 15px; font-weight: 600; min-width: 119px; text-align: center; color: #e6e9f2; }
.mini-month-control .icon-button { width: 26px; height: 27px; }
.mini-month-control svg { width: 15px; height: 15px; }
.mini-today-button { font-size: 13px; color: #e9af8e; padding: 7px 8px; border: 1px solid #574538; border-radius: 6px; white-space: nowrap; }
.mini-today-button:hover { background: #3a2e27; }
.mini-weekdays, .mini-row { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); }
.mini-weekdays { margin-bottom: 5px; }
.mini-weekdays > span { text-align:center; padding: 5px 0; color: #98a6c0; font-size: 13px; }
.mini-row { padding: 2px 0; }
.mini-day { height: 33px; padding: 0; display: flex; align-items: center; justify-content: center; font-size: 14px; color: #cbd5e6; border-radius: 6px; }
.mini-day > span { height: 30px; width: 30px; display: flex; align-items: center; justify-content: center; border-radius: 6px; border: 1px solid transparent; }
.mini-day:hover:not(:disabled) > span { background: #384357; color: #fff2e9; }
.mini-day.outside-month { color: #6c7992; }
.mini-day:disabled { opacity: .65; }
.mini-day.mini-today > span { border-color: #987056; color: #edbb98; }
.mini-day.in-range { background: #49362e; color: #efd1ba; border-radius: 0; }
.mini-day.range-start { border-top-left-radius: 7px; border-bottom-left-radius: 7px; }
.mini-day.range-end { border-top-right-radius: 7px; border-bottom-right-radius: 7px; }
.mini-day.is-selected > span, .mini-day.range-start > span, .mini-day.range-end > span { background: var(--orange); border-color: var(--orange); color: #2c1d16; font-weight: 700; }
.mini-day.is-selected:hover:not(:disabled) > span, .mini-day.range-start:hover:not(:disabled) > span, .mini-day.range-end:hover:not(:disabled) > span { background: #f3a180; color: #2c1d16; }
.mini-day.range-preview.in-range:not(.range-start):not(.range-end) { background: #3c302b; }
.mini-calendar-footer { border-top: 1px solid #343e50; padding-top: 10px; margin-top: 9px; display: flex; flex-direction: column; gap: 5px; min-height: 47px; }
.mini-calendar-footer > p { font-size: 13px; color: #d3b59f; line-height: 1.5; }
.mini-calendar-footer > span { font-size: 12px; color: #94a3be; line-height: 1.5; }
@media(max-width:400px) {
  .event-date-picker { padding-left: 9px; padding-right: 9px; }
  .mini-month-control { gap: 3px; }
  .mini-month-control > strong { min-width: 105px; font-size: 14px; }
  .mini-today-button { font-size: 12px; padding: 6px; }
}

/* A floating event window: the calendar stays sharp and fully visible behind it. */
#event-dialog {
  inset: 0;
  margin: auto;
  width: 1152px;
  max-width: calc(100vw - 32px);
  height: min(960px, calc(100dvh - 48px));
  max-height: calc(100dvh - 32px);
  border: 1px solid #59657a;
  border-radius: 16px;
  box-shadow: 0 18px 65px #0008, 0 2px 10px #0005;
}
#event-dialog::backdrop { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
#event-dialog .dialog-heading { position: relative; }
#event-dialog .event-details-column, #event-dialog .event-dates-column { display:flex; flex-direction:column; gap:18px; min-width:0; }
#event-dialog .category-option { min-height:56px; }
#event-dialog .event-form-grid > .form-error { grid-column:1/-1; }
.event-footer-info { display:flex; align-items:center; gap:14px; min-width:0; }
.event-current-status { display:inline-flex; align-items:center; gap:7px; padding:6px 9px; border:1px solid #485266; border-radius:6px; font-size:13px; color:#bcc7dc; white-space:nowrap; }
.event-current-status::before { content:''; width:5px; height:5px; border-radius:50%; background:currentColor; }
.event-current-status.status-in_progress { color:#c3cfee; background:#2b3750; border-color:#4b6083; }
.event-current-status.status-done { color:#b6dbbd; background:#294134; border-color:#466a50; }
.button.progress-action { background:#2c3d56; border-color:#4b648a; color:#c4d9fb; }
.button.progress-action:hover { background:#354e72; }
.button.progress-action.finish-action { background:#2b4536; border-color:#4a7257; color:#bfe3c8; }
.button.progress-action.finish-action:hover { background:#365b43; }
.event-dialog-footer { gap:16px; flex-wrap:wrap; }
.event-dialog-footer .footer-actions { flex-wrap:wrap; justify-content:flex-end; }
@media(min-width:900px) {
  #event-dialog .event-form-grid { display:grid; grid-template-columns:minmax(0,1fr) minmax(310px,.95fr); gap:24px; align-items:start; }
  #event-dialog .event-dates-column { padding-left:24px; border-left:1px solid #3a4353; }
  #event-dialog .event-date-section > legend { margin-bottom:13px; }
}
@media(max-width:899px) {
  #event-dialog { width:660px; }
  #event-dialog .event-details-column { display:contents; }
  #event-dialog .event-title-field { order:0; }
  #event-dialog .category-fieldset { order:1; }
  #event-dialog .event-dates-column { order:2; }
  #event-dialog .event-metadata-fields { order:3; }
  #event-dialog .event-description-field { order:4; }
  #event-dialog #event-updated { order:5; }
  #event-dialog #event-form-error { order:-1; }
}
#event-dialog .dialog-heading:focus-visible { outline: 2px solid #b48368; outline-offset: -5px; border-radius: 14px 14px 0 0; }
@media(min-width:768px) {
  #event-dialog .dialog-heading { cursor: grab; user-select: none; }
  #event-dialog .dialog-heading::before {
    content: '';
    position: absolute;
    top: 9px;
    left: calc(50% - 15px);
    width: 30px;
    height: 3px;
    border-radius: 3px;
    background: #68758d;
  }
  #event-dialog.is-dragging .dialog-heading { cursor: grabbing; }
}
@media(max-width:620px) {
  #event-dialog {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
    height: calc(100dvh - 20px);
    max-height: calc(100dvh - 20px);
    border-radius: 14px;
  }
}

/* Shared tags: reusable choices, created directly in the event form. */
.calendar-filters { flex-wrap:wrap; }
.calendar-tag-filter { min-width:130px; max-width:180px; flex:1; }
.calendar-tag-filter select { padding:9px 10px; min-height:35px; font-size:14px; color:#c4ccda; background:#222834; }
.event-tags-fieldset > legend { font-size:14px; }
.event-tags-fieldset .optional { font-size:12px; margin-left:6px; }
.event-tag-chips { display:flex; flex-wrap:wrap; gap:6px; margin-bottom:8px; }
.event-tag-chips:empty { display:none; }
.event-tag-chip, .tag-pill { display:inline-flex; align-items:center; gap:5px; border:1px solid #4d5266; background:#2d3141; color:#c8c8e1; border-radius:5px; padding:4px 7px; font-size:13px; line-height:1.4; max-width:100%; overflow-wrap:anywhere; }
.event-tag-chip > button { padding:0; color:#a9abc3; display:inline-flex; align-items:center; }
.event-tag-chip > button:hover { color:#f4c6b0; }
.event-tag-chip svg { height:12px; width:12px; }
.event-tag-picker { position:relative; }
.tag-entry-row { display:flex; gap:7px; }
.tag-entry-row > input { flex:1; min-width:0; font-size:14px !important; }
.tag-create-button { width:40px; padding:9px !important; flex-shrink:0; }
.tag-create-button svg { width:16px; height:16px; }
.tag-entry-hint { margin-top:6px; font-size:12px; }
.event-tag-options { position:absolute; top:calc(100% - 15px); left:0; right:0; z-index:30; background:#282f3d; border:1px solid #59657d; border-radius:8px; box-shadow:0 8px 25px #0007; padding:4px; overflow-y:auto; scrollbar-width:thin; }
.event-tag-picker.options-above .event-tag-options { top:auto; bottom:calc(100% + 5px); }
.event-tag-options > button { display:flex; align-items:center; gap:8px; width:100%; padding:10px; text-align:left; font-size:14px; border-radius:5px; color:#d4d9e8; overflow-wrap:anywhere; }
.event-tag-options > button.active, .event-tag-options > button:hover { background:#3a4357; }
.event-tag-options > button svg { height:14px; width:14px; flex-shrink:0; }
.event-tag-options > p { font-size:13px; line-height:1.7; padding:8px; color:#a7b3cb; }
#tag-create-error { font-size:13px; margin-top:8px; }

/* Event tracker: type tabs, compact cards and independent filters. */
.tracker-controls { display:grid; grid-template-columns:minmax(190px,1fr) 170px 170px 160px; gap:12px; margin-bottom:23px; }
.tracker-controls .search-field { max-width:none; }
.tracker-controls .search-field input, .tracker-controls select { min-height:39px; font-size:14px; }
.tracker-select select { padding:10px 11px; background:#222834; color:#c7cfe0; }
.tracker-tabs { display:flex; gap:5px; border-bottom:1px solid #37404f; overflow-x:auto; scrollbar-width:thin; margin-bottom:18px; padding-bottom:1px; }
.tracker-tab { display:flex; align-items:center; justify-content:center; gap:7px; padding:13px 12px 14px; border-bottom:2px solid transparent; color:#9ca9c0; font-size:14px; white-space:nowrap; border-radius:7px 7px 0 0; }
.tracker-tab:hover { background:#242b38; color:#e1d8d1; }
.tracker-tab.selected { background:#272b36; border-bottom-color:var(--type-dot,var(--orange)); color:var(--type-text,#efb394); }
.tracker-tab-count { display:inline-flex; align-items:center; justify-content:center; min-width:19px; padding:1px 5px; border-radius:4px; background:#333b4c; font-size:12px; color:#b3bfd6; }
.tracker-tab.selected .tracker-tab-count { color:inherit; background:#ffffff09; }
.tracker-results-bar { display:flex; justify-content:space-between; align-items:center; gap:13px; margin-bottom:25px; color:#a5b0c7; font-size:14px; }
.tracker-results-bar > label { margin-left:auto; }
.tracker-results-bar select { width:auto; min-width:175px; padding:7px 10px; font-size:13px; background:#222834; color:#adb9ce; }
.tracker-results-bar .button { font-size:13px; }
.tracker-groups { display:flex; flex-direction:column; gap:29px; }
.tracker-groups.all-types { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); align-items:start; gap:26px; }
.tracker-groups.all-types .tracker-card-grid { grid-template-columns:1fr; }
.tracker-groups.all-types > .tracker-empty, .tracker-groups.all-types > .loading-state { grid-column:1/-1; }
.tracker-group-header { display:flex; align-items:center; gap:10px; margin-bottom:14px; }
.tracker-group-icon { display:inline-flex; justify-content:center; align-items:center; color:var(--type-text); background:var(--type-bg); border:1px solid var(--type-border); width:30px; height:30px; border-radius:8px; }
.tracker-group-icon svg { width:16px; height:16px; }
.tracker-group-header h2 { font-size:17px; font-weight:550; }
.tracker-group-header > span:not(.tracker-group-icon):not(.tracker-group-line) { font-size:13px; color:#94a2bb; }
.tracker-group-line { flex:1; height:1px; background:#303947; margin-left:5px; }
.tracker-card-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; }
.tracker-card { display:flex; flex-direction:column; align-items:stretch; text-align:left; padding:17px; min-width:0; border:1px solid #3b4556; border-radius:12px; background:#222934; box-shadow:0 3px 9px #0001; transition:border-color .15s,background .15s,transform .15s; }
.tracker-card:hover { border-color:var(--type-dot); background:#29323f; transform:translateY(-2px); }
.tracker-card-top { display:flex; align-items:center; justify-content:space-between; gap:7px; margin-bottom:14px; }
.tracker-card-top .category-label { font-size:12px; }
.tracker-status { display:inline-flex; align-items:center; padding:4px 6px; border-radius:4px; background:#343e50; color:#bdc9de; font-size:12px; white-space:nowrap; }
.tracker-status.status-in_progress { background:#354463; color:#bfd0f3; }
.tracker-status.status-done { background:#2b4838; color:#b8ddc1; }
.tracker-card-title { font-size:16px; line-height:1.5; font-weight:550; overflow-wrap:anywhere; }
.tracker-card-description { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; min-height:48px; font-size:14px; line-height:1.65; color:#a4b0c7; margin:9px 0 10px; white-space:pre-line; overflow-wrap:anywhere; }
.tracker-card-description.no-description { color:#7d8aa3; font-style:italic; }
.tracker-card-tags { display:flex; flex-wrap:wrap; align-items:center; gap:5px; margin-bottom:13px; }
.tracker-card-tags:empty { margin-bottom:0; }
.tracker-card-tags .tag-pill { font-size:12px; padding:3px 6px; }
.tag-overflow { font-size:13px; color:#a4b0c8; }
.tracker-card-date { display:flex; align-items:flex-start; gap:7px; padding-top:11px; margin-top:auto; border-top:1px solid #364153; color:#b4c1d8; font-size:13px; line-height:1.65; }
.tracker-card-date > svg { width:14px; height:14px; margin-top:1px; flex-shrink:0; color:#91a0bb; }
.tracker-card-bottom { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-top:12px; font-size:13px; }
.tracker-card-assignee { display:flex; align-items:center; gap:6px; color:#b1bed5; min-width:0; overflow-wrap:anywhere; }
.tracker-card-assignee .mini-avatar { width:20px; height:20px; font-size:12px; flex-shrink:0; }
.tracker-unassigned { color:#7e8ca5; font-size:12px; }
.tracker-card-open { display:flex; align-items:center; gap:3px; color:#8f9cb4; font-size:12px; flex-shrink:0; }
.tracker-card-open > svg { width:12px; height:12px; }
.tracker-card-done .tracker-card-title { color:#a8b5c9; text-decoration:line-through; }
.tracker-pagination { display:flex; align-items:center; justify-content:center; gap:16px; margin-top:28px; color:#8f9eb7; font-size:13px; }
.tracker-empty { text-align:center; padding:70px 25px; border:1px dashed #3d485d; border-radius:13px; }
.tracker-empty > svg { width:34px; height:34px; color:#a398b5; margin:0 auto 18px; }
.tracker-empty > h2 { font-size:23px; font-weight:500; }
.tracker-empty > p { font-size:15px; line-height:1.8; color:#a1aec6; margin:13px 0 22px; }
@media(min-width:1700px) { .tracker-card-grid { grid-template-columns:repeat(4,minmax(0,1fr)); } .tracker-groups.all-types { grid-template-columns:repeat(3,minmax(0,1fr)); } }
@media(max-width:1250px) { .tracker-controls { grid-template-columns:minmax(175px,1fr) repeat(3,minmax(120px,145px)); } .tracker-card-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:1000px) { .tracker-controls { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:620px) {
  .tracker-controls { gap:9px; margin-bottom:16px; }
  .tracker-controls .search-field { grid-column:1/-1; }
  .tracker-controls .tracker-select:last-child { grid-column:1/-1; }
  .tracker-tabs { gap:2px; margin-bottom:14px; }
  .tracker-tab { padding:11px 9px; font-size:13px; }
  .tracker-results-bar { flex-wrap:wrap; margin-bottom:20px; font-size:13px; }
  .tracker-results-bar > label { margin-left:auto; }
  .tracker-results-bar select { font-size:12px; min-width:160px; }
  .tracker-card-grid { grid-template-columns:1fr; gap:11px; }
  .tracker-groups.all-types { grid-template-columns:1fr; gap:22px; }
  .tracker-card { padding:16px; }
  .tracker-card-title { font-size:16px; }
  .tracker-card-top .category-label { font-size:13px; }
  .tracker-status { font-size:12px; }
  .tracker-card-description { min-height:0; font-size:14px; }
  .tracker-card-bottom { font-size:13px; }
  .tracker-pagination { flex-direction:column; gap:11px; }
  .calendar-tag-filter select { font-size:13px; }
  #event-dialog .event-tags-fieldset { order:2; }
  #event-dialog .event-dates-column { order:3; }
  #event-dialog .event-metadata-fields { order:4; }
  #event-dialog .event-description-field { order:5; }
  #event-dialog #event-updated { order:6; }
}
@media(min-width:621px) and (max-width:899px) {
  #event-dialog .event-tags-fieldset { order:2; }
  #event-dialog .event-dates-column { order:3; }
  #event-dialog .event-metadata-fields { order:4; }
  #event-dialog .event-description-field { order:5; }
  #event-dialog #event-updated { order:6; }
}
#event-dialog .event-description-field textarea { min-height:180px; }
.event-materials-fieldset { margin-top:7px; padding-top:20px; border-top:1px solid var(--border); }
.event-materials-fieldset legend { font-size:14px; float:left; width:100%; margin-bottom:12px; }
.event-materials-fieldset .optional { font-size:12px; margin-left:6px; }
.event-material-chips { clear:both; display:flex; flex-direction:column; gap:7px; margin-bottom:9px; }
.event-material-chip { display:flex; gap:6px; align-items:center; border:1px solid #444d60; border-radius:7px; background:#2a303c; }
.event-material-chip > button:first-child { display:flex; flex:1; min-width:0; gap:8px; padding:9px; text-align:left; font-size:14px; color:#d2d9e9; }
.event-material-chip > button:first-child span { overflow-wrap:anywhere; }
.event-material-chip > button:last-child:not(:first-child) { padding:8px; }
.event-material-chip svg { width:15px; height:15px; flex-shrink:0; }
.event-material-chip button:hover { color:var(--orange); }
.material-picker { position:relative; }
.material-options { position:absolute; z-index:5; top:calc(100% + 5px); width:100%; max-height:210px; overflow:auto; border:1px solid #58647a; border-radius:9px; background:#272e3b; box-shadow:0 10px 30px #0006; padding:5px; }
.material-options.opens-above { top:auto; bottom:calc(100% + 5px); }
.material-options > button { width:100%; display:flex; align-items:center; gap:9px; text-align:left; padding:10px; font-size:15px; border-radius:5px; }
.material-options > button.highlighted,.material-options > button:hover { background:#394154; color:#ffe1cd; }
.material-options > button svg { width:16px; flex-shrink:0; }
.material-options p { font-size:14px; line-height:1.6; padding:9px; color:#adb8ce; }
.event-materials-fieldset > .field-hint { margin-top:8px; }
.materials-layout { display:grid; grid-template-columns:270px minmax(0,1fr); border:1px solid var(--border); border-radius:14px; overflow:hidden; min-height:630px; }
.materials-library { padding:20px 14px; border-right:1px solid var(--border); background:#181d27; }
.material-library-heading { display:flex; justify-content:space-between; color:#929db2; font-size:13px; letter-spacing:1.2px; padding:0 8px 18px; }
.materials-library .search-field { margin-bottom:14px; }
.materials-library .search-field input { font-size:14px; }
.material-list { display:flex; flex-direction:column; gap:6px; }
.material-list-item { display:flex; gap:11px; width:100%; padding:14px 11px; text-align:left; border:1px solid transparent; border-radius:9px; }
.material-list-item > svg { color:#8999b5; width:17px; height:19px; margin-top:1px; }
.material-list-item > span { min-width:0; display:flex; flex-direction:column; gap:7px; }
.material-list-item strong { font-size:15px; line-height:1.5; overflow-wrap:anywhere; }
.material-list-item small { color:#919db3; font-size:14px; line-height:1.6; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.material-list-item time { color:#7d8a9f; font-size:13px; }
.material-list-item:hover { background:#242b37; }
.material-list-item.selected { background:#342d2c; border-color:#5c473e; }
.material-list-item.selected > svg { color:var(--orange); }
.material-library-empty { font-size:15px; line-height:1.8; padding:18px 8px; color:#929eb5; }
#material-more { width:100%; margin-top:14px; }
.material-workspace { min-width:0; background:#202530; }
.material-empty { display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; padding:90px 25px; gap:18px; min-height:580px; }
.material-empty > i { padding:20px; border-radius:16px; background:#302e36; color:var(--orange); }
.material-empty > i svg { width:32px; height:32px; }
.material-empty h2 { font-weight:550; font-size:26px; letter-spacing:-.6px; }
.material-empty p { color:#a4aec1; font-size:16px; line-height:1.8; }
.material-document-bar { display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:12px; padding:16px 24px; border-bottom:1px solid var(--border); background:#242a36; }
.material-document-bar > span { color:#a7b3ca; font-size:14px; }
.material-document-bar > div { display:flex; align-items:center; gap:18px; }
#material-form-error { margin:16px 24px 0; }
.material-paper { padding:40px clamp(24px,4vw,72px) 52px; max-width:1120px; margin:0 auto; }
.material-document-icon { color:#ddb69a; margin-bottom:18px; }
.material-document-icon svg { height:33px; width:33px; }
#material-title { font-size:clamp(27px,2.2vw,38px); font-weight:650; letter-spacing:-1.1px; min-height:55px; padding:0; border:0; border-radius:0; background:transparent; box-shadow:none; resize:none; line-height:1.3; overflow:hidden; }
#material-title:focus { outline:0; }
#material-title:focus-visible { border-bottom:1px solid #966f59; }
#material-title::placeholder { color:#768196; }
.material-byline { font-size:13px; color:#8694ab; margin:12px 0 32px; }
.material-blocks { display:flex; flex-direction:column; gap:22px; min-width:0; }
.material-block { position:relative; min-width:0; padding-top:27px; }
.material-block-tools { display:flex; align-items:center; gap:4px; position:absolute; top:0; left:0; opacity:.55; }
.material-block:hover .material-block-tools,.material-block:focus-within .material-block-tools { opacity:1; }
.material-block-tools select { border:0; padding:3px 5px; font-size:13px; background:#2a303d; width:auto; max-width:185px; border-radius:4px; }
.material-block-tools button { display:flex; align-items:center; justify-content:center; width:23px; height:23px; border-radius:4px; color:#9eabc2; font-size:16px; }
.material-block-tools button:hover { background:#3a4353; color:#ffe1cf; }
.material-block-tools svg { width:13px; height:13px; }
.material-text-wrap { display:flex; align-items:flex-start; gap:10px; }
.material-text-wrap > span { padding-top:7px; color:#bfc8da; }
.material-text-wrap input[type=checkbox] { accent-color:var(--orange); margin-top:10px; width:16px; height:16px; flex-shrink:0; }
.material-text-wrap:has(input:checked) textarea { text-decoration:line-through; color:#8c9aaf; }
.material-block textarea.material-block-text { border:0; border-radius:3px; padding:5px 0; min-height:34px; background:transparent; color:#d4dbe8; resize:none; overflow:hidden; font-size:16px; line-height:1.8; font-weight:400; }
.material-block textarea.material-block-text:focus { outline:1px solid #56617a; outline-offset:5px; }
.material-text-wrap.type-h1 textarea { font-size:31px; font-weight:600; line-height:1.4; letter-spacing:-.6px; color:#f0f0f5; }
.material-text-wrap.type-h2 textarea { font-size:25px; font-weight:600; line-height:1.45; color:#e8eaf1; }
.material-text-wrap.type-h3 textarea { font-size:20px; font-weight:600; line-height:1.5; color:#e2e5ee; }
.material-text-wrap.type-quote { border-left:3px solid #bd8869; padding-left:18px; }
.material-block hr,.material-read-block hr { border:0; border-top:1px solid #465064; margin:10px 0; }
.material-add-block { display:flex; flex-wrap:wrap; gap:10px; padding-top:28px; margin-top:28px; border-top:1px dashed #414b5f; }
.material-add-block > select { width:auto; max-width:100%; font-size:14px; padding:8px 10px; }
.material-table-scroll { overflow:auto; border:1px solid #424c60; border-radius:8px; }
.material-table { width:100%; border-collapse:collapse; table-layout:fixed; min-width:380px; font-size:15px; }
.material-table th,.material-table td { border-right:1px solid #424c60; border-bottom:1px solid #424c60; padding:10px 12px; min-width:115px; vertical-align:top; overflow-wrap:anywhere; white-space:pre-wrap; }
.material-table th { background:#2c3342; color:#dce3ee; text-align:left; position:relative; }
.material-table th:last-child,.material-table td:last-child { border-right:0; }
.material-table tbody tr:last-child td { border-bottom:0; }
.material-table input,.material-table textarea { border:0!important; border-radius:0!important; padding:0!important; background:transparent!important; font-size:15px!important; line-height:1.7; min-height:22px; resize:none; overflow:hidden; }
.material-table th input { padding-right:15px!important; font-weight:600; }
.material-table th > button { position:absolute; right:2px; top:7px; color:#8d9cb3; }
.material-table .table-row-action { width:28px; min-width:28px; padding:10px 3px; }
.table-row-action button { color:#8998b1; }
.material-table-actions { display:flex; gap:15px; padding-top:10px; color:#b6c1d7; font-size:14px; }
.material-table-actions button:hover { color:var(--orange); }
.material-read-block { color:#d4dce9; font-size:16px; line-height:1.85; overflow-wrap:anywhere; }
.material-read-block p,.material-read-block h1,.material-read-block h2,.material-read-block h3,.material-read-block blockquote { white-space:pre-wrap; }
.material-read-block h1 { font-size:31px; font-weight:600; }
.material-read-block h2 { font-size:25px; font-weight:600; }
.material-read-block h3 { font-size:20px; font-weight:600; }
.material-read-block ul,.material-read-block ol { margin:0; padding-left:25px; }
.material-read-block blockquote { border-left:3px solid #bd8869; margin:0; padding-left:18px; }
.material-read-check { display:flex; gap:12px; }
.material-read-check.checked { color:#8f9cb0; text-decoration:line-through; }
@media(max-width:1100px) {
  .materials-layout { grid-template-columns:230px minmax(0,1fr); }
  .material-paper { padding:30px 24px 40px; }
}
@media(max-width:800px) {
  .materials-layout { grid-template-columns:1fr; }
  .materials-library { border-right:0; border-bottom:1px solid var(--border); max-height:275px; overflow:auto; }
  .material-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
  .material-list-item small { display:none; }
  .material-library-heading { padding-bottom:12px; }
  .material-empty { min-height:350px; padding:45px 20px; }
}
@media(max-width:620px) {
  .material-paper { padding:26px 17px 35px; }
  .material-document-bar { padding:14px 17px; }
  .material-block-tools { opacity:1; }
  .material-add-block { flex-direction:column; }
  .material-list { grid-template-columns:1fr; }
}
/* Readable type and a compact, draggable event header. */
#event-dialog { width:1280px; height:min(1120px,calc(100dvh - 48px)); }
#event-dialog .dialog-heading { display:grid; grid-template-columns:205px minmax(0,1fr) 36px; gap:18px; padding:28px 28px 22px; }
#event-dialog .event-heading-copy { min-width:0; }
#event-dialog .event-heading-copy h2 { font-size:24px; line-height:1.25; margin-top:7px; }
#event-dialog .event-heading-copy .eyebrow { font-size:12px; letter-spacing:.8px; line-height:1.5; }
#event-dialog .event-type-header { min-width:0; }
#event-dialog .event-type-header .category-options { display:flex; align-items:stretch; flex-wrap:wrap; gap:8px; }
#event-dialog .event-type-header .category-option { flex:1; flex-direction:row; gap:7px; min-height:42px; padding:9px 10px; white-space:nowrap; font-size:14px!important; cursor:pointer; }
#event-dialog .event-type-header .category-option svg { width:18px; height:18px; }
#event-dialog .event-type-header .category-option:has(input:disabled) { cursor:default; }
#event-dialog .dialog-heading > .icon-button { width:36px; height:36px; align-self:center; }
#event-dialog .dialog-body { padding:24px 28px; }
#event-dialog .dialog-body label,#event-dialog legend { font-size:14px; }
#event-dialog .dialog-body input,#event-dialog .dialog-body select,#event-dialog .dialog-body textarea { font-size:15px; }
#event-dialog .event-details-column,#event-dialog .event-dates-column { gap:19px; }
#event-dialog .event-description-field textarea { min-height:200px; }
#event-dialog .dialog-footer .button { min-height:44px; font-size:14px; padding:10px 15px; }
#event-dialog .event-current-status { font-size:13px; }
#event-dialog .event-date-picker { padding:14px 16px 12px; }
#event-dialog .mini-month-control > strong { min-width:145px; font-size:16px; }
#event-dialog .mini-month-control .icon-button { width:30px; height:30px; }
#event-dialog .mini-weekdays > span { font-size:13px; padding:6px 0; }
#event-dialog .mini-day { height:37px; font-size:14px; }
#event-dialog .mini-day > span { width:34px; height:34px; }
#event-dialog .mini-calendar-footer > p { font-size:13px; }
#event-dialog .mini-calendar-footer > span { font-size:12px; }
#event-dialog .mini-today-button { font-size:13px; }
#event-dialog .event-materials-fieldset legend { margin-bottom:10px; }
#event-dialog .event-material-chip > button:first-child { font-size:14px; }
#event-dialog .event-tag-chip { font-size:13px; }
.tracker-group-add { width:36px; height:36px; border:1px solid #4b566b; background:#29313e; color:#bac7df; }
.tracker-group-add:hover { color:var(--type-text); border-color:var(--type-dot); background:var(--type-bg); }
.tracker-group-add svg { width:18px; height:18px; }
.tracker-group-header { min-height:38px; }
.tracker-results-bar select { min-width:260px; }
.tracker-status { padding:5px 8px; }
.tracker-card-top { flex-wrap:wrap; }
.tracker-card-description { min-height:69px; }
.tracker-card-assignee .mini-avatar { width:26px; height:26px; }
.calendar-event { min-height:24px; line-height:20px; }
@media(min-width:1600px) {
  .sidebar { width:280px; padding-left:25px; padding-right:25px; }
  .app-main { margin-left:280px; }
  .calendar-layout { grid-template-columns:minmax(0,1fr) 320px; }
  .calendar-week { min-height:150px!important; }
}
@media(max-width:1120px) {
  #event-dialog .dialog-heading { grid-template-columns:minmax(0,1fr) 36px; gap:16px; padding-top:26px; }
  #event-dialog .event-type-header { grid-column:1/-1; grid-row:2; }
  #event-dialog .dialog-heading > .icon-button { grid-column:2; grid-row:1; }
  #event-dialog .event-type-header .category-options { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media(max-width:899px) {
  #event-dialog { width:700px; }
  #event-dialog .event-type-header { order:initial; }
}
@media(max-width:620px) {
  #event-dialog { width:calc(100vw - 20px); height:calc(100dvh - 20px); }
  #event-dialog .dialog-heading { padding:22px 17px 16px; gap:12px; }
  #event-dialog .event-heading-copy h2 { font-size:22px; }
  #event-dialog .event-heading-copy .eyebrow { font-size:12px; letter-spacing:.3px; }
  #event-dialog .event-type-header .category-options { gap:6px; }
  #event-dialog .event-type-header .category-option { font-size:12px!important; min-height:40px; padding:7px 5px; gap:5px; }
  #event-dialog .event-type-header .category-option svg { width:14px; height:14px; }
  #event-dialog .dialog-body { padding:20px 17px; }
  #event-dialog .dialog-footer { padding:15px 17px; }
  #event-dialog .dialog-footer .button { font-size:13px; padding:9px 11px; }
  #event-dialog .event-footer-info { flex-wrap:wrap; gap:8px; }
  #event-dialog .event-date-fields.has-range { gap:9px; }
  #event-dialog .date-input-wrap input { padding-left:30px!important; font-size:14px; }
  #event-dialog .date-input-wrap > i { left:9px; }
  #event-dialog .event-date-picker { padding:12px 9px; }
  #event-dialog .mini-month-control { gap:3px; }
  #event-dialog .mini-month-control > strong { min-width:120px; font-size:14px; }
  #event-dialog .mini-month-control .icon-button { width:24px; height:27px; }
  #event-dialog .mini-today-button { font-size:12px; padding:6px; }
  .tracker-results-bar select { min-width:0; max-width:100%; }
  .tracker-card-assignee { font-size:13px; }
  .tracker-card-bottom { align-items:flex-start; }
}

.week-events { grid-auto-rows:32px; }
.calendar-event { min-height:32px; padding:5px 7px; }
#event-dialog .dialog-heading { grid-template-columns:220px minmax(0,1fr) 36px; }
#event-dialog .event-heading-copy .eyebrow { white-space:nowrap; letter-spacing:.4px; }
#event-dialog .dialog-body { flex:1; }
@media(max-width:1120px) { #event-dialog .dialog-heading { grid-template-columns:minmax(0,1fr) 36px; } }
@media(max-width:620px) { #event-dialog .event-heading-copy .eyebrow { white-space:normal; } }
/* Keep navigation and account actions accessible with the larger type. */
@media(min-width:801px) {
  .sidebar { overflow-y:auto; overflow-x:hidden; scrollbar-width:thin; }
  .sidebar nav,.sidebar-bottom { flex-shrink:0; }
}
@media(min-width:801px) and (max-width:1599px) {
  .sidebar { width:260px; padding-left:19px; padding-right:19px; }
  .app-main { margin-left:260px; }
  .toast { left:calc(50% + 130px); }
}
@media(min-width:801px) and (max-height:900px) {
  .sidebar-note { display:none; }
  .sidebar-bottom { margin-top:auto; }
}
/* Materials open as finished articles; editing is an explicit mode. */
.material-article-title { font-size:clamp(28px,2.2vw,38px); font-weight:650; letter-spacing:-.9px; line-height:1.3; overflow-wrap:anywhere; }
#material-editor:not(.is-editing) .material-document-bar { background:transparent; }
#material-editor:not(.is-editing) .material-paper { padding-top:38px; }
#material-editor:not(.is-editing) .material-blocks { gap:22px; }
#material-editor:not(.is-editing) .material-read-block h1,#material-editor:not(.is-editing) .material-read-block h2,#material-editor:not(.is-editing) .material-read-block h3 { margin-top:14px; }
#material-editor.is-editing .material-block { border:1px solid #46536a; border-radius:9px; padding:44px 16px 15px; background:#232b38; }
#material-editor.is-editing .material-block:focus-within { border-color:#b78b70; box-shadow:0 0 0 2px #b78b7014; }
#material-editor.is-editing .material-block-tools { top:9px; left:12px; opacity:1; }
.material-rich-text { width:100%; min-width:0; min-height:28px; line-height:1.8; font-size:16px; white-space:pre-wrap; overflow-wrap:anywhere; outline:none; font-weight:400; color:#d4dbe8; cursor:text; }
.material-rich-text:empty:before { content:attr(data-placeholder); color:#8491a9; pointer-events:none; }
.material-rich-text[aria-readonly=true] { cursor:default; opacity:.75; }
.material-text-wrap .material-rich-text { padding:4px 0; }
.material-text-wrap.type-h1 .material-rich-text { font-size:31px; font-weight:600; line-height:1.4; letter-spacing:-.6px; }
.material-text-wrap.type-h2 .material-rich-text { font-size:25px; font-weight:600; line-height:1.45; }
.material-text-wrap.type-h3 .material-rich-text { font-size:20px; font-weight:600; line-height:1.5; }
.material-text-wrap:has(input:checked) .material-rich-text { text-decoration:line-through; color:#8c9aaf; }
.material-table .material-rich-text { font-size:15px; line-height:1.7; }
.material-inline-link { color:#edb492; text-decoration:underline; text-decoration-color:#a57864; text-underline-offset:3px; cursor:pointer; }
.material-inline-link:hover { color:#ffcfb5; text-decoration-color:currentColor; }
.material-inline-link:focus-visible { outline:2px solid var(--orange); outline-offset:3px; border-radius:3px; }
.event-material-chip > a { display:flex; align-items:center; flex:1; min-width:0; gap:8px; padding:9px; font-size:14px; color:#d2d9e9; }
.event-material-chip > a > span:not(.material-link-arrow) { overflow-wrap:anywhere; }
.event-material-chip > a:hover { color:var(--orange); background:#333b4a; border-radius:7px; }
.material-link-arrow { margin-left:auto; flex-shrink:0; color:#9daec8; }
@media(max-width:620px) { #material-editor.is-editing .material-block { padding:44px 12px 14px; } .material-document-bar > div { flex-wrap:wrap; gap:10px; } }
/* Material tags have their own catalog, filters and editing controls. */
.material-tag-filter-bar { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin:-3px 0 14px; }
.material-tag-filter-search { position:relative; width:260px; flex-shrink:0; }
.material-tag-filter-search .search-field { max-width:none; }
.material-tag-filter-search input { font-size:14px; min-height:42px; }
.material-tag-quick,.material-tags-expanded { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.material-tag-quick { flex:1; min-width:0; }
.material-filter-tag { display:inline-flex; align-items:center; gap:8px; border:1px solid #41495e; border-radius:7px; background:#222936; color:#b4c0d6; padding:9px 12px; font-size:14px; line-height:1.4; overflow-wrap:anywhere; text-align:left; }
.material-filter-tag > span { font-size:12px; color:#9aabc5; background:#313b4e; padding:1px 5px; border-radius:4px; }
.material-filter-tag:hover { background:#303b4f; border-color:#7e89a0; }
.material-filter-tag.selected { background:#3b302c; color:#efbd9e; border-color:#987157; }
.material-filter-tag.selected > span { color:#f1c4ab; background:#584237; }
#material-tags-more { min-width:42px; min-height:42px; font-size:20px; }
.material-tags-expanded { background:#202632; border:1px solid #3c465a; border-radius:10px; padding:13px; margin:0 0 16px; }
.material-tag-filter-search .material-options { top:calc(100% + 6px); }
.material-tag-filter-search .material-options > button { justify-content:space-between; font-size:14px; }
.material-tag-filter-search .material-options small { font-size:12px; color:#9caac1; }
.material-tags-fieldset { margin:-8px 0 28px; }
.material-tags-fieldset legend { font-size:13px; color:#a4b1c7; margin-bottom:11px; }
#material-editor:not(.is-editing) .material-tags-fieldset legend { display:none; }
.material-tag-chips { display:flex; flex-wrap:wrap; gap:7px; margin-bottom:10px; }
.material-tag-chips:empty { display:none; }
.material-document-tag { display:inline-flex; align-items:center; gap:7px; padding:5px 9px; background:#30354a; border:1px solid #4f5974; color:#c7d2ed; border-radius:6px; font-size:13px; overflow-wrap:anywhere; }
.material-document-tag button { display:flex; padding:1px; color:#b6c0d8; }
.material-document-tag button:hover { color:var(--orange); }
.material-document-tag button svg { width:13px; height:13px; }
.material-tag-picker { position:relative; max-width:560px; }
.material-tag-picker .tag-entry-row input { font-size:14px!important; }
.material-tag-picker .field-hint { margin-top:8px; font-size:13px; }
#material-tag-error { margin-top:10px; }
.material-library-tags { display:flex; flex-wrap:wrap; gap:5px; font-size:12px; color:#b6c4e3; }
.material-library-tags > span { background:#30384a; padding:2px 5px; border-radius:4px; overflow-wrap:anywhere; }
/* Workspace settings are separate from personal profile settings. */
.settings-tag-search { max-width:440px; margin:24px 0; }
.tag-settings-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.tag-settings-card { background:#222934; border:1px solid #3c475a; border-radius:12px; min-width:0; overflow:hidden; }
.tag-settings-heading { display:flex; align-items:center; gap:14px; border-bottom:1px solid #3b4657; padding:24px; }
.tag-settings-heading > i { padding:11px; border:1px solid #4d566c; background:#2e3444; border-radius:9px; color:#cfbcae; }
.tag-settings-heading h2 { font-size:20px; font-weight:550; }
.tag-settings-heading p { font-size:13px; color:#a6b1c7; margin-top:7px; line-height:1.6; }
.tag-settings-heading > span { margin-left:auto; background:#333e51; border-radius:5px; padding:5px 8px; color:#b7c5df; font-size:13px; }
.tag-setting-row { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:18px 24px; border-bottom:1px solid #333e50; }
.tag-setting-row:last-child { border-bottom:0; }
.tag-setting-row > div { min-width:0; }
.tag-setting-row strong { font-size:15px; overflow-wrap:anywhere; }
.tag-setting-row small { display:block; color:#97a6c1; font-size:13px; margin-top:7px; }
.tag-setting-row .button { font-size:13px; flex-shrink:0; }
.tag-setting-row .button svg { height:15px; width:15px; }
.tag-setting-empty { padding:28px 24px; font-size:14px; color:#a4b0c8; }
@media(max-width:1100px) { .tag-settings-grid { grid-template-columns:1fr; } }
@media(max-width:620px) {
  .material-tag-filter-search { width:100%; }
  .material-tag-quick { gap:6px; }
  .material-filter-tag { font-size:13px; padding:8px 10px; }
  .tag-settings-heading,.tag-setting-row { padding:18px; }
  .tag-settings-heading h2 { font-size:18px; }
  .tag-setting-row { gap:10px; }
  .tag-setting-row .button { font-size:12px; }
}
@media(max-width:620px) {
  .sidebar .brand-name { display:none; }
  .sidebar .brand { margin-right:6px; }
  .sidebar nav { margin-left:auto; gap:5px; }
  .sidebar-bottom { flex-shrink:0; }
}
.tag-settings-grid { align-items:start; }
/* Event reminders and personal Telegram connection. */
.event-reminder-section { padding:17px 18px; border:1px solid #414d62; border-radius:9px; background:#202733; }
#event-dialog .event-reminder-section .checkbox-label { font-size:14px; font-weight:600; align-items:center; }
#event-reminder-options { margin-top:15px; }
.reminder-mode-options { display:flex; gap:8px; margin-bottom:13px; }
.reminder-mode { display:flex; flex:1; position:relative; align-items:center; justify-content:center; border:1px solid #45536b; border-radius:7px; padding:10px; cursor:pointer; font-weight:500; text-align:center; }
.reminder-mode input { position:absolute; opacity:0; width:1px; height:1px; }
.reminder-mode:has(input:checked) { border-color:#ba876b; background:#45362f; color:#f2c6aa; }
.reminder-mode:has(input:focus-visible) { outline:2px solid var(--orange); outline-offset:2px; }
.reminder-mode:has(input:disabled) { cursor:default; }
.reminder-time-label { display:grid!important; grid-template-columns:auto 145px; align-items:center; justify-content:space-between; gap:12px; }
.event-reminder-section .field-hint { margin-top:11px; font-size:12px; line-height:1.6; }
.telegram-profile-section { border:1px solid #455066; border-radius:10px; padding:18px; background:#1f2632; }
.telegram-section-heading { display:flex; align-items:center; gap:12px; margin-bottom:18px; }
.telegram-section-heading > i { background:#343b50; color:#cfb5a2; border-radius:8px; padding:10px; flex-shrink:0; }
.telegram-section-heading h2 { font-size:21px; font-weight:550; }
.telegram-section-heading h3 { font-size:16px; }
.telegram-section-heading p { color:#9eacc5; font-size:13px; line-height:1.6; margin-top:6px; }
#telegram-link-fields { display:flex; flex-direction:column; gap:13px; }
#telegram-link-fields .button { align-self:flex-start; font-size:13px; }
#telegram-profile-error { margin-bottom:14px; }
.telegram-linked-actions { display:flex; gap:12px; align-items:center; flex-wrap:wrap; }
.telegram-linked-actions .button { font-size:13px; }
.telegram-settings-card { padding:24px; margin-bottom:28px; border:1px solid #414c60; border-radius:12px; background:#222934; }
.telegram-settings-card .field-row { gap:22px; }
.telegram-settings-card form > .field-hint { margin-top:12px; font-size:13px; }
.telegram-settings-card .telegram-section-heading { flex-wrap:wrap; }
.telegram-worker-status { margin-left:auto; padding:7px 10px; background:#3a3540; color:#c7bdca; border-radius:6px; font-size:13px; }
.telegram-worker-status.connected { background:#2b4437; color:#b7d7c4; }
.telegram-settings-footer { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-top:20px; }
.telegram-settings-footer > span { font-size:13px; color:#a8b7d0; line-height:1.7; }
#telegram-settings-error { margin-bottom:18px; }
@media(max-width:899px) {
  #event-dialog .event-reminder-section { order:6; }
  #event-dialog #event-updated { order:7; }
}
@media(max-width:620px) {
  .telegram-settings-card { padding:18px; }
  .telegram-settings-card .field-row { grid-template-columns:1fr; gap:16px; }
  .telegram-settings-footer { align-items:flex-start; flex-direction:column; }
  .telegram-worker-status { margin-left:0; }
  .event-reminder-section { padding:15px; }
}
