/* DocketRadar — Component Styles
   Buttons, cards, navigation, footer, and reusable patterns */

/* ========== Buttons ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-sans);
  font-size: var(--text-button);
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  padding: var(--space-3) var(--space-6);
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition:
    all var(--transition-base),
    box-shadow var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
}

.btn:focus-visible {
  outline: 2px solid var(--color-teal);
  outline-offset: 2px;
}

/* Primary CTA — Amber */
.btn-primary {
  background-color: var(--color-teal);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background-color: var(--color-teal-dark);
  color: #ffffff;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

/* Secondary — Outline */
.btn-secondary {
  background-color: transparent;
  color: var(--color-teal);
  border: 2px solid var(--color-teal);
}

.btn-secondary:hover {
  background-color: var(--color-teal);
  color: #ffffff;
}

/* Ghost — White outline (for dark backgrounds) */
.btn-ghost {
  background-color: transparent;
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn-ghost:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.7);
}

/* Large button variant */
.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: 1rem;
  border-radius: 10px;
}

/* Small button variant */
.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-caption);
}

/* ========== Navigation ========== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(250, 250, 248, 0.75);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  height: var(--nav-height);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
  height: 100%;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  flex-shrink: 0;
}

.nav-logo img {
  height: 36px;
  width: auto;
}

.nav-logo-text {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-slate-900);
}

.nav-logo-text span {
  font-weight: 500;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-link {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-slate-500);
  text-decoration: none;
  transition: color var(--transition-base);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-slate-800);
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--color-teal);
  transform: scaleX(0);
  transition: transform var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

.nav-cta {
  margin-left: var(--space-4);
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-2);
  cursor: pointer;
  background: none;
  border: none;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-slate-700);
  border-radius: 1px;
  transition: all var(--transition-base);
}

/* Mobile nav */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  background: rgba(250, 250, 248, 0.95);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
  z-index: 999;
}

.nav-mobile.open {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.nav-mobile .nav-link {
  font-size: 1rem;
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-slate-200);
}

.nav-mobile .nav-link::after {
  display: none;
}

.nav-mobile .btn {
  margin-top: var(--space-2);
  text-align: center;
}

/* ========== Cards ========== */
.card {
  background-color: #ffffff;
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-slow);
  border: 1px solid var(--color-slate-200);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(
    to bottom,
    var(--color-accent-light),
    var(--color-accent)
  );
  opacity: 0;
  transition: opacity var(--transition-slow);
}

.card:hover {
  box-shadow: 0 12px 40px rgba(28, 25, 23, 0.08);
  transform: translateY(-3px);
}

.card:hover::before {
  opacity: 1;
}

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  background-color: rgba(184, 134, 11, 0.08);
  color: var(--color-teal);
  margin-bottom: var(--space-5);
}

.card-icon svg {
  width: 28px;
  height: 28px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card h3 {
  margin-bottom: var(--space-3);
  color: var(--color-navy);
}

.card p {
  color: var(--color-slate-600);
  line-height: 1.6;
}

/* ========== County Badge ========== */
.county-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-slate-200);
  font-weight: 500;
  font-size: var(--text-body-sm);
  color: var(--color-slate-700);
  transition: all var(--transition-base);
}

.county-badge:hover {
  border-color: var(--color-teal);
  box-shadow: var(--shadow-sm);
}

.county-badge svg {
  width: 20px;
  height: 20px;
  color: var(--color-teal);
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

/* ========== Privacy Shield ========== */
.privacy-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--color-teal), var(--color-navy));
  margin: 0 auto var(--space-6);
}

.privacy-icon svg {
  width: 36px;
  height: 36px;
  stroke: #ffffff;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ========== Footer ========== */
.footer {
  background-color: var(--color-dark-bg-alt, #142b20);
  color: rgba(255, 255, 255, 0.7);
  padding: var(--space-16) 0 var(--space-8);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-10);
  margin-bottom: var(--space-12);
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.6);
  font-size: var(--text-body-sm);
  line-height: 1.7;
  max-width: 320px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  text-decoration: none;
}

.footer-logo img {
  height: 32px;
  width: auto;
}

.footer-logo-text {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.footer-logo-text span {
  font-weight: 500;
}

.footer-heading {
  font-size: var(--text-body-sm);
  font-weight: 600;
  color: #ffffff;
  margin-bottom: var(--space-4);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: var(--text-body-sm);
  transition: color var(--transition-base);
  text-decoration: none;
}

.footer-links a:hover {
  color: #ffffff;
}

.footer-social {
  display: flex;
  gap: var(--space-3);
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-lg);
  background-color: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  transition: all var(--transition-base);
}

.footer-social a:hover {
  background-color: rgba(255, 255, 255, 0.15);
  color: #ffffff;
}

.footer-social svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--space-8);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer-copyright {
  font-size: var(--text-caption);
  color: rgba(255, 255, 255, 0.4);
}

.footer-legal {
  display: flex;
  gap: var(--space-6);
}

.footer-legal a {
  font-size: var(--text-caption);
  color: rgba(255, 255, 255, 0.4);
  transition: color var(--transition-base);
}

.footer-legal a:hover {
  color: rgba(255, 255, 255, 0.7);
}

