/* =========================================
   JEEPRADIO - BLACK & CYAN THEME
   ========================================= */

:root {
  color-scheme: dark;

  --bg-main: #080808;
  --bg-section: #0e1117;
  --bg-card: #111111;
  --bg-card-hover: #161616;

  --accent: #00d9f5;
  --accent-hover: #67e8f9;

  --heading: #ffffff;
  --text-main: #e2e8f0;
  --text-muted: #a1aec5;

  --border: #262626;
  --border-accent: rgba(0, 217, 245, 0.35);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg-main);
  color: var(--text-main);
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

a:hover {
  color: var(--accent-hover);
}

button {
  min-height: 44px;
  min-width: 44px;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Header */
.site-header {
  background: #080808;
  border-color: var(--border);
  border-style: solid;
  border-width: 0 0 1px;
  padding: 0;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 6.5rem;
  color: #ffffff;
  background: #080808;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  padding: 0.5rem;
  cursor: pointer;
}

.brand-logo {
  display: block;
  width: min(100%, 36rem);
  max-height: 6.5rem;
  padding: 0.25rem 0.5rem;
  object-fit: contain;
  transition: transform 0.2s ease;
}

.brand:hover .brand-logo {
  transform: scale(1.015);
}

.brand-subtitle {
  font-size: 0.625rem;
  font-family: monospace;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  margin-top: 0.25rem;
}

@media (min-width: 640px) {
  .brand-subtitle {
    font-size: 0.75rem;
  }
}

/* Navigation */
nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.35rem 0.5rem;
  width: 100%;
  margin: 0 auto;
  padding: 0.6rem 0.75rem;
  background: #080808;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

nav a {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.65rem;
  color: #d4d4d8;
  text-decoration: none;
  white-space: nowrap;
  border-radius: 6px;
  transition: background-color 0.15s ease, color 0.15s ease;
  min-height: 34px;
}

nav a:hover,
nav a[aria-current="page"] {
  color: var(--accent);
  background: #111111;
  border-color: var(--border-accent);
}

/* Don't highlight footer links for current page */
.footer-links a[aria-current="page"] {
  color: var(--text-muted);
  background: transparent;
  border-color: transparent;
}

.footer-links a[aria-current="page"]:hover {
  color: var(--accent);
}

/* Mobile menu button */
.mobile-menu-btn {
  display: none;
  background: transparent;
  border: none;
  color: #9ca3af;
  padding: 0.5rem;
  cursor: pointer;
  border-radius: 0.5rem;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.mobile-menu-btn:hover {
  color: #fff;
  background: rgba(23, 23, 23, 0.9);
}

@media (max-width: 639px) {
  .mobile-menu-btn {
    display: block;
  }

  .desktop-nav {
    display: none;
  }

  .mobile-nav {
    display: none;
  }

  .mobile-nav.open {
    display: block;
  }
}

/* Mobile navigation dropdown */
.mobile-nav {
  display: none;
  border-top: 1px solid var(--border);
  background: #080808;
}

.mobile-nav a {
  display: block;
  padding: 0.75rem 0.75rem;
  color: #d4d4d8;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 0.5rem;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.mobile-nav a:hover,
.mobile-nav a[aria-current="page"] {
  color: var(--accent);
}

@media (min-width: 640px) {
  .brand {
    min-height: 8.5rem;
  }
  .brand-logo {
    max-height: 8rem;
  }
  nav {
    font-size: 0.8rem;
    gap: 0.4rem 0.75rem;
    padding: 0.65rem 1.5rem;
  }
}

/* Main content */
main {
  width: min(100% - 2rem, 54rem);
  margin: 0 auto;
  padding: 2rem 0 4rem;
  flex: 1;
  background: transparent;
}

/* Quick Guide Section */
.quick-guide-section {
  background: linear-gradient(135deg, rgba(0, 217, 245, 0.1) 0%, rgba(34, 211, 238, 0.05) 100%);
  border: 2px solid var(--border-accent);
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.quick-guide-section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin: 0 0 0.5rem 0;
}

.quick-guide-section h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--heading);
  margin: 0 0 1rem 0;
}

.quick-guide-items {
  display: grid;
  gap: 1rem;
}

.quick-guide-item {
  background: rgba(17, 17, 17, 0.8);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1rem;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.quick-guide-item:hover {
  border-color: var(--accent);
  background: rgba(22, 22, 22, 0.9);
}

.quick-guide-item h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 0.5rem 0;
}

.quick-guide-item p {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.6;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.breadcrumbs a:hover {
  color: var(--accent);
}

/* About page specific */
.thanks-message {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--accent);
  margin-top: 2rem;
  text-align: center;
}

.tagline {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
  margin-top: 0.5rem;
  text-align: center;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Contact page specific */
.email-link {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 1rem 0;
}

.email-link a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.15s ease;
}

.email-link a:hover {
  color: #22d3ee;
  text-decoration: underline;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  padding: 0.25rem 0;
}

.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.breadcrumbs span[aria-hidden="true"] {
  color: #475569;
}

/* Headings */
h1, h2, h3, h4 {
  color: var(--heading);
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.75rem, 4.5vw, 2.5rem);
  font-weight: 800;
}

