/**
 * RTISchedulerHub WordPress Theme CSS
 * Replicates the modern Tailwind + OKLCH design system of the Lovable application.
 */

:root {
  --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  --font-display: 'Space Grotesk', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --radius-sm: 0.625rem;
  --radius-md: 0.75rem;
  --radius-lg: 0.875rem;
  --radius-xl: 1.125rem;
  --radius-2xl: 1.375rem;
  --radius-3xl: 1.625rem;

  --background: #ffffff;
  --foreground: #0f172a;
  --card: #ffffff;
  --card-foreground: #0f172a;
  --popover: #ffffff;
  --popover-foreground: #0f172a;

  --primary: #2563eb;
  --primary-foreground: #ffffff;
  --secondary: #f1f5f9;
  --secondary-foreground: #1e293b;
  --muted: #f8fafc;
  --muted-foreground: #64748b;
  --accent: #f0f9ff;
  --accent-foreground: #1e293b;
  --destructive: #ef4444;
  --destructive-foreground: #ffffff;
  --border: #e2e8f0;
  --input: #e2e8f0;
  --ring: #3b82f6;

  /* Brand Tokens */
  --brand: #2563eb;
  --brand-2: #3b82f6;
  --brand-accent: #06b6d4;
  --surface: #ffffff;
  --surface-muted: #f8fafc;

  --gradient-brand: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #06b6d4 100%);
  --gradient-soft: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  --gradient-hero: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(59, 130, 246, 0.15) 0%, transparent 60%);

  --shadow-soft: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px -8px rgba(37, 99, 235, 0.10);
  --shadow-elevated: 0 10px 40px -12px rgba(37, 99, 235, 0.25);
  --shadow-glow: 0 0 0 1px rgba(255, 255, 255, 0.6) inset, 0 20px 60px -20px rgba(37, 99, 235, 0.35);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  color: var(--foreground);
  margin-top: 0;
  line-height: 1.2;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--brand-2);
}

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Layout Container */
.container-page {
  width: 100%;
  max-width: 76rem;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* Utilities */
.gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}

.glass {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.glass-nav {
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid rgba(37, 99, 235, 0.08);
}

.card-premium {
  background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(59, 130, 246, 0.03));
  border: 1px solid rgba(37, 99, 235, 0.1);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-soft);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.card-premium-hover:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-elevated);
  border-color: rgba(37, 99, 235, 0.25);
}

.bg-hero {
  background-image: var(--gradient-hero);
}

.bg-brand-gradient {
  background: var(--gradient-brand);
}

.bg-soft {
  background: var(--gradient-soft);
}

.shadow-elevated {
  box-shadow: var(--shadow-elevated);
}

.shadow-glow {
  box-shadow: var(--shadow-glow);
}

/* Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  transition: all 0.3s ease;
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 1px 0 0 rgba(37, 99, 235, 0.08), 0 4px 20px -4px rgba(0, 0, 0, 0.05);
}

.site-nav-inner {
  display: flex;
  height: 4.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-family: var(--font-display);
  color: var(--foreground);
  text-decoration: none;
}

.site-logo-img {
  height: 2.25rem;
  width: auto;
}

.logo-text-group {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
}

.logo-rti {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.375rem;
  color: #1d4ed8;
  letter-spacing: 0.02em;
}

.logo-sub {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.75rem;
  color: #64748b;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.nav-links {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.875rem;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }
}

.nav-links a {
  display: block;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  color: var(--muted-foreground);
  font-weight: 500;
  transition: all 0.2s ease;
}

.nav-links a:hover,
.nav-links li.current-menu-item a,
.nav-links li.current_page_item a {
  color: var(--foreground);
  background-color: rgba(241, 245, 249, 0.8);
}

.nav-cta {
  display: none;
  align-items: center;
  gap: 0.5rem;
}

@media (min-width: 768px) {
  .nav-cta {
    display: flex;
  }
}

.btn-demo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: var(--gradient-brand);
  padding: 0.5rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #ffffff;
  box-shadow: var(--shadow-elevated);
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.btn-demo:hover {
  opacity: 0.95;
  color: #ffffff;
  transform: translateY(-1px);
}

.menu-toggle-btn {
  display: inline-flex;
  height: 2.5rem;
  width: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--foreground);
  cursor: pointer;
}

@media (min-width: 768px) {
  .menu-toggle-btn {
    display: none;
  }
}

.mobile-menu-drawer {
  display: none;
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(18px);
}

.mobile-menu-drawer.open {
  display: block;
}

.mobile-menu-drawer ul {
  list-style: none;
  margin: 0;
  padding: 0.75rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.875rem;
}

.mobile-menu-drawer a {
  display: block;
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
  color: var(--foreground);
  font-weight: 500;
}

.mobile-menu-drawer a:hover {
  background-color: var(--secondary);
}

/* Hero Section */
.hero-section {
  position: relative;
  overflow: hidden;
  padding-top: 3.5rem;
  padding-bottom: 6rem;
}

