/* ==========================================================================
   HugeAstrology Unified Design System & Standardization Standards
   CSS tokens dynamically overridden by /internal-staff/editor-customization/
   ========================================================================== */

:root {
  --ha-font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --ha-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --ha-font-size-base: 14px;
  --ha-heading-weight: 900;

  /* Inputs & Forms */
  --ha-input-radius: 0.75rem;
  --ha-input-border: #e2e8f0;
  --ha-input-focus: #6366f1;
  --ha-input-bg-light: #ffffff;
  --ha-input-bg-dark: #0f172a;
  --ha-input-font-size: 14px;
  --ha-input-padding-y: 0.625rem;
  --ha-input-padding-x: 0.875rem;

  /* Buttons & Interactive Elements */
  --ha-btn-radius: 9999px;
  --ha-btn-primary-bg: #4f46e5;
  --ha-btn-primary-hover: #4338ca;
  --ha-btn-primary-text: #ffffff;
  --ha-btn-font-weight: 700;

  /* Secondary Button */
  --ha-btn-sec-bg-light: #f1f5f9;
  --ha-btn-sec-hover-light: #e2e8f0;
  --ha-btn-sec-text-light: #334155;
  --ha-btn-sec-bg-dark: #1e293b;
  --ha-btn-sec-hover-dark: #334155;
  --ha-btn-sec-text-dark: #f1f5f9;

  /* Links */
  --ha-link-color: #4f46e5;
  --ha-link-hover-color: #3730a3;
  --ha-link-hover-decoration: underline;

  /* Surfaces & Cards */
  --ha-card-radius: 1.25rem;
  --ha-card-bg-light: #ffffff;
  --ha-card-border-light: #e2e8f0;
  --ha-card-bg-dark: #0f172a;
  --ha-card-border-dark: #1e293b;
}

/* ==========================================================================
   1. Form Inputs, Textareas & Selects (.ha-input, .ha-textarea, .ha-select)
   ========================================================================== */

.ha-input,
.ha-textarea,
.ha-select {
  display: block;
  width: 100%;
  padding: var(--ha-input-padding-y) var(--ha-input-padding-x);
  font-family: var(--ha-font-sans);
  font-size: var(--ha-input-font-size);
  line-height: 1.5;
  color: #0f172a;
  background-color: var(--ha-input-bg-light);
  border: 1px solid var(--ha-input-border);
  border-radius: var(--ha-input-radius);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  box-sizing: border-box;
}

html.dark .ha-input,
html.dark .ha-textarea,
html.dark .ha-select,
.dark .ha-input,
.dark .ha-textarea,
.dark .ha-select {
  color: #f8fafc;
  background-color: var(--ha-input-bg-dark);
  border-color: #334155;
}

.ha-input:focus,
.ha-textarea:focus,
.ha-select:focus {
  outline: none;
  border-color: var(--ha-input-focus) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.22) !important;
}

.ha-input::placeholder,
.ha-textarea::placeholder {
  color: #94a3b8;
  opacity: 1;
}

/* ==========================================================================
   Standardized Search Bar Component (.ha-search-bar, .ha-input-search)
   ========================================================================== */
.ha-search-bar {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.ha-search-bar .ha-input,
.ha-search-bar input[type="text"],
.ha-search-bar input[type="search"],
.ha-input-search {
  padding-left: 2.75rem !important;
  padding-right: 1rem !important;
  border-radius: var(--ha-input-radius) !important;
}

.ha-search-bar .ha-search-icon {
  position: absolute;
  left: 0.875rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  color: #94a3b8;
  width: 1.125rem;
  height: 1.125rem;
  z-index: 2;
  transition: color 0.15s ease;
}

.ha-search-bar:focus-within .ha-search-icon {
  color: var(--ha-input-focus, #6366f1);
}

/* Form Groups & Labels */
.ha-form-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin-bottom: 0.375rem;
}

html.dark .ha-form-label,
.dark .ha-form-label {
  color: #94a3b8;
}

/* ==========================================================================
   2. Button System (.ha-btn, .ha-btn-primary, .ha-btn-secondary, etc.)
   ========================================================================== */

.ha-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--ha-font-sans);
  font-weight: var(--ha-btn-font-weight);
  font-size: 0.8125rem;
  line-height: 1.25;
  padding: 0.5rem 1.125rem;
  border-radius: var(--ha-btn-radius);
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: all 0.15s ease;
  text-decoration: none !important;
}

