@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap");

/* Shared styles: header, nav, dropdowns, social icons, buttons */

:root {
  --color-primary: #0066ff;
  --color-text: #111827;
  --color-text-secondary: #4b5563;
  --color-text-muted: #6b7280;
  --color-bg: #ffffff;
  --color-bg-subtle: #f8fafc;
  --color-bg-code: #f1f5f9;
  --color-bg-hover: #f1f5f9;
  --color-border: #cbd5e1;
  --color-border-light: #e2e8f0;
  --color-border-medium: #d1d5db;
  --font-family:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui,
    sans-serif;
}

*,
*::before,
*::after {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Header */
header {
  padding: 16px 40px;
  display: flex;
  align-items: center;
  z-index: 1000;
}
.header-left {
  flex: 1;
}
.header-nav {
  flex: 0 0 auto;
  display: flex;
  justify-content: center;
}
.header-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.logo {
  width: 36px;
  height: 36px;
  cursor: pointer;
}

/* Footer */
footer {
  margin-top: 40px;
  border-top: 1px solid var(--color-border-light);
  padding: 60px 40px 40px;
}
.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  align-self: stretch;
}
.footer-logo {
  width: 240px;
  height: auto;
  margin-top: 8px;
}
.footer-left span {
  font-size: 13px;
  color: var(--color-text-muted);
  margin-top: auto;
}
.footer-right {
  display: flex;
  gap: 48px;
  width: 60%;
}
.footer-col h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 12px;
}
.footer-col a {
  display: block;
  font-size: 13px;
  color: var(--color-text-muted);
  text-decoration: none;
  line-height: 2;
  transition: color 0.2s ease;
}
.footer-col a:hover {
  color: var(--color-text);
}

/* Nav */
nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 36px;
}
nav a {
  color: #1a1a1a;
  text-decoration: none;
  margin: 0;
  font-size: clamp(15px, 1.1vw, 18px);
  font-weight: 400;
  letter-spacing: 0;
  cursor: pointer;
  position: relative;
}
nav a::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -5px;
  left: 0;
  background-color: var(--color-primary);
  visibility: hidden;
  transform: scaleX(0);
  transition: all 0.3s ease-in-out;
}
nav a:hover::after,
nav a.active::after,
nav a.page-active::after {
  visibility: visible;
  transform: scaleX(1);
}

/* Dropdown */
.nav-item {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.dropdown-trigger {
  color: #1a1a1a;
  text-decoration: none;
  margin: 0;
  font-size: clamp(15px, 1.1vw, 18px);
  font-weight: 400;
  letter-spacing: 0;
  cursor: pointer;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  font-family: inherit;
  padding: 0;
}
.dropdown-chevron {
  width: 8px;
  height: 5px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.35;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
  transform: translateY(1px);
  pointer-events: none;
}
.dropdown-trigger::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -5px;
  left: 0;
  background-color: var(--color-primary);
  visibility: hidden;
  transform: scaleX(0);
  transition: all 0.3s ease-in-out;
}
.dropdown-trigger:hover::after,
.nav-item:hover .dropdown-trigger::after,
.nav-item.active .dropdown-trigger::after,
.nav-item.page-active .dropdown-trigger::after {
  visibility: visible;
  transform: scaleX(1);
}
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  margin-top: 15px;
  min-width: 240px;
  border-radius: 14px;
  padding: 10px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease-in-out;
  z-index: 1001;
  isolation: isolate;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(248, 251, 255, 0.94) 100%);
  backdrop-filter: blur(14px) saturate(125%);
  -webkit-backdrop-filter: blur(14px) saturate(125%);
  border: 1px solid rgba(170, 188, 220, 0.55);
  box-shadow:
    0 18px 44px rgba(15, 23, 42, 0.16),
    0 1px 0 rgba(255, 255, 255, 0.9) inset;
}
.nav-item:hover .dropdown-menu,
.nav-item.active .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
.dropdown-item {
  display: block;
  padding: 10px 12px;
  color: #1f2937;
  text-decoration: none;
  font-size: clamp(15px, 1.3vw, 18px);
  transition: background-color 0.18s ease, color 0.18s ease;
  border-radius: 10px;
}
.dropdown-item:hover {
  background-color: #edf4ff;
  color: var(--color-primary);
}
.dropdown-item::after {
  display: none;
}
.dropdown-subheading {
  display: block;
  padding: 10px 12px 5px;
  color: var(--color-text-muted);
  font-size: clamp(13px, 1.1vw, 16px);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Pill Buttons */
.btn-ghost {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 24px;
  background-color: rgba(0, 102, 255, 0.75);
  color: #ffffff;
  text-decoration: none;
  font-size: clamp(16px, 1.5vw, 18px);
  font-weight: 500;
  letter-spacing: 0.02em;
  cursor: pointer;
  border: 1px solid rgba(0, 102, 255, 0.6);
  border-radius: 9999px;
  box-shadow: 0 4px 16px rgba(0, 102, 255, 0.15);
  transition:
    opacity 0.5s ease-in-out,
    background-color 0.4s ease;
  opacity: 0;
}
.btn-ghost:hover {
  background-color: rgba(0, 102, 255, 0.9);
  color: #ffffff;
}
.btn-ghost::after {
  display: none;
}
.btn-ghost:active {
  background-color: rgba(0, 102, 255, 0.85);
}
/* CTA Button (Docs) */
.btn-cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 10px 24px;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: none;
  font-size: clamp(16px, 1.5vw, 18px);
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--color-text);
  transition:
    opacity 0.5s ease-in-out,
    color 0.4s ease;
  opacity: 0;
}
.btn-cta:hover {
  color: var(--color-primary);
}
.btn-cta::before {
  display: none;
}
.btn-cta:hover svg {
  stroke: currentColor;
}
.btn-cta span {
  position: relative;
}
.btn-cta svg {
  position: relative;
  margin-left: 8px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.4s ease;
}
.btn-visible {
  opacity: 1;
}

