/* Animation Classes for Home Page */

/* Define keyframes that might not be in Tailwind */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideInUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Stagger Animation */
.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  animation: staggerReveal 0.5s ease-out forwards;
}

@keyframes staggerReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Ensure animations from design system are available */
.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

.animate-slide-up {
  animation: slideInUp 0.6s ease-out forwards;
}

.animate-scale-in {
  animation: scaleIn 0.4s ease-out forwards;
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-20px);
  }
}

/* Hover Scale */
.hover-scale {
  transition: transform 0.2s ease-in-out;
}

.hover-scale:hover {
  transform: scale(1.05);
}

/* Hover Elevate */
.hover-elevate {
  transition: box-shadow 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.hover-elevate:hover {
  transform: translateY(-4px);
}
/* Design System - Authentication Components (Papier calme) */

.auth-container {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: var(--space-4) 0 var(--space-8);
}

.auth-card {
  width: 100%;
  max-width: 28rem;
  background: var(--color-surface);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-raised);
}

.auth-header {
  padding: var(--space-8) var(--space-6) var(--space-4);
  text-align: center;
}

.auth-title {
  font-family: var(--font-display);
  font-size: var(--text-display);
  line-height: var(--text-display--line-height);
  font-weight: var(--text-display--font-weight);
  color: var(--color-ink);
  margin: 0 0 var(--space-2) 0;
}

.auth-subtitle {
  font-size: var(--text-body);
  line-height: var(--text-body--line-height);
  color: var(--color-sable-600);
  margin: 0;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-2) var(--space-6) var(--space-6);
}

.auth-footer {
  padding: var(--space-4) var(--space-6) var(--space-6);
  border-top: 1.5px solid var(--color-sable-200);
  text-align: center;
}

.auth-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
}

.auth-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: var(--text-label);
  line-height: var(--text-label--line-height);
  font-weight: var(--text-label--font-weight);
  color: var(--color-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

@media (max-width: 480px) {
  .auth-header {
    padding: var(--space-6) var(--space-4) var(--space-4);
  }

  .auth-form {
    padding: var(--space-2) var(--space-4) var(--space-4);
  }

  .auth-footer {
    padding: var(--space-4);
  }
}

/* Links Component */
.link {
  color: var(--color-primary-600);
  text-decoration: none;
  font-weight: var(--font-weight-medium);
  transition: var(--transition-all);
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
}

.link:hover {
  color: var(--color-primary-700);
  text-decoration: underline;
}

.link:focus {
  outline: 2px solid var(--color-primary-500);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.link-secondary {
  color: var(--color-text-secondary);
  font-weight: var(--font-weight-normal);
}

.link-secondary:hover {
  color: var(--color-text-primary);
}
.child-day-row {
  display: grid;
  grid-template-columns: 52px 36px minmax(0, 1fr);
  align-items: center;
  column-gap: 12px;
  width: 100%;
  padding: 10px 8px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: var(--color-primary-950);
  font: inherit;
  text-align: left;
}

button.child-day-row {
  cursor: pointer;
}

.child-day-row--now {
  background: var(--color-nap-tint);
  box-shadow: inset 0 0 0 1.5px var(--color-primary-300);
}

.child-day-time {
  font-size: 19px;
  line-height: 24px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.child-day-disc {
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}

.child-day-label {
  font-size: 15px;
  line-height: 20px;
  font-weight: 700;
  color: var(--color-primary-800);
}

.child-day-text {
  font-size: 18px;
  line-height: 24px;
  overflow-wrap: anywhere;
}

.child-day-row--planned .child-day-time,
.child-day-row--planned .child-day-text {
  color: var(--color-sable-600);
}

.child-day-row--planned .child-day-disc {
  background: transparent;
  border: 1.5px dashed var(--color-sable-300);
  color: var(--color-sable-600);
}

.child-day-summary-section {
  padding-top: 14px;
  border-top: 1px solid var(--color-sable-200);
}

@media (min-width: 768px) {
  .child-day-row {
    grid-template-columns: 72px 40px minmax(0, 1fr);
    column-gap: 16px;
    padding: 10px 16px;
  }

  .child-day-time {
    font-size: 22px;
    line-height: 28px;
  }

  .child-day-disc {
    width: 40px;
    height: 40px;
    font-size: 17px;
  }

  .child-day-label {
    font-size: 16px;
  }

  .child-day-text {
    font-size: 20px;
    line-height: 26px;
  }
}

.child-day-rows:not(:has(li)) {
  display: none;
}
/* frozen_string_literal: true */

/* Daily Handling Module Specific Styles */

/* Child card styles are handled by ChildCardComponent via Tailwind */

/* Loading States */
.event-btn-loading {
  pointer-events: none;
  opacity: 0.75;
  position: relative;
}

.event-btn-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.9);
  border-radius: inherit;
}

.event-btn-loading::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.5rem; /* w-6 */
  height: 1.5rem; /* h-6 */
  border: 2px solid #d1d5db; /* border-gray-300 */
  border-top-color: #4b5563; /* border-t-gray-600 */
  border-radius: 50%; /* rounded-full */
  animation: spin 1s linear infinite; /* animate-spin */
  margin-left: -12px;
  margin-top: -12px;
  z-index: 10;
}

/* Success Animation */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes success-pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.event-success {
  animation: success-pulse 0.5s ease-in-out;
}

/* Toast Notifications */
.toast {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  min-width: 300px;
  max-width: 28rem;
  position: relative;
  animation: toast-slide-in 0.3s ease-out;
  opacity: 0;
  transform: translateX(100%);
}

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

@keyframes toast-slide-in {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes toast-slide-out {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

.toast-dismissing {
  animation: toast-slide-out 0.3s ease-in forwards;
}

.toast-success {
  background-color: #ecfdf7;
  border: 1px solid #a5f3d9;
}

.toast-error {
  background-color: #fff3f0;
  border: 1px solid #ffc5b8;
}

.toast-info {
  background-color: #f0fbfa;
  border: 1px solid #abeae4;
}

.toast-icon {
  flex-shrink: 0;
}

.toast-content {
  flex: 1;
}

.toast-message {
  font-size: 0.875rem;
  font-weight: 500;
  color: #111827;
}

.toast-close {
  margin-left: 1rem;
  color: #9ca3af;
  transition: color 150ms;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-size: 1rem;
}

.toast-close:hover {
  color: #4b5563;
}

/* Enhanced Recording Feedback */
.recording-active {
  position: relative;
  overflow: hidden;
}

.recording-active::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(239, 68, 68, 0.15);
  animation: recording-pulse 1.5s ease-in-out infinite;
}

@keyframes recording-pulse {
  0%, 100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.6;
  }
}

/* Recording indicator overlay */
.recording-indicator {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.9);
  border-radius: inherit;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease-in-out;
}

.recording-indicator.active {
  opacity: 1;
  pointer-events: auto;
}

/* Microphone animation */
.recording-mic {
  font-size: 2.5rem;
  color: white;
  animation: mic-pulse 1s ease-in-out infinite;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

@keyframes mic-pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
}

/* Sound waves animation */
.sound-waves {
  position: absolute;
  width: 100px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sound-wave {
  position: absolute;
  width: 80px;
  height: 80px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  animation: sound-wave 1.5s ease-out infinite;
}

.sound-wave:nth-child(2) {
  animation-delay: 0.3s;
}

.sound-wave:nth-child(3) {
  animation-delay: 0.6s;
}

@keyframes sound-wave {
  0% {
    transform: scale(1);
    opacity: 0.4;
  }
  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}

/* Recording text */
.recording-text {
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 8px;
  animation: fade-in 0.3s ease-out;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Collapsible Sections - Remove all browser default markers */
details summary {
  list-style: none;
  cursor: pointer;
  user-select: none;
}

details summary::-webkit-details-marker {
  display: none;
}

details summary::-moz-list-bullet {
  list-style: none;
}

details summary::marker {
  display: none;
}

details summary::before {
  display: none;
}
.data-table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
  color: var(--color-primary-950);
  font-size: var(--text-label);
  line-height: var(--text-label--line-height);
}

.data-table th,
.data-table td {
  height: 52px;
  padding: 6px 12px;
  border: 0;
  background: transparent;
  vertical-align: middle;
}

.data-table :is(th, td):first-child {
  padding-left: 24px;
}

.data-table :is(th, td):last-child {
  padding-right: 24px;
}

.data-table thead th {
  color: var(--color-sable-600);
  font-size: var(--text-meta);
  font-weight: 700;
}

.data-table tbody tr {
  border-top: 1px solid var(--color-sable-100);
}

.data-table tbody th {
  font-weight: 700;
}

@container (max-width: 719px) {
  .data-table th,
  .data-table td {
    padding-left: 8px;
    padding-right: 8px;
  }

  .data-table :is(th, td):first-child {
    padding-left: 16px;
  }

  .data-table :is(th, td):last-child {
    padding-right: 16px;
  }
}
/* Footer Component */
.footer {
  background-color: var(--color-paper);
  border-top: 1.5px solid var(--color-sable-200);
  padding: 1.5rem 0;
  margin-top: auto;
}

@media (min-width: 768px) {
  .footer {
    padding: 2rem 0;
  }
}

.footer-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
}

@media (min-width: 768px) {
  .footer-content {
    gap: 1.5rem;
  }
}

/* Footer sections */
.footer-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

@media (min-width: 768px) {
  .footer-main {
    flex-direction: row;
    gap: 2rem;
  }
}