/* ========== Pricing Table ========== */
.pricing-card {
  background-color: #ffffff;
  border-radius: var(--radius-2xl);
  padding: var(--space-10);
  border: 1px solid var(--color-slate-200);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
}

.pricing-card.featured {
  border-color: var(--color-teal);
  border-width: 2px;
  position: relative;
  box-shadow: var(--shadow-lg);
}

.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--color-teal);
  color: #ffffff;
  font-size: var(--text-caption);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.pricing-tier {
  font-size: var(--text-h3);
  font-weight: 600;
  color: var(--color-navy);
  margin-bottom: var(--space-2);
}

.pricing-desc {
  font-size: var(--text-body-sm);
  color: var(--color-slate-500);
  margin-bottom: var(--space-6);
}

.pricing-price {
  display: flex;
  align-items: baseline;
  gap: var(--space-1);
  margin-bottom: var(--space-6);
}

.pricing-amount {
  font-size: var(--text-display);
  font-weight: 700;
  color: var(--color-slate-900);
}

.pricing-period {
  font-size: var(--text-body-sm);
  color: var(--color-slate-500);
}

.pricing-features {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

.pricing-feature {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  font-size: var(--text-body-sm);
  color: var(--color-slate-600);
}

.pricing-feature svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-top: 1px;
}

.pricing-feature .check {
  color: var(--color-success);
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.pricing-feature .dash {
  color: var(--color-slate-300);
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.pricing-card .btn {
  width: 100%;
}

/* ========== Comparison Table ========== */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-body-sm);
}

.comparison-table thead th {
  padding: var(--space-4) var(--space-4);
  text-align: left;
  font-weight: 600;
  color: var(--color-navy);
  border-bottom: 2px solid var(--color-slate-200);
  font-size: var(--text-body-sm);
}

.comparison-table thead th:first-child {
  text-align: left;
}

.comparison-table thead th:not(:first-child) {
  text-align: center;
}

.comparison-table tbody td {
  padding: var(--space-4) var(--space-4);
  border-bottom: 1px solid var(--color-slate-100);
  color: var(--color-slate-600);
}

.comparison-table tbody td:first-child {
  font-weight: 500;
  color: var(--color-slate-700);
}

.comparison-table tbody td:not(:first-child) {
  text-align: center;
}

.comparison-table tbody tr:hover {
  background-color: var(--color-slate-50);
}

.comparison-table .check-icon {
  color: var(--color-success);
}

.comparison-table .dash-icon {
  color: var(--color-slate-300);
}

/* ========== FAQ ========== */
.faq-item {
  border-bottom: 1px solid var(--color-slate-200);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5) 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-size: var(--text-body);
  font-weight: 600;
  color: var(--color-slate-800);
  transition: color var(--transition-base);
}

.faq-question:hover {
  color: var(--color-teal);
}

.faq-question svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  stroke: var(--color-slate-400);
  stroke-width: 2;
  fill: none;
  transition: transform var(--transition-base);
}

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

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height var(--transition-slow),
    padding var(--transition-slow);
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding-bottom: var(--space-5);
}

.faq-answer p {
  color: var(--color-slate-600);
  line-height: 1.7;
}

/* ========== Feature Detail Card ========== */
.feature-detail {
  display: flex;
  align-items: flex-start;
  gap: var(--space-6);
  padding: var(--space-8);
  background-color: #ffffff;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-slate-200);
  transition: all var(--transition-base);
}

.feature-detail:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-slate-300);
}

.feature-detail-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: var(--radius-lg);
  background-color: rgba(184, 134, 11, 0.08);
  color: var(--color-teal);
  flex-shrink: 0;
}

.feature-detail-icon svg {
  width: 26px;
  height: 26px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-detail h3 {
  color: var(--color-navy);
  margin-bottom: var(--space-2);
}

.feature-detail p {
  color: var(--color-slate-600);
  font-size: var(--text-body-sm);
  line-height: 1.7;
}

/* ========== Section Divider ========== */
.section-divider {
  position: relative;
  padding-top: 100px;
  text-align: center;
  overflow: hidden;
}

.section-divider::before {
  content: attr(data-number);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 180px;
  font-weight: 800;
  letter-spacing: -0.06em;
  line-height: 0.85;
  opacity: 0.03;
  pointer-events: none;
  white-space: nowrap;
  color: currentColor;
}

.section-divider-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--color-accent);
  margin-bottom: var(--space-4);
}

.section-divider-title {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--color-slate-900);
  margin-bottom: var(--space-3);
}

.section-divider-desc {
  font-size: 1.125rem;
  font-weight: 300;
  color: var(--color-slate-400);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* Dark variant */
.section-dark .section-divider-title {
  color: #ffffff;
}

.section-dark .section-divider-desc {
  color: rgba(255, 255, 255, 0.4);
}

/* ========== Touch Feedback ========== */
@media (hover: none) and (pointer: coarse) {
  .card::before {
    opacity: 0.5;
  }
  .card:active {
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
  }
  .btn:active {
    transform: scale(0.97);
  }
  .county-badge:active {
    border-color: var(--color-teal);
  }
}
