:root {
  --blue: #0052CC;
  --blue-dark: #003d99;
  --green: #00C853;
  --green-dark: #00a844;
  --gray: #333;
  --gray-light: #666;
  --gray-bg: #f5f7fa;
  --white: #fff;
  --danger: #e53935;
  --warning: #ff9800;
  --radius: 12px;
  --shadow: 0 4px 20px rgba(0, 82, 204, 0.08);
  --transition: 0.2s ease;
}

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

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  color: var(--gray);
  background: var(--gray-bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 1.25rem; width: 100%; }
main.container { flex: 1; padding-top: 2rem; padding-bottom: 3rem; }

/* Header */
.header {
  background: var(--white);
  border-bottom: 1px solid #e8ecf0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--gray);
  font-size: 1.25rem;
}

.logo strong { color: var(--blue); }
.logo-icon { font-size: 1.5rem; }

.nav {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav a {
  text-decoration: none;
  color: var(--gray);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.nav a:hover { color: var(--blue); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--gray);
  transition: var(--transition);
}

.nav-toggle-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle-open span:nth-child(2) { opacity: 0; }
.nav-toggle-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.25rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
}

.btn-primary { background: var(--blue); color: var(--white); }
.btn-primary:hover { background: var(--blue-dark); }

.btn-success { background: var(--green); color: var(--white); }
.btn-success:hover { background: var(--green-dark); }

.btn-outline { background: transparent; border-color: var(--blue); color: var(--blue); }
.btn-outline:hover { background: var(--blue); color: var(--white); }

.btn-danger { background: var(--danger); color: var(--white); border: none; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.85rem; }
.btn-lg { padding: 0.85rem 1.5rem; font-size: 1.05rem; }
.btn-block { width: 100%; }

/* Hero */
.hero { padding: 3rem 0 2rem; }

.hero-content { text-align: center; max-width: 700px; margin: 0 auto 3rem; }

.hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--blue);
  margin: 1rem 0;
  line-height: 1.2;
}

.hero-sub { font-size: 1.1rem; color: var(--gray-light); margin-bottom: 2rem; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.badge {
  display: inline-block;
  background: #e8f0fe;
  color: var(--blue);
  padding: 0.35rem 0.85rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.hero-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  background: var(--white);
  padding: 1.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform var(--transition);
}

.feature-card:hover { transform: translateY(-4px); }
.feature-icon { font-size: 2rem; display: block; margin-bottom: 0.75rem; }
.feature-card h3 { color: var(--blue); margin-bottom: 0.5rem; }

a.admin-hub-card {
  text-decoration: none;
  color: inherit;
  display: block;
}

.admin-hub-grid { padding: 0 1.5rem 1.5rem; }

/* Modules */
.modules { padding: 2rem 0 4rem; }
.modules h2 { text-align: center; color: var(--blue); margin-bottom: 2rem; }

.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.module-card {
  background: var(--white);
  padding: 1.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border-top: 4px solid var(--green);
}

.module-card h3 { margin-bottom: 1rem; }
.module-card ul { list-style: none; }
.module-card li { padding: 0.35rem 0; padding-left: 1.25rem; position: relative; }
.module-card li::before { content: '✓'; position: absolute; left: 0; color: var(--green); font-weight: bold; }

/* Landing — pricing & groupe */
.section-intro {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 2.5rem;
}
.section-intro h2 { color: var(--blue); margin-bottom: 0.75rem; }
.section-intro p { color: var(--gray-light); }

.pricing { padding: 3rem 0 2rem; }
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  align-items: stretch;
}

.pricing-card {
  position: relative;
  background: var(--white);
  padding: 2rem 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
}
.pricing-card-featured {
  border-color: var(--blue);
  box-shadow: 0 8px 32px rgba(0, 82, 204, 0.15);
  transform: scale(1.02);
}
.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--green);
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.85rem;
  border-radius: 20px;
  white-space: nowrap;
}
.pricing-card h3 { color: var(--blue); font-size: 1.35rem; margin-bottom: 0.25rem; }
.pricing-tagline { color: var(--gray-light); font-size: 0.9rem; margin-bottom: 1rem; }
.pricing-price { margin-bottom: 0.5rem; }
.pricing-amount { font-size: 2rem; font-weight: 800; color: var(--blue); line-height: 1.1; }
.pricing-period { display: block; font-size: 0.85rem; color: var(--gray-light); margin-top: 0.15rem; }
.pricing-limits {
  font-size: 0.8rem;
  color: var(--gray-light);
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid #e8ecf0;
}
.pricing-modules {
  list-style: none;
  flex: 1;
  margin-bottom: 1.5rem;
}
.pricing-modules li {
  padding: 0.3rem 0;
  font-size: 0.9rem;
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}
.pricing-modules .check { color: var(--green); font-weight: bold; flex-shrink: 0; }
.pricing-more { color: var(--gray-light); font-style: italic; padding-left: 1.25rem !important; }