.footer-copyright {
  font-size: var(--text-meta);
  line-height: var(--text-meta--line-height);
  color: var(--color-sable-600);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

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

@media (min-width: 768px) {
  .footer-links {
    gap: 1.5rem;
  }
}

.footer-link {
  font-size: var(--text-meta);
  line-height: var(--text-meta--line-height);
  color: var(--color-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-link.admin {
  color: var(--color-admin);
}

.footer-link.admin:hover {
  color: var(--color-admin);
  opacity: 0.8;
}

/* Footer badge */
.footer-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  background-color: rgba(239, 68, 68, 0.1);
  color: var(--color-admin);
  font-size: var(--text-meta);
  font-weight: 700;
}

/* Logo in footer — SVG wordmark (charte 2026) */
.footer-logo-img {
  display: inline-block;
  height: 1.5rem;
  width: auto;
  vertical-align: middle;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .footer {
    padding: 1rem 0;
  }
  
  .footer-content {
    gap: 0.75rem;
  }
  
  .footer-main {
    gap: 0.75rem;
  }
  
  .footer-links {
    gap: 0.75rem;
  }
}
/* Design System - Form Components */

/* Form Groups */
.form-group {
  margin-bottom: var(--space-6);
}

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

/* Labels */
.form-label {
  display: block;
  margin-bottom: var(--space-2);
  font-size: var(--font-size-small);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-primary);
}

.form-label-required::after {
  content: " *";
  color: var(--color-danger-600);
}

/* Base Input Styles */
.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-primary);
  font-size: var(--font-size-body);
  line-height: 1.5;
  color: var(--color-text-primary);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--input-radius);
  transition: var(--transition-all);
  appearance: none;
}

.form-input.pl-10 {
  padding-left: 2.5rem;
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--color-text-disabled);
}

.form-input:disabled,
.form-textarea:disabled {
  background-color: var(--color-surface);
  color: var(--color-text-disabled);
  border-color: var(--color-gray-300);
}

/* Textarea */
.form-textarea {
  min-height: 6rem;
  resize: vertical;
}

/* Form Actions */
.form-actions {
  display: flex;
  gap: var(--space-3);
  margin-top: var(--space-8);
}
.landing {
  --landing-curve: cubic-bezier(0.22, 1, 0.36, 1);
  width: 100%;
  overflow-x: clip;
  color: var(--color-ink);
  font-size: 16px;
  line-height: 24px;
}

html:has(.landing) { scroll-padding-top: 96px; }

.landing :where(h1, h2, h3, p, ul, ol, li, figure) { margin: 0; padding: 0; }
.landing :where(ul, ol) { list-style: none; }
.landing :where(h1, h2, h3) { font-weight: 700; text-wrap: balance; }
.landing :where(p, li, summary, figcaption) { text-wrap: pretty; }
.landing :where(main section) { padding: 80px 0; }
@media (min-width: 768px) { .landing :where(main section) { padding: 96px 0; } }

.landing-container { width: 100%; max-width: 1152px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .landing-container { padding: 0 32px; } }

.landing-skip-link {
  position: absolute; left: 16px; top: 16px; z-index: 100;
  padding: 8px 12px; border-radius: var(--radius-tile);
  background: var(--color-ink); color: var(--color-surface); font-weight: 600;
  transform: translateY(-200%);
}
.landing-skip-link:focus { transform: none; }
.landing main:focus { outline: none; }