.ha-btn:active {
  transform: scale(0.97);
}

.ha-btn:disabled,
.ha-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* Primary Brand Action Button */
.ha-btn-primary {
  background-color: var(--ha-btn-primary-bg);
  color: var(--ha-btn-primary-text) !important;
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
}

.ha-btn-primary:hover {
  background-color: var(--ha-btn-primary-hover);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

/* Secondary Neutral Button */
.ha-btn-secondary {
  background-color: var(--ha-btn-sec-bg-light);
  color: var(--ha-btn-sec-text-light) !important;
  border-color: #e2e8f0;
}

.ha-btn-secondary:hover {
  background-color: var(--ha-btn-sec-hover-light);
}

html.dark .ha-btn-secondary,
.dark .ha-btn-secondary {
  background-color: var(--ha-btn-sec-bg-dark);
  color: var(--ha-btn-sec-text-dark) !important;
  border-color: #334155;
}

html.dark .ha-btn-secondary:hover,
.dark .ha-btn-secondary:hover {
  background-color: var(--ha-btn-sec-hover-dark);
}

/* Outline Ghost Button */
.ha-btn-outline {
  background-color: transparent;
  color: #475569 !important;
  border-color: #cbd5e1;
}

.ha-btn-outline:hover {
  background-color: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a !important;
}

html.dark .ha-btn-outline,
.dark .ha-btn-outline {
  color: #cbd5e1 !important;
  border-color: #475569;
}

html.dark .ha-btn-outline:hover,
.dark .ha-btn-outline:hover {
  background-color: #1e293b;
  border-color: #64748b;
  color: #f8fafc !important;
}

/* Danger Button */
.ha-btn-danger {
  background-color: #e11d48;
  color: #ffffff !important;
  border-color: transparent;
}

.ha-btn-danger:hover {
  background-color: #be123c;
}

/* Button Sizing */
.ha-btn-sm {
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
}

.ha-btn-lg {
  padding: 0.75rem 1.75rem;
  font-size: 0.9375rem;
}

/* ==========================================================================
   3. Link Styling (.ha-link)
   ========================================================================== */

.ha-link,
a.ha-link {
  color: var(--ha-link-color) !important;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease, text-decoration 0.15s ease;
}

.ha-link:hover,
a.ha-link:hover {
  color: var(--ha-link-hover-color) !important;
  text-decoration: var(--ha-link-hover-decoration) !important;
  text-underline-offset: 3px;
}

/* ==========================================================================
   4. Unified Cards (.ha-card)
   ========================================================================== */

.ha-card {
  background-color: var(--ha-card-bg-light);
  border: 1px solid var(--ha-card-border-light);
  border-radius: var(--ha-card-radius);
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

html.dark .ha-card,
.dark .ha-card {
  background-color: var(--ha-card-bg-dark);
  border-color: var(--ha-card-border-dark);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* ==========================================================================
   5. Icon Standards (.ha-icon-sm, .ha-icon-md, .ha-icon-lg)
   ========================================================================== */

.ha-icon-sm {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.ha-icon-md {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.ha-icon-lg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* ==========================================================================
   6. Badges, Tags & Astrological Flairs (.ha-badge, .ha-badge-fire, etc.)
   ========================================================================== */

.ha-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: var(--ha-font-sans);
  font-size: 0.6875rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.625rem;
  border-radius: 9999px;
  border: 1px solid transparent;
  line-height: 1.25;
  white-space: nowrap;
}

/* Astrological Element Flairs */
.ha-badge-fire {
  background-color: rgba(239, 68, 68, 0.12);
  color: #dc2626;
  border-color: rgba(239, 68, 68, 0.28);
}
html.dark .ha-badge-fire, .dark .ha-badge-fire {
  background-color: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

.ha-badge-earth {
  background-color: rgba(16, 185, 129, 0.12);
  color: #059669;
  border-color: rgba(16, 185, 129, 0.28);
}
html.dark .ha-badge-earth, .dark .ha-badge-earth {
  background-color: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.ha-badge-air {
  background-color: rgba(6, 182, 212, 0.12);
  color: #0891b2;
  border-color: rgba(6, 182, 212, 0.28);
}
html.dark .ha-badge-air, .dark .ha-badge-air {
  background-color: rgba(6, 182, 212, 0.2);
  color: #22d3ee;
}

.ha-badge-water {
  background-color: rgba(99, 102, 241, 0.12);
  color: #4f46e5;
  border-color: rgba(99, 102, 241, 0.28);
}
html.dark .ha-badge-water, .dark .ha-badge-water {
  background-color: rgba(99, 102, 241, 0.2);
  color: #818cf8;
}

/* Functional Status Badges */
.ha-badge-primary {
  background-color: rgba(79, 70, 229, 0.12);
  color: #4f46e5;
  border-color: rgba(79, 70, 229, 0.25);
}
html.dark .ha-badge-primary, .dark .ha-badge-primary {
  background-color: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
}

.ha-badge-success {
  background-color: rgba(16, 185, 129, 0.12);
  color: #059669;
  border-color: rgba(16, 185, 129, 0.25);
}
html.dark .ha-badge-success, .dark .ha-badge-success {
  background-color: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.ha-badge-neutral {
  background-color: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}
html.dark .ha-badge-neutral, .dark .ha-badge-neutral {
  background-color: #1e293b;
  color: #94a3b8;
  border-color: #334155;
}

/* ==========================================================================
   7. Tabs & Segmented Switchers (.ha-tabs-pill, .ha-tabs-underline)
   ========================================================================== */

.ha-tabs-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.3125rem;
  background-color: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
}
html.dark .ha-tabs-pill, .dark .ha-tabs-pill {
  background-color: #0f172a;
  border-color: #1e293b;
}

.ha-tab-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.875rem;
  font-family: var(--ha-font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 9999px;
  border: none;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  transition: all 0.15s ease;
}
.ha-tab-pill-btn:hover {
  color: #0f172a;
}
html.dark .ha-tab-pill-btn:hover, .dark .ha-tab-pill-btn:hover {
  color: #f8fafc;
}
.ha-tab-pill-btn.active {
  background-color: var(--ha-btn-primary-bg) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.3) !important;
}
html.dark .ha-tab-pill-btn.active, .dark .ha-tab-pill-btn.active {
  background-color: var(--ha-btn-primary-bg) !important;
  color: #ffffff !important;
}

/* Underline Tabs */
.ha-tabs-underline {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border-bottom: 1px solid #e2e8f0;
}
html.dark .ha-tabs-underline, .dark .ha-tabs-underline {
  border-bottom-color: #1e293b;
}

.ha-tab-underline-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 0.25rem;
  font-family: var(--ha-font-sans);
  font-size: 0.8125rem;
  font-weight: 700;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: #64748b;
  cursor: pointer;
  transition: all 0.15s ease;
  margin-bottom: -1px;
}
.ha-tab-underline-btn:hover {
  color: #0f172a;
}
html.dark .ha-tab-underline-btn:hover, .dark .ha-tab-underline-btn:hover {
  color: #f8fafc;
}
.ha-tab-underline-btn.active {
  color: var(--ha-btn-primary-bg);
  border-bottom-color: var(--ha-btn-primary-bg);
  font-weight: 900;
}
html.dark .ha-tab-underline-btn.active, .dark .ha-tab-underline-btn.active {
  color: #818cf8;
  border-bottom-color: #818cf8;
}

/* ==========================================================================
   8. Show / Hide Accordions (.ha-accordion)
   ========================================================================== */

.ha-accordion {
  border: 1px solid #e2e8f0;
  border-radius: var(--ha-input-radius);
  overflow: hidden;
  background-color: #ffffff;
  transition: border-color 0.15s ease;
}
html.dark .ha-accordion, .dark .ha-accordion {
  border-color: #1e293b;
  background-color: #0f172a;
}

.ha-accordion-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1.125rem;
  background: transparent;
  border: none;
  font-family: var(--ha-font-sans);
  font-size: 0.8125rem;
  font-weight: 700;
  color: #1e293b;
  cursor: pointer;
  text-align: left;
}
html.dark .ha-accordion-toggle, .dark .ha-accordion-toggle {
  color: #f1f5f9;
}

.ha-accordion-chevron {
  width: 16px;
  height: 16px;
  transition: transform 0.2s ease;
}
.ha-accordion.open .ha-accordion-chevron {
  transform: rotate(180deg);
}

.ha-accordion-content {
  padding: 1rem 1.125rem;
  border-top: 1px solid #f1f5f9;
  font-size: 0.8125rem;
  color: #475569;
}
html.dark .ha-accordion-content, .dark .ha-accordion-content {
  border-top-color: #1e293b;
  color: #94a3b8;
}

/* ==========================================================================
   9. Card Interactive Lift (.ha-card-interactive)
   ========================================================================== */

.ha-card-interactive {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
}
.ha-card-interactive:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  border-color: #cbd5e1;
}
html.dark .ha-card-interactive:hover, .dark .ha-card-interactive:hover {
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  border-color: #475569;
}

/* ==========================================================================
   10. Tables (.ha-table, .ha-table-striped, .ha-table-hover)
   ========================================================================== */

.ha-table-container {
  width: 100%;
  overflow-x: auto;
  border-radius: var(--ha-card-radius);
  border: 1px solid var(--ha-card-border-light);
  background-color: var(--ha-card-bg-light);
}
html.dark .ha-table-container, .dark .ha-table-container {
  border-color: var(--ha-card-border-dark);
  background-color: var(--ha-card-bg-dark);
}

.ha-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--ha-font-sans);
  font-size: 0.8125rem;
  text-align: left;
}

