@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,700;0,900;1,700&family=DM+Sans:wght@300;400;500;600;700&family=DM+Mono:wght@400;500&display=swap');

:root {
  --blue-950: #04101f;
  --blue-900: #071428;
  --blue-800: #0c1f44;
  --blue-700: #153580;
  --blue-600: #1a47ba;
  --blue-500: #2260f5;
  --blue-400: #5585f8;
  --blue-300: #89aefb;
  --blue-200: #c4d8fd;
  --blue-100: #e4edfe;
  --blue-50: #f0f5ff;
  --white: #ffffff;
  --off: #f8faff;
  --ink: #0b1422;
  --ink-2: #243451;
  --ink-3: #556880;
  --ink-4: #96acbf;
  --border: #dae5f4;
  --border-s: #edf4fb;
  --green: #0d9f57;
  --green-l: #d4f5e5;
  --amber: #d97706;
  --amber-l: #fef3c7;
  --red: #d42a2a;
  --red-l: #fde8e8;
  --sidebar-w: 240px;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  --f-display: 'Playfair Display', Georgia, serif;
  --f-sans: 'DM Sans', system-ui, sans-serif;
  --f-mono: 'DM Mono', monospace;

  --shadow-sm: 0 1px 3px rgba(4, 16, 31, 0.07), 0 1px 2px rgba(4, 16, 31, 0.04);
  --shadow-md: 0 4px 12px rgba(4, 16, 31, 0.08), 0 2px 6px rgba(4, 16, 31, 0.05);
  --shadow-lg: 0 12px 32px rgba(4, 16, 31, 0.1), 0 4px 12px rgba(4, 16, 31, 0.06);
  --shadow-glow: 0 0 0 3px rgba(34, 96, 245, 0.12);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body.mn-standalone-page {
  font-family: var(--f-sans);
  background: var(--off);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

.mn-standalone-root {
  width: 100%;
}

.mn-committee-control {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--blue-950);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  border-right: 1px solid rgba(255, 255, 255, 0.04);
  background-image: none !important;
}

.sidebar-header {
  padding: 1.3rem 1.3rem 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.committee-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.committee-avatar {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--f-mono);
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: none !important;
  overflow: hidden;
}

.committee-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  line-height: 1;
}

.committee-avatar.has-image .avatar-fallback,
.user-avatar.has-image .avatar-fallback,
.avatar-preview.has-image .avatar-fallback {
  display: none;
}

.committee-name {
  font-weight: 700;
  font-size: 0.88rem;
  color: #fff;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.committee-sub {
  font-size: 0.62rem;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 2px;
  font-family: var(--f-mono);
  letter-spacing: 0.04em;
}

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 0.85rem 0;
}

.nav-section-label {
  padding: 0.7rem 1.3rem 0.3rem;
  font-size: 0.56rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.2);
  font-family: var(--f-mono);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 1.3rem;
  margin: 1px 0.65rem;
  border-radius: var(--radius-sm);
  font-size: 0.81rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
  position: relative;
}

.nav-item:hover {
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.06);
}

.nav-item.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: -0.65rem;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 1.4rem;
  border-radius: 0 3px 3px 0;
  background: rgba(255, 255, 255, 0.8);
}

.nav-icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  opacity: 0.65;
}

.nav-item.active .nav-icon {
  opacity: 1;
}

.nav-badge {
  margin-left: auto;
  background: rgba(34, 96, 245, 0.35);
  border: 1px solid rgba(85, 133, 248, 0.35);
  color: var(--blue-200);
  font-size: 0.59rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.15rem 0.5rem;
  font-family: var(--f-mono);
}

.nav-badge.red {
  background: rgba(212, 42, 42, 0.25);
  border-color: rgba(212, 42, 42, 0.3);
  color: #fca5a5;
}

.sidebar-footer {
  padding: 0.85rem 1.3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.15);
}

.user-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.user-avatar {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  border: 1.5px solid rgba(255, 255, 255, 0.24);
  overflow: hidden;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: -0.01em;
}

.user-role {
  font-size: 0.6rem;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 1px;
  font-family: var(--f-mono);
  letter-spacing: 0.03em;
}