.landing-nav-wrap {
  position: fixed; top: 16px; left: 0; right: 0; z-index: 50;
  display: flex; justify-content: center; padding: 0 16px; pointer-events: none;
}
.landing-nav {
  pointer-events: auto;
  display: flex; align-items: center; gap: 24px;
  width: 100%; max-width: 760px;
  padding: 8px 8px 8px 16px;
  border: 1px solid color-mix(in srgb, var(--color-sable-300) 60%, transparent);
  border-radius: 9999px;
  background: color-mix(in srgb, var(--color-paper) 72%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  box-shadow: var(--shadow-raised);
}
.landing-nav-logo { flex: none; display: flex; align-items: center; min-height: 40px; border-radius: var(--radius-tile); }
.landing-nav-logo img { height: 32px; width: auto; }
.landing-nav-links { display: none; gap: 4px; }
.landing-nav-links a, .landing-nav-session {
  display: inline-flex; align-items: center; min-height: 40px;
  padding: 8px 12px; border-radius: 9999px;
  font-size: 15px; line-height: 20px; font-weight: 600; color: var(--color-sable-600); white-space: nowrap;
}
.landing-nav-session { display: none; color: var(--color-ink); }
.landing-nav-links a[aria-current="true"] { background: var(--color-primary-300); color: var(--color-ink); }
.landing-nav-links a:hover, .landing-nav-session:hover { text-decoration: none; }
@media (hover: hover) {
  .landing-nav-links a:not([aria-current="true"]):hover, .landing-nav-session:hover { background: var(--color-sable-200); color: var(--color-ink); }
}
.landing-sign-out-form { display: contents; }
.landing-sign-out { border: 0; background: none; font-family: inherit; cursor: pointer; }
.landing-nav-cta { display: none; }
.landing-nav-spacer { flex: 1; }
@media (min-width: 900px) {
  .landing-nav { width: auto; max-width: none; }
  .landing-nav-links { display: inline-flex; }
  .landing-nav-session { display: inline-flex; }
  .landing-nav-cta { display: inline-flex; }
  .landing-nav-spacer, .landing-menu-toggle { display: none; }
}

.landing-menu-toggle {
  position: relative; width: 48px; height: 48px;
  border: 0; border-radius: 9999px; background: transparent; color: var(--color-ink); cursor: pointer;
}
@media (hover: hover) { .landing-menu-toggle:hover { background: var(--color-sable-200); } }
.landing-menu-toggle span {
  position: absolute; left: 14px; width: 20px; height: 2px; border-radius: 2px; background: currentColor;
  transition: transform 500ms var(--landing-curve);
}
.landing-menu-toggle span:first-child { top: 19px; }
.landing-menu-toggle span:last-child { top: 27px; }
.landing-menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.landing-menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

.landing-menu-panel {
  position: fixed; inset: 0; z-index: -1;
  display: flex; flex-direction: column; justify-content: center; gap: 16px;
  padding: 96px 24px 48px;
  background: color-mix(in srgb, var(--color-paper) 94%, transparent);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  pointer-events: auto;
  opacity: 0; visibility: hidden;
  transition: opacity 500ms var(--landing-curve), visibility 0s linear 500ms;
}
.landing-menu-panel.is-open { opacity: 1; visibility: visible; transition: opacity 500ms var(--landing-curve); }
.landing-menu-panel a.landing-menu-item, .landing-menu-panel .landing-sign-out {
  display: flex; align-items: center; min-height: 48px; padding: 0;
  font-size: 30px; line-height: 36px; font-weight: 700; color: var(--color-ink);
}
.landing-menu-panel a[aria-current="true"] {
  text-decoration: underline; text-decoration-color: var(--color-primary-600);
  text-decoration-thickness: 3px; text-underline-offset: 8px;
}
.landing-menu-item { opacity: 0; transform: translateY(24px); transition: opacity 500ms var(--landing-curve), transform 500ms var(--landing-curve); }
.landing-menu-panel.is-open .landing-menu-item { opacity: 1; transform: none; }
.landing-menu-panel.is-open .landing-menu-item:nth-child(2) { transition-delay: 60ms; }
.landing-menu-panel.is-open .landing-menu-item:nth-child(3) { transition-delay: 120ms; }
.landing-menu-panel.is-open .landing-menu-item:nth-child(4) { transition-delay: 180ms; }
.landing-menu-panel.is-open .landing-menu-item:nth-child(5) { transition-delay: 240ms; }
.landing-menu-button { margin-top: 24px; }
@media (min-width: 900px) { .landing-menu-panel { display: none; } }

.landing-surface { background: var(--color-surface); }
.landing-eyebrow { font-size: 15px; line-height: 20px; font-weight: 600; color: var(--color-sable-600); margin-bottom: 12px; }
.landing-section-title { font-size: 30px; line-height: 36px; max-width: 680px; }
@media (min-width: 768px) { .landing-section-title { font-size: 36px; line-height: 40px; } }
.landing-section-lead { margin-top: 16px; max-width: 680px; font-size: 18px; line-height: 28px; color: var(--color-sable-600); }

.landing-hero { padding: 128px 0 80px; }
@media (min-width: 768px) { .landing-hero { padding-top: 160px; } }
.landing-hero h1 { max-width: 680px; font-size: 48px; line-height: 1; letter-spacing: -0.01em; }
.landing-hero h1 span { display: block; }
@media (min-width: 768px) { .landing-hero h1 { font-size: 72px; } }
.landing-hero-sub { margin-top: 24px; max-width: 680px; font-size: 18px; line-height: 28px; color: var(--color-sable-600); }
@media (min-width: 768px) { .landing-hero-sub { font-size: 20px; } }
.landing-hero-actions { margin-top: 32px; display: flex; flex-direction: column; align-items: stretch; gap: 12px; }
@media (min-width: 640px) { .landing-hero-actions { flex-direction: row; align-items: center; gap: 16px; } }
.landing-free { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.landing-proof-line { margin-top: 24px; display: flex; align-items: flex-start; gap: 8px; max-width: 680px; color: var(--color-sable-600); }
.landing-proof-line svg { color: var(--color-ink); }

.landing-shot {
  margin-top: 48px; padding: 8px;
  border-radius: 24px; background: var(--color-surface); box-shadow: var(--shadow-float);
}
.landing-shot img, .landing-shot video { display: block; width: 100%; height: auto; border-radius: 16px; }
.landing-video-toggle { display: none; }
.landing-js .landing-video-toggle { display: inline-flex; flex: none; }
.landing-shot figcaption { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 4px 8px 0; font-size: 15px; line-height: 20px; color: var(--color-sable-600); }
.landing-phone-shot { max-width: 320px; margin: 0 auto; }

.landing-split { display: grid; gap: 24px; margin-top: 40px; }
@media (min-width: 768px) { .landing-split { grid-template-columns: 1fr 1fr; } }
.landing-card { height: 100%; }
.landing-card h3 { font-size: 20px; line-height: 28px; margin-bottom: 8px; }
.landing-card p { color: var(--color-sable-600); }
.landing-tag {
  display: inline-flex; padding: 4px 12px; margin-bottom: 16px;
  border-radius: 9999px; font-size: 15px; line-height: 20px; font-weight: 600;
}

.landing-benefits { display: grid; gap: 16px; margin-top: 40px; }
@media (min-width: 768px) { .landing-benefits { grid-template-columns: 1fr 1fr; gap: 24px; } }
.landing-benefit { display: flex; gap: 16px; align-items: flex-start; }
.landing-benefit-icon {
  flex: none; display: grid; place-items: center; width: 48px; height: 48px;
  border-radius: 16px; background: var(--color-primary-100);
}
.landing-benefit h3 { font-size: 18px; line-height: 28px; }
.landing-benefit p { margin-top: 4px; color: var(--color-sable-600); }
.landing-proof-tag { display: inline-block; margin-top: 8px; font-size: 15px; line-height: 20px; font-weight: 600; }

.landing-tagline { padding: 96px 0; background: var(--color-primary-100); }
.landing-tagline p { max-width: 680px; font-size: 36px; line-height: 40px; font-weight: 700; letter-spacing: -0.01em; }
@media (min-width: 768px) { .landing-tagline p { max-width: 880px; font-size: 60px; line-height: 1; } }
.landing-tagline-line { display: block; text-wrap: balance; }
.landing-word { transition: color 600ms var(--landing-curve); }
.landing-js .landing-word { color: rgba(0, 70, 71, 0.3); }
.landing-js .landing-word.is-on { color: var(--color-ink); }
.landing-word-voice, .landing-js .landing-word-voice.is-on {
  text-decoration: underline; text-decoration-color: var(--color-accent-600);
  text-decoration-thickness: 6px; text-underline-offset: 10px;
}
.landing-js .landing-word-voice { text-decoration-color: transparent; }

.landing-steps { display: grid; gap: 16px; margin-top: 40px; }
@media (min-width: 900px) { .landing-steps { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.landing-step-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.landing-step-num, .landing-step-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 9999px; }
.landing-step-num { background: var(--color-ink); color: var(--color-surface); font-weight: 700; }

.landing-video {
  margin: 40px auto 0; max-width: 800px;
  display: grid; place-items: center; text-align: center;
  aspect-ratio: 16 / 9; padding: 24px;
  border-radius: var(--radius-panel); border: 2px dashed var(--color-sable-300); background: var(--color-sable-100);
}
.landing-video img { width: 40px; height: auto; margin: 0 auto 12px; }
.landing-video-title { font-weight: 600; }
.landing-video-note { font-size: 15px; line-height: 20px; color: var(--color-sable-600); }

.landing-pilot { display: grid; gap: 40px; align-items: start; margin-top: 40px; }
@media (min-width: 900px) { .landing-pilot { grid-template-columns: 1.2fr 0.8fr; gap: 64px; } }
.landing-facts { display: grid; gap: 16px; }
.landing-facts p { margin-top: 4px; color: var(--color-sable-600); }
.landing-facts .landing-fact-figure { margin-top: 0; font-size: 30px; line-height: 36px; font-weight: 700; color: var(--color-ink); }
.landing-privacy {
  display: flex; gap: 12px; align-items: flex-start;
  margin-top: 24px; padding: 16px;
  border-radius: 16px; background: var(--color-paper);
}
.landing-privacy p { font-size: 15px; line-height: 20px; color: var(--color-sable-600); }

.landing-faq { margin-top: 40px; max-width: 800px; display: grid; gap: 12px; }
.landing-faq details { border-radius: 16px; background: var(--color-surface); box-shadow: var(--shadow-raised); }
.landing-faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 16px 24px;
  font-size: 18px; line-height: 28px; font-weight: 600; cursor: pointer; list-style: none;
  border-radius: 16px;
}
.landing-faq summary::-webkit-details-marker { display: none; }
@media (hover: hover) { .landing-faq summary:hover { background: var(--color-sable-100); } }
.landing-faq summary:active { transform: translateY(1px); }
.landing-faq summary svg { transition: transform 500ms var(--landing-curve); }
.landing-faq details[open] summary svg { transform: rotate(180deg); }
.landing-answer { padding: 0 24px 24px; color: var(--color-sable-600); max-width: 680px; }

.landing-beta { background: var(--color-primary-100); }
.landing-signup { display: grid; gap: 40px; }
@media (min-width: 900px) { .landing-signup { grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; } }
.landing-signup-intro .landing-section-title { font-size: 36px; line-height: 40px; }
@media (min-width: 768px) { .landing-signup-intro .landing-section-title { font-size: 48px; line-height: 1; } }
.landing-signup-intro ul { margin-top: 24px; display: grid; gap: 12px; }
.landing-signup-intro li { display: flex; gap: 8px; align-items: flex-start; }
.landing-signup-intro li p { font-weight: 600; }
.landing-signup-question { margin-top: 20px; text-align: center; }
.landing-signup-question a { color: var(--color-primary-800); text-decoration: underline; text-underline-offset: 2px; }

.landing-footer { padding: 48px 0 32px; background: var(--color-paper); border-top: 1px solid var(--color-sable-200); }
.landing-footer-row { display: flex; flex-direction: column; gap: 24px; }
@media (min-width: 768px) { .landing-footer-row { flex-direction: row; justify-content: space-between; align-items: center; } }
.landing-footer-row > a { border-radius: var(--radius-tile); }
.landing-footer img { height: 32px; width: auto; }
.landing-footer nav ul { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.landing-footer nav a {
  display: inline-flex; align-items: center; min-height: 40px;
  font-size: 15px; line-height: 20px; color: var(--color-sable-600); text-decoration: underline; text-underline-offset: 4px;
}
@media (hover: hover) { .landing-footer nav a:hover { color: var(--color-ink); } }
.landing-footer-meta { margin-top: 16px; font-size: 15px; line-height: 20px; color: var(--color-sable-600); }

.landing-js .landing-reveal { opacity: 0; transform: translateY(32px); transition: opacity 700ms var(--landing-curve), transform 700ms var(--landing-curve); }
.landing-js .landing-reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html:has(.landing) { scroll-behavior: auto; }
  .landing-js .landing-reveal { transform: none; transition: opacity 700ms var(--landing-curve); }
  .landing-menu-item { transform: none; transition-property: opacity; }
  .landing-menu-toggle span, .landing-faq summary svg { transition: none; }
}

.landing-hero, .landing-beta { position: relative; overflow: hidden; isolation: isolate; }
.landing-hero .landing-container { position: relative; }
.landing-hero::before, .landing-hero::after, .landing-beta::before, .landing-hero .landing-container::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
}
.landing-hero::before {
  width: min(760px, 130vw); height: min(640px, 110vw); right: -18%; top: -120px;
  background: var(--color-primary-100); border-radius: 62% 38% 46% 54% / 55% 48% 52% 45%;
}
.landing-hero::after {
  width: min(560px, 100vw); height: min(480px, 86vw); left: -16%; top: 52%;
  background: var(--color-accent-200); border-radius: 44% 56% 61% 39% / 48% 58% 42% 52%;
}
.landing-hero .landing-container::before {
  width: 112px; height: 112px; right: 6%; top: -48px;
  border: 4px solid var(--color-primary-300); border-radius: 9999px;
}
.landing-beta::before {
  width: min(520px, 100vw); height: min(440px, 86vw); left: -10%; bottom: -160px;
  background: var(--color-accent-200); border-radius: 58% 42% 38% 62% / 46% 54% 46% 54%;
}
/* Design System - Modal Components */

/* Modal Container */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  z-index: var(--z-modal);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-all);
}

.modal-open {
  opacity: 1;
  visibility: visible;
}

/* Modal Backdrop */
.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: var(--z-modal-backdrop);
  transition: var(--transition-all);
}

/* Modal Content */
.modal-content {
  position: relative;
  width: 100%;
  max-width: 32rem;
  max-height: 90vh;
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-2xl);
  overflow: hidden;
  z-index: var(--z-modal);
  transform: scale(0.9) translateY(20px);
  transition: var(--transition-all);
}

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

/* Modal Sizes */
.modal-sm .modal-content {
  max-width: 24rem;
}

.modal-lg .modal-content {
  max-width: 48rem;
}

.modal-xl .modal-content {
  max-width: 64rem;
}

.modal-full .modal-content {
  max-width: 100%;
  max-height: 100%;
  height: 100%;
  border-radius: 0;
}

/* Modal Header */
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-6);
  border-bottom: 1px solid var(--color-border);
}

.modal-title {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  margin: 0;
}

.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: var(--transition-all);
}

.modal-close:hover {
  background: var(--color-gray-100);
  color: var(--color-text-primary);
}

/* Modal Body */
.modal-body {
  padding: var(--space-6);
  overflow-y: auto;
  max-height: calc(90vh - 8rem);
}

/* Modal Footer */
.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-6);
  border-top: 1px solid var(--color-border);
  background: var(--color-gray-50);
}

/* Sheet Modal (Slide from side) */
.modal-sheet .modal-content {
  max-width: 24rem;
  height: 100%;
  max-height: 100%;
  border-radius: 0;
  transform: translateX(100%);
}

.modal-sheet.modal-open .modal-content {
  transform: translateX(0);
}

.modal-sheet-left .modal-content {
  transform: translateX(-100%);
}

.modal-sheet-left.modal-open .modal-content {
  transform: translateX(0);
}

/* Bottom Sheet (Mobile) */
.modal-bottom-sheet .modal-content {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: 100%;
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  transform: translateY(100%);
}

.modal-bottom-sheet.modal-open .modal-content {
  transform: translateY(0);
}

.modal-bottom-sheet .modal-header {
  position: relative;
  padding-top: var(--space-4);
}

.modal-bottom-sheet .modal-header::before {
  content: "";
  position: absolute;
  top: var(--space-2);
  left: 50%;
  transform: translateX(-50%);
  width: 3rem;
  height: 0.25rem;
  background: var(--color-gray-300);
  border-radius: var(--radius-full);
}

/* Alert Modal */
.modal-alert .modal-content {
  max-width: 24rem;
  text-align: center;
}

.modal-alert .modal-body {
  padding: var(--space-8);
}

.modal-alert-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  margin: 0 auto var(--space-4);
  border-radius: var(--radius-full);
}

