/* Modern Sovereign Legal-Tech Design System
   Brand: LegalOutput (L.d Malani & Associates - Senior Legal Chambers)
   Chamber: GF 05, Lotus Plaza Market, Indirapuram, Ghaziabad
*/

:root {
  --color-obsidian-950: #060A12;
  --color-obsidian-900: #0B1120;
  --color-obsidian-850: #0F172A;
  --color-obsidian-800: #141E33;
  --color-obsidian-700: #1E293B;
  
  --color-gold-500: #D4AF37;
  --color-gold-600: #C59B27;
  --color-gold-400: #E1BF5B;
  --color-gold-glow: rgba(212, 175, 55, 0.25);
  
  --color-alabaster: #F8FAFC;
  --color-alabaster-card: #FFFFFF;
  --color-slate-subtle: #94A3B8;
  --color-slate-text: #334155;
  --color-slate-dark: #0F172A;
  
  --color-emerald-whatsapp: #10B981;
  --color-emerald-hover: #059669;

  --ease-spring: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Global Reset & Font Foundations */
html {
  scroll-behavior: smooth;
}

::selection {
  background: #D4AF37;
  color: #060A12;
}

::-moz-selection {
  background: #D4AF37;
  color: #060A12;
}

/* Elegant Slim Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #0B1120;
}

::-webkit-scrollbar-thumb {
  background: #1E293B;
  border-radius: 4px;
  border: 1px solid rgba(212, 175, 55, 0.2);
}

::-webkit-scrollbar-thumb:hover {
  background: #C59B27;
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  color: var(--color-slate-dark);
  background-color: var(--color-alabaster);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, .font-display {
  font-family: 'Playfair Display', Georgia, serif;
  letter-spacing: -0.015em;
}

/* Subtle Shimmer for Primary CTAs */
@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

.btn-shimmer {
  position: relative;
  overflow: hidden;
}

.btn-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
  transform: translateX(-100%);
  animation: shimmer 4s infinite;
  pointer-events: none;
}

/* Gold Gradient Accents */
.gold-gradient-text {
  background: linear-gradient(135deg, #F4E5B8 0%, #D4AF37 50%, #C59B27 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gold-gradient-bg {
  background: linear-gradient(135deg, #E1BF5B 0%, #C59B27 50%, #9E7A1C 100%);
}

.gold-badge {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: #D4AF37;
}

/* Glassmorphism & Header */
.glass-header {
  background: rgba(11, 17, 32, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Bento Card System with Spotlight Hover */
.bento-card {
  position: relative;
  background: #0F172A;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  overflow: hidden;
  transition: transform 0.35s var(--ease-spring), border-color 0.35s var(--ease-spring), box-shadow 0.35s var(--ease-spring);
}

.bento-card:hover {
  transform: translateY(-3px);
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.5), 0 0 25px -5px rgba(212, 175, 55, 0.15);
}

.bento-spotlight::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-radius: inherit;
  background: radial-gradient(600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(212, 175, 55, 0.09), transparent 40%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 1;
}

.bento-card:hover.bento-spotlight::before {
  opacity: 1;
}

/* Authority Proof & Article Typography */
.authority-proof {
  color: #1E293B;
  font-size: 1.0625rem;
  line-height: 1.8;
  background: transparent !important;
}

.authority-proof h1,
.authority-proof h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.875rem;
  font-weight: 700;
  color: #0F172A !important;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid rgba(212, 175, 55, 0.3);
  position: relative;
}

.authority-proof h1::after,
.authority-proof h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 60px;
  height: 2px;
  background: #C59B27;
}

.authority-proof h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: #1E293B !important;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.authority-proof p {
  margin-bottom: 1.25rem;
  color: #334155;
  line-height: 1.75;
}

.authority-proof ul, .authority-proof ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.authority-proof ul li {
  list-style-type: disc;
  margin-bottom: 0.6rem;
  color: #334155;
  line-height: 1.7;
}

.authority-proof ol li {
  list-style-type: decimal;
  margin-bottom: 0.6rem;
  color: #334155;
  line-height: 1.7;
}

.authority-proof strong {
  color: #0F172A;
  font-weight: 700;
}

.authority-proof a {
  color: #C59B27;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.authority-proof a:hover {
  color: #9E7A1C;
}