.user-status {
  width: 0.5rem;
  height: 0.5rem;
  min-width: 0.5rem;
  min-height: 0.5rem;
  flex: 0 0 0.5rem;
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  display: block;
  background: var(--green);
  margin-left: auto;
  box-shadow: 0 0 0 2px rgba(13, 159, 87, 0.25);
}

.main {
  margin-left: var(--sidebar-w);
  width: calc(100% - var(--sidebar-w));
  max-width: calc(100% - var(--sidebar-w));
  min-width: 0;
  flex: 0 0 calc(100% - var(--sidebar-w));
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.topbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0 1.75rem;
  height: 3.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 0 var(--border-s), 0 2px 8px rgba(4, 16, 31, 0.04);
  min-width: 0;
}

.topbar-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
}

.topbar-root {
  color: var(--ink-4);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s ease;
}

.topbar-root:hover,
.topbar-root:focus-visible {
  color: var(--blue-600);
}

.topbar-slash {
  color: var(--border);
  font-size: 0.9rem;
}

.topbar-page {
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.topbar-link {
  font-size: 0.74rem;
  color: var(--ink-3);
  text-decoration: none;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.topbar-link:hover {
  color: var(--blue-600);
}

.content {
  flex: 1;
  padding: 1.75rem;
  min-width: 0;
}

.page {
  display: none;
}

.page.active {
  display: block;
  animation: pageFadeIn 0.2s ease;
}

@keyframes pageFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.page-title {
  font-family: var(--f-display);
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.page-sub {
  font-size: 0.8rem;
  color: var(--ink-3);
  margin-top: 0.25rem;
  font-weight: 400;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  font-family: var(--f-sans);
  font-size: 0.79rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
  line-height: 1;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.btn-sm {
  font-size: 0.72rem;
  padding: 0.38rem 0.72rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
  color: #fff;
  border-color: var(--blue-600);
  box-shadow: none;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  box-shadow: none;
  transform: translateY(-1px);
}

.btn-ghost {
  border-color: var(--border);
  color: var(--ink-2);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.btn-ghost:hover {
  background: var(--blue-50);
  border-color: var(--blue-200);
  color: var(--blue-600);
}

.btn-danger {
  border-color: #fccaca;
  background: #fff6f6;
  color: var(--red);
}

.btn-danger:hover {
  background: var(--red-l);
  border-color: #f9a8a8;
}

.btn-success {
  background: linear-gradient(135deg, var(--green), #0a8a49);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 1px 3px rgba(13, 159, 87, 0.25);
}

.btn-success:hover {
  box-shadow: 0 4px 12px rgba(13, 159, 87, 0.3);
  transform: translateY(-1px);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.3rem 1.4rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s;
}

.stat-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.stat-card::after {
  content: attr(data-icon);
  position: absolute;
  right: 0.9rem;
  bottom: 0.5rem;
  font-size: 3.5rem;
  line-height: 1;
  pointer-events: none;
  opacity: 0.06;
}

.stat-card.blue::before {
  background: linear-gradient(90deg, var(--blue-500), var(--blue-300));
}

.stat-card.green::before {
  background: linear-gradient(90deg, var(--green), #6ee7b7);
}

.stat-card.amber::before {
  background: linear-gradient(90deg, var(--amber), #fcd34d);
}

.stat-card.red::before {
  background: linear-gradient(90deg, var(--red), #fc8181);
}

.stat-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-3);
  margin-bottom: 0.5rem;
  font-family: var(--f-mono);
}

.stat-value {
  font-family: var(--f-display);
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--ink);
  letter-spacing: -0.04em;
  line-height: 1;
}

.stat-delta {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.69rem;
  font-weight: 600;
  margin-top: 0.35rem;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
}

.stat-delta.up {
  color: var(--green);
  background: var(--green-l);
}

.stat-delta.neutral {
  color: var(--ink-3);
  background: var(--border-s);
}

.stat-delta.warn {
  color: var(--amber);
  background: var(--amber-l);
}

.grid-main-side {
  display: grid;
  grid-template-columns: 1fr 310px;
  gap: 0.85rem;
}

.panel {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-s);
  background: linear-gradient(to bottom, rgba(248, 250, 255, 0.8), var(--white));
}

.panel-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.panel-body {
  padding: 1.1rem 1.25rem;
}

.panel-body.no-pad {
  padding: 0;
}

.activity-list {
  display: flex;
  flex-direction: column;
}

.activity-item {
  display: flex;
  gap: 0.85rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--border-s);
  transition: background 0.12s;
  align-items: flex-start;
}

.activity-item:last-child {
  border-bottom: none;
}

.activity-item:hover {
  background: var(--off);
}

.activity-dot-wrap {
  position: relative;
  flex-shrink: 0;
  margin-top: 0.3rem;
}

.activity-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  display: block;
}

.activity-dot-blue {
  background: var(--blue-500);
}

.activity-text {
  font-size: 0.79rem;
  color: var(--ink-2);
  line-height: 1.5;
}

.activity-text strong {
  color: var(--ink);
  font-weight: 600;
}

.activity-time {
  font-size: 0.65rem;
  color: var(--ink-4);
  margin-top: 0.1rem;
  font-family: var(--f-mono);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

thead th {
  text-align: left;
  padding: 0.65rem 1.1rem;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-3);
  background: linear-gradient(to bottom, var(--off), rgba(248, 250, 255, 0.5));
  border-bottom: 1px solid var(--border);
  font-family: var(--f-mono);
}

tbody tr {
  border-bottom: 1px solid var(--border-s);
  transition: background 0.12s;
}

tbody tr:last-child {
  border-bottom: none;
}

tbody tr:hover {
  background: var(--blue-50);
}

tbody td {
  padding: 0.78rem 1.1rem;
  color: var(--ink-2);
  vertical-align: middle;
}

tbody td strong {
  color: var(--ink);
  font-weight: 600;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  border-radius: 999px;
  padding: 0.24rem 0.6rem;
  font-size: 0.63rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-family: var(--f-mono);
}

.badge-blue {
  background: var(--blue-100);
  color: var(--blue-700);
}

.badge-green {
  background: var(--green-l);
  color: #0a7a42;
}

.badge-amber {
  background: var(--amber-l);
  color: #92400e;
}

.badge-red {
  background: var(--red-l);
  color: #991b1b;
}

.badge-gray {
  background: var(--border-s);
  color: var(--ink-3);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4, 16, 31, 0.6);
  backdrop-filter: blur(6px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 32px 80px rgba(4, 16, 31, 0.35), 0 0 0 1px rgba(34, 96, 245, 0.08);
  transform: translateY(16px) scale(0.98);
  transition: transform 0.22s cubic-bezier(.16, 1, .3, 1);
}

.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

.modal.wide {
  max-width: 700px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.4rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(to bottom, var(--off), var(--white));
}

.modal-title {
  font-family: var(--f-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.modal-close {
  width: 1.9rem;
  height: 1.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink-3);
  font-size: 1.05rem;
  transition: all 0.12s;
}

.modal-close:hover {
  background: var(--red-l);
  border-color: #fccaca;
  color: var(--red);
}

.modal-body {
  padding: 1.4rem;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  padding: 1rem 1.4rem;
  border-top: 1px solid var(--border);
  background: var(--off);
}

.form-group {
  margin-bottom: 1rem;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

label {
  display: block;
  font-size: 0.73rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 0.38rem;
  letter-spacing: -0.01em;
}

.required::after {
  content: ' *';
  color: var(--red);
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="time"],
input[type="url"],
select,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.58rem 0.8rem;
  font-size: 0.8rem;
  font-family: var(--f-sans);
  color: var(--ink);
  background: var(--white);
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
  box-shadow: 0 1px 2px rgba(4, 16, 31, 0.04);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--blue-400);
  box-shadow: var(--shadow-glow);
}

textarea {
  resize: vertical;
  min-height: 90px;
  line-height: 1.55;
}

.hint {
  font-size: 0.67rem;
  color: var(--ink-4);
  margin-top: 0.28rem;
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-s);
}

.toggle-row:last-child {
  border-bottom: none;
}

.toggle-label {
  font-size: 0.81rem;
  font-weight: 500;
  color: var(--ink-2);
}

.toggle-sub {
  font-size: 0.7rem;
  color: var(--ink-4);
  margin-top: 2px;
}

.toggle {
  width: 2.6rem;
  height: 1.45rem;
  border-radius: 999px;
  background: var(--border);
  position: relative;
  cursor: pointer;
  transition: background 0.2s;
  flex-shrink: 0;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.12);
}

.toggle.on {
  background: var(--blue-500);
  box-shadow: 0 0 0 2px rgba(34, 96, 245, 0.15);
}

.toggle::after {
  content: '';
  position: absolute;
  width: 1.05rem;
  height: 1.05rem;
  border-radius: 50%;
  background: #fff;
  top: 0.2rem;
  left: 0.2rem;
  transition: transform 0.2s cubic-bezier(.16, 1, .3, 1);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
}

.toggle.on::after {
  transform: translateX(1.15rem);
}

.search-bar {
  position: relative;
  flex: 1;
  max-width: 280px;
}

.search-bar svg {
  position: absolute;
  left: 0.7rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0.85rem;
  height: 0.85rem;
  color: var(--ink-4);
}

.search-bar input {
  padding-left: 2.1rem;
  font-size: 0.77rem;
}

.event-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.1rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  transition: all 0.2s;
  margin-bottom: 0.7rem;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.event-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--border-s);
  transition: background 0.2s;
}