.modal-alert-icon-success {
  background: var(--color-success-100);
  color: var(--color-success-600);
}

.modal-alert-icon-warning {
  background: var(--color-warning-100);
  color: var(--color-warning-600);
}

.modal-alert-icon-error {
  background: var(--color-danger-100);
  color: var(--color-danger-600);
}

.modal-alert-icon-info {
  background: var(--color-primary-100);
  color: var(--color-primary-600);
}

.modal-alert-title {
  font-size: var(--font-size-h4);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  margin-bottom: var(--space-2);
}

.modal-alert-description {
  color: var(--color-text-secondary);
  margin-bottom: var(--space-6);
}

/* Confirmation Modal */
.modal-confirm .modal-footer {
  justify-content: center;
}

/* Loading Modal */
.modal-loading .modal-content {
  max-width: 16rem;
  text-align: center;
}

.modal-loading .modal-body {
  padding: var(--space-8);
}

.modal-spinner {
  display: inline-block;
  width: 3rem;
  height: 3rem;
  margin: 0 auto var(--space-4);
  border: 3px solid var(--color-gray-200);
  border-top-color: var(--color-primary-600);
  border-radius: var(--radius-full);
  animation: spin 1s linear infinite;
}

/* Image Modal */
.modal-image .modal-content {
  max-width: 90vw;
  max-height: 90vh;
  background: transparent;
  box-shadow: none;
}

.modal-image .modal-body {
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-image img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius-lg);
}

/* Popover */
.popover {
  position: absolute;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-4);
  z-index: var(--z-popover);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: var(--transition-all);
}

.popover-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.popover-arrow {
  position: absolute;
  width: 0.75rem;
  height: 0.75rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  transform: rotate(45deg);
}

.popover-top .popover-arrow {
  bottom: -0.375rem;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  border-top: none;
  border-left: none;
}

.popover-bottom .popover-arrow {
  top: -0.375rem;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  border-bottom: none;
  border-right: none;
}

.popover-left .popover-arrow {
  right: -0.375rem;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  border-left: none;
  border-bottom: none;
}

.popover-right .popover-arrow {
  left: -0.375rem;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  border-right: none;
  border-top: none;
}

/* Tooltip */
.tooltip {
  position: absolute;
  background: var(--color-gray-900);
  color: white;
  font-size: var(--font-size-small);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  white-space: nowrap;
  z-index: var(--z-tooltip);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-5px);
  transition: var(--transition-all);
}

.tooltip-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Toast/Notification */
.toast-container {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  z-index: var(--z-notification);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 18rem;
  padding: var(--space-4);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  pointer-events: auto;
  animation: slideInRight var(--duration-slow) var(--ease-out);
}

.toast-success {
  border-color: var(--color-success-200);
  background: var(--color-success-50);
}

.toast-warning {
  border-color: var(--color-warning-200);
  background: var(--color-warning-50);
}

.toast-error {
  border-color: var(--color-danger-200);
  background: var(--color-danger-50);
}

.toast-info {
  border-color: var(--color-primary-200);
  background: var(--color-primary-50);
}

.toast-icon {
  flex-shrink: 0;
  width: 1.5rem;
  height: 1.5rem;
}

.toast-content {
  flex: 1;
}

.toast-title {
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  margin-bottom: var(--space-1);
}

.toast-message {
  font-size: var(--font-size-small);
  color: var(--color-text-secondary);
}

.toast-close {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: var(--transition-all);
}

.toast-close:hover {
  background: var(--color-gray-100);
  color: var(--color-text-primary);
}

/* Responsive */
@media (max-width: 640px) {
  .modal-content {
    max-width: calc(100vw - 2rem);
  }
  
  .toast-container {
    left: var(--space-4);
    right: var(--space-4);
  }
  
  .toast {
    min-width: auto;
    width: 100%;
  }
}
/* Design System - Navigation Components */

/* Navbar */
.navbar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-2) var(--space-6);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  transition: var(--transition-all);
}

/* Sticky Navbar with Glassmorphism */
.navbar-sticky {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
}

.navbar-glass {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-sable-200);
}

/* Navbar Brand */
.navbar-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--font-size-h4);
  font-weight: var(--font-weight-bold);
  color: var(--color-text-primary);
  text-decoration: none;
  transition: var(--transition-all);
}

@media (hover: hover) {
  .navbar-brand:hover {
    color: var(--color-primary-600);
  }
}

.navbar-brand-logo {
  height: 2rem;
  width: auto;
}

.navbar-link {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  font-size: var(--font-size-body);
  color: var(--color-text-secondary);
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: var(--transition-all);
  position: relative;
}

/* Hover feedback only on devices that actually hover — on touch, a tap would
   leave a sticky hover state on the shared tablet (CRE-203 finding). */
@media (hover: hover) {
  .navbar-link:hover {
    color: var(--color-text-primary);
    background: var(--color-gray-100);
  }
}

/* Navbar Actions */
.navbar-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

/* Tabs */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--color-border);
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  position: relative;
  flex-shrink: 0;
}

.tab-link {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  font-size: var(--font-size-body);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-secondary);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: var(--transition-all);
  white-space: nowrap;
}

@media (hover: hover) {
  .tab-link:hover {
    color: var(--color-text-primary);
    border-bottom-color: var(--color-gray-300);
  }
}

.tab-link-active {
  color: var(--color-primary-950);
  font-weight: var(--font-weight-bold);
  border-bottom-color: var(--color-primary-300);
}

.tab-link svg {
  width: 1.25rem;
  height: 1.25rem;
}

.tab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 var(--space-1);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  color: white;
  background: var(--color-primary-600);
  border-radius: var(--radius-full);
}

/* Device-type nav switching. Default state targets mouse devices (desktop):
   show the top header + horizontal tab bar, hide the mobile header + bottom
   nav. The @media (pointer: coarse) block below flips this for touch devices
   (phone + tablet). Driven by pointer capability, not viewport width, so a
   narrow desktop window still gets the top nav and a wide tablet still gets
   the bottom nav. Plain CSS (not Tailwind variants) so it wins the cascade
   over the .bottom-nav base display + Tailwind's .hidden. */
.nav-desktop-header { display: flex; }
.nav-mobile-header { display: none; }
.footer-desktop-only { display: block; }

/* Desktop Tab Bar */
.desktop-tab-bar {
  display: flex;
  justify-content: center;
  justify-content: safe center;
  gap: var(--space-1);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: 0 var(--space-6);
  overflow-x: auto;
}

.desktop-tab-bar .tab-link {
  padding: var(--space-3) var(--space-5);
}

/* Single source of truth for what the fixed nav takes from the screen: the
   bottom bar's height on a phone, the rail's width on a tablet, zero where
   the nav is not there. Every fixed surface that must clear the nav reads
   these tokens instead of guessing (PR #277, #282 came from guessed values). */
:root {
  --bottom-nav-height: 0px;
  --rail-width: 0px;
}

/* One nav for touch devices, hidden on mouse devices: a bottom bar on a
   phone, a left rail on a tablet. */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: none;
  justify-content: center;
  gap: 2px;
  padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0));
  background: var(--color-surface);
  border-top: 1px solid var(--color-sable-200);
  z-index: var(--z-sticky);
}

.bottom-nav-logo {
  display: none;
}

.bottom-nav-item {
  flex: 1;
  max-width: 9rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-radius: var(--radius-field);
  color: var(--color-sable-600);
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  transition: var(--transition-all);
}

.bottom-nav-item-active {
  color: var(--color-primary-950);
  font-weight: var(--font-weight-bold);
  background: var(--color-primary-300);
}

.bottom-nav-icon {
  width: 22px;
  height: 22px;
}

.bottom-nav-label {
  font-size: 12px;
  line-height: 16px;
}

@media (pointer: coarse) {
  .nav-desktop-header { display: none; }
  .nav-mobile-header { display: block; }
  .desktop-tab-bar { display: none; }
  .bottom-nav { display: flex; }
  .footer-desktop-only { display: none; }
}

@media (pointer: coarse) and (max-width: 767px), (pointer: coarse) and (max-height: 599px) {
  :root {
    --bottom-nav-height: 4rem;
  }

  .bottom-nav {
    height: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0));
  }

  .has-bottom-nav {
    padding-bottom: calc(var(--bottom-nav-height) + 1.5rem + env(safe-area-inset-bottom, 0));
  }
}

@media (pointer: coarse) and (min-width: 768px) and (min-height: 600px) {
  :root {
    --rail-width: 104px;
  }

  .with-bottom-nav {
    padding-left: var(--rail-width);
  }

  .bottom-nav {
    top: 0;
    right: auto;
    width: var(--rail-width);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 24px 12px;
    background: var(--color-paper);
    border-top: 0;
    border-right: 1px solid var(--color-sable-200);
  }

  .bottom-nav-logo {
    display: block;
    margin-bottom: 24px;
  }

  .bottom-nav-logo img {
    height: 22px;
    width: auto;
  }

  .bottom-nav-item {
    flex: none;
    width: 80px;
    height: 72px;
    max-width: none;
    gap: 6px;
    border-radius: var(--radius-tile);
  }

  .bottom-nav-icon {
    width: 26px;
    height: 26px;
  }

  .bottom-nav-label {
    font-size: 15px;
    line-height: 18px;
  }
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  list-style: none;
  margin: 0;
  padding: 0;
}

.pagination-item {
  display: flex;
}

.pagination-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  height: 2.5rem;
  padding: 0 var(--space-3);
  font-size: var(--font-size-body);
  color: var(--color-text-secondary);
  text-decoration: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: var(--transition-all);
}

@media (hover: hover) {
  .pagination-link:hover {
    color: var(--color-text-primary);
    background: var(--color-gray-100);
    border-color: var(--color-border-hover);
  }
}

.pagination-link-active {
  color: white;
  background: var(--color-primary-600);
  border-color: var(--color-primary-600);
}

.pagination-link:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination-ellipsis {
  padding: 0 var(--space-2);
  color: var(--color-text-disabled);
}
/* Structure Module Specific Styles */