h2 {
  margin: 2.25rem 0 0.75rem;
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  font-weight: 700;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.4rem;
}

h3 {
  margin: 1.75rem 0 0.5rem;
  font-size: 1.15rem;
  font-weight: 600;
}

h4 {
  margin: 1.25rem 0 0.35rem;
  font-size: 1rem;
  font-weight: 600;
}

/* Paragraphs */
p, ul, ol {
  color: var(--text-main);
  font-size: clamp(0.95rem, 1.8vw, 1.05rem);
  line-height: 1.75;
}

/* Article metadata */
.article-meta {
  margin: 0 0 0.5rem;
  color: var(--text-muted);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
}

.article-meta a {
  color: var(--accent);
  text-decoration: none;
}

.article-meta a:hover {
  text-decoration: underline;
}

/* Article images */
.article-image {
  margin: 2rem 0;
  width: 100%;
}

.article-image img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
  border: 1px solid var(--border);
  object-fit: cover;
}

.article-image figcaption {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
  font-style: italic;
}

.author-meta {
  margin: 0 0 1.5rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-style: italic;
}

.author-meta a {
  color: var(--accent);
  text-decoration: none;
}

.author-meta a:hover {
  text-decoration: underline;
}

ul, ol {
  padding-left: 1.4rem;
  margin: 1rem 0;
}

li + li {
  margin-top: 0.5rem;
}

/* Topic labels */
.topic-tag {
  display: inline-block;
  margin-bottom: 0.75rem;
  padding: 0.2rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  background: #101010;
  border: 1px solid var(--border-accent);
  border-radius: 9999px;
}

.hero-lede {
  color: #e2e8f0;
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

/* Information cards */
.info-card {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-card);
  box-shadow: none;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  margin: 1.75rem 0;
}

@media (min-width: 640px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Feature cards */
.feature-box {
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.feature-box:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-accent);
  transform: translateY(-2px);
}

.feature-box h3 {
  margin-top: 0;
  color: #d4d4d8;
  font-size: 1.1rem;
}

.feature-box p {
  font-size: 0.92rem;
  margin: 0.5rem 0 0;
}

/* Tables */
.table-wrapper {
  overflow-x: auto;
  margin: 1.5rem 0;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: var(--bg-card);
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

thead {
  background: #111111;
  border-bottom: 1px solid var(--border);
}

th {
  padding: 0.75rem 1rem;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #252525;
  color: var(--text-main);
}

tr:last-child td {
  border-bottom: none;
}

tr:hover td {
  background: rgba(0, 0, 0, 0.3);
}

/* Responsive table for mobile - stack table rows as cards */
@media (max-width: 640px) {
  .table-wrapper {
    overflow-x: visible;
  }

  table,
  thead,
  tbody,
  th,
  td,
  tr {
    display: block;
  }

  thead {
    display: none;
  }

  tr {
    margin-bottom: 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--bg-card);
    padding: 0.75rem;
  }

  td {
    border: none;
    padding: 0.5rem 0;
    padding-left: 0;
    position: relative;
    padding-left: 0;
    display: flex;
    flex-direction: column;
  }

  td::before {
    content: attr(data-label);
    font-weight: 700;
    color: var(--accent);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.25rem;
  }

  tr:hover td {
    background: transparent;
  }
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.4rem;
  background: #101010;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 9999px;
  border: 1px solid var(--border-accent);
  box-shadow: none;
  transition: background-color 0.15s ease, transform 0.15s ease;
  white-space: nowrap;
  min-height: 44px;
}

.btn-primary:hover {
  background: #151515;
  color: var(--accent-hover);
  border-color: var(--accent);
  transform: translateY(-1px);
}

/* Share Button */
.share-row {
  margin: 2rem 0;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.2rem;
  background: #101010;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 9999px;
  border: 1px solid var(--border-accent);
  transition: background-color 0.15s ease, transform 0.15s ease;
  white-space: nowrap;
  min-height: 44px;
  min-width: 44px;
  cursor: pointer;
}