.event-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--blue-200);
  transform: translateY(-1px);
}

.event-card:hover::before {
  background: var(--blue-400);
}

.event-date-box {
  width: 3.5rem;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--blue-50), var(--blue-100));
  border: 1px solid var(--blue-200);
  text-align: center;
  padding: 0.45rem 0.25rem;
  flex-shrink: 0;
}

.event-date-day {
  font-family: var(--f-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--blue-700);
  line-height: 1;
}

.event-date-mon {
  font-size: 0.57rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--blue-400);
  font-family: var(--f-mono);
  margin-top: 3px;
}

.event-info {
  flex: 1;
}

.event-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.22rem;
  letter-spacing: -0.01em;
}

.event-meta {
  font-size: 0.72rem;
  color: var(--ink-3);
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
  margin-bottom: 0.55rem;
}

.event-meta span {
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

.event-actions {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
  align-items: flex-start;
}

.event-actions form {
  display: inline-flex;
}

.progress-bar {
  height: 5px;
  background: var(--border-s);
  border-radius: 99px;
  margin-top: 0.4rem;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--blue-500), var(--blue-400));
  transition: width 0.6s cubic-bezier(.16, 1, .3, 1);
  position: relative;
}

.progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 8px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 99px;
}

.composer {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s;
}

.composer:focus-within {
  box-shadow: var(--shadow-md);
  border-color: var(--blue-200);
}