/* Override link styles inside buttons */
button a {
  color: inherit !important;
  text-decoration: none !important;
}

/* Voice bar — the coral Dicter key. A touch phone has it full width above
   the bottom bar; a tablet and any mouse screen bottom-right, the same split
   as the nav in navigation.css. Its states are styled on
   .voice-bar[data-state], which the voice-bar controller sets. */
.voice-bar-container {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0) + 16px);
  z-index: var(--z-sticky);
}

@media not all and (pointer: coarse), (min-width: 768px) and (min-height: 600px) {
  .voice-bar-container {
    left: auto;
    right: 32px;
    bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom, 0) + 28px);
    max-width: 420px;
  }
}

.voice-bar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-radius: var(--radius-panel);
  color: var(--color-primary-950);
}

.voice-bar .hidden {
  display: none;
}

.voice-bar[data-state="recording"] {
  padding: 12px;
  background: var(--color-accent-200);
  box-shadow: var(--shadow-float);
}

.voice-bar[data-state="error"] {
  max-height: 40vh;
  overflow-y: auto;
  padding: 16px;
  background: var(--color-sable-100);
  box-shadow: var(--shadow-float);
}

.voice-bar-button {
  width: 100%;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  background: var(--color-accent-600);
  color: var(--color-primary-950);
  box-shadow: var(--shadow-float);
  font-size: 21px;
  font-weight: var(--font-weight-bold);
  cursor: pointer;
  transition: filter 160ms cubic-bezier(0.2, 0.7, 0.2, 1), transform 160ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media not all and (pointer: coarse), (min-width: 768px) and (min-height: 600px) {
  .voice-bar-button {
    width: auto;
    height: 76px;
    margin-left: auto;
    gap: 12px;
    padding: 0 30px 0 24px;
    font-size: 23px;
  }
}

.voice-bar-icon {
  display: flex;
}

.voice-bar-icon svg {
  width: 28px;
  height: 28px;
  stroke-width: 2.2;
}

@media not all and (pointer: coarse), (min-width: 768px) and (min-height: 600px) {
  .voice-bar-icon svg {
    width: 32px;
    height: 32px;
  }
}

/* Recording: one ring that breathes once per 1.6 s; still under reduced motion. */
.voice-bar[data-state="recording"] .voice-bar-button {
  box-shadow: 0 0 0 6px rgba(255, 108, 87, 0.35);
}

@media (prefers-reduced-motion: no-preference) {
  .voice-bar[data-state="recording"] .voice-bar-button {
    animation: voice-bar-breath 1600ms cubic-bezier(0.2, 0.7, 0.2, 1) infinite;
  }
}

@keyframes voice-bar-breath {
  0%, 100% { box-shadow: 0 0 0 4px rgba(255, 108, 87, 0.35); }
  50% { box-shadow: 0 0 0 12px rgba(255, 108, 87, 0.2); }
}

.voice-bar-status {
  white-space: nowrap;
}

.voice-bar-waveform {
  display: flex;
  justify-content: center;
}

.voice-bar-waveform-canvas {
  width: 100%;
  max-width: 18rem;
  height: 2rem;
  color: var(--color-primary-950);
}

/* Room under the content so the key and its band never sit over the last tiles. */
.has-voice-bar {
  padding-bottom: calc(64px + 32px + var(--bottom-nav-height) + env(safe-area-inset-bottom, 0));
}

@media not all and (pointer: coarse), (min-width: 768px) and (min-height: 600px) {
  .has-voice-bar {
    padding-bottom: calc(120px + var(--bottom-nav-height));
  }
}

.has-voice-bar:has(.voice-bar[data-state="error"]) {
  padding-bottom: calc(40vh + 56px + var(--bottom-nav-height) + env(safe-area-inset-bottom, 0));
}

.voice-bar-error-message {
  margin: 0 0 4px;
  font-size: 17px;
  line-height: 22px;
  font-weight: var(--font-weight-semibold);
}

.voice-bar-error-transcription {
  margin: 0;
  font-size: 15px;
  line-height: 20px;
  color: var(--color-sable-600);
}

.voice-bar-error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.voice-bar-retry-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 18px;
  border: 0;
  border-radius: var(--radius-tile);
  background: var(--color-surface);
  box-shadow: inset 0 0 0 1.5px var(--color-sable-300);
  color: var(--color-primary-950);
  font-size: 17px;
  font-weight: var(--font-weight-semibold);
  cursor: pointer;
}

.voice-bar-retry-btn svg {
  width: 20px;
  height: 20px;
}
/* « À valider » — Papier calme (mockups A-AValider-Echec, A-Mobile-AValider-Echec). */

.voice-queue-page {
  container: voice-page / inline-size;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.voice-queue-errored-block:not(:has(.voice-queue-failure)) {
  display: none;
}

.voice-queue-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.voice-queue-stack:empty {
  display: none;
}

.voice-queue-previous-block,
.voice-queue-today-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.voice-queue-previous-block:not(:has(.voice-event-group)),
.voice-queue-today-block:not(:has(.voice-event-group)) {
  display: none;
}

/* The event modal of a child's day (daily_handling/_edit_card) keeps the card's frame. */
.voice-event-card-content {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  padding: 1rem;
}

.voice-event-card-footer {
  padding: 0.875rem 1rem calc(0.875rem + env(safe-area-inset-bottom, 0));
  border-top: 1px solid var(--color-sable-200);
}

.voice-event-card-footer turbo-frame {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Failure band: sand, the sad ü, the dictated sentence and the reason, no capitals. */
.voice-queue-failure {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 12px 12px 16px;
  border-radius: var(--radius-tile);
  background: var(--color-sable-100);
  color: var(--color-ink);
}

.voice-queue-failure-face {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.voice-queue-failure-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.voice-queue-failure-transcript {
  margin: 0;
  font-size: 17px;
  line-height: 22px;
}

.voice-queue-failure-transcript strong,
.voice-event-group-time {
  font-variant-numeric: tabular-nums;
}

.voice-queue-failure-reason {
  margin: 0;
  font-size: 16px;
  line-height: 21px;
  color: var(--color-sable-600);
}



.voice-event-group-validate-all {
  flex-shrink: 0;
  white-space: nowrap;
}

.voice-queue-failure-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

@container voice-page (max-width: 639px) {
  .voice-queue-failure {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 18px;
  }

  .voice-queue-failure-text {
    flex-basis: calc(100% - 42px);
  }

  .voice-queue-failure-actions {
    flex-basis: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .voice-queue-failure-reason {
    font-size: 15px;
    line-height: 20px;
  }
}

/* One dictation: a white panel, its sentence on top, then one line per event. */
.voice-event-group {
  container: voice-group / inline-size;
  background: var(--color-surface);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-raised);
  overflow: hidden;
}

.voice-event-group-header {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 56px;
  padding: 10px 12px 10px 22px;
  border-bottom: 1px solid var(--color-sable-200);
}

.voice-event-group-said {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

/* Collapsed transcript: 3 lines, « Afficher plus » when it runs longer (CRE-209). */
.voice-event-group-transcript {
  margin: 0;
  font-size: 18px;
  line-height: 24px;
  color: var(--color-ink);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: max-height 200ms ease-out;
}

.voice-event-group--expanded .voice-event-group-transcript {
  -webkit-line-clamp: unset;
}

.voice-event-group-toggle[hidden] {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .voice-event-group-transcript {
    transition: none;
  }
}

.voice-event-group-time {
  margin-right: 12px;
  font-size: 15px;
  font-weight: 700;
  color: var(--color-sable-600);
}

.voice-event-group-date-pill {
  display: inline-block;
  padding: 1px 10px;
  border-radius: 9999px;
  background: var(--color-sable-100);
  font-size: 15px;
  line-height: 22px;
  color: var(--color-ink);
}



.voice-event-group-cards > .voice-event-card + .voice-event-card {
  border-top: 1px solid var(--color-sable-100);
}

/* One line (event or absence). Wide: child · type · time · comment · actions in one row. */
.voice-event-card {
  display: grid;
  grid-template-columns: 180px 164px 124px minmax(0, 1fr) auto;
  grid-template-areas:
    "child type time comment actions"
    "extra extra extra extra extra"
    "warn warn warn warn warn";
  align-items: center;
  column-gap: 14px;
  padding: 10px 12px 10px 22px;
  color: var(--color-ink);
}

.voice-line-who {
  display: contents;
}

.voice-line-child {
  grid-area: child;
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 48px;
  border-radius: var(--radius-field);
  cursor: pointer;
}

.voice-line-child:focus-within {
  outline: 3px solid var(--color-primary-950);
  outline-offset: 2px;
}

.voice-line-child-name {
  font-size: 18px;
  font-weight: 700;
  line-height: 24px;
  overflow-wrap: anywhere;
}

.voice-line-child-select {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  font-size: 18px;
}

.voice-line-type {
  grid-area: type;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 17px;
  line-height: 22px;
}

.voice-line-type-dot {
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 14px;
}

.voice-line-time {
  grid-area: time;
  width: 124px;
  height: 48px;
  padding: 0 8px;
  border: 1.5px solid var(--color-sable-200);
  border-radius: var(--radius-field);
  background: var(--color-paper);
  color: var(--color-ink);
  font-size: 21px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

@media (pointer: coarse) {
  .voice-line-time::-webkit-calendar-picker-indicator {
    display: none;
  }
}

.voice-absence-dates {
  grid-area: time;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 16px;
  line-height: 20px;
}

.voice-line-comment {
  grid-area: comment;
  display: flex;
  gap: 8px;
  min-width: 0;
}

.voice-line-comment textarea {
  flex: 1;
  min-width: 0;
  field-sizing: content;
  min-height: 48px;
  padding: 12px 14px;
  border: 1.5px solid var(--color-sable-200);
  border-radius: var(--radius-field);
  background: var(--color-paper);
  color: var(--color-ink);
  font-size: 17px;
  line-height: 22px;
  resize: none;
  overflow-y: auto;
  scrollbar-width: none;
}

.voice-line-comment textarea::placeholder {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--color-sable-600);
}


.voice-line-decision {
  display: contents;
}

.voice-line-actions {
  grid-area: actions;
  display: flex;
  gap: 8px;
}

.voice-card-preflight {
  grid-area: warn;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}

@container voice-group (min-width: 880px) and (max-width: 1119px) {
  .voice-event-card {
    grid-template-columns: 180px minmax(0, 1fr) 124px auto;
    grid-template-areas:
      "child type time actions"
      "comment comment comment comment"
      "warn warn warn warn";
    row-gap: 10px;
  }

  .voice-card-preflight {
    margin-top: 0;
  }
}

/* Stacked line: phone, upright tablet. */
@container voice-group (max-width: 879px) {
  .voice-event-group-header {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 14px 16px;
  }

  .voice-event-group-transcript {
    font-size: 17px;
    line-height: 23px;
  }

  .voice-event-group-time {
    margin-right: 4px;
    font-size: 17px;
    color: var(--color-ink);
  }

  .voice-event-card {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "who time"
      "comment comment"
      "warn warn"
      "actions actions";
    row-gap: 10px;
    padding: 12px 16px 14px;
  }

  .voice-line-who {
    grid-area: who;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 6px;
    min-width: 0;
  }

  .voice-line-child {
    min-height: 44px;
    gap: 8px;
  }

  .voice-line-type {
    font-weight: 700;
    color: var(--color-primary-800);
    font-size: 18px;
  }

  .voice-line-type::before {
    content: "·";
    color: var(--color-ink);
  }

  .voice-line-type-dot {
    display: none;
  }

  .voice-line-time {
    width: 100px;
    font-size: 20px;
  }

  .voice-absence-dates {
    text-align: right;
  }

  .voice-card-preflight {
    margin-top: 0;
  }

  .voice-line-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Warnings: words on sand, never red — nothing missing is shown in red. */
.voice-card-preflight-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-field);
  background: var(--color-sable-100);
  color: var(--color-ink);
  font-size: 16px;
  line-height: 20px;
}

.voice-card-preflight-primary {
  font-weight: 700;
}

.voice-card-preflight-row--info {
  background: var(--color-primary-100);
}

/* Tab badge bubble — bottom nav / desktop tab */
.voice-queue-tab-badge {
  position: absolute;
  top: -0.4rem;
  right: -0.65rem;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary-950);
  background: var(--color-success-500);
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  border: 2px solid var(--color-surface, white);
  font-variant-numeric: tabular-nums;
  pointer-events: none;
  transition: transform 150ms ease-out;
}

.voice-queue-tab-badge.voice-queue-tab-badge-empty {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  .voice-queue-tab-badge.voice-queue-tab-badge-bounce {
    animation: voice-queue-tab-badge-bounce 600ms ease-out;
  }
}

@media (prefers-reduced-motion: reduce) {
  .voice-queue-tab-badge.voice-queue-tab-badge-bounce {
    box-shadow: 0 0 0 3px rgba(3, 218, 168, 0.45);
  }
}

@keyframes voice-queue-tab-badge-bounce {
  0%   { transform: scale(1); }
  35%  { transform: scale(1.22); }
  70%  { transform: scale(0.96); }
  100% { transform: scale(1); }
}

/* Processing pill — mirrors the tab-badge geometry on the opposite corner.
   Icon-only spinner ; the count is exposed via aria-label so the surface
   stays tight inside the navbar icon slot. */
.voice-queue-processing-pill {
  position: absolute;
  top: -0.4rem;
  left: -0.55rem;
  width: 1.05rem;
  height: 1.05rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  line-height: 1;
  color: #08ad9f;
  background: var(--color-surface, white);
  border-radius: 9999px;
  border: 2px solid var(--color-surface, white);
  box-shadow: 0 0 0 1px rgba(8, 173, 159, 0.35);
  pointer-events: none;
}

.voice-queue-processing-pill.voice-queue-processing-pill-empty {
  display: none;
}


@media (prefers-reduced-motion: reduce) {
  .voice-line-comment textarea,
  .voice-queue-tab-badge {
    transition: none;
  }
}
/* Design System - Main Index */

/* Base Styles */
* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-primary);
  font-size: var(--font-size-body);
  line-height: var(--line-height-normal);
  color: var(--color-text-primary);
  background-color: var(--color-background);
  transition: background-color var(--duration-slow) var(--ease-in-out),
              color var(--duration-slow) var(--ease-in-out);
}