.ha-table th {
  padding: 0.875rem 1.125rem;
  background-color: #f8fafc;
  font-size: 0.6875rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  border-bottom: 1px solid #e2e8f0;
}
html.dark .ha-table th, .dark .ha-table th {
  background-color: #0b1120;
  color: #94a3b8;
  border-bottom-color: #1e293b;
}

.ha-table td {
  padding: 0.875rem 1.125rem;
  color: #334155;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}
html.dark .ha-table td, .dark .ha-table td {
  color: #cbd5e1;
  border-bottom-color: #1e293b;
}

.ha-table tr:last-child td {
  border-bottom: none;
}

.ha-table-striped tbody tr:nth-child(even) {
  background-color: #f8fafc;
}
html.dark .ha-table-striped tbody tr:nth-child(even), .dark .ha-table-striped tbody tr:nth-child(even) {
  background-color: #0f172a;
}

.ha-table-hover tbody tr:hover {
  background-color: #f1f5f9;
}
html.dark .ha-table-hover tbody tr:hover, .dark .ha-table-hover tbody tr:hover {
  background-color: #1e293b;
}

/* ==========================================================================
   11. Image Slider / Carousel (.ha-slider)
   ========================================================================== */

.ha-slider {
  position: relative;
  overflow: hidden;
  border-radius: var(--ha-card-radius);
  background-color: #0f172a;
  border: 1px solid var(--ha-card-border-light);
}
html.dark .ha-slider, .dark .ha-slider {
  border-color: var(--ha-card-border-dark);
}

.ha-slider-track {
  display: flex;
  transition: transform 0.35s ease-in-out;
  width: 100%;
}

.ha-slider-slide {
  min-width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.ha-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  background-color: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}
.ha-slider-btn:hover {
  background-color: rgba(15, 23, 42, 0.95);
  transform: translateY(-50%) scale(1.08);
}
.ha-slider-btn-prev { left: 12px; }
.ha-slider-btn-next { right: 12px; }

.ha-slider-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 10;
}

