/* ============================================================
   Mobile Slide Panel — modular component stylesheet
   Extracted from style.css §navbar + new close button header
   Pure CSS — no Tailwind
   ============================================================ */

/* --- Overlay --- */
.navbar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 49;
}

.navbar-overlay.open {
  display: block;
}

/* --- Slide Panel --- */
.navbar-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  height: 100dvh;
  background: var(--surface);
  z-index: 50;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  padding: 0 24px 24px;
  overflow-y: auto;
  box-shadow: -4px 0 24px rgba(15,23,42,0.08);
}

.navbar-panel.open {
  transform: translateX(0);
}

/* --- Panel Header — absolutely positioned to match hamburger --- */
.navbar-panel-header {
  position: absolute;
  top: 20px;         /* = navbar top (12px) + padding-top (8px) */
  right: 24px;       /* = navbar gap (12px) + padding-right (12px) */
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
  border: none;
}

/* Hide "Menu" title visually but keep accessible */
.navbar-panel-title {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Close (X) button — always visible at top-right inside panel */
.navbar-panel-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.2s ease;
}

.navbar-panel-close:hover {
  background: var(--bgSection);
}

.navbar-panel-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* --- Panel Navigation Links --- */
.navbar-panel-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 80px;  /* clear fixed navbar area */
}

.navbar-panel-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  color: var(--inkMuted);
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
  font-family: 'Inter', system-ui, sans-serif;
}

.navbar-panel-link:hover {
  background: var(--bgSection);
  color: var(--ink);
}

.navbar-panel-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.navbar-panel-cta {
  background: var(--accentLight);
  color: var(--accent);
  font-weight: 600;
  margin-top: 12px;
}

.navbar-panel-divider {
  border: none;
  border-top: 1px solid var(--bordLight);
  margin: 12px 0;
}

/* --- Desktop: hide mobile-only elements --- */
@media (min-width: 768px) {
  .navbar-panel,
  .navbar-overlay {
    display: none;
  }
}
