/* CareOS — Component styles (glass, navbar, footer, CTA, pricing) */

.section-fade {
  background: linear-gradient(
    180deg,
    transparent 0%,
    #ffffff 60%
  );
}

/* Glassmorphism */
.glass-panel {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.02);
}

.glass-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.8) 0%, rgba(255, 255, 255, 0.4) 100%);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.03);
}

/* Gradient text */
.text-gradient {
  background: linear-gradient(135deg, #44A3EC 0%, #5B63E6 50%, #9B50E9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Navbar — fixed bar with glass */
.navbar-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  transition: all 0.3s ease;
}

/* Nav dropdown — keep panel open when moving from trigger to panel */
.nav-dropdown .nav-dropdown-panel {
  pointer-events: none;
}
.nav-dropdown.group:hover .nav-dropdown-panel {
  pointer-events: auto;
}
.nav-dropdown .nav-dropdown-trigger:focus + .nav-dropdown-panel,
.nav-dropdown .nav-dropdown-panel:focus-within {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Mobile nav accordion — open state */
.js-nav-accordion.is-open .js-nav-accordion-icon {
  transform: rotate(180deg);
}

/* Footer — base footer layout, no extra space below */
.footer-base {
  background: white;
  border-top: 1px solid #e2e8f0;
  padding-top: 3rem;
  padding-bottom: 1.5rem;
  flex-shrink: 0;
  margin-bottom: 0;
}

/* Back to top — theme gradient, fixed bottom-right */
.back-to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 40;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #44A3EC 0%, #5B63E6 50%, #9B50E9 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(91, 99, 230, 0.35);
  transition: opacity 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
  opacity: 0;
  visibility: hidden;
  border: none;
  cursor: pointer;
  text-decoration: none;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(91, 99, 230, 0.45);
  color: white;
}

.back-to-top:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(91, 99, 230, 0.4);
}

/* CTA section — gradient block */
.cta-gradient-block {
  background: linear-gradient(135deg, #44A3EC 0%, #5B63E6 50%, #9B50E9 100%);
  border-radius: 40px;
  padding: 2.5rem 1rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

@media (min-width: 768px) {
  .cta-gradient-block {
    padding: 5rem 5rem;
  }
}

/* Pricing cards */
.pricing-card {
  border-radius: 1.5rem;
  padding: 2rem;
  border: 1px solid rgba(226, 232, 240, 0.5);
  background: rgba(255, 255, 255, 0.4);
}

.pricing-card-featured {
  position: relative;
  padding: 1px;
  border-radius: 1.5rem;
  background: linear-gradient(to bottom, #44A3EC, #5B63E6, #9B50E9);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

@media (min-width: 768px) {
  .pricing-card-featured {
    transform: translateY(-1rem);
  }
}

.pricing-card-featured-inner {
  background: white;
  border-radius: 23px;
  padding: 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Trust logos section */
.trust-section {
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
  border-top: 1px solid rgba(226, 232, 240, 0.5);
  border-bottom: 1px solid rgba(226, 232, 240, 0.5);
  background: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(4px);
}

/* Demo section — interactive feature selector */
.demo-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.demo-tabs button {
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid #e5e7eb;
  background: white;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.demo-tabs button:hover {
  border-color: #44A3EC;
  color: #5B63E6;
}

.demo-tabs button.active {
  background: linear-gradient(135deg, #44A3EC, #5B63E6);
  color: white;
  border: none;
}

.demo-preview {
  max-width: 560px;
  margin: 0 auto;
}

.demo-preview img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 40px -15px rgba(0, 0, 0, 0.1);
}

/* Docs layout — sidebar + content */
.docs-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
}

.docs-sidebar {
  border-right: 1px solid #e5e7eb;
  padding-right: 20px;
}

.docs-sidebar ul {
  list-style: none;
  padding: 0;
}

.docs-sidebar li {
  margin-bottom: 12px;
}

.docs-content h1 {
  font-size: 32px;
  margin-bottom: 16px;
}

.docs-content p {
  color: #475569;
  line-height: 1.6;
}

@media (max-width: 768px) {
  .docs-layout {
    grid-template-columns: 1fr;
  }

  .docs-sidebar {
    border: none;
    padding-right: 0;
    margin-bottom: 30px;
  }
}

/* Toast notifications */
.careos-toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 90vw;
  pointer-events: none;
}

.careos-toast-container > * {
  pointer-events: auto;
}

.careos-toast {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-radius: 0.75rem;
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
  background: white;
  border: 1px solid #e2e8f0;
  opacity: 0;
  transform: translateY(0.5rem);
  transition: opacity 0.3s ease, transform 0.3s ease;
  cursor: pointer;
}

.careos-toast--visible {
  opacity: 1;
  transform: translateY(0);
}

.careos-toast--success .careos-toast-icon {
  color: #059669;
}

.careos-toast--error .careos-toast-icon {
  color: #dc2626;
}

.careos-toast-message {
  font-size: 0.875rem;
  color: #334155;
}

/* Site search results */
#site-search-results {
  display: none;
  max-height: 400px;
  overflow: auto;
}

#site-search-results a {
  transition: all 0.2s ease;
}

#site-search-results a:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

/* Product tour — highlight area in Command Center mockup */
[data-tour-area].tour-highlight {
  outline: 2px solid rgba(91, 99, 230, 0.8);
  outline-offset: 2px;
  border-radius: 0.5rem;
  box-shadow: 0 0 0 4px rgba(91, 99, 230, 0.15);
  transition: outline-color 0.2s ease, box-shadow 0.2s ease;
}
.command-center-mockup [data-tour-area].tour-highlight {
  position: relative;
  z-index: 5;
}