.ha-slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background-color: rgba(255, 255, 255, 0.4);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
}
.ha-slider-dot.active {
  width: 22px;
  background-color: #ffffff;
}

/* ==========================================================================
   12. Pagination (.ha-pagination)
   ========================================================================== */

.ha-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 1rem 0;
}

.ha-page-item {
  display: inline-flex;
}

.ha-page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 0.5rem;
  border-radius: 0.625rem;
  font-family: var(--ha-font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  color: #475569;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  text-decoration: none !important;
  transition: all 0.15s ease;
  cursor: pointer;
}
html.dark .ha-page-link, .dark .ha-page-link {
  color: #94a3b8;
  background-color: #0f172a;
  border-color: #1e293b;
}

.ha-page-link:hover {
  background-color: #f8fafc;
  color: #0f172a;
  border-color: #cbd5e1;
}
html.dark .ha-page-link:hover, .dark .ha-page-link:hover {
  background-color: #1e293b;
  color: #f8fafc;
  border-color: #334155;
}

.ha-page-link.active {
  background-color: var(--ha-btn-primary-bg);
  color: #ffffff !important;
  border-color: var(--ha-btn-primary-bg);
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.3);
}

.ha-page-link.disabled {
  opacity: 0.4;
  pointer-events: none;
  cursor: not-allowed;
}

