/* DateHub Today — Professional Theme Overlay (theme-pro.css) */

/* Import Fonts definitions */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: -0.03em !important;
  line-height: 1.2 !important;
  color: var(--color-ink);
}

/* Premium Selection Accent */
::selection {
  background-color: rgba(99, 102, 241, 0.25);
  color: var(--color-ink);
}

:root {
  --header-bg: rgba(255, 255, 255, 0.8);
  --shadow-color: rgba(15, 23, 42, 0.05);
  --shadow-heavy: rgba(15, 23, 42, 0.08);
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #4f46e5 50%, #7c3aed 100%);
  --accent-soft: rgba(99, 102, 241, 0.1);
}

:root[class~="dark"] {
  --header-bg: rgba(10, 10, 10, 0.8);
  --shadow-color: rgba(0, 0, 0, 0.3);
  --shadow-heavy: rgba(0, 0, 0, 0.45);
  --accent-gradient: linear-gradient(135deg, #818cf8 0%, #6366f1 50%, #8b5cf6 100%);
  --accent-soft: rgba(129, 140, 248, 0.15);
}

/* 1. Glassy Sticky Header */
header.sticky {
  background-color: var(--header-bg) !important;
  backdrop-filter: blur(12px) saturate(190%);
  -webkit-backdrop-filter: blur(12px) saturate(190%);
  box-shadow: 0 1px 3px 0 var(--shadow-color), 0 1px 2px -1px var(--shadow-color);
  border-bottom: 1px solid var(--color-hairline) !important;
}

/* 2. Elevated Hero Panel (First Content Section / Interactive Widget) */
[slot="tool"] > div,
section[aria-label="Interactive Tool"] > div:nth-of-type(2),
.max-w-3xl.mx-auto.shadow-md {
  position: relative !important;
  overflow: hidden !important;
  border-top: none !important;
  border: 1px solid var(--color-hairline) !important;
  background: linear-gradient(180deg, var(--color-canvas) 0%, var(--color-canvas-soft) 100%) !important;
  box-shadow: 0 20px 40px -15px var(--shadow-heavy) !important;
  border-radius: 12px !important;
}

[slot="tool"] > div::before,
section[aria-label="Interactive Tool"] > div:nth-of-type(2)::before,
.max-w-3xl.mx-auto.shadow-md::before {
  content: "" !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  height: 4px !important;
  background: var(--accent-gradient) !important;
  z-index: 10 !important;
}

/* 3. Ticking Clock & Digital Displays */
#tamil-clock, 
#clock, 
#bangla-clock, 
#hijri-clock {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace !important;
  font-variant-numeric: tabular-nums;
  background: var(--color-canvas-soft-2) !important;
  padding: 4px 10px !important;
  border-radius: 6px !important;
  border: 1px solid var(--color-hairline) !important;
  color: #6366f1 !important;
  font-weight: 600 !important;
  letter-spacing: 0.05em !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02) !important;
}
:root[class~="dark"] #tamil-clock,
:root[class~="dark"] #clock,
:root[class~="dark"] #bangla-clock,
:root[class~="dark"] #hijri-clock {
  color: #818cf8 !important;
}

/* 4. Badges (Paksha, Tithi, etc.) */
#paksha-badge, 
#tithi-badge {
  border: 1px solid currentColor !important;
  background-color: var(--accent-soft) !important;
  font-weight: 600 !important;
  letter-spacing: 0.05em !important;
  text-transform: uppercase !important;
  font-size: 9px !important;
  padding: 2px 8px !important;
}

/* 5. Cards with Subtle Shadow + Hover Lift */
.p-5.bg-canvas.border, 
.bg-canvas.border.border-hairline.rounded-lg,
.border.border-hairline.rounded-md {
  box-shadow: 0 4px 12px -2px var(--shadow-color), 0 1px 3px 0 var(--shadow-color);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
  border-radius: 10px !important;
}

.p-5.bg-canvas.border:hover, 
.bg-canvas.border.border-hairline.rounded-lg:hover,
.border.border-hairline.rounded-md:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 28px -10px var(--shadow-heavy);
  border-color: var(--color-hairline-strong) !important;
}

/* 6. Accent Gradient on Brand Logo and Highlights */
a[href="/"] > div.bg-primary,
.bg-primary:not(body) {
  background: var(--accent-gradient) !important;
  color: #ffffff !important;
  border: none !important;
}

a[href="/"] > div.bg-primary svg {
  stroke: #ffffff !important;
}

/* 7. Typography Polish */
h1 {
  font-size: 2.25rem !important;
}
@media (min-width: 768px) {
  h1 {
    font-size: 3.25rem !important;
  }
}

h2 {
  font-size: 1.5rem !important;
  margin-top: 2rem !important;
  margin-bottom: 1rem !important;
}

/* Professional Link styling with animated border transition */
a.text-link,
article.prose a {
  text-decoration: none !important;
  color: #6366f1 !important;
  border-bottom: 1.5px solid rgba(99, 102, 241, 0.15) !important;
  transition: border-color 0.15s ease, color 0.15s ease;
  padding-bottom: 1px;
}
:root[class~="dark"] a.text-link,
:root[class~="dark"] article.prose a {
  color: #818cf8 !important;
  border-bottom-color: rgba(129, 140, 248, 0.2) !important;
}

a.text-link:hover,
article.prose a:hover {
  border-bottom-color: currentColor !important;
  opacity: 0.9;
}

/* 8. Table Styling inside prose */
article.prose table {
  width: 100% !important;
  border-collapse: collapse !important;
  margin: 1.5rem 0 !important;
}
article.prose th {
  background-color: var(--color-canvas-soft) !important;
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-weight: 600 !important;
  color: var(--color-ink) !important;
  padding: 10px 14px !important;
  border-bottom: 2px solid var(--color-hairline) !important;
  text-align: left !important;
}
article.prose td {
  padding: 10px 14px !important;
  border-bottom: 1px solid var(--color-hairline) !important;
  color: var(--color-body) !important;
}

/* Focus outlines */
a:focus-visible, 
button:focus-visible, 
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid #6366f1 !important;
  outline-offset: 2px !important;
}

/* 9. Motion Reduction */
@media (prefers-reduced-motion: reduce) {
  *, :before, :after {
    animation-delay: -1ms !important;
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    background-attachment: initial !important;
    scroll-behavior: auto !important;
    transition-duration: 0s !important;
    transition-delay: 0s !important;
  }
}