button:active:not(:disabled),
input[type="submit"]:active:not(:disabled),
.pressable:active {
  transform: translateY(1px);
  filter: brightness(0.88);
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Focus Visible */
:focus-visible,
.peer:focus-visible + * {
  outline: 3px solid var(--color-primary-950);
  outline-offset: 2px;
}

input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]):focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--color-primary-700);
  box-shadow: inset 0 0 0 1px var(--color-primary-700);
}

/* Selection */
::selection {
  background-color: var(--color-primary-200);
  color: var(--color-primary-900);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 0.5rem;
  height: 0.5rem;
}

::-webkit-scrollbar-track {
  background: var(--color-gray-100);
}

::-webkit-scrollbar-thumb {
  background: var(--color-gray-400);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-gray-500);
}

/* Links — in @layer base so Tailwind utilities (text-*, hover:*) win without
   !important. Hover adds underline only, never a color shift (brand.md §14);
   non-text <a> roles (buttons, nav items, cards) opt out via the
   text-decoration block in application.css. */
@layer base {
  a {
    color: var(--color-primary-600);
    text-decoration: none;
    transition: text-decoration-color var(--duration-fast) var(--ease-out);
  }

  a:hover,
  a:focus-visible {
    text-decoration: underline;
  }
}

/* Lists */
ul, ol {
  padding-left: var(--space-6);
  margin: var(--space-4) 0;
}

li {
  margin-bottom: var(--space-2);
}

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-4) 0;
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
}

h1 { font-size: var(--font-size-h1); }
h2 { font-size: var(--font-size-h2); }
h3 { font-size: var(--font-size-h3); }
h4 { font-size: var(--font-size-h4); }

/* Paragraphs */
p {
  margin: 0 0 var(--space-4) 0;
}

/* Code */
code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  padding: 0.125rem 0.25rem;
  background-color: var(--color-gray-100);
  border-radius: var(--radius-sm);
}

pre {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  padding: var(--space-4);
  background-color: var(--color-gray-100);
  border-radius: var(--radius-md);
  overflow-x: auto;
}

pre code {
  padding: 0;
  background-color: transparent;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-4) 0;
}