.composer-body {
  padding: 1.1rem 1.2rem;
}

.composer-textarea {
  width: 100%;
  border: none;
  outline: none;
  font-size: 0.86rem;
  font-family: var(--f-sans);
  color: var(--ink);
  resize: none;
  min-height: 80px;
  line-height: 1.65;
  background: transparent;
}

.composer-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 1.2rem;
  border-top: 1px solid var(--border-s);
  background: linear-gradient(to bottom, var(--off), rgba(248, 250, 255, 0.5));
}

.composer-tags {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.tag-chip {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.22rem 0.6rem;
  font-size: 0.66rem;
  font-weight: 600;
  color: var(--ink-3);
  background: var(--white);
  cursor: pointer;
  transition: all 0.12s;
  font-family: var(--f-mono);
  letter-spacing: 0.03em;
}

.tag-chip.active,
.tag-chip:hover {
  border-color: var(--blue-300);
  color: var(--blue-600);
  background: var(--blue-50);
}

.post-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.2rem;
  margin-bottom: 0.7rem;
  transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}

.post-item:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--blue-100);
}

.post-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.post-meta {
  font-size: 0.67rem;
  color: var(--ink-4);
  font-family: var(--f-mono);
}

.post-text {
  font-size: 0.82rem;
  color: var(--ink-2);
  line-height: 1.6;
}

.post-footer {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.65rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--border-s);
  flex-wrap: wrap;
}

.post-stat {
  font-size: 0.67rem;
  color: var(--ink-4);
  font-family: var(--f-mono);
}

.request-item {
  display: flex;
  gap: 0.85rem;
  padding: 0.95rem 1.25rem;
  border-bottom: 1px solid var(--border-s);
  align-items: flex-start;
  transition: background 0.12s;
  cursor: pointer;
}