.share-btn:hover {
  background: #151515;
  color: var(--accent-hover);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.share-dropdown {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: 0.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 0.75rem;
  min-width: 180px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  z-index: 100;
}

.share-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.share-link {
  display: flex;
  align-items: center;
  padding: 0.6rem 0.8rem;
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 0.5rem;
  transition: background-color 0.15s ease;
  min-height: 44px;
  border: none;
  background: transparent;
  cursor: pointer;
  width: 100%;
  text-align: left;
}

.share-link:hover {
  background: var(--bg-card-hover);
  color: var(--accent);
}

.share-link.copy-link {
  color: var(--accent);
  border: 1px solid var(--border-accent);
}

/* Save Button */
.remove-bookmark {
  margin-top: 0.5rem;
  padding: 0.4rem 0.8rem;
  background: #101010;
  color: #ef4444;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  cursor: pointer;
  transition: background-color 0.15s ease;
  min-height: 44px;
  min-width: 44px;
}

.remove-bookmark:hover {
  background: #151515;
  border-color: #ef4444;
}

/* FAQ */
details {
  border: 1px solid var(--border);
  border-radius: 0.65rem;
  background: var(--bg-card);
  margin: 0.75rem 0;
  padding: 0.75rem 1rem;
  transition: border-color 0.15s ease;
}

details[open] {
  background: #101010;
  border-color: var(--border-accent);
}

summary {
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.25rem 0;
  min-height: 38px;
  -webkit-tap-highlight-color: transparent;
}

summary::-webkit-details-marker {
  display: none;
}

summary:hover {
  color: var(--accent);
}

summary::after {
  content: "+";
  color: var(--accent);
  font-size: 1.25rem;
  line-height: 1;
  font-weight: 700;
  transition: transform 0.2s ease;
}

details[open] summary::after {
  content: "−";
  transform: rotate(180deg);
}

details p {
  margin: 0.75rem 0 0.25rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* CTA */
.cta-banner {
  margin: 2.5rem 0;
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 0.85rem;
  background: #101010;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: flex-start;
  box-shadow: none;
}

@media (min-width: 640px) {
  .cta-banner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 1.75rem 2rem;
  }
}

.cta-banner h3 {
  margin: 0 0 0.35rem;
  color: #fff;
  font-size: 1.2rem;
}

.cta-banner p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

/* Footer */
.site-footer {
  border-width: 1px 0 0;
  padding: 2.5rem 1rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  background: #080808;
  border-color: var(--border);
  margin-top: auto;
}

.footer-content {
  max-width: 960px;
  margin: 0 auto;
}

/* Enhanced Footer Navigation Grid */
.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
  align-items: start;
}

@media (min-width: 640px) {
  .footer-nav {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-nav {
    grid-template-columns: repeat(5, 1fr);
  }
}

.footer-section {
  display: flex;
  flex-direction: column;
}

.footer-heading {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: normal;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
  transition: color 0.15s ease;
  display: inline-flex;
  align-items: center;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-brand {
  grid-column: span 2;
}

@media (min-width: 640px) {
  .footer-brand {
    grid-column: span 4;
  }
}

@media (min-width: 1024px) {
  .footer-brand {
    grid-column: span 1;
  }
}

.footer-brand-text {
  font-size: 0.875rem;
  line-height: 1.5;
  margin-bottom: 0.5rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
}

.footer-brand-credit {
  font-size: 0.7rem;
  color: #6b7280;
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
}

/* Footer Bottom Bar */
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 640px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
  }
}

.footer-bottom-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

@media (min-width: 640px) {
  .footer-bottom-left {
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
  }
}

.footer-copyright {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.8rem;
  letter-spacing: normal;
  text-align: center;
  font-weight: 400;
  text-transform: none;
}

@media (min-width: 640px) {
  .footer-copyright {
    text-align: left;
  }
}

.footer-back-to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(0, 217, 245, 0.3);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: normal;
  text-transform: none;
  text-decoration: none;
  transition: background-color 0.15s ease;
}

.footer-back-to-top:hover {
  background-color: rgba(0, 217, 245, 0.1);
}

/* Alternating content sections */
section:nth-of-type(even) {
  background: var(--bg-section);
}

section:nth-of-type(odd) {
  background: var(--bg-main);
}

/* Mobile menu */
.mobile-nav {
  background: #080808;
  border-color: var(--border);
}

.mobile-nav a:hover,
.mobile-nav a[aria-current="page"] {
  color: var(--accent);
}

/* Focus */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* Responsive adjustment for small screens (320px - 400px) */
@media (max-width: 480px) {
  main {
    padding: 1.25rem 0 3rem;
  }
  .info-card {
    padding: 1rem;
  }
}