/* ==========================================================================
   13. Tooltips ([data-ha-tooltip])
   ========================================================================== */

.ha-tooltip-wrap {
  position: relative;
  display: inline-flex;
}

.ha-tooltip-wrap:hover .ha-tooltip {
  visibility: visible;
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.ha-tooltip {
  visibility: hidden;
  opacity: 0;
  position: absolute;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  background-color: #0f172a;
  color: #f8fafc;
  font-family: var(--ha-font-sans);
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.375rem 0.625rem;
  border-radius: 0.5rem;
  white-space: nowrap;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
  border: 1px solid #334155;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
  z-index: 100;
  pointer-events: none;
}

.ha-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -4px;
  border-width: 4px;
  border-style: solid;
  border-color: #0f172a transparent transparent transparent;
}

/* ==========================================================================
   14. Tabs with Content Panels (.ha-tab-panel)
   ========================================================================== */

.ha-tab-panel {
  display: none;
}
.ha-tab-panel.active {
  display: block;
  animation: haFadeIn 0.2s ease-in-out;
}

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

/* ==========================================================================
   15. Astrological Poll / Voting Widget (.ha-poll-card)
   ========================================================================== */

.ha-poll-card {
  border-radius: 1rem;
  border: 1px solid #e2e8f0;
  background-color: #ffffff;
  padding: 1.25rem;
  box-sizing: border-box;
}
html.dark .ha-poll-card, .dark .ha-poll-card {
  border-color: #1e293b;
  background-color: #0f172a;
}

.ha-poll-option {
  position: relative;
  overflow: hidden;
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
  padding: 0.75rem 1rem;
  margin-bottom: 0.625rem;
  cursor: pointer;
  transition: all 0.15s ease;
  background-color: #ffffff;
}
html.dark .ha-poll-option, .dark .ha-poll-option {
  border-color: #1e293b;
  background-color: #0b1120;
}

.ha-poll-option:hover {
  border-color: var(--ha-btn-primary-bg);
}

.ha-poll-bar {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  background-color: rgba(99, 102, 241, 0.12);
  transition: width 0.4s ease;
  z-index: 1;
}
html.dark .ha-poll-bar, .dark .ha-poll-bar {
  background-color: rgba(99, 102, 241, 0.25);
}

.ha-poll-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8125rem;
  font-weight: 700;
}

/* ==========================================================================
   16. Dropdown Menus & Popovers (.ha-dropdown)
   ========================================================================== */

.ha-dropdown {
  position: relative;
  display: inline-block;
}

.ha-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 180px;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0.875rem;
  padding: 0.375rem;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
html.dark .ha-dropdown-menu, .dark .ha-dropdown-menu {
  background-color: #0f172a;
  border-color: #1e293b;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
}

