@font-face {
  font-family: 'Baloo 2';
  src: url("/fonts/Baloo2-VariableFont_wght.woff2") format('woff2');
  font-weight: 400 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Nunito Sans';
  src: url("/fonts/NunitoSans-VariableFont.woff2") format('woff2');
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Nunito Sans';
  src: url("/fonts/NunitoSans-Italic-VariableFont.woff2") format('woff2');
  font-weight: 200 1000;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@tailwind base;
@tailwind components;
@tailwind utilities;

/* Accessibility: Global focus-visible styles */
@layer base {
  a:focus-visible,
  button:focus-visible,
  [role="button"]:focus-visible,
  input:focus-visible,
  select:focus-visible,
  textarea:focus-visible {
    @apply outline-none ring-2 ring-amber-500 ring-offset-2;
  }
}

/* Cropper.js styles */
.cropper-container {
  direction: ltr;
  font-size: 0;
  line-height: 0;
  position: relative;
  touch-action: none;
  user-select: none;
}

.cropper-container img {
  display: block;
  height: 100%;
  image-orientation: 0deg;
  max-height: none !important;
  max-width: none !important;
  min-height: 0 !important;
  min-width: 0 !important;
  width: 100%;
}

.cropper-wrap-box,
.cropper-canvas,
.cropper-drag-box,
.cropper-crop-box,
.cropper-modal {
  bottom: 0;
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
}

.cropper-wrap-box,
.cropper-canvas {
  overflow: hidden;
}

/* Solid background to prevent checkerboard transparency pattern */
.cropper-wrap-box {
  background-color: #1c1917 !important;
}

.cropper-canvas {
  background-color: #1c1917 !important;
}

.cropper-drag-box {
  background-color: #fff;
  opacity: 0;
}

.cropper-modal {
  /* Darker overlay to clearly show excluded area */
  background-color: rgba(0, 0, 0, 0.7) !important;
}

.cropper-view-box {
  display: block;
  height: 100%;
  outline: 3px solid #f59e0b;
  outline-offset: -3px;
  overflow: hidden;
  width: 100%;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.6);
}

.cropper-dashed {
  border: 0 dashed #eee;
  display: block;
  opacity: 0.5;
  position: absolute;
}

.cropper-dashed.dashed-h {
  border-bottom-width: 1px;
  border-top-width: 1px;
  height: calc(100% / 3);
  left: 0;
  top: calc(100% / 3);
  width: 100%;
}

.cropper-dashed.dashed-v {
  border-left-width: 1px;
  border-right-width: 1px;
  height: 100%;
  left: calc(100% / 3);
  top: 0;
  width: calc(100% / 3);
}

.cropper-center {
  display: block;
  height: 0;
  left: 50%;
  opacity: 0.75;
  position: absolute;
  top: 50%;
  width: 0;
}

.cropper-center::before,
.cropper-center::after {
  background-color: #eee;
  content: ' ';
  display: block;
  position: absolute;
}

.cropper-center::before {
  height: 1px;
  left: -3px;
  top: 0;
  width: 7px;
}

.cropper-center::after {
  height: 7px;
  left: 0;
  top: -3px;
  width: 1px;
}

.cropper-face,
.cropper-line,
.cropper-point {
  display: block;
  height: 100%;
  opacity: 0.1;
  position: absolute;
  width: 100%;
}

.cropper-face {
  background-color: #fff;
  left: 0;
  top: 0;
}

.cropper-line {
  background-color: rgba(255, 255, 255, 0.5);
}

.cropper-line.line-e {
  cursor: ew-resize;
  right: -3px;
  top: 0;
  width: 5px;
}

.cropper-line.line-n {
  cursor: ns-resize;
  height: 5px;
  left: 0;
  top: -3px;
}

.cropper-line.line-w {
  cursor: ew-resize;
  left: -3px;
  top: 0;
  width: 5px;
}

.cropper-line.line-s {
  bottom: -3px;
  cursor: ns-resize;
  height: 5px;
  left: 0;
}

.cropper-point {
  background-color: #f59e0b;
  height: 10px;
  opacity: 0.75;
  width: 10px;
}

.cropper-point.point-e {
  cursor: ew-resize;
  margin-top: -3px;
  right: -3px;
  top: 50%;
}

