/* ============================================
   VAANYA CLINIC — HEADER STYLE (Black Navbar)
   File: /css/header.css
   ============================================ */

/* -------- Root Variables -------- */
:root {
  --bg: #ffffff;
  --text: #101828;
  --muted: #667085;
  --brand: #0ea5e9;
  --brand-dark: #075985;
  --ring: rgba(14,165,233,0.35);
  --shadow: 0 2px 10px rgba(0,0,0,0.08);
  --radius: 14px;
  --container: 1200px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1220;
    --text: #ecf0f5;
    --muted: #94a3b8;
    --brand: #22d3ee;
    --brand-dark: #06b6d4;
  }
}

/* -------- General Reset -------- */
.site-header a {
  text-decoration: none;
  color: inherit;
}

/* -------- Header -------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg);
  border-bottom: 1px solid rgba(0,0,0,0.05);
  box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}

/* -------- Container -------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
}

/* -------- Header Layout -------- */
.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  min-height: 80px;
}

/* -------- Logo -------- */
.logo img {
  display: block;
  height: 50px;
  width: auto;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* -------- Navbar -------- */
.navbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 8px 16px;
  border-radius: var(--radius);
  background: #000; /* Black navbar */
}

/* Navbar Links */
.navbar a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 500;
  color: #f1f1f1;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: color 0.25s ease, background-color 0.25s ease, transform 0.05s ease;
}

/* Hover & Active Link underline */
.navbar a::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 6px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.3s ease;
  pointer-events: none;
}

.navbar a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.navbar a:hover::after {
  transform: scaleX(1);
}

/* Current Page Highlight */
.navbar a[aria-current="page"] {
  color: var(--brand);
  background: rgba(255, 255, 255, 0.15);
}

.navbar a[aria-current="page"]::after {
  transform: scaleX(1);
}

/* -------- Appointment Button -------- */
.btn-appointment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  font-size: 15px;
  font-weight: 600;
  color: #746e6e;
  background: linear-gradient(180deg, var(--brand), var(--brand-dark));
  border-radius: 999px;
  box-shadow: 0 6px 16px rgba(14,165,233,0.35);
  transition: transform 0.1s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}

.btn-appointment:hover {
  filter: saturate(110%);
  box-shadow: 0 8px 22px rgba(14,165,233,0.45);
}

.btn-appointment:active {
  transform: translateY(1px);
}

/* Focus accessibility */
.btn-appointment:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px var(--bg),
    0 0 0 6px var(--ring);
}

/* -------- Responsive Design -------- */

/* Tablet adjustments */
@media (max-width: 1024px) {
  .header-inner {
    gap: 12px;
  }
  .navbar a {
    padding: 8px 10px;
    font-size: 14px;
  }
}

/* Mobile: Stack layout */
@media (max-width: 820px) {
  .header-inner {
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "logo cta"
      "nav nav";
    row-gap: 10px;
    padding-block: 12px;
  }

  .logo { grid-area: logo; }
  .navbar { 
    grid-area: nav;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .navbar::-webkit-scrollbar { display: none; }

  .btn-appointment { grid-area: cta; }

  .navbar {
    justify-content: flex-start;
    padding: 8px;
    border-radius: 12px;
  }
  .navbar a {
    padding: 10px 12px;
  }
}

/* Small screens */
@media (max-width: 480px) {
  .logo img {
    height: 40px;
  }
  .btn-appointment {
    padding: 8px 14px;
    font-size: 14px;
  }
  .navbar a {
    font-size: 14px;
  }
}

/* -------- Focus-visible (Keyboard Navigation) -------- */
.navbar a:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px var(--bg),
    0 0 0 6px var(--ring);
  color: #fff;
  background: rgba(14,165,233,0.25);
}

/* -------- Reduce motion -------- */
@media (prefers-reduced-motion: reduce) {
  .navbar a,
  .navbar a::after,
  .btn-appointment {
    transition: none !important;
  }
}