.request-item:last-child {
  border-bottom: none;
}

.request-item:hover {
  background: var(--blue-50);
}

.request-item.unread {
  background: rgba(240, 245, 255, 0.7);
}

.request-item.unread:hover {
  background: var(--blue-50);
}

.request-unread-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--blue-500);
  flex-shrink: 0;
  margin-top: 0.48rem;
  box-shadow: 0 0 0 2px rgba(34, 96, 245, 0.2);
}

.request-unread-dot.hidden {
  background: transparent;
  box-shadow: none;
}

.request-from {
  font-size: 0.81rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.request-subject {
  font-size: 0.77rem;
  color: var(--ink-2);
  margin-top: 2px;
}

.request-preview {
  font-size: 0.72rem;
  color: var(--ink-4);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 36ch;
}

.request-time {
  font-size: 0.63rem;
  color: var(--ink-4);
  margin-left: auto;
  flex-shrink: 0;
  font-family: var(--f-mono);
  padding-top: 0.1rem;
}

.settings-section {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.settings-section-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-s);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(to bottom, var(--off), var(--white));
}

.settings-section-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.settings-section-body {
  padding: 1.25rem;
}

.avatar-upload {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  margin-bottom: 1rem;
}

.avatar-preview {
  width: 4rem;
  height: 4rem;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--blue-500), var(--blue-400));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--f-display);
  font-size: 1.4rem;
  font-weight: 900;
  color: #fff;
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.avatar-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.danger-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--border-s);
}

.danger-item:last-child {
  border-bottom: none;
}

.danger-label {
  font-size: 0.81rem;
  font-weight: 600;
  color: var(--ink);
}

.danger-sub {
  font-size: 0.72rem;
  color: var(--ink-3);
  margin-top: 2px;
}

.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--ink-3);
}

.empty-state h4 {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 0.35rem;
}

.empty-state p {
  font-size: 0.78rem;
}

.toast {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  background: var(--ink);
  color: #fff;
  padding: 0.75rem 1.1rem;
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  z-index: 9999;
  transform: translateY(6rem);
  opacity: 0;
  transition: all 0.28s cubic-bezier(.16, 1, .3, 1);
  max-width: 340px;
  box-shadow: 0 12px 30px rgba(4, 16, 31, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  letter-spacing: -0.01em;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast.green {
  background: linear-gradient(135deg, var(--green), #0a8a49);
}

.toast.red {
  background: linear-gradient(135deg, var(--red), #b91c1c);
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.quick-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
  padding: 1rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  cursor: pointer;
  font-size: 0.71rem;
  font-weight: 600;
  color: var(--ink-2);
  text-align: center;
  transition: all 0.15s;
  line-height: 1.3;
  box-shadow: var(--shadow-sm);
  letter-spacing: -0.01em;
  text-decoration: none;
}

.quick-btn:hover {
  border-color: var(--blue-200);
  background: var(--blue-50);
  color: var(--blue-700);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.quick-btn svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--blue-500);
  transition: transform 0.15s;
}

.quick-btn:hover svg {
  transform: scale(1.1);
}

.committee-profile-card {
  background: linear-gradient(135deg, var(--blue-50), var(--blue-100));
  border: 1px solid var(--blue-200);
  border-radius: var(--radius);
  padding: 1rem;
  margin-bottom: 1rem;
}

.profile-stat-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--blue-200);
}

.ps {
  text-align: center;
}

.ps strong {
  display: block;
  font-family: var(--f-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--blue-700);
  letter-spacing: -0.03em;
  line-height: 1;
}

.ps span {
  font-size: 0.6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--ink-4);
  font-family: var(--f-mono);
  margin-top: 3px;
  display: block;
}

.divider {
  height: 1px;
  background: var(--border-s);
  margin: 0.85rem 0;
}

.mb-1 {
  margin-bottom: 0.55rem;
}

.mb-2 {
  margin-bottom: 1rem;
}

.mt-1 {
  margin-top: 0.55rem;
}

.text-mono {
  font-family: var(--f-mono);
}

.text-sm {
  font-size: 0.78rem;
}

.text-xs {
  font-size: 0.7rem;
}

.text-muted {
  color: var(--ink-3);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.fw-600 {
  font-weight: 600;
}

::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--ink-4);
}