/* Nav CTA Button (Start Building) */
.nav-cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 8px 20px;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: none;
  font-size: clamp(14px, 1.1vw, 16px);
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--color-text);
  transition: color 0.4s ease;
}
.nav-cta:hover {
  color: var(--color-primary);
}
.nav-cta::before {
  display: none;
}
.nav-cta::after {
  display: none;
}
.nav-cta span {
  position: relative;
}
.nav-cta svg {
  position: relative;
  margin-left: 6px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.4s ease;
}

.button-container {
  margin-top: 20px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Mobile */
@media (max-width: 768px) {
  header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 10px 16px;
    background-color: var(--color-bg);
    border-bottom: 1px solid var(--color-border-medium);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    align-items: center;
  }
  .header-left {
    flex: 0 0 auto;
  }
  .header-nav {
    flex: 1;
  }
  .header-right {
    flex: 0 0 auto;
  }
  nav {
    gap: 12px;
  }
  nav a {
    font-size: 12px;
    margin: 0;
    padding: 5px 4px;
  }
  .dropdown-trigger {
    font-size: 12px;
    margin: 0;
    padding: 5px 4px;
  }
  .dropdown-menu {
    position: fixed;
    top: 50px;
    left: 0;
    right: 0;
    min-width: 100%;
    border-radius: 0;
    margin-top: 0;
    max-height: 70vh;
    overflow-y: auto;
    transform: translateY(-10px);
  }
  .nav-item:hover .dropdown-menu,
  .nav-item.active .dropdown-menu {
    transform: translateY(0);
  }
  .dropdown-item {
    font-size: 14px;
    padding: 12px 20px;
  }
  .dropdown-subheading {
    font-size: 11px;
    padding: 12px 20px 6px;
  }
  .btn-ghost {
    font-size: 12px;
    padding: 6px 16px;
  }
  .btn-cta {
    padding: 6px 16px;
    font-size: 12px;
  }
  .btn-cta::before {
    width: 34px;
    height: 100%;
  }
  .nav-cta {
    font-size: 12px;
    padding: 6px 12px;
  }
  .nav-cta svg {
    display: none;
  }
  .button-container {
    justify-content: flex-start;
  }
  footer {
    padding: 40px 16px 24px;
  }
  .footer-inner {
    flex-direction: column;
    gap: 32px;
  }
  .footer-right {
    gap: 32px;
  }
}
