/*
Theme Name: RadioHub Club
Theme URI: https://radiohub.cc
Author: RadioHub
Description: Lightweight, accessible block theme for amateur radio clubs with built-in Light and Dark mode.
Version: 1.1.0
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 8.1
License: GNU General Public License v2 or later
Text Domain: radiohub-club
*/

:root {
  --rh-bg: #f8fafc;
  --rh-surface: #ffffff;
  --rh-surface-alt: #f1f5f9;
  --rh-border: #cbd5e1;
  --rh-text: #0f172a;
  --rh-muted: #475569;
  --rh-accent: #0369a1;
  --rh-accent-hover: #075985;
  --rh-accent-contrast: #ffffff;
}

html[data-theme="dark"] {
  --rh-bg: #0b1120;
  --rh-surface: #111827;
  --rh-surface-alt: #1e293b;
  --rh-border: #334155;
  --rh-text: #f1f5f9;
  --rh-muted: #94a3b8;
  --rh-accent: #38bdf8;
  --rh-accent-hover: #7dd3fc;
  --rh-accent-contrast: #082f49;
}

html {
  background-color: var(--rh-bg);
  color: var(--rh-text);
  scroll-behavior: smooth;
}

body {
  background-color: var(--rh-bg);
  color: var(--rh-text);
  margin: 0;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--rh-accent);
  text-underline-offset: 3px;
}

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

/* Sticky Header */
.rh-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background-color: var(--rh-surface);
  border-bottom: 1px solid var(--rh-border);
}

.rh-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.rh-brand .wp-block-site-title a {
  color: var(--rh-text);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
}

/* Navigation links */
.wp-block-navigation .wp-block-navigation-item__content {
  color: var(--rh-text);
  font-weight: 500;
}

.wp-block-navigation .wp-block-navigation-item__content:hover {
  color: var(--rh-accent);
}

/* Light/Dark Toggle Button */
.rh-theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--rh-text);
  background-color: var(--rh-surface-alt);
  border: 1px solid var(--rh-border);
  border-radius: 9999px;
  cursor: pointer;
}

.rh-theme-toggle:hover {
  border-color: var(--rh-accent);
  color: var(--rh-accent);
}

/* Cards & Tables */
.rh-card {
  background-color: var(--rh-surface);
  border: 1px solid var(--rh-border);
  border-radius: 0.75rem;
  padding: 1.5rem;
}

.rh-hero {
  background-color: var(--rh-surface);
  border: 1px solid var(--rh-border);
  border-radius: 1rem;
  padding: clamp(1.75rem, 4vw, 3rem);
}

.wp-block-button__link {
  background-color: var(--rh-accent) !important;
  color: var(--rh-accent-contrast) !important;
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
}

.wp-block-button__link:hover {
  background-color: var(--rh-accent-hover) !important;
}

.wp-block-button.is-style-outline .wp-block-button__link {
  background-color: transparent !important;
  color: var(--rh-text) !important;
  border: 1px solid var(--rh-border) !important;
}

.wp-block-button.is-style-outline .wp-block-button__link:hover {
  border-color: var(--rh-accent) !important;
  color: var(--rh-accent) !important;
}

.wp-block-table table {
  border-collapse: collapse;
  width: 100%;
}

.wp-block-table th,
.wp-block-table td {
  border: 1px solid var(--rh-border);
  padding: 0.65rem 0.85rem;
  text-align: left;
}

.wp-block-table th {
  background-color: var(--rh-surface-alt);
}

/* Footer */
.rh-footer {
  background-color: var(--rh-surface);
  border-top: 1px solid var(--rh-border);
  color: var(--rh-muted);
  margin-top: 3rem;
}