.ha-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #334155;
  border-radius: 0.5rem;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
  border: none;
  background: transparent;
  width: 100%;
  text-align: left;
}
html.dark .ha-dropdown-item, .dark .ha-dropdown-item {
  color: #cbd5e1;
}

.ha-dropdown-item:hover {
  background-color: #f1f5f9;
  color: #0f172a;
}
html.dark .ha-dropdown-item:hover, .dark .ha-dropdown-item:hover {
  background-color: #1e293b;
  color: #f8fafc;
}

/* ==========================================================================
   17. Avatars & Identity Flairs (.ha-avatar)
   ========================================================================== */

.ha-avatar-wrap {
  position: relative;
  display: inline-flex;
}

.ha-avatar {
  border-radius: 9999px;
  object-cover: cover;
  border: 2px solid #ffffff;
  background-color: #e2e8f0;
}
html.dark .ha-avatar, .dark .ha-avatar {
  border-color: #0f172a;
  background-color: #1e293b;
}

.ha-avatar-sm { width: 28px; height: 28px; }
.ha-avatar-md { width: 40px; height: 40px; }
.ha-avatar-lg { width: 56px; height: 56px; }

.ha-avatar-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 12px;
  height: 12px;
  border-radius: 9999px;
  border: 2px solid #ffffff;
  background-color: #10b981;
}
html.dark .ha-avatar-badge, .dark .ha-avatar-badge {
  border-color: #0f172a;
}

/* ==========================================================================
   18. Alerts & Callouts (.ha-alert)
   ========================================================================== */

.ha-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1.125rem;
  border-radius: 1rem;
  border: 1px solid transparent;
  font-size: 0.8125rem;
  line-height: 1.5;
}

.ha-alert-info {
  background-color: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.25);
  color: #3730a3;
}
html.dark .ha-alert-info, .dark .ha-alert-info {
  background-color: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.35);
  color: #c7d2fe;
}

.ha-alert-success {
  background-color: rgba(16, 185, 129, 0.08);
  border-color: rgba(16, 185, 129, 0.25);
  color: #065f46;
}
html.dark .ha-alert-success, .dark .ha-alert-success {
  background-color: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.35);
  color: #a7f3d0;
}

.ha-alert-warning {
  background-color: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.25);
  color: #92400e;
}
html.dark .ha-alert-warning, .dark .ha-alert-warning {
  background-color: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.35);
  color: #fde68a;
}

.ha-alert-danger {
  background-color: rgba(239, 68, 68, 0.08);
  border-color: rgba(239, 68, 68, 0.25);
  color: #991b1b;
}
html.dark .ha-alert-danger, .dark .ha-alert-danger {
  background-color: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.35);
  color: #fecaca;
}

/* ==========================================================================
   19. Progress Bars & Meters (.ha-progress)
   ========================================================================== */

.ha-progress {
  width: 100%;
  height: 8px;
  background-color: #e2e8f0;
  border-radius: 9999px;
  overflow: hidden;
}
html.dark .ha-progress, .dark .ha-progress {
  background-color: #1e293b;
}

.ha-progress-bar {
  height: 100%;
  background-color: var(--ha-btn-primary-bg);
  border-radius: 9999px;
  transition: width 0.3s ease;
}

/* ==========================================================================
   20. Skeleton Shimmer Loaders (.ha-skeleton)
   ========================================================================== */

.ha-skeleton {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: haSkeletonShimmer 1.5s infinite;
  border-radius: 0.5rem;
}
html.dark .ha-skeleton, .dark .ha-skeleton {
  background: linear-gradient(90deg, #1e293b 25%, #334155 50%, #1e293b 75%);
  background-size: 200% 100%;
}

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

/* ==========================================================================
   21. Empty State Component (.ha-empty-state)
   ========================================================================== */

.ha-empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  border: 1px dashed #cbd5e1;
  border-radius: var(--ha-card-radius);
  background-color: #f8fafc;
}
html.dark .ha-empty-state, .dark .ha-empty-state {
  border-color: #334155;
  background-color: #0b1120;
}/* ==========================================================================
   22. Standard 3-Column Layout & Sizing Tokens (.ha-two-col-grid, .ha-right-sidebar, .ha-center-feed)
   ========================================================================== */