.cropper-point.point-n {
  cursor: ns-resize;
  left: 50%;
  margin-left: -3px;
  top: -3px;
}

.cropper-point.point-w {
  cursor: ew-resize;
  left: -3px;
  margin-top: -3px;
  top: 50%;
}

.cropper-point.point-s {
  bottom: -3px;
  cursor: s-resize;
  left: 50%;
  margin-left: -3px;
}

.cropper-point.point-ne {
  cursor: nesw-resize;
  right: -3px;
  top: -3px;
}

.cropper-point.point-nw {
  cursor: nwse-resize;
  left: -3px;
  top: -3px;
}

.cropper-point.point-sw {
  bottom: -3px;
  cursor: nesw-resize;
  left: -3px;
}

.cropper-point.point-se {
  bottom: -3px;
  cursor: nwse-resize;
  height: 20px;
  opacity: 1;
  right: -3px;
  width: 20px;
}

@media (min-width: 768px) {
  .cropper-point.point-se {
    height: 15px;
    width: 15px;
  }
}

.cropper-point.point-se::before {
  background-color: #f59e0b;
  bottom: -50%;
  content: ' ';
  display: block;
  height: 200%;
  opacity: 0;
  position: absolute;
  right: -50%;
  width: 200%;
}

.cropper-invisible {
  opacity: 0;
}

.cropper-bg {
  /* Solid dark background instead of checkerboard */
  background-color: #292524;
  background-image: none !important;
}

.cropper-hide {
  display: block;
  height: 0;
  position: absolute;
  width: 0;
}

.cropper-hidden {
  display: none !important;
}

.cropper-move {
  cursor: move;
}

.cropper-crop {
  cursor: crosshair;
}

.cropper-disabled .cropper-drag-box,
.cropper-disabled .cropper-face,
.cropper-disabled .cropper-line,
.cropper-disabled .cropper-point {
  cursor: not-allowed;
}

/* Circular avatar crop overlay */
.avatar-crop-circle .cropper-view-box,
.avatar-crop-circle .cropper-face {
  border-radius: 50%;
}