th, td {
  padding: var(--space-3);
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

th {
  font-weight: var(--font-weight-semibold);
  background-color: var(--color-gray-50);
}

/* Blockquote */
blockquote {
  margin: var(--space-4) 0;
  padding: var(--space-4);
  border-left: 4px solid var(--color-primary-500);
  background-color: var(--color-gray-50);
  font-style: italic;
}

/* HR */
hr {
  margin: var(--space-8) 0;
  border: none;
  border-top: 1px solid var(--color-border);
}

/* Utility Classes for Common Patterns */
.container-fluid {
  width: 100%;
  padding-left: var(--container-padding-mobile);
  padding-right: var(--container-padding-mobile);
}

@media (min-width: 768px) {
  .container-fluid {
    padding-left: var(--container-padding-tablet);
    padding-right: var(--container-padding-tablet);
  }
}

@media (min-width: 1280px) {
  .container-fluid {
    padding-left: var(--container-padding-desktop);
    padding-right: var(--container-padding-desktop);
  }
}

/* Page Wrapper */
.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-content {
  flex: 1;
  padding-top: var(--section-spacing-mobile);
}

@media (min-width: 768px) {
  .page-content {
    padding-top: var(--section-spacing-tablet);
  }
}

@media (min-width: 1280px) {
  .page-content {
    padding-top: var(--section-spacing-desktop);
  }
}

/* Section */
.section {
  margin-bottom: var(--section-spacing-mobile);
}

@media (min-width: 768px) {
  .section {
    margin-bottom: var(--section-spacing-tablet);
  }
}

@media (min-width: 1280px) {
  .section {
    margin-bottom: var(--section-spacing-desktop);
  }
}

/* Print Styles */
@media print {
  body {
    background: white;
    color: black;
  }
  
  .no-print {
    display: none !important;
  }
  
  a {
    color: black;
    text-decoration: underline;
  }
  
  .navbar,
  .sidebar,
  .bottom-nav,
  .voice-bar-container,
  .modal,
  .toast-container {
    display: none !important;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
/* Design System - Animation Tokens */

:root {
  /* Transition Durations */
  --duration-instant: 0ms;
  --duration-fast: 150ms;
  --duration-base: 200ms;
  --duration-slow: 300ms;
  --duration-slower: 400ms;
  --duration-slowest: 500ms;

  /* Transition Timing Functions */
  --ease-linear: linear;
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.68, -0.55, 0.265, 1.55);
  --ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);

  /* Common Transitions */
  --transition-all: all var(--duration-base) var(--ease-in-out);
  --transition-colors: background-color var(--duration-base) var(--ease-in-out),
                      border-color var(--duration-base) var(--ease-in-out),
                      color var(--duration-base) var(--ease-in-out),
                      fill var(--duration-base) var(--ease-in-out),
                      stroke var(--duration-base) var(--ease-in-out);
  --transition-opacity: opacity var(--duration-base) var(--ease-in-out);
  --transition-shadow: box-shadow var(--duration-base) var(--ease-in-out);
  --transition-transform: transform var(--duration-base) var(--ease-in-out);
}

/* Keyframe Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

@keyframes slideInUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideInDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideInLeft {
  from {
    transform: translateX(-100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes scaleOut {
  from {
    transform: scale(1);
    opacity: 1;
  }
  to {
    transform: scale(0.9);
    opacity: 0;
  }
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

@keyframes bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-25%);
  }
}

@keyframes shake {
  0%, 100% {
    transform: translateX(0);
  }
  10%, 30%, 50%, 70%, 90% {
    transform: translateX(-10px);
  }
  20%, 40%, 60%, 80% {
    transform: translateX(10px);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

/* Loading Animations */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes skeleton {
  0% {
    background-position: -200px 0;
  }
  100% {
    background-position: calc(200px + 100%) 0;
  }
}

/* Animation Classes */
.animate-fade-in {
  animation: fadeIn var(--duration-slow) var(--ease-out);
}

.animate-fade-out {
  animation: fadeOut var(--duration-slow) var(--ease-in);
}

.animate-slide-up {
  animation: slideInUp var(--duration-slow) var(--ease-out);
}

.animate-slide-down {
  animation: slideInDown var(--duration-slow) var(--ease-out);
}

.animate-slide-left {
  animation: slideInLeft var(--duration-slow) var(--ease-out);
}

.animate-slide-right {
  animation: slideInRight var(--duration-slow) var(--ease-out);
}

.animate-scale-in {
  animation: scaleIn var(--duration-base) var(--ease-spring);
}

.animate-scale-out {
  animation: scaleOut var(--duration-base) var(--ease-in);
}

.animate-pulse {
  animation: pulse 2s var(--ease-in-out) infinite;
}

.animate-bounce {
  animation: bounce 1s var(--ease-bounce) infinite;
}

.animate-shake {
  animation: shake 0.5s var(--ease-in-out);
}

.animate-spin {
  animation: spin 1s var(--ease-linear) infinite;
}

/* Transition Utilities */
.transition-all {
  transition: var(--transition-all);
}

.transition-colors {
  transition: var(--transition-colors);
}

.transition-opacity {
  transition: var(--transition-opacity);
}

.transition-shadow {
  transition: var(--transition-shadow);
}

.transition-transform {
  transition: var(--transition-transform);
}

.transition-none {
  transition: none;
}

/* Duration Modifiers */
.duration-fast {
  transition-duration: var(--duration-fast);
}

.duration-base {
  transition-duration: var(--duration-base);
}

.duration-slow {
  transition-duration: var(--duration-slow);
}

.duration-slower {
  transition-duration: var(--duration-slower);
}

/* Delay Utilities */
.delay-75 {
  transition-delay: 75ms;
}

.delay-100 {
  transition-delay: 100ms;
}

.delay-150 {
  transition-delay: 150ms;
}

.delay-200 {
  transition-delay: 200ms;
}

.delay-300 {
  transition-delay: 300ms;
}

/* Skeleton Loading */
.skeleton {
  background: linear-gradient(
    90deg,
    var(--color-gray-200) 25%,
    var(--color-gray-100) 50%,
    var(--color-gray-200) 75%
  );
  background-size: 200% 100%;
  animation: skeleton 1.5s ease-in-out infinite;
}

/* Shimmer Effect */
.shimmer {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s ease-in-out infinite;
}

/* Hover Scale */
.hover-scale {
  transition: transform var(--duration-base) var(--ease-in-out);
}

.hover-scale:hover {
  transform: scale(1.05);
}

.hover-scale-sm:hover {
  transform: scale(1.02);
}

.hover-scale-lg:hover {
  transform: scale(1.1);
}

/* Focus Scale */
.focus-scale {
  transition: transform var(--duration-base) var(--ease-in-out);
}

.focus-scale:focus {
  transform: scale(1.05);
}

/* Active Scale */
.active-scale:active {
  transform: scale(0.95);
}

/* Smooth Scroll */
.smooth-scroll {
  scroll-behavior: smooth;
}

/* GPU Acceleration */
.gpu-accelerated {
  transform: translateZ(0);
  will-change: transform;
}
/* Design System - Shadow Tokens */

:root {
  /* Base Shadow Scale */
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-sm: 0 2px 4px -1px rgba(0, 0, 0, 0.06), 0 1px 2px -1px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 6px -2px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.12), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  --shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);
  --shadow-none: none;

  /* Colored Shadows */
  --shadow-success: 0 4px 14px 0 rgba(34, 197, 94, 0.2);
  --shadow-warning: 0 4px 14px 0 rgba(245, 158, 11, 0.2);
  --shadow-error: 0 4px 14px 0 rgba(239, 68, 68, 0.2);

  /* Component Shadows */
  --dropdown-shadow: var(--shadow-xl);
  --modal-shadow: var(--shadow-2xl);
  --tooltip-shadow: var(--shadow-lg);

  /* Text Shadows */
  --text-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.1);
  --text-shadow-md: 0 2px 4px rgba(0, 0, 0, 0.15);
  --text-shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Shadow Utilities */
.shadow-xs { box-shadow: var(--shadow-xs); }
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }
.shadow-2xl { box-shadow: var(--shadow-2xl); }
.shadow-inner { box-shadow: var(--shadow-inner); }
.shadow-none { box-shadow: var(--shadow-none); }

/* Colored Shadow Utilities */
.shadow-success { box-shadow: var(--shadow-success); }
.shadow-warning { box-shadow: var(--shadow-warning); }
.shadow-error { box-shadow: var(--shadow-error); }

/* Glassmorphism Shadow */

/* Text Shadow Utilities */
.text-shadow-sm { text-shadow: var(--text-shadow-sm); }
.text-shadow-md { text-shadow: var(--text-shadow-md); }
.text-shadow-lg { text-shadow: var(--text-shadow-lg); }
.text-shadow-none { text-shadow: none; }

/* Elevation Classes - Combines shadows with subtle transforms */
.elevation-0 {
  box-shadow: var(--shadow-none);
  transform: translateY(0);
}

.elevation-1 {
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

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

.elevation-3 {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.elevation-4 {
  box-shadow: var(--shadow-xl);
  transform: translateY(-4px);
}

/* Hover Elevation Transitions */
.hover-elevate {
  transition: box-shadow 200ms ease-in-out, transform 200ms ease-in-out;
}

.hover-elevate:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}
/* Design System - Spacing Tokens */

:root {
  /* Base Spacing Scale */
  --space-0: 0;
  --space-1: 0.25rem;  /* 4px */
  --space-2: 0.5rem;   /* 8px */
  --space-3: 0.75rem;  /* 12px */
  --space-4: 1rem;     /* 16px */
  --space-5: 1.5rem;   /* 24px */
  --space-6: 2rem;     /* 32px */
  --space-7: 2.5rem;   /* 40px */
  --space-8: 3rem;     /* 48px */
  --space-9: 3.5rem;   /* 56px */
  --space-10: 4rem;    /* 64px */
  --space-11: 5rem;    /* 80px */
  --space-12: 6rem;    /* 96px */
  --space-14: 8rem;    /* 128px */
  --space-16: 10rem;   /* 160px */

  /* Component Spacing */
  --space-xs: var(--space-2);
  --space-sm: var(--space-3);
  --space-md: var(--space-4);
  --space-lg: var(--space-6);
  --space-xl: var(--space-8);
  --space-2xl: var(--space-12);

  /* Layout Spacing */
  --container-padding-mobile: var(--space-4);
  --container-padding-tablet: var(--space-6);
  --container-padding-desktop: var(--space-8);
  
  --section-spacing-mobile: var(--space-1);
  --section-spacing-tablet: var(--space-2);
  --section-spacing-desktop: var(--space-3);

  /* Component-Specific Spacing */
  --form-spacing: var(--space-4);
  --form-group-spacing: var(--space-6);
  
  --nav-item-spacing: var(--space-3);
  --nav-section-spacing: var(--space-6);

  /* Border Radius Scale */
  --radius-none: 0;
  --radius-xs: 0.25rem;   /* 4px */
  --radius-sm: 0.5rem;    /* 8px */
  --radius-md: 0.75rem;   /* 12px */
  --radius-lg: 1rem;      /* 16px */
  --radius-xl: 1.25rem;   /* 20px */
  --radius-2xl: 1.5rem;   /* 24px */
  --radius-3xl: 2rem;     /* 32px */
  --radius-full: 9999px;

  /* Radius doctrine: surfaces = --radius-lg (1rem, Tailwind rounded-2xl);
     controls = --radius-md (0.75rem, rounded-xl); chips = rounded-md;
     pills/avatars = full. Inner elements sit one step below their container;
     a surface inside a surface is inset with margin, never flush. */

  /* Component Border Radius */
  --input-radius: var(--radius-md);
  --badge-radius: var(--radius-full);
  --avatar-radius: var(--radius-full);

  /* Z-Index Scale */
  --z-negative: -1;
  --z-0: 0;
  --z-10: 10;
  --z-20: 20;
  --z-30: 30;
  --z-40: 40;
  --z-50: 50;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-modal-backdrop: 300;
  --z-modal: 400;
  --z-popover: 500;
  --z-tooltip: 600;
  --z-notification: 700;
  --z-max: 9999;
}

/* Spacing Utilities */
.p-0 { padding: var(--space-0); }
.p-1 { padding: var(--space-1); }
.p-2 { padding: var(--space-2); }
.p-3 { padding: var(--space-3); }
.p-4 { padding: var(--space-4); }
.p-5 { padding: var(--space-5); }
.p-6 { padding: var(--space-6); }
.p-8 { padding: var(--space-8); }
.p-10 { padding: var(--space-10); }
.p-12 { padding: var(--space-12); }

.px-0 { padding-left: var(--space-0); padding-right: var(--space-0); }
.px-1 { padding-left: var(--space-1); padding-right: var(--space-1); }
.px-2 { padding-left: var(--space-2); padding-right: var(--space-2); }
.px-3 { padding-left: var(--space-3); padding-right: var(--space-3); }
.px-4 { padding-left: var(--space-4); padding-right: var(--space-4); }
.px-5 { padding-left: var(--space-5); padding-right: var(--space-5); }
.px-6 { padding-left: var(--space-6); padding-right: var(--space-6); }
.px-8 { padding-left: var(--space-8); padding-right: var(--space-8); }

.py-0 { padding-top: var(--space-0); padding-bottom: var(--space-0); }
.py-1 { padding-top: var(--space-1); padding-bottom: var(--space-1); }
.py-2 { padding-top: var(--space-2); padding-bottom: var(--space-2); }
.py-3 { padding-top: var(--space-3); padding-bottom: var(--space-3); }
.py-4 { padding-top: var(--space-4); padding-bottom: var(--space-4); }
.py-5 { padding-top: var(--space-5); padding-bottom: var(--space-5); }
.py-6 { padding-top: var(--space-6); padding-bottom: var(--space-6); }
.py-8 { padding-top: var(--space-8); padding-bottom: var(--space-8); }

/* Margin utilities follow same pattern */
.m-0 { margin: var(--space-0); }
.m-1 { margin: var(--space-1); }
.m-2 { margin: var(--space-2); }
.m-3 { margin: var(--space-3); }
.m-4 { margin: var(--space-4); }
.m-5 { margin: var(--space-5); }
.m-6 { margin: var(--space-6); }
.m-8 { margin: var(--space-8); }

.mx-auto { margin-left: auto; margin-right: auto; }
.my-auto { margin-top: auto; margin-bottom: auto; }

/* Gap utilities for flexbox/grid */
.gap-0 { gap: var(--space-0); }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

/* Border Radius Utilities */
.rounded-none { border-radius: var(--radius-none); }
.rounded-sm { border-radius: var(--radius-sm); }
.rounded { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-2xl { border-radius: var(--radius-2xl); }
.rounded-full { border-radius: var(--radius-full); }

/* Responsive Container */
.container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding-mobile);
  padding-right: var(--container-padding-mobile);
}