.module-compare { padding: 3rem 0; }
.compare-wrap {
  overflow-x: auto;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.compare-table { width: 100%; border-collapse: collapse; min-width: 520px; }
.compare-table th,
.compare-table td { padding: 0.75rem 1rem; text-align: center; border-bottom: 1px solid #e8ecf0; }
.compare-table th:first-child,
.compare-table td:first-child { text-align: left; }
.compare-table thead th { background: #f0f4fa; color: var(--blue); font-size: 0.9rem; }
.compare-table tbody tr:hover { background: #fafbfc; }
.compare-core {
  display: inline-block;
  margin-left: 0.5rem;
  font-size: 0.7rem;
  background: #e8f0fe;
  color: var(--blue);
  padding: 0.1rem 0.45rem;
  border-radius: 4px;
  font-weight: 600;
}
.compare-cell.yes { color: var(--green); font-weight: 700; font-size: 1.1rem; }
.compare-cell.no { color: #ccc; }

.group-offer {
  padding: 3rem 0;
  margin: 1rem 0 2rem;
}
.group-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}
.badge-group { background: #fff3e0; color: #e65100; margin-bottom: 1rem; }
.group-content h2 { color: var(--blue); font-size: 1.75rem; margin-bottom: 0.75rem; }
.group-lead { color: var(--gray-light); margin-bottom: 1.5rem; }
.group-perks { list-style: none; margin-bottom: 1.5rem; }
.group-perks li {
  padding: 0.45rem 0;
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
}
.group-perks .check { color: var(--green); font-weight: bold; }
.group-price {
  margin-bottom: 1.5rem;
  padding: 1rem 1.25rem;
  background: var(--white);
  border-radius: var(--radius);
  border-left: 4px solid var(--blue);
}
.group-price strong { display: block; font-size: 1.5rem; color: var(--blue); }
.group-price span { font-size: 0.9rem; color: var(--gray-light); }
.group-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 1rem; }
.group-demo { font-size: 0.85rem; color: var(--gray-light); }
.group-visual { padding: 1.5rem; }
.group-visual h3 { color: var(--blue); margin-bottom: 1rem; font-size: 1.1rem; }
.group-mock-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.group-mock-stat {
  text-align: center;
  padding: 0.75rem;
  background: var(--gray-bg);
  border-radius: 8px;
}
.group-mock-stat span { display: block; font-size: 1.35rem; font-weight: 800; color: var(--blue); }
.group-mock-stat small { font-size: 0.75rem; color: var(--gray-light); }
.table-compact th,
.table-compact td { padding: 0.5rem 0.65rem; font-size: 0.85rem; }
.group-visual-note { font-size: 0.8rem; color: var(--gray-light); margin-top: 1rem; }
.landing-cta-sub { text-align: center; margin-top: 1.5rem; color: var(--gray-light); font-size: 0.9rem; }
.landing-cta-sub a { color: var(--blue); font-weight: 600; }

/* Auth */
.auth-page {
  display: flex;
  justify-content: center;
  padding: 2rem 0;
}

.auth-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  max-width: 420px;
}

.auth-card-wide { max-width: 560px; }
.auth-card h1 { color: var(--blue); margin-bottom: 0.25rem; }
.auth-sub { color: var(--gray-light); margin-bottom: 1.5rem; }
.auth-link { text-align: center; margin-top: 1.5rem; font-size: 0.9rem; }
.auth-link a { color: var(--blue); }

.role-tabs {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.5rem;
  justify-content: center;
}

.role-tabs-top { margin-bottom: 1.5rem; margin-top: 0; }

.role-tabs a {
  padding: 0.4rem 0.85rem;
  border-radius: 20px;
  text-decoration: none;
  font-size: 0.85rem;
  color: var(--gray-light);
  background: var(--gray-bg);
  transition: all var(--transition);
}

.role-tabs a.active,
.role-tabs a:hover {
  background: var(--blue);
  color: var(--white);
}

/* Forms */
.form { display: flex; flex-direction: column; gap: 1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.35rem; }
.form-group label { font-weight: 600; font-size: 0.9rem; }
.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.7rem 0.85rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(0, 82, 204, 0.12);
}

.form-divider { border: none; border-top: 1px solid #eee; margin: 0.5rem 0; }
.form-inline { flex-direction: row; align-items: flex-end; flex-wrap: wrap; }

/* Alerts */
.alert {
  padding: 0.85rem 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.alert-error { background: #fdecea; color: var(--danger); }
.alert-success { background: #e8f5e9; color: var(--green-dark); }
.alert-info { background: #e8f0fe; color: #0d47a1; }

.consent-banner h2 { font-size: 1.05rem; margin-bottom: 0.25rem; }
.consent-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.5rem;
}

/* Page layout */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.page-header h1 { color: var(--blue); font-size: 1.75rem; }
.page-sub { color: var(--gray-light); margin-top: 0.25rem; }

/* Cards & stats */
.card {
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.card h2 { color: var(--blue); font-size: 1.15rem; margin-bottom: 1rem; }
.card h3 { font-size: 1rem; margin: 1rem 0 0.75rem; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  border-bottom: 3px solid var(--blue);
}

.stat-card-warning { border-bottom-color: var(--warning); }
.stat-card-success { border-bottom-color: var(--green); }

.export-links { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.upgrade-page { max-width: 520px; margin: 2rem auto; text-align: center; }
.upgrade-list { text-align: left; margin: 1.5rem 0; list-style: none; }
.upgrade-list li { padding: 0.35rem 0; }

.timeline-full .timeline-event { padding: 0.85rem; border-bottom: 1px solid #eee; }
.attendance-grid { display: flex; flex-direction: column; gap: 0.65rem; margin: 1rem 0; }
.attendance-check { display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem; background: var(--gray-bg); border-radius: 6px; }
.attendance-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--gray-bg);
  border-radius: 8px;
}
.attendance-name { font-weight: 600; }
.attendance-choices { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.attendance-choice { margin: 0; cursor: pointer; }
.attendance-choice input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
.attendance-choice span {
  display: inline-block;
  min-width: 5.6rem;
  padding: 0.55rem 0.9rem;
  border-radius: 8px;
  border: 2px solid #ddd;
  font-weight: 700;
  text-align: center;
  background: #fff;
}
.attendance-choice.present input:checked + span,
.attendance-choice.present input:focus-visible + span {
  background: #e8f5e9;
  border-color: var(--green);
  color: var(--green-dark);
}
.attendance-choice.late input:checked + span,
.attendance-choice.late input:focus-visible + span {
  background: #fff3e0;
  border-color: var(--warning);
  color: #e65100;
}
.attendance-choice.absent input:checked + span,
.attendance-choice.absent input:focus-visible + span {
  background: #fdecea;
  border-color: var(--danger);
  color: var(--danger);
}
.chat-typing { font-size: 0.8rem; color: var(--gray-light); min-height: 1.2rem; }

.demo-banner {
  background: #e8f0fe;
  border: 1px solid var(--blue);
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  margin-bottom: 2rem;
  font-size: 0.9rem;
}

.admin-assist-banner {
  background: #1e3a5f;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.7rem 1.25rem;
  font-size: 0.9rem;
  position: sticky;
  top: 0;
  z-index: 120;
}
.admin-assist-banner strong { font-weight: 700; }
.btn-assist-exit {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.7);
  color: #fff;
}
.btn-assist-exit:hover { background: rgba(255,255,255,0.12); color: #fff; }
.assist-form { display: inline-flex; margin: 0; }
.assist-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}
.assist-search { min-width: min(100%, 18rem); }
.assist-search input {
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: 1px solid #d0d7de;
  border-radius: var(--radius);
}
.assist-section-title {
  font-size: 1rem;
  margin: 1rem 0 0.5rem;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
@media (max-width: 600px) {
  .assist-actions { justify-content: stretch; }
  .assist-actions .btn,
  .assist-actions form { width: 100%; }
  .assist-actions .btn { text-align: center; }
}
.stat-value { display: block; font-size: 2rem; font-weight: 700; color: var(--blue); }
.stat-label { font-size: 0.85rem; color: var(--gray-light); }

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

/* Table */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.accounting-filter { margin-bottom: 1.5rem; }
.accounting-filter .btn { margin-top: 0.25rem; }
@media (max-width: 600px) {
  .accounting-form .btn,
  .accounting-filter .btn { width: 100%; }
  .grid-2 { grid-template-columns: 1fr; }
}

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

.table th,
.table td {
  padding: 0.75rem;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.table th { color: var(--gray-light); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; }

/* Lists */
.list { list-style: none; }
.list-item {
  padding: 0.85rem 0;
  border-bottom: 1px solid #eee;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.list-item span { color: var(--gray-light); font-size: 0.9rem; }
.list-item small { color: #999; font-size: 0.8rem; }

.empty, .empty-state, .empty-sm { color: var(--gray-light); font-style: italic; }
.empty-state { text-align: center; padding: 3rem; background: var(--white); border-radius: var(--radius); }

/* Badges status */
.badge-status {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-pending { background: #fff3e0; color: var(--warning); }
.badge-validated { background: #e8f5e9; color: var(--green-dark); }
.badge-rejected { background: #fdecea; color: var(--danger); }

/* Payment */
.payment-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
  border-left: 4px solid var(--green);
}

.payment-card h2 { color: var(--blue); }
.school-name { color: var(--gray-light); margin-bottom: 1.5rem; }

.payment-info {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.payment-method {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--gray-bg);
  padding: 1rem 1.25rem;
  border-radius: 8px;
  flex: 1;
  min-width: 200px;
}

.method-icon { font-size: 1.75rem; }
.phone-number { font-size: 1.25rem; font-weight: 700; color: var(--blue); letter-spacing: 0.05em; }

/* Child card */
.child-card {
  background: var(--white);
  padding: 1.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}

.child-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.child-header h2 { color: var(--blue); }

.child-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.child-stats h4 { font-size: 0.85rem; color: var(--gray-light); margin-bottom: 0.5rem; text-transform: uppercase; }

/* Quick actions */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.action-card {
  background: var(--white);
  padding: 1.25rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--gray);
  font-weight: 600;
  text-align: center;
  transition: all var(--transition);
  border: 2px solid transparent;
}

.action-card:hover {
  border-color: var(--blue);
  color: var(--blue);
  transform: translateY(-2px);
}

.inline-forms { display: inline; }

code {
  background: var(--gray-bg);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.85rem;
}

/* Footer */
.footer {
  background: var(--blue);
  color: rgba(255, 255, 255, 0.9);
  padding: 1.5rem 0;
  margin-top: auto;
}

.footer-inner { text-align: center; }
.footer-brand {
  font-weight: 600;
  color: #fff;
  font-size: 1.05rem;
}
.footer-entity {
  font-size: 0.9rem;
  margin-top: 0.2rem;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem 1.15rem;
  margin: 0.85rem 0 0.4rem;
}
.footer-links a {
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  font-size: 0.88rem;
}
.footer-links a:hover,
.footer-links a:focus {
  text-decoration: underline;
  color: #fff;
}
.footer-sub { font-size: 0.85rem; opacity: 0.75; margin-top: 0.25rem; }

/* Public legal pages */
.legal-page { max-width: 800px; }
.legal-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}
.legal-nav a {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--blue);
  text-decoration: none;
  font-size: 0.88rem;
  border: 1px solid #d6e0f0;
}
.legal-nav a:hover,
.legal-nav a.is-active {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}
.legal-card h1 {
  color: var(--blue);
  font-size: 1.6rem;
  margin-bottom: 0.35rem;
}
.legal-updated {
  color: var(--gray-light);
  font-size: 0.85rem;
  margin-bottom: 1.25rem;
}
.legal-card h2 {
  color: var(--blue);
  font-size: 1.08rem;
  margin: 1.35rem 0 0.5rem;
}
.legal-card p { margin-bottom: 0.85rem; }
.legal-card ul {
  margin: 0 0 1rem 1.2rem;
}
.legal-card li { margin-bottom: 0.35rem; }
.legal-card a { color: var(--blue); }
.auth-legal {
  margin-top: 1rem;
  font-size: 0.82rem;
  color: var(--gray-light);
  line-height: 1.45;
  text-align: center;
}
.auth-legal a { color: var(--blue); }

@media (max-width: 640px) {
  .legal-card h1 { font-size: 1.3rem; }
  .footer { padding: 1.25rem 0 1.5rem; }
}

.error-page {
  text-align: center;
  padding: 4rem 0;
}

.error-page h1 { color: var(--blue); font-size: 3rem; margin-bottom: 1rem; }

/* Chat */
.chat-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 1rem;
  min-height: 400px;
}

.container-chat { max-width: 900px; }

.chat-sidebar h2 { font-size: 1rem; margin-bottom: 1rem; color: var(--blue); }

.chat-list { list-style: none; }

.chat-list-item { border-bottom: 1px solid #eee; }

.chat-list-link {
  display: block;
  padding: 0.85rem 0;
  text-decoration: none;
  color: inherit;
  transition: background var(--transition);
}

.chat-list-link:hover { background: var(--gray-bg); margin: 0 -1rem; padding-left: 1rem; padding-right: 1rem; }

.chat-list-top { display: flex; justify-content: space-between; align-items: center; }

.chat-unread {
  background: var(--green);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 10px;
}

.chat-preview {
  font-size: 0.85rem;
  color: var(--gray-light);
  margin-top: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-light);
}

.chat-thread { display: flex; flex-direction: column; max-height: 70vh; }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 300px;
  max-height: 450px;
  background: var(--gray-bg);
  border-radius: 8px;
  margin-bottom: 1rem;
}

.chat-bubble {
  max-width: 75%;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.95rem;
}

.chat-bubble time {
  display: block;
  font-size: 0.7rem;
  opacity: 0.7;
  margin-top: 0.35rem;
}

.chat-mine {
  align-self: flex-end;
  background: var(--blue);
  color: white;
  border-bottom-right-radius: 4px;
}

.chat-theirs {
  align-self: flex-start;
  background: white;
  border: 1px solid #e8ecf0;
  border-bottom-left-radius: 4px;
}

.chat-student { display: block; font-size: 0.75rem; opacity: 0.85; margin-bottom: 0.25rem; }

.chat-audio { width: 100%; max-width: 260px; height: 36px; }
.chat-file {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.7rem;
  background: rgba(0, 82, 204, 0.08);
  border-radius: 8px;
  font-weight: 600;
}

.chat-form textarea {
  flex: 1;
  padding: 0.7rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-family: inherit;
  resize: vertical;
}

.chat-input-row { display: flex; gap: 0.75rem; align-items: flex-end; }

.chat-student-select {
  width: 100%;
  padding: 0.5rem;
  margin-bottom: 0.75rem;
  border-radius: 8px;
  border: 1px solid #ddd;
}

.chat-audio-row { margin-top: 0.75rem; display: flex; align-items: center; gap: 0.75rem; }

.badge-unread { background: var(--green); color: white; padding: 0.35rem 0.75rem; border-radius: 20px; font-size: 0.85rem; }

/* Homework */
.homework-list { display: flex; flex-direction: column; gap: 1rem; }

.homework-item {
  padding: 1rem;
  background: var(--gray-bg);
  border-radius: 8px;
  border-left: 3px solid var(--blue);
}

.homework-late { border-left-color: var(--warning); opacity: 0.85; }

.homework-test { border-left-color: var(--danger); }

.hw-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  vertical-align: middle;
  margin-right: 0.25rem;
}

.hw-badge-homework { background: var(--blue); color: #fff; }
.hw-badge-test { background: var(--danger); color: #fff; }

.hw-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.hw-subject { color: var(--gray-light); font-size: 0.9rem; margin: 0.25rem 0; }

.hw-calendar-card { margin-top: 1.5rem; }
.hw-calendar { min-height: 380px; }
.hw-calendar .fc-toolbar-title { font-size: 1.05rem; }
.hw-calendar .fc-event { cursor: pointer; font-size: 0.82rem; }

@media (max-width: 640px) {
  .hw-calendar { min-height: 320px; }
  .page-header .export-links { display: flex; flex-wrap: wrap; gap: 0.5rem; }
}

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

.teacher-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1rem 0;
}

/* Suivi enfant */
.suivi-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.suivi-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--gray);
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  border: 2px solid transparent;
  transition: all var(--transition);
}

.suivi-btn:hover { border-color: var(--green); color: var(--green); transform: translateY(-2px); }

.suivi-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.suivi-block {
  background: var(--gray-bg);
  padding: 1rem;
  border-radius: 8px;
}

.suivi-block h3 { font-size: 0.95rem; color: var(--blue); margin-bottom: 0.75rem; }

.timeline { list-style: none; }
.timeline-item, .timeline li { padding: 0.4rem 0; font-size: 0.9rem; border-bottom: 1px solid #eee; }

.badge-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.75rem;
}

.badge-card {
  background: white;
  padding: 0.75rem;
  border-radius: 8px;
  text-align: center;
  border: 2px solid var(--green);
}

.badge-card span { font-size: 1.5rem; display: block; }
.badge-card strong { display: block; font-size: 0.85rem; margin-top: 0.25rem; }
.badge-card small { color: var(--gray-light); font-size: 0.75rem; }

.badge-list { list-style: none; }
.badge-item { padding: 0.5rem 0; border-bottom: 1px solid #eee; }

.behavior-positive { color: var(--green-dark); }
.behavior-negative { color: var(--danger); }
.behavior-line { font-size: 0.9rem; margin-bottom: 0.35rem; }

.health-alert { background: #fff3e0; padding: 0.5rem 0.75rem; border-radius: 6px; margin-bottom: 0.5rem; font-size: 0.9rem; }
.lost-alert { background: #e8f0fe; padding: 0.5rem 0.75rem; border-radius: 6px; margin-bottom: 0.5rem; }

.qr-card {
  background: var(--gray-bg);
  padding: 1.25rem;
  border-radius: 8px;
  text-align: center;
  margin-bottom: 1rem;
  border: 2px dashed var(--blue);
}

.qr-code {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.input-lg { font-size: 1.25rem !important; text-align: center; letter-spacing: 0.05em; }

.card-highlight { border: 2px solid var(--green); }

.lost-item {
  padding: 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.lost-claimed { opacity: 0.5; }

.menu-text { font-size: 1.05rem; margin-bottom: 1rem; color: var(--gray); }

.activities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.activity-card { border-top: 3px solid var(--green); }

/* Responsive */
@media (max-width: 768px) {
  .nav-toggle { display: flex; }

  .nav {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    gap: 0;
    border-bottom: 1px solid #e8ecf0;
    box-shadow: var(--shadow);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.25s ease, opacity 0.25s ease;
    z-index: 99;
  }

  .nav.nav-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav a {
    display: block;
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid #f0f0f0;
  }

  .nav a.btn { margin-top: 0.5rem; text-align: center; }
}

@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .chat-layout { grid-template-columns: 1fr; }
  .chat-placeholder { display: none; }
  .group-layout { grid-template-columns: 1fr; }
  .pricing-card-featured { transform: none; }
  .group-actions { flex-direction: column; }
  .group-actions .btn { width: 100%; }
}

.qr-image { max-width: 200px; height: auto; display: block; margin: 0.5rem auto; }
.inline-form { display: inline-flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.edit-row { padding: 0.75rem 0; border-bottom: 1px solid #eee; }
.edit-row summary { cursor: pointer; font-weight: 600; }

.form-hint { font-size: 0.85rem; color: var(--gray-light); margin: 0.25rem 0 0.75rem; }
.logo-upload-group { margin-bottom: 1.5rem; }
.logo-preview {
  margin: 0.75rem 0;
  padding: 1rem;
  background: var(--gray-bg);
  border-radius: 8px;
  display: inline-block;
}
.school-logo-preview {
  max-width: 160px;
  max-height: 120px;
  object-fit: contain;
  display: block;
}
.page-header-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.badge-premium { background: linear-gradient(135deg, #0052CC, #00C853); color: white; }
.badge-success { background: #e8f5e9; color: var(--green-dark); }
.module-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.75rem;
  padding: 0 1.5rem 1rem;
}
.module-stat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 0.85rem;
  background: var(--gray-bg);
  border-radius: 8px;
  font-size: 0.9rem;
}
.module-stat-value { font-weight: 700; color: var(--blue); }
.admin-modules-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 1.25rem;
  align-items: start;
}
.admin-schools-list { padding: 0; overflow: hidden; }
.school-picker { list-style: none; }
.school-picker-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.85rem 1.25rem;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid #eee;
  transition: background var(--transition);
}
.school-picker-item:hover { background: var(--gray-bg); }
.school-picker-item.active {
  background: #e8f0fe;
  border-left: 3px solid var(--blue);
}
.admin-modules-panel .card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem 0;
}
.card-footer { padding: 1rem 1.5rem 1.5rem; }

.admin-plans-grid { margin-bottom: 0.5rem; }
.admin-plans-grid .pricing-modules {
  max-height: none;
  overflow: visible;
}
.checkbox-line {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  cursor: pointer;
}
.checkbox-line input { margin-top: 0.2rem; }

@media (max-width: 900px) {
  .admin-modules-layout { grid-template-columns: 1fr; }
}

.hr-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}
.hr-subnav a {
  text-decoration: none;
  color: var(--blue);
  font-weight: 600;
  font-size: 0.9rem;
}
.hr-subnav a:hover { text-decoration: underline; }

/* App shell (navbar + sidebar + content) */
.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-navbar {
  background: var(--white);
  border-bottom: 1px solid #e8ecf0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.app-navbar-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 64px;
  padding: 0 1.25rem;
}

.app-navbar-end {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.app-navbar-user {
  font-size: 0.9rem;
  color: var(--gray-light);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.app-body {
  display: flex;
  flex: 1;
  min-height: 0;
}

.app-sidebar {
  width: 240px;
  flex-shrink: 0;
  background: var(--white);
  border-right: 1px solid #e8ecf0;
  padding: 1rem 0.75rem 2rem;
}

.app-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.app-sidebar-nav a {
  display: block;
  padding: 0.55rem 0.85rem;
  border-radius: 8px;
  text-decoration: none;
  color: var(--gray);
  font-size: 0.9rem;
  transition: background var(--transition), color var(--transition);
}

.app-sidebar-nav a:hover,
.app-sidebar-nav a.is-active {
  background: #e8f0fe;
  color: var(--blue);
  font-weight: 600;
}

.app-content {
  flex: 1;
  min-width: 0;
  padding-top: 2rem;
  padding-bottom: 3rem;
}

.app-sidebar-overlay {
  display: none;
}

.app-shell .footer { margin-top: auto; }

@media (max-width: 900px) {
  .app-navbar .nav-toggle { display: flex; }

  .app-sidebar {
    position: fixed;
    top: 64px;
    left: 0;
    bottom: 0;
    z-index: 98;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    box-shadow: var(--shadow);
    overflow-y: auto;
  }

  .app-sidebar.is-open { transform: translateX(0); }

  .app-sidebar-overlay {
    display: block;
    position: fixed;
    inset: 64px 0 0 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 97;
  }

  .app-sidebar-overlay[hidden] { display: none; }
}

.hr-subnav a.active { color: var(--navy, #0a2540); text-decoration: underline; }
.group-subnav { margin-bottom: 1.25rem; }
.group-alerts { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.group-alert { padding: 0.65rem 0.85rem; border-radius: 8px; background: #fff8e6; }
.group-alert-info { background: #e8f0fe; }
.group-bar-row { margin-bottom: 0.85rem; }
.group-bar-meta { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.9rem; margin-bottom: 0.3rem; }
.bar-track { background: #e8eef7; height: 10px; border-radius: 99px; overflow: hidden; }
.bar-track-sm { height: 6px; display: inline-block; width: 72px; vertical-align: middle; margin-right: 0.35rem; }
.bar-fill { height: 100%; background: var(--blue); border-radius: 99px; }
.group-rank { list-style: none; }
.group-rank li { display: flex; align-items: center; gap: 0.6rem; padding: 0.4rem 0; }
.group-rank-n { width: 1.5rem; height: 1.5rem; border-radius: 50%; background: var(--blue); color: #fff; font-size: 0.75rem; display: inline-flex; align-items: center; justify-content: center; }
.group-modules { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 0.35rem; font-size: 0.85rem; }
.group-modules .on { color: var(--green); }
.group-modules .off { color: var(--gray-light); }
.campus-compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.group-compare-picks { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.group-compare-kpis { list-style: none; margin: 1rem 0; }
.group-compare-kpis li { padding: 0.25rem 0; }
.group-circular { border-bottom: 1px solid #eee; padding: 0.75rem 0; }
.group-circular h3 { margin: 0 0 0.25rem; font-size: 1rem; }
.group-admins { list-style: none; margin-bottom: 1.25rem; }
.group-admins li { padding: 0.35rem 0; }

.person-line,
.person-cell {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}
.person-cell { white-space: nowrap; }

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  overflow: hidden;
  background: #e8eef7;
  color: var(--blue);
  font-weight: 700;
  flex-shrink: 0;
  line-height: 1;
}
.avatar-sm { width: 32px; height: 32px; font-size: 0.72rem; }
.avatar-md { width: 44px; height: 44px; font-size: 0.88rem; }
.avatar-lg { width: 72px; height: 72px; font-size: 1.2rem; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar-initials { text-transform: uppercase; }

.brand-logo {
  object-fit: contain;
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #e8ecf0;
  border-radius: 8px;
}
.brand-logo-sm { width: 36px; height: 36px; }
.brand-logo-md { width: 56px; height: 56px; }
.brand-logo-lg { width: 88px; height: 88px; }
.brand-logo-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--blue);
  color: #fff;
  font-weight: 700;
  border-radius: 8px;
  flex-shrink: 0;
  line-height: 1;
}
.brand-logo-fallback.brand-logo-sm { width: 36px; height: 36px; font-size: 0.95rem; }
.brand-logo-fallback.brand-logo-md { width: 56px; height: 56px; font-size: 1.25rem; }
.brand-logo-fallback.brand-logo-lg { width: 88px; height: 88px; font-size: 1.75rem; }

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.25rem 0.6rem 1rem;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--gray);
}
.sidebar-brand span {
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
}

.school-identity {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  min-width: 0;
  flex: 1;
}
.school-identity h1 { word-break: break-word; }
.school-meta {
  list-style: none;
  margin-top: 0.5rem;
  color: var(--gray);
  font-size: 0.92rem;
}
.school-meta li { margin: 0.15rem 0; }
.school-meta code {
  background: #e8eef7;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-size: 0.85rem;
}

.navbar-school {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--gray);
}
.navbar-school-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 34vw;
}

@media (max-width: 900px) {
  .app-navbar-user-name { display: none; }
  .page-header { flex-direction: column; align-items: stretch; }
  .page-header h1 { font-size: 1.3rem; }
  .school-identity { align-items: center; }
  .brand-logo-lg { width: 96px; height: 96px; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-value { font-size: 1.5rem; color: var(--blue); }
  .stat-label { color: var(--gray); }
  .app-content { padding-top: 1.25rem; }
  .logo-text { display: none; }
}

@media (max-width: 600px) {
  .navbar-school-name { max-width: 42vw; }
}

/* Contextual help tooltips */
.hint {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin-left: 0.35rem;
  vertical-align: middle;
  cursor: help;
  outline: none;
  flex-shrink: 0;
}

.hint-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.05rem;
  height: 1.05rem;
  border-radius: 50%;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1;
  color: var(--gray-light, #666);
  background: #e8ecf0;
  border: 1px solid #d0d7de;
  transition: background var(--transition), color var(--transition);
}

.hint:hover .hint-icon,
.hint:focus .hint-icon {
  background: var(--blue, #0052CC);
  color: var(--white, #fff);
  border-color: var(--blue, #0052CC);
}

.hint-tip {
  position: absolute;
  z-index: 200;
  left: 50%;
  bottom: calc(100% + 6px);
  transform: translateX(-50%);
  max-width: 240px;
  width: max-content;
  padding: 0.45rem 0.6rem;
  font-size: 0.78rem;
  font-weight: 400;
  line-height: 1.35;
  text-align: left;
  color: #f5f5f5;
  background: #1e293b;
  border-radius: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.hint-tip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: #1e293b;
}

.hint:hover .hint-tip,
.hint:focus .hint-tip,
.hint:focus-within .hint-tip {
  opacity: 1;
  visibility: visible;
}

h1 .hint, h2 .hint, h3 .hint, .stat-label .hint {
  vertical-align: text-top;
}

/* Offline-first banner & status */
.offline-banner {
  position: sticky;
  top: 0;
  z-index: 160;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  padding: 0.85rem 1rem;
  padding-left: max(1rem, env(safe-area-inset-left));
  padding-right: max(1rem, env(safe-area-inset-right));
  font-size: 0.95rem;
  line-height: 1.4;
}
.offline-banner[hidden] { display: none !important; }
.offline-banner-pending { background: #fff8e1; color: #8a5a00; }
.offline-banner-error { background: #fdecea; color: var(--danger); }
.offline-banner-ok { background: #e8f5e9; color: var(--green-dark); }
.offline-banner-msg { flex: 1; min-width: 12rem; }
.offline-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.offline-banner .btn {
  min-height: 44px;
  min-width: 44px;
}
.offline-fab {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 170;
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
  font-size: 1.35rem;
  cursor: pointer;
}
.offline-fab[hidden] { display: none !important; }
.offline-conflict {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.offline-page { display: flex; align-items: center; justify-content: center; min-height: 70vh; }
.offline-card { max-width: 32rem; text-align: center; padding: 2rem 1.5rem; }
.offline-status-icon { font-size: 2.5rem; margin-bottom: 0.5rem; }