.ha-two-col-grid,
.hugeastrology-two-col-grid {
  max-width: 1058px !important;
  margin: 0 auto !important;
  padding: 0 24px !important;
  display: grid !important;
  grid-template-columns: minmax(0, 726px) 308px !important;
  gap: 24px !important;
  align-items: start !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

@media (min-width: 1024px) {
  .ha-two-col-grid,
  .hugeastrology-two-col-grid {
    max-width: 1076px !important;
    padding-left: 18px !important;
    padding-right: 0 !important;
    margin: 0 auto !important;
  }
}

@media (max-width: 1024px) {
  .ha-two-col-grid,
  .hugeastrology-two-col-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    padding: 0 16px !important;
    gap: 16px !important;
  }
}

.ha-right-sidebar {
  width: 308px !important;
  min-width: 308px !important;
  max-width: 308px !important;
  flex: 0 0 308px !important;
  box-sizing: border-box !important;
}

.ha-center-feed {
  width: 100% !important;
  max-width: 726px !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
}

/* 2-Column Standard: Combined width of center feed (726px) + gap (24px) + right sidebar (308px) = 1058px */
.ha-layout-2col-standard,
.ha-2col-standard {
  max-width: 1058px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

/* 2-Column Compact: Strictly matches the center content list card size (726px) */
.ha-layout-2col-compact,
.ha-2col-compact {
  max-width: 726px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

/* 2-Column Full: Expansive 100% Canvas for Multi-Column Grids and Wide Data Tables */
.ha-layout-2col-full,
.ha-2col-full {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* 2-Column Split: 50/50 Dual Workspace for Synastry & Chart Comparison */
.ha-layout-2col-split,
.ha-2col-split {
  width: 100% !important;
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)) !important;
  gap: 24px !important;
  box-sizing: border-box !important;
}

/* 1-Column Focused Zen Canvas */
.ha-layout-1col-focus,
.ha-1col-focus {
  max-width: 768px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

/* ==========================================================================
   23. Standard Modals & Overlays (.ha-modal-backdrop, .ha-modal, etc.)
   ========================================================================== */

.ha-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background-color: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
}

.ha-modal {
  width: 100%;
  max-width: 32rem;
  background-color: var(--ha-card-bg-light);
  border: 1px solid var(--ha-card-border-light);
  border-radius: var(--ha-card-radius);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.2s ease, opacity 0.2s ease;
  font-family: var(--ha-font-sans);
}

html.dark .ha-modal,
.dark .ha-modal {
  background-color: var(--ha-card-bg-dark);
  border-color: var(--ha-card-border-dark);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6);
}

.ha-modal-header {
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #f1f5f9;
  background-color: #ffffff;
}

html.dark .ha-modal-header,
.dark .ha-modal-header {
  border-bottom-color: #1e293b;
  background-color: #0f172a;
}

.ha-modal-title {
  font-size: 1rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.01em;
}

html.dark .ha-modal-title,
.dark .ha-modal-title {
  color: #f8fafc;
}

.ha-modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  background-color: #f1f5f9;
  color: #64748b;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ha-modal-close:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

html.dark .ha-modal-close,
.dark .ha-modal-close {
  background-color: #1e293b;
  color: #94a3b8;
}

html.dark .ha-modal-close:hover,
.dark .ha-modal-close:hover {
  background-color: #334155;
  color: #f8fafc;
}

.ha-modal-body {
  padding: 1.5rem;
}

.ha-modal-footer {
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  border-top: 1px solid #f1f5f9;
  background-color: #f8fafc;
}

html.dark .ha-modal-footer,
.dark .ha-modal-footer {
  border-top-color: #1e293b;
  background-color: #0b1120;
}

.ha-btn-accent {
  background-color: #f59e0b;
  color: #0f172a !important;
  font-weight: 800;
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.25);
}

.ha-btn-accent:hover {
  background-color: #d97706;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}