.tab-btn {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 0.6rem 0.9rem;
  margin-bottom: -1px;
  font-size: 0.79rem;
  font-weight: 600;
  color: var(--ink-3);
  cursor: pointer;
  transition: all 0.14s;
  font-family: var(--f-sans);
  letter-spacing: -0.01em;
}

.tab-btn:hover {
  color: var(--ink-2);
}

.tab-btn.active {
  color: var(--blue-600);
  border-bottom-color: var(--blue-500);
}

.inline-note {
  font-size: 0.73rem;
  color: var(--ink-4);
}

.flash-stack {
  margin-bottom: 1rem;
}

.flash-item {
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  border: 1px solid;
  font-size: 0.78rem;
  line-height: 1.4;
}

.flash-item.success {
  color: #065f46;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.flash-item.error {
  color: #991b1b;
  background: #fef2f2;
  border-color: #fecaca;
}

.flash-item.info {
  color: #1d4ed8;
  background: #eff6ff;
  border-color: #bfdbfe;
}

.ui-card {
  box-shadow: var(--shadow-sm);
}

.topbar-divider {
  width: 1px;
  height: 1.1rem;
  background: var(--border);
  margin: 0 0.2rem;
}

.committee-switch-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.committee-switch-select,
.member-role-filter {
  width: auto;
  font-size: 0.77rem;
  padding: 0.5rem 0.7rem;
}

.event-progress-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.progress-bar-flex {
  flex: 1;
  max-width: 160px;
}

.progress-bar-fixed {
  width: 160px;
}

.snapshot-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--blue-800);
  letter-spacing: -0.01em;
}

.snapshot-college {
  font-size: 0.71rem;
  color: var(--ink-3);
  margin-top: 3px;
}

.snapshot-status-list {
  font-size: 0.75rem;
  color: var(--ink-3);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.snapshot-status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.empty-state-compact {
  padding: 1.2rem 0.8rem;
}

.request-content {
  flex: 1;
  min-width: 0;
}

.events-tab-strip {
  display: flex;
  gap: 0.1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
  overflow-x: auto;
}

.is-hidden {
  display: none;
}

.event-date-box-muted {
  background: var(--border-s);
  border-color: var(--border);
}

.event-date-day-muted {
  color: var(--ink-3);
}

.event-date-mon-muted {
  color: var(--ink-4);
}

.event-name-muted {
  color: var(--ink-2);
}

.members-toolbar,
.composer-actions,
.page-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

#page-members .panel-header {
  gap: 0.9rem;
}

#page-members .members-toolbar {
  flex-wrap: wrap;
  min-width: 0;
}

#page-members .panel-header > .text-xs {
  margin-left: auto;
  white-space: nowrap;
}

.posted-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.post-tag {
  margin-bottom: 0.35rem;
}

.post-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.post-actions {
  display: flex;
  gap: 0.4rem;
  align-items: flex-start;
  flex-shrink: 0;
}

.post-stat-push {
  margin-left: auto;
}

.request-meta-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 2px;
}

.request-inline-actions {
  margin-top: 0.45rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.request-inline-form {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.request-role-select {
  width: auto;
  min-width: 140px;
  padding: 0.38rem 0.55rem;
  font-size: 0.7rem;
}

.request-reject-input {
  width: 180px;
  padding: 0.38rem 0.55rem;
  font-size: 0.72rem;
}

.event-editor-panel {
  margin-bottom: 1.2rem;
}

.event-editor-panel-header {
  gap: 0.8rem;
}

.event-editor-meta {
  margin-top: 0.24rem;
}

.event-editor-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.event-editor-form .form-group {
  margin-bottom: 0.85rem;
}

.event-editor-toggle {
  margin-top: 0.3rem;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.76rem;
  color: var(--ink-2);
  font-weight: 600;
}

.event-editor-submit-row {
  margin-top: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.registrations-panel {
  margin-bottom: 1.2rem;
}

.registrations-panel-header {
  gap: 0.8rem;
}

.registrations-panel-meta {
  margin-top: 0.24rem;
}

.registrations-panel-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.registrations-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
}

.registrations-summary-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--off);
  padding: 0.72rem 0.78rem;
}