@media (min-width: 640px) {
  .container {
    max-width: 640px;
  }
}

@media (min-width: 768px) {
  .container {
    max-width: 768px;
    padding-left: var(--container-padding-tablet);
    padding-right: var(--container-padding-tablet);
  }
}

@media (min-width: 1024px) {
  .container {
    max-width: 1024px;
  }
}

@media (min-width: 1280px) {
  .container {
    max-width: 1280px;
    padding-left: var(--container-padding-desktop);
    padding-right: var(--container-padding-desktop);
  }
}

@media (min-width: 1536px) {
  .container {
    max-width: 1536px;
  }
}
/* Design System - Typography Tokens */

:root {
  /* Font Families */
  --font-primary: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, sans-serif;
  --font-display: var(--font-primary);
  --font-accent: var(--font-primary);
  --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, 'Courier New', monospace;

  /* Font Sizes - Fluid Typography */
  --font-size-display: clamp(2rem, 5vw, 3rem);
  --font-size-h1: clamp(1.875rem, 4vw, 2.25rem);
  --font-size-h2: clamp(1.5rem, 3vw, 1.875rem);
  --font-size-h3: clamp(1.25rem, 2.5vw, 1.5rem);
  --font-size-h4: clamp(1.125rem, 2vw, 1.25rem);
  --font-size-body: clamp(0.875rem, 1.5vw, 1rem);
  --font-size-small: clamp(0.75rem, 1.2vw, 0.875rem);
  --font-size-xs: 0.75rem;

  /* Line Heights */
  --line-height-tight: 1.2;
  --line-height-snug: 1.375;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.625;
  --line-height-loose: 2;

  /* Font Weights */
  --font-weight-light: 300;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  /* Letter Spacing */
  --letter-spacing-tighter: -0.05em;
  --letter-spacing-tight: -0.025em;
  --letter-spacing-normal: 0;
  --letter-spacing-wide: 0.025em;
  --letter-spacing-wider: 0.05em;

  /* Text Decoration */
  --text-decoration-underline-offset: 0.2em;
  --text-decoration-thickness: 0.1em;
}

/* Typography Classes */
.text-h1 {
  font-family: var(--font-display);
  font-size: var(--font-size-h1);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
}

.text-h2 {
  font-family: var(--font-display);
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-snug);
  letter-spacing: var(--letter-spacing-tight);
}

.text-h3 {
  font-family: var(--font-primary);
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-snug);
}

.text-h4 {
  font-family: var(--font-primary);
  font-size: var(--font-size-h4);
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-normal);
}

.text-small {
  font-family: var(--font-primary);
  font-size: var(--font-size-small);
  font-weight: var(--font-weight-normal);
  line-height: var(--line-height-normal);
}

/* No font-family/font-weight here: .text-xs is also a Tailwind utility carried by
   Font Awesome icons (IconComponent size :xs) — re-fonting it breaks their glyphs. */
.text-xs {
  font-size: var(--font-size-xs);
  line-height: var(--line-height-normal);
}

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

.text-mono {
  font-family: var(--font-mono);
  font-size: 0.875em;
}

/* Text Utilities */
.text-primary {
  color: var(--color-text-primary);
}

.text-secondary {
  color: var(--color-text-secondary);
}

.text-disabled {
  color: var(--color-text-disabled);
}

.text-inverse {
  color: var(--color-text-inverse);
}

/* Text Alignment */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-justify { text-align: justify; }

/* Text Transform */
.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

/* Text Decoration */
.underline {
  text-decoration: underline;
  text-underline-offset: var(--text-decoration-underline-offset);
  text-decoration-thickness: var(--text-decoration-thickness);
}

.line-through {
  text-decoration: line-through;
}

/* Truncation */
.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Morphing Shapes */
.blob {
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation: blobMorph 8s ease-in-out infinite;
}

@keyframes blobMorph {
  0%, 100% {
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  }
  33% {
    border-radius: 70% 30% 30% 70% / 70% 70% 30% 30%;
  }
  66% {
    border-radius: 30% 70% 70% 30% / 50% 30% 70% 50%;
  }
}

/* Noise Texture */
.noise {
  position: relative;
}

.noise::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' /%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(/%23noise)' opacity='0.02'/%3E%3C/svg%3E");
  pointer-events: none;
  opacity: 0.03;
}

/* Floating Animation */
.float {
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-20px);
  }
}

/* Stagger Animation */
.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  animation: staggerReveal 0.5s ease-out forwards;
}

@keyframes staggerReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }

/* Empty states — soft cloud backdrop (echoes the auth/charte clouds) + a
   gentle pop when the smiling picto appears (e.g. queue just emptied) */
.empty-clouds {
  position: relative;
  overflow: hidden;
}

.empty-clouds::before,
.empty-clouds::after {
  content: "";
  position: absolute;
  width: 11rem;
  height: 11rem;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.4;
  pointer-events: none;
}

.empty-clouds::before {
  top: -4rem;
  left: -3rem;
  background: var(--color-primary-100);
}

.empty-clouds::after {
  bottom: -4rem;
  right: -3rem;
  background: var(--color-accent-100);
}

.empty-pop {
  animation: empty-pop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes empty-pop {
  0% { transform: scale(0.4); opacity: 0; }
  100% { transform: scale(1); opacity: 0.8; }
}

@media (prefers-reduced-motion: reduce) {
  .empty-pop { animation: none; }
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */

html, body {
  font-family: var(--font-primary);
}

/* Wordmark is an SVG asset (charte 2026) — .logo-img sizes it per surface */
.logo-img {
  height: 2.5rem;
  width: auto;
  display: block;
}
.logo-img-sm {
  height: 2rem;
  width: auto;
  display: block;
}

/* Child name styling — primary-800 is the darkest teal that stays AA at body size */
.child-name {
  font-family: var(--font-primary);
  font-weight: 600;
  color: var(--color-primary-800);
}

/* Mobile Link Improvements */

/* Make navigation links larger on mobile */
@media (max-width: 767px) {
  .mobile-link {
    font-size: 1rem !important;
    padding: 0.5rem 0.75rem !important;
    margin: 0.25rem 0 !important;
    display: inline-block !important;
    min-height: 44px !important;
    min-width: 44px !important;
    display: flex !important;
    align-items: center !important;
  }
  
  /* Make list item links take the full width of their container */
  .mobile-list-item {
    padding: 0.75rem 1rem !important;
    display: flex !important;
    width: 100% !important;
  }

  /* Increase spacing between actionable items */
  .mobile-action-group {
    display: flex !important;
    flex-direction: column !important; 
    gap: 0.5rem !important;
  }
  
  /* Make buttons and actionable items larger */
  .mobile-action {
    min-height: 44px !important;
    min-width: 44px !important;
    padding: 0.5rem 0.75rem !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
  
  /* Special styling for icon-only links */
  .mobile-icon-link {
    min-height: 44px !important;
    min-width: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
  
  /* Make entire card/row clickable for navigation */
  .mobile-card-link {
    position: relative !important;
  }
  
  .mobile-card-link::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
  }
  
  /* Fix positioning within clickable cards */
  .mobile-card-link > * {
    position: relative;
    z-index: 2;
  }
}

/* Ensure no underlines on button links and card links */
a.inline-flex,
button a,
a[class*="rounded"],
a.block.group {
  text-decoration: none !important;
}

/* Prevent underline on hover for block group links */
a.block.group:hover {
  text-decoration: none !important;
}

/* Remove unwanted borders from timeline items and any list items */
.space-y-3 > div:last-child,
.space-y-4 > div:last-child,
li:last-child,
ul li:last-child,
ol li:last-child {
  border-bottom: none !important;
  border-top: none !important;
}

/* Specific fix for datetime-local inputs which often ignore padding */
input[type="datetime-local"],
input[type="date"],
input[type="time"] {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

select,
select.form-input {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
  background-position: right 0.5rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 2.5rem;
}

/* Ensure the icon containers are properly positioned */
.relative > .absolute.left-0.pl-3 {
  left: 0;
  padding-left: 0.75rem;
  z-index: 10;
}

/* Alert System */
.alert {
  border-radius: 0.5rem;
  padding: 1.25rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border: 1px solid;
}

.alert-success {
  background-color: var(--color-success-50);
  border-color: var(--color-success-200);
}

.alert-error {
  background-color: var(--color-danger-50);
  border-color: var(--color-danger-200);
}

.alert-warning {
  background-color: #fffbeb;
  border-color: #fed7aa;
}

.alert-info {
  background-color: var(--color-primary-50);
  border-color: var(--color-primary-200);
}

/* Turbo Frame loading state */
turbo-frame[busy] {
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