@media (min-width: 768px) {
  .hero-section {
    padding-top: 6rem;
    padding-bottom: 8rem;
  }
}

.hero-grid {
  display: grid;
  gap: 3.5rem;
  align-items: center;
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 9999px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(8px);
  padding: 0.25rem 0.875rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary);
}

.hero-title {
  margin-top: 1.25rem;
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

@media (min-width: 640px) {
  .hero-title { font-size: 3rem; }
}

@media (min-width: 768px) {
  .hero-title { font-size: 3.75rem; }
}

.hero-body {
  margin-top: 1.25rem;
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 36rem;
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 9999px;
  background: var(--gradient-brand);
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #ffffff !important;
  box-shadow: var(--shadow-elevated);
  transition: all 0.25s ease;
}

.btn-primary:hover {
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 9999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--foreground) !important;
  transition: all 0.25s ease;
}

.btn-secondary:hover {
  border-color: rgba(37, 99, 235, 0.4);
  background: #ffffff;
}

/* Trust Bar */
.trust-bar {
  border-radius: 1rem;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  padding: 1rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted-foreground);
}

/* Feature Grid */
.grid-3 {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.icon-box {
  display: grid;
  height: 3rem;
  width: 3rem;
  place-items: center;
  border-radius: 1rem;
  background: var(--gradient-brand);
  color: #ffffff;
  box-shadow: var(--shadow-elevated);
}

/* FAQ Accordion */
.faq-item {
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: #ffffff;
  overflow: hidden;
  margin-bottom: 0.75rem;
  transition: all 0.2s ease;
}

.faq-trigger {
  width: 100%;
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  border: none;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--foreground);
  text-align: left;
  cursor: pointer;
}

.faq-content {
  display: none;
  padding: 0 1.5rem 1.25rem 1.5rem;
  color: var(--muted-foreground);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.faq-item.open .faq-content {
  display: block;
}

.faq-item.open .faq-icon {
  transform: rotate(180deg);
}

.faq-icon {
  transition: transform 0.25s ease;
}

/* Stats Section */
.stats-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(1, 1fr);
}

@media (min-width: 640px) {
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
}

.stat-card {
  padding: 2rem;
  text-align: center;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
}

/* Footer */
.site-footer {
  margin-top: 6rem;
  border-top: 1px solid var(--border);
  background: var(--gradient-soft);
}

.footer-grid {
  padding-top: 3.5rem;
  padding-bottom: 3.5rem;
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.footer-col-title {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--foreground);
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  font-size: 0.875rem;
}

.footer-links a {
  color: var(--muted-foreground);
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--foreground);
}

.social-icon-btn {
  display: grid;
  height: 2.25rem;
  width: 2.25rem;
  place-items: center;
  border-radius: 9999px;
  border: 1px solid var(--border);
  color: var(--muted-foreground);
  transition: all 0.2s ease;
}

.social-icon-btn:hover {
  color: var(--foreground);
  border-color: rgba(37, 99, 235, 0.4);
}

/* Back To Top Button */
.back-to-top-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 40;
  display: grid;
  height: 2.75rem;
  width: 2.75rem;
  place-items: center;
  border-radius: 9999px;
  background: #ffffff;
  border: 1px solid var(--border);
  color: var(--foreground);
  box-shadow: var(--shadow-elevated);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
}

.back-to-top-btn.visible {
  opacity: 1;
  pointer-events: auto;
}

.back-to-top-btn:hover {
  transform: translateY(-2px);
}

/* Blog Styles */
.blog-post-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
}

.blog-tag {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 600;
  width: fit-content;
}

.post-content-typography {
  font-size: 1.125rem;
  line-height: 1.75;
  color: #334155;
}

.post-content-typography h2 {
  font-size: 1.875rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.post-content-typography h3 {
  font-size: 1.375rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.post-content-typography p {
  margin-bottom: 1.5rem;
}

.post-content-typography ul, .post-content-typography ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.post-content-typography li {
  margin-bottom: 0.5rem;
}

/* Keyframes */
@keyframes float-slow {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-14px) translateX(6px); }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

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

.animate-fade-up {
  animation: fade-up 0.7s ease-out both;
}