.registrations-summary-card span {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-4);
  font-family: var(--f-mono);
  font-weight: 600;
}

.registrations-summary-card strong {
  display: block;
  margin-top: 0.28rem;
  font-family: var(--f-display);
  font-size: 1.34rem;
  line-height: 1;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.registrations-filter-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin: 0.9rem 0 0.95rem;
}

.registrations-filter-chip {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--ink-3);
  padding: 0.28rem 0.68rem;
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-family: var(--f-mono);
  transition: all 0.15s ease;
}

.registrations-filter-chip:hover {
  border-color: var(--blue-200);
  color: var(--blue-700);
  background: var(--blue-50);
}

.registrations-filter-chip.active {
  border-color: var(--blue-300);
  color: var(--blue-700);
  background: var(--blue-100);
}

.registrations-table-wrap {
  margin-top: 0.3rem;
}

.registrations-action-form {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 130px;
}

.registrations-status-select {
  width: 100%;
  min-width: 120px;
  padding: 0.36rem 0.5rem;
  font-size: 0.7rem;
  border-radius: var(--radius-sm);
}

.settings-section-danger {
  border-color: #fccaca;
}

.settings-section-header-danger {
  background: #fff6f6;
  border-bottom-color: #fccaca;
}

.settings-section-title-danger {
  color: var(--red);
}

.request-modal-subject {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.6rem;
  letter-spacing: -0.01em;
}

.request-modal-body {
  font-size: 0.83rem;
  color: var(--ink-2);
  line-height: 1.65;
  background: var(--off);
  border-radius: 10px;
  padding: 1rem;
  border: 1px solid var(--border-s);
}

.member-name-cell {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}

.member-initial-avatar {
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-100), var(--blue-200));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.63rem;
  font-weight: 700;
  color: var(--blue-700);
  flex-shrink: 0;
  overflow: hidden;
}

.member-initial-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.member-initial-avatar .avatar-fallback {
  display: inline-flex;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.member-initial-avatar.has-image .avatar-fallback {
  display: none;
}

.member-name-label {
  display: block;
  max-width: 24ch;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.member-email {
  display: inline-block;
  max-width: 30ch;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.72rem;
  color: var(--ink-3);
}

.member-action-stack {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-end;
}

.member-action-form {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.member-role-inline {
  width: auto;
  min-width: 106px;
  padding: 0.32rem 0.48rem;
  font-size: 0.7rem;
}

#members-table th:last-child,
#members-table td:last-child {
  text-align: right;
  width: 1%;
  white-space: nowrap;
}

.post-item-new {
  border-color: var(--blue-200);
}

@media (max-width: 680px) {
  body.mn-standalone-page {
    display: block;
  }

  .mn-committee-control {
    display: block;
  }

  .sidebar {
    position: sticky;
    top: 0;
    width: 100%;
    height: auto;
    bottom: auto;
    max-height: none;
  }

  .sidebar-nav {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    overflow-x: auto;
    padding: 0.55rem 0.65rem;
    flex-wrap: nowrap;
  }

  .nav-section-label,
  .sidebar-footer,
  .committee-sub {
    display: none;
  }

  .nav-item {
    margin: 0;
    white-space: nowrap;
    padding: 0.55rem 0.75rem;
  }

  .nav-item.active::before {
    left: 0;
    top: auto;
    bottom: -0.55rem;
    transform: none;
    width: 100%;
    height: 3px;
    border-radius: 3px 3px 0 0;
  }

  .main {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
    flex: 1 1 auto;
  }

  .topbar {
    padding: 0 1rem;
    height: auto;
    min-height: 3.75rem;
  }

  .topbar-right {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .content {
    padding: 1.1rem;
  }

  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-main-side {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .content {
    padding: 0.9rem;
  }

  .page-title {
    font-size: 1.35rem;
  }

  .stat-grid,
  .profile-stat-row {
    grid-template-columns: 1fr;
  }

  .quick-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .event-card {
    flex-direction: column;
    gap: 0.7rem;
  }

  .event-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .composer-toolbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
  }

  .request-time {
    margin-left: 0;
  }

  .topbar-link {
    display: none;
  }

  .registrations-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .registrations-action-form {
    min-width: 112px;
  }

  .event-editor-submit-row {
    width: 100%;
  }
}