/* Explicit High-Contrast Dark Blocks inside Authority Proof */
.ai-statutory-table,
.taxpayer-rights-block,
.tricity-gst-grid,
.fear-relief,
.authority-proof [style*="background:#1"],
.authority-proof [style*="background: #1"],
.authority-proof [style*="background:#0"],
.authority-proof [style*="background: #0"] {
  background: #0B1120 !important;
  border: 1px solid rgba(212, 175, 55, 0.35) !important;
  border-radius: 0.75rem !important;
  color: #E2E8F0 !important;
}

.ai-statutory-table p,
.taxpayer-rights-block p,
.tricity-gst-grid p,
.fear-relief p,
.authority-proof [style*="background:#1"] p,
.authority-proof [style*="background: #1"] p,
.authority-proof [style*="background:#0"] p,
.authority-proof [style*="background: #0"] p {
  color: #CBD5E1 !important;
}

.ai-statutory-table li,
.taxpayer-rights-block li,
.tricity-gst-grid li,
.fear-relief li,
.authority-proof [style*="background:#1"] li,
.authority-proof [style*="background: #1"] li,
.authority-proof [style*="background:#0"] li,
.authority-proof [style*="background: #0"] li {
  color: #E2E8F0 !important;
}

.ai-statutory-table strong,
.taxpayer-rights-block strong,
.tricity-gst-grid strong,
.fear-relief strong,
.authority-proof [style*="background:#1"] strong,
.authority-proof [style*="background: #1"] strong,
.authority-proof [style*="background:#0"] strong,
.authority-proof [style*="background: #0"] strong {
  color: #FFFFFF !important;
}

.ai-statutory-table h3,
.taxpayer-rights-block h3,
.tricity-gst-grid h3,
.fear-relief h3 {
  color: #D4AF37 !important;
}

.ai-statutory-table a,
.taxpayer-rights-block a,
.tricity-gst-grid a,
.fear-relief a {
  color: #D4AF37 !important;
}

/* Statutory Tables */
.ai-statutory-table {
  background: #0B1120 !important;
  border: 1px solid rgba(212, 175, 55, 0.3) !important;
  border-radius: 0.75rem !important;
  overflow: hidden;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
}

.ai-statutory-table h3 {
  color: #D4AF37 !important;
}

.ai-statutory-table table {
  border-collapse: collapse;
}

.ai-statutory-table th {
  background: #141E33 !important;
  color: #E1BF5B !important;
  font-weight: 600;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  font-size: 0.75rem;
}

/* FAQ Accordion Styling */
.faq-item {
  border: 1px solid #E2E8F0;
  border-radius: 0.75rem;
  background: #FFFFFF;
  transition: all 0.25s ease;
}

.faq-item:hover {
  border-color: rgba(212, 175, 55, 0.5);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.faq-trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 1.5rem;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: #0F172A;
  text-align: left;
}

.faq-icon {
  transition: transform 0.3s var(--ease-spring);
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
  color: #C59B27;
}

.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s var(--ease-spring), padding 0.35s ease;
  padding: 0 1.5rem;
  color: #475569;
  line-height: 1.7;
}

.faq-item.active .faq-content {
  max-height: 400px;
  padding-bottom: 1.25rem;
}

/* Floating Bottom Mobile Dock */
.mobile-action-dock {
  display: none;
}

@media (max-width: 767px) {
  .mobile-action-dock {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 999;
    padding: 0.65rem 1rem;
    padding-bottom: max(0.65rem, env(safe-area-inset-bottom));
    background: rgba(11, 17, 32, 0.94);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.35);
  }
  body {
    padding-bottom: 75px;
  }
}

/* WhatsApp Floating Button */
.whatsapp-pulse-btn {
  position: fixed;
  bottom: 5.5rem;
  right: 1.25rem;
  z-index: 900;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #10B981;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.45);
  transition: transform 0.25s var(--ease-spring), background-color 0.2s ease;
}

.whatsapp-pulse-btn:hover {
  transform: scale(1.08);
  background: #059669;
}

@media (min-width: 768px) {
  .whatsapp-pulse-btn {
    bottom: 2rem;
    right: 2rem;
    width: auto;
    height: 52px;
    border-radius: 9999px;
    padding: 0 1.25rem 0 1.1rem;
    gap: 0.5rem;
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.2) inset;
  }
}

/* Motion Reveal Classes */
.motion-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease-spring), transform 0.7s var(--ease-spring);
  will-change: opacity, transform;
}

.motion-reveal.is-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Respect Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .motion-reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .bento-card {
    transition: none !important;
    transform: none !important;
  }
  .faq-content {
    transition: none !important;
  }
}

/* Focus Visible for Accessibility */
a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible {
  outline: 2px solid #D4AF37;
  outline-offset: 3px;
}