@layer components {
  /* Planning mode card selection */
  .planning-mode-card {
    @apply relative block;
  }

  .planning-mode-card-inner {
    @apply relative flex flex-row items-center gap-3 px-4 py-3 rounded-xl border-2 border-stone-200 bg-white transition-all;
  }

  .planning-mode-card:hover .planning-mode-card-inner {
    @apply border-stone-300 bg-stone-50;
  }

  .planning-mode-input:checked + .planning-mode-card-inner {
    @apply border-amber-500 bg-amber-50;
  }

  .planning-mode-check {
    @apply absolute -top-1.5 -left-1.5 w-5 h-5 rounded-full bg-amber-500 flex items-center justify-center opacity-0 transition-opacity;
  }

  .planning-mode-input:checked + .planning-mode-card-inner .planning-mode-check {
    @apply opacity-100;
  }

  .planning-mode-emoji {
    @apply text-xl flex-shrink-0;
  }

  .planning-mode-label {
    @apply text-sm text-stone-700;
  }

  /* Split-flap display animation */
  .split-flap-container {
    display: inline-block;
    vertical-align: baseline;
  }

  .split-flap-word {
    display: inline-grid;
    grid-auto-flow: column;
    grid-auto-columns: 0.6em;
    gap: 0.08em;
    perspective: 1000px;
    /* Reserve space to prevent layout shift before JS renders */
    /* 10 chars × 0.6em + 9 gaps × 0.08em ≈ 6.7em width */
    min-width: 6.7em;
    min-height: 1.2em;
  }

  .split-flap-char {
    position: relative;
    display: block;
    width: 100%;
    height: 1.2em;
    transform-style: preserve-3d;
    font: inherit;
    text-transform: lowercase;
  }

  /* All four flaps share these base styles */
  .split-flap-char .top,
  .split-flap-char .bottom,
  .split-flap-char .top-next,
  .split-flap-char .bottom-next {
    border-radius: 4px;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: white;
    background: linear-gradient(180deg, #1c1917 0%, #292524 100%);
    backface-visibility: hidden;
  }

  /* Top halves clipped */
  .split-flap-char .top,
  .split-flap-char .top-next {
    clip-path: polygon(0 0, 100% 0, 100% 50%, 0 50%);
  }

  /* Bottom halves clipped */
  .split-flap-char .bottom,
  .split-flap-char .bottom-next {
    clip-path: polygon(0 50%, 100% 50%, 100% 100%, 0 100%);
  }

  /* Divider line */
  .split-flap-char .divider {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background-color: #44403c;
    z-index: 10;
    transform: translateY(-50%);
  }

  /* Split-flap sound toggle button */
  .split-flap-sound-toggle {
    @apply p-1 text-stone-300 hover:text-stone-500 transition-colors rounded;
    /* Subtle appearance, doesn't distract from the animation */
  }

  .split-flap-sound-toggle:hover {
    @apply bg-stone-100;
  }

  /* When unmuted, show a subtle indicator */
  .split-flap-sound-toggle[data-active="true"] {
    @apply text-amber-500;
  }

  /* Toast animations */
  .animate-slide-up {
    animation: slideUp 0.3s ease-out forwards;
  }

  .animate-fade-out {
    animation: fadeOut 0.2s ease-out forwards;
  }
}

@keyframes bounce-x {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}

.animate-bounce-x {
  animation: bounce-x 1.5s ease-in-out infinite;
}

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

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

/* Suggestion map custom pins */
.suggestion-pin {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: default;
}

.suggestion-pin-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: #f59e0b; /* amber-500 */
  border: 2px solid #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Private home: house emoji dot instead of plain amber circle */
.suggestion-pin--home {
  /* Shift down so the dot center (12px from top) sits on the coordinate.
     Default AdvancedMarkerElement anchor = bottom-center of content. */
  transform: translateY(calc(100% - 12px));
}

.suggestion-pin-home-dot {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: #fffbeb; /* amber-50 */
  border: 2px solid #f59e0b; /* amber-500 */
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
}

/* Label chip — inline row with optional count pill */
.suggestion-pin-chip {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #ffffff;
  padding: 2px 6px;
  border-radius: 6px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
  white-space: nowrap;
  max-width: 150px;
  line-height: 1.3;
}

.suggestion-pin-chip--home {
  background: #fffbeb; /* amber-50 */
  border: 1px solid #fde68a; /* amber-200 */
}

.suggestion-pin-chip-text {
  font-size: 11px;
  font-weight: 600;
  color: #1c1917; /* stone-900 */
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Inline interest count pill inside the label chip */
.suggestion-pin-chip-count {
  flex-shrink: 0;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background-color: #f59e0b; /* amber-500 */
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

/* Cluster bubble — groups nearby pins at zoomed-out levels */
.suggestion-cluster {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: #f59e0b; /* amber-500 */
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  border: 3px solid #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  cursor: pointer;
}

/* === Wizard dark mode (when cover image is present) === */

/* Flip stone text to light on dark blurred background */
.wizard-dark .text-stone-400 { color: rgba(255, 255, 255, 0.45) !important; }
.wizard-dark .text-stone-500 { color: rgba(255, 255, 255, 0.6) !important; }
.wizard-dark .text-stone-600 { color: rgba(255, 255, 255, 0.7) !important; }
.wizard-dark .text-stone-700 { color: rgba(255, 255, 255, 0.8) !important; }
.wizard-dark .text-stone-900 { color: rgba(255, 255, 255, 0.95) !important; }

/* Instruction boxes: dark glass instead of light gray */
.wizard-dark .bg-stone-50 {
  background-color: rgba(0, 0, 0, 0.2) !important;
  backdrop-filter: blur(8px);
}

/* Borders: subtle white instead of stone */
.wizard-dark .border-stone-200 { border-color: rgba(255, 255, 255, 0.12) !important; }
.wizard-dark .border-stone-300 { border-color: rgba(255, 255, 255, 0.18) !important; }

/* Scroll hint gradient: dark instead of white */
.wizard-dark .bg-gradient-to-l.from-white { --tw-gradient-from: rgba(0, 0, 0, 0.3) !important; }
.wizard-dark .via-white\/90 { --tw-gradient-via: rgba(0, 0, 0, 0.2) !important; }

/* Range slider track */
.wizard-dark .bg-stone-200[type="range"] { background-color: rgba(255, 255, 255, 0.2) !important; }

/* Restore original colors inside white/light card containers and phone mockup */
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .text-stone-400 { color: #a8a29e !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .text-stone-500 { color: #78716c !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .text-stone-600 { color: #57534e !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .text-stone-700 { color: #44403c !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .text-stone-900 { color: #1c1917 !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .border-stone-200 { border-color: #e7e5e4 !important; }
.wizard-dark :is([class*="bg-white"], [class*="bg-amber-50"], .share-preview-phone) .border-stone-300 { border-color: #d6d3d1 !important; }
.wizard-dark .share-preview-phone .bg-stone-50 { background-color: #fafaf9 !important; backdrop-filter: none; }

/* Also restore text/border on elements that have both bg-white AND text-stone-* */
.wizard-dark [class*="bg-white"].text-stone-400 { color: #a8a29e !important; }
.wizard-dark [class*="bg-white"].text-stone-500 { color: #78716c !important; }
.wizard-dark [class*="bg-white"].text-stone-600 { color: #57534e !important; }
.wizard-dark [class*="bg-white"].text-stone-700 { color: #44403c !important; }
.wizard-dark [class*="bg-white"].text-stone-900 { color: #1c1917 !important; }
.wizard-dark [class*="bg-white"].border-stone-200,
.wizard-dark [class*="bg-amber-50"].border-stone-200 { border-color: #e7e5e4 !important; }
.wizard-dark [class*="bg-amber-50"].text-stone-400 { color: #a8a29e !important; }
.wizard-dark [class*="bg-amber-50"].text-stone-500 { color: #78716c !important; }
.wizard-dark [class*="bg-amber-50"].text-stone-600 { color: #57534e !important; }
.wizard-dark [class*="bg-amber-50"].text-stone-700 { color: #44403c !important; }
.wizard-dark [class*="bg-amber-50"].text-stone-900 { color: #1c1917 !important; }

/* ─── Dark mode (v2 scope) ─── */
@layer base {
  :root {
    --gl-page-bg: #1c1917;
    --gl-surface: #292524;
    --gl-surface-elevated: #44403c;
    --gl-border: #44403c;
    --gl-border-emphasis: #57534e;
    --gl-text-primary: #f5f5f4;
    --gl-text-secondary: #a8a29e;
    --gl-text-muted: #78716c;
  }
}

/* Slide panel: ensure base text color is light for the dark panel background.
   Tailwind classes still override via .gl-dark rules, but any element without
   an explicit color class inherits a readable light color instead of black. */
#v2-slide-panel [data-role="panel-content"] {
  color: var(--gl-text-primary);
}

/* Light-mode island: .gl-light inside .gl-dark resets Tailwind utilities to their
   original light-mode values. Used to wrap calendar grids and other shared partials
   that need to render light inside dark panels/drawers. The gl-dark selector + gl-light
   gives 2 class specificity; we add an extra class to beat .gl-dark's 2-class rules. */
.gl-dark .gl-light.gl-light { color-scheme: light; }
.gl-dark .gl-light .bg-white { background-color: #ffffff !important; }
.gl-dark .gl-light .bg-stone-50 { background-color: #fafaf9 !important; }
.gl-dark .gl-light .bg-stone-100 { background-color: #f5f5f4 !important; }
.gl-dark .gl-light .bg-stone-200 { background-color: #e7e5e4 !important; }
.gl-dark .gl-light .text-stone-900 { color: #1c1917 !important; }
.gl-dark .gl-light .text-stone-800 { color: #292524 !important; }
.gl-dark .gl-light .text-stone-700 { color: #44403c !important; }
.gl-dark .gl-light .text-stone-600 { color: #57534e !important; }
.gl-dark .gl-light .text-stone-500 { color: #78716c !important; }
.gl-dark .gl-light .text-stone-400 { color: #a8a29e !important; }
.gl-dark .gl-light .border-stone-200 { border-color: #e7e5e4 !important; }
.gl-dark .gl-light .border-stone-300 { border-color: #d6d3d1 !important; }
.gl-dark .gl-light .shadow-sm { box-shadow: 0 1px 2px 0 rgba(0,0,0,0.05) !important; }
.gl-dark .gl-light .bg-emerald-100 { background-color: #d1fae5 !important; }
.gl-dark .gl-light .bg-amber-100 { background-color: #fef3c7 !important; }
.gl-dark .gl-light .text-emerald-800 { color: #065f46 !important; }
.gl-dark .gl-light .text-emerald-700 { color: #047857 !important; }
.gl-dark .gl-light .text-amber-800 { color: #92400e !important; }
.gl-dark .gl-light .text-amber-600 { color: #d97706 !important; }
.gl-dark .gl-light .text-green-600 { color: #16a34a !important; }
.gl-dark .gl-light .text-blue-800 { color: #1e40af !important; }
.gl-dark .gl-light .bg-blue-100 { background-color: #dbeafe !important; }
.gl-dark .gl-light .bg-emerald-50 { background-color: #ecfdf5 !important; }
.gl-dark .gl-light .border-amber-300 { border-color: #fcd34d !important; }
.gl-dark .gl-light .border-amber-200 { border-color: #fde68a !important; }
.gl-dark .gl-light .border-green-300 { border-color: #86efac !important; }
.gl-dark .gl-light .text-red-500 { color: #ef4444 !important; }
.gl-dark .gl-light .text-amber-700 { color: #b45309 !important; }
.gl-dark .gl-light .text-stone-300 { color: #d6d3d1 !important; }
.gl-dark .gl-light .bg-green-300 { background-color: #86efac !important; }
.gl-dark .gl-light .border-green-500 { border-color: #22c55e !important; }
.gl-dark .gl-light .text-green-900 { color: #14532d !important; }
.gl-dark .gl-light .border-stone-100 { border-color: #f5f5f4 !important; }
.gl-dark .gl-light .bg-amber-50 { background-color: #fffbeb !important; }
.gl-dark .gl-light .border-amber-500 { border-color: #f59e0b !important; }
.gl-dark .gl-light .hover\:bg-stone-50:hover { background-color: #fafaf9 !important; }
.gl-dark .gl-light .hover\:bg-stone-200:hover { background-color: #e7e5e4 !important; }

/* Reset form inputs inside gl-light islands back to light mode */
.gl-dark .gl-light input,
.gl-dark .gl-light select,
.gl-dark .gl-light textarea {
  background-color: #ffffff;
  border-color: #e7e5e4;
  color: #1c1917;
  color-scheme: light;
}
.gl-dark .gl-light input::placeholder,
.gl-dark .gl-light textarea::placeholder {
  color: #a8a29e;
}

/* Scoped overrides: shared partials rendered inside .gl-dark get dark treatment
   automatically without modifying their Tailwind classes. */
.gl-dark .bg-white { background-color: var(--gl-surface) !important; }
.gl-dark .bg-stone-50 { background-color: var(--gl-page-bg) !important; }
.gl-dark .bg-stone-100 { background-color: var(--gl-surface) !important; }

.gl-dark .text-stone-900 { color: var(--gl-text-primary) !important; }
.gl-dark .text-stone-800 { color: var(--gl-text-primary) !important; }
.gl-dark .text-stone-700 { color: #e7e5e4 !important; }
.gl-dark .text-stone-600 { color: var(--gl-text-secondary) !important; }
.gl-dark .text-stone-500 { color: var(--gl-text-secondary) !important; }
.gl-dark .text-stone-400 { color: var(--gl-text-muted) !important; }

.gl-dark .border-stone-200 { border-color: var(--gl-border) !important; }
.gl-dark .border-stone-300 { border-color: var(--gl-border-emphasis) !important; }
.gl-dark .border-stone-100 { border-color: var(--gl-border) !important; }
.gl-dark .divide-stone-200 > :not([hidden]) ~ :not([hidden]) { border-color: var(--gl-border) !important; }

.gl-dark .hover\:bg-stone-50:hover { background-color: var(--gl-surface-elevated) !important; }
.gl-dark .hover\:bg-stone-100:hover { background-color: var(--gl-surface-elevated) !important; }
.gl-dark .hover\:bg-white:hover { background-color: var(--gl-surface) !important; }

.gl-dark .shadow-sm { box-shadow: 0 1px 2px 0 rgba(0,0,0,0.3) !important; }

/* Form inputs inside v2 */
.gl-dark input,
.gl-dark select,
.gl-dark textarea {
  background-color: var(--gl-surface);
  border-color: var(--gl-border-emphasis);
  color: var(--gl-text-primary);
  color-scheme: dark;
}
.gl-dark select option {
  background-color: var(--gl-surface);
  color: var(--gl-text-primary);
}
.gl-dark input::placeholder,
.gl-dark textarea::placeholder {
  color: var(--gl-text-muted);
}

/* Focus ring offset for dark backgrounds */
.gl-dark a:focus-visible,
.gl-dark button:focus-visible,
.gl-dark [role="button"]:focus-visible,
.gl-dark input:focus-visible,
.gl-dark select:focus-visible,
.gl-dark textarea:focus-visible {
  --tw-ring-offset-color: #1c1917;
}

/* Status color dark variants */
.gl-dark .bg-green-50 { background-color: #022c22 !important; }
.gl-dark .bg-yellow-50 { background-color: #451a03 !important; }
.gl-dark .bg-red-50 { background-color: #450a0a !important; }
.gl-dark .bg-amber-50 { background-color: rgba(69,26,3,0.3) !important; }

.gl-dark .border-green-200 { border-color: #065f46 !important; }
.gl-dark .border-yellow-200 { border-color: #92400e !important; }
.gl-dark .border-red-200 { border-color: #991b1b !important; }
.gl-dark .border-amber-200 { border-color: #92400e !important; }
.gl-dark .border-amber-300 { border-color: #b45309 !important; }

.gl-dark .text-green-700 { color: #34d399 !important; }
.gl-dark .text-green-800 { color: #34d399 !important; }
.gl-dark .text-green-600 { color: #34d399 !important; }
.gl-dark .text-yellow-700 { color: #fde68a !important; }
.gl-dark .text-yellow-600 { color: #fde68a !important; }
.gl-dark .text-yellow-800 { color: #fde68a !important; }
.gl-dark .text-red-700 { color: #f87171 !important; }
.gl-dark .text-amber-700 { color: #fde68a !important; }
.gl-dark .text-amber-800 { color: #fde68a !important; }
.gl-dark .text-amber-600 { color: #fbbf24 !important; }

.gl-dark .bg-green-100 { background-color: #064e3b !important; }
.gl-dark .bg-amber-100 { background-color: rgba(69,26,3,0.5) !important; }
.gl-dark .bg-red-100 { background-color: #7f1d1d !important; }
.gl-dark .bg-blue-50 { background-color: rgba(30,58,138,0.3) !important; }
.gl-dark .border-blue-200 { border-color: #1e40af !important; }
.gl-dark .text-blue-800 { color: #93c5fd !important; }

.gl-dark .bg-emerald-50 { background-color: #022c22 !important; }
.gl-dark .bg-teal-50 { background-color: #042f2e !important; }
.gl-dark .border-emerald-200 { border-color: #065f46 !important; }
.gl-dark .bg-emerald-100 { background-color: #064e3b !important; }
.gl-dark .text-emerald-700 { color: #34d399 !important; }
.gl-dark .text-emerald-600 { color: #34d399 !important; }

.gl-dark .bg-indigo-100 { background-color: rgba(49,46,129,0.5) !important; }
.gl-dark .text-indigo-600 { color: #a5b4fc !important; }
.gl-dark .hover\:border-indigo-400:hover { border-color: #818cf8 !important; }
.gl-dark .hover\:bg-indigo-50:hover { background-color: rgba(49,46,129,0.3) !important; }

/* Additional status text colors */
.gl-dark .text-blue-700 { color: #93c5fd !important; }
.gl-dark .text-emerald-800 { color: #34d399 !important; }

/* Additional status backgrounds */
.gl-dark .bg-blue-100 { background-color: rgba(30,58,138,0.5) !important; }
.gl-dark .bg-stone-200 { background-color: var(--gl-surface-elevated) !important; }

/* Hover variants for channel/action buttons */
.gl-dark .hover\:bg-emerald-100:hover { background-color: #064e3b !important; }
.gl-dark .hover\:bg-green-100:hover { background-color: #064e3b !important; }
.gl-dark .hover\:bg-blue-100:hover { background-color: rgba(30,58,138,0.5) !important; }
.gl-dark .hover\:bg-amber-50:hover { background-color: rgba(69,26,3,0.3) !important; }
.gl-dark .hover\:border-amber-400:hover { border-color: #f59e0b !important; }
.gl-dark .hover\:bg-amber-200:hover { background-color: rgba(69,26,3,0.5) !important; }
.gl-dark .hover\:text-stone-900:hover { color: var(--gl-text-primary) !important; }
.gl-dark .hover\:border-stone-300:hover { border-color: var(--gl-border-emphasis) !important; }
.gl-dark .hover\:text-amber-700:hover { color: #fde68a !important; }

/* Curation card overrides */
.gl-dark .border-green-300 { border-color: #065f46 !important; }
.gl-dark .bg-gradient-to-br.from-stone-100 { --tw-gradient-from: var(--gl-surface) !important; }
.gl-dark .bg-gradient-to-br.to-stone-200 { --tw-gradient-to: var(--gl-surface-elevated) !important; }
.gl-dark .hover\:bg-red-50:hover { background-color: #450a0a !important; }
.gl-dark .hover\:text-red-600:hover { color: #f87171 !important; }
.gl-dark .hover\:text-red-500:hover { color: #f87171 !important; }
.gl-dark .hover\:text-green-600:hover { color: #34d399 !important; }
.gl-dark .hover\:text-stone-600:hover { color: var(--gl-text-secondary) !important; }
.gl-dark .text-stone-300 { color: #d6d3d1 !important; }
.gl-dark .bg-stone-400 { background-color: var(--gl-text-muted) !important; }
.gl-dark .text-stone-400 { color: var(--gl-text-muted) !important; }

/* RSVP button hovers */
.gl-dark .hover\:border-green-300:hover { border-color: #065f46 !important; }
.gl-dark .hover\:bg-green-50:hover { background-color: #022c22 !important; }
.gl-dark .hover\:border-yellow-300:hover { border-color: #92400e !important; }
.gl-dark .hover\:bg-yellow-50:hover { background-color: #451a03 !important; }
.gl-dark .hover\:border-red-300:hover { border-color: #991b1b !important; }
.gl-dark .hover\:bg-red-50:hover { background-color: #450a0a !important; }

/* ═══════════════════════════════════════════
   Lantern flicker effect — header logo
   ═══════════════════════════════════════════ */

.lantern-wrap {
  position: relative;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.flame {
  position: absolute;
  width: 14px;
  height: 6px;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  margin-top: -3px;
  margin-left: -7px;
  background-color: #fee3ac;
  box-shadow:
    0 0 8px 4px rgba(254, 227, 172, 0.3),
    0 0 20px 10px rgba(245, 158, 11, 0.12);
  animation: flame 4s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.glow-ambient {
  position: absolute;
  inset: -18px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(245, 158, 11, 0.18) 0%,
    rgba(245, 158, 11, 0.05) 45%,
    transparent 70%
  );
  animation: lantern-ambient-pulse 4s ease-in-out infinite;
  pointer-events: none;
}

.glow-cast {
  position: absolute;
  top: -8px;
  left: -24px;
  width: 200px;
  height: 70px;
  background: radial-gradient(
    ellipse at 44px 32px,
    rgba(245, 158, 11, 0.06) 0%,
    transparent 65%
  );
  animation: lantern-ambient-pulse 4s ease-in-out infinite 0.2s;
  pointer-events: none;
}

.lantern-icon {
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.45));
  animation: lantern-bob 5s ease-in-out infinite;
}

.lantern-icon img {
  display: block;
}

@keyframes flame {
  0%   { height: 6px; opacity: 0.9;  box-shadow: 0 0 6px 3px rgba(254,227,172,0.35), 0 0 16px 8px rgba(245,158,11,0.12); transform: rotate(0deg) scaleX(1); }
  5%   { height: 4px; opacity: 0.7;  box-shadow: 0 0 4px 2px rgba(254,227,172,0.25), 0 0 12px 6px rgba(245,158,11,0.08); transform: rotate(-1deg) scaleX(0.9); }
  10%  { height: 7px; opacity: 0.85; box-shadow: 0 0 7px 3.5px rgba(254,225,167,0.3), 0 0 18px 9px rgba(245,158,11,0.1); transform: rotate(0.5deg) scaleX(1.05); }
  18%  { height: 4px; opacity: 0.65; box-shadow: 0 0 3px 1.5px rgba(254,222,157,0.2), 0 0 10px 5px rgba(245,158,11,0.06); transform: rotate(-0.5deg) scaleX(0.85); }
  23%  { height: 8px; opacity: 0.95; box-shadow: 0 0 8px 4px rgba(254,227,172,0.38), 0 0 22px 11px rgba(245,158,11,0.14); transform: rotate(1deg) scaleX(1.1); }
  30%  { height: 5px; opacity: 0.75; box-shadow: 0 0 5px 2.5px rgba(254,224,162,0.28), 0 0 14px 7px rgba(245,158,11,0.09); transform: rotate(-1.5deg) scaleX(0.92); }
  38%  { height: 7px; opacity: 0.88; box-shadow: 0 0 7px 3.5px rgba(254,219,147,0.32), 0 0 19px 9.5px rgba(245,158,11,0.11); transform: rotate(0.8deg) scaleX(1.02); }
  45%  { height: 3px; opacity: 0.6;  box-shadow: 0 0 3px 1.5px rgba(254,217,142,0.18), 0 0 8px 4px rgba(245,158,11,0.05); transform: rotate(-0.3deg) scaleX(0.8); }
  50%  { height: 6px; opacity: 0.82; box-shadow: 0 0 6px 3px rgba(254,222,157,0.3), 0 0 16px 8px rgba(245,158,11,0.1); transform: rotate(1.2deg) scaleX(1); }
  58%  { height: 4px; opacity: 0.72; box-shadow: 0 0 4px 2px rgba(254,225,167,0.22), 0 0 11px 5.5px rgba(245,158,11,0.07); transform: rotate(-0.8deg) scaleX(0.88); }
  65%  { height: 8px; opacity: 0.92; box-shadow: 0 0 8px 4px rgba(254,227,172,0.36), 0 0 20px 10px rgba(245,158,11,0.13); transform: rotate(0.3deg) scaleX(1.08); }
  72%  { height: 4px; opacity: 0.62; box-shadow: 0 0 3px 1.5px rgba(254,219,147,0.2), 0 0 9px 4.5px rgba(245,158,11,0.06); transform: rotate(-1.2deg) scaleX(0.85); }
  78%  { height: 7px; opacity: 0.87; box-shadow: 0 0 7px 3.5px rgba(254,224,162,0.33), 0 0 18px 9px rgba(245,158,11,0.11); transform: rotate(0.6deg) scaleX(1.04); }
  85%  { height: 5px; opacity: 0.78; box-shadow: 0 0 5px 2.5px rgba(254,222,157,0.26), 0 0 13px 6.5px rgba(245,158,11,0.08); transform: rotate(-0.5deg) scaleX(0.95); }
  92%  { height: 6px; opacity: 0.83; box-shadow: 0 0 6px 3px rgba(254,225,167,0.3), 0 0 15px 7.5px rgba(245,158,11,0.1); transform: rotate(0.8deg) scaleX(1); }
  100% { height: 6px; opacity: 0.9;  box-shadow: 0 0 6px 3px rgba(254,227,172,0.35), 0 0 16px 8px rgba(245,158,11,0.12); transform: rotate(0deg) scaleX(1); }
}

@keyframes lantern-ambient-pulse {
  0%, 100% { opacity: 1;    transform: scale(1); }
  18%      { opacity: 0.6;  transform: scale(0.96); }
  23%      { opacity: 0.95; transform: scale(1.03); }
  45%      { opacity: 0.5;  transform: scale(0.94); }
  65%      { opacity: 0.92; transform: scale(1.02); }
  72%      { opacity: 0.55; transform: scale(0.95); }
  85%      { opacity: 0.88; transform: scale(1.01); }
}

@keyframes lantern-bob {
  0%, 100% { transform: translateY(0); }
  40%      { transform: translateY(-1px); }
  70%      { transform: translateY(0.5px); }
}

@media (prefers-reduced-motion: reduce) {
  .flame,
  .glow-ambient,
  .glow-cast,
  .lantern-icon {
    animation: none;
  }
  .flame {
    opacity: 0.85;
    height: 6px;
  }
}

/* Hide scrollbar but allow scrolling */
.scrollbar-hide {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

.scrollbar-hide::-webkit-scrollbar {
  display: none;  /* Chrome, Safari, Opera */
}

