/* The Silent Observatory — shared styles */

:root {
  --bg-deep: #070b14;
  --bg-panel: #0c1222;
  --bg-card: #111827;
  --border: #1e293b;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --accent: #38bdf8;
  --accent-soft: #7dd3fc;
  --glow: rgba(56, 189, 248, 0.35);
  --star: #e0f2fe;
  --font-sans: "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "Cascadia Code", "Fira Code", "Consolas", monospace;
  --radius: 10px;
  --max-width: 920px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: var(--font-sans);
  background-color: var(--bg-deep);
  color: var(--text);
  line-height: 1.65;
  display: flex;
  flex-direction: column;
  background-image:
    radial-gradient(1.5px 1.5px at 20px 30px, var(--star), transparent),
    radial-gradient(1px 1px at 90px 70px, rgba(224, 242, 254, 0.7), transparent),
    radial-gradient(1.2px 1.2px at 160px 120px, var(--star), transparent),
    radial-gradient(1px 1px at 250px 40px, rgba(224, 242, 254, 0.5), transparent),
    radial-gradient(1.5px 1.5px at 340px 180px, var(--star), transparent),
    radial-gradient(1px 1px at 420px 90px, rgba(224, 242, 254, 0.6), transparent),
    radial-gradient(1.2px 1.2px at 500px 200px, var(--star), transparent),
    radial-gradient(1px 1px at 80px 220px, rgba(224, 242, 254, 0.4), transparent);
  background-size: 550px 280px;
  background-attachment: fixed;
}

/* Layout */
.site-header {
  border-bottom: 1px solid var(--border);
  background: rgba(7, 11, 20, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--accent-soft);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 1.05rem;
}

.logo-mark {
  width: 28px;
  height: 28px;
  border: 1.5px solid var(--accent);
  border-radius: 50%;
  display: grid;
  place-items: center;
  position: relative;
  box-shadow: 0 0 12px var(--glow);
}

.logo-mark::after {
  content: "";
  width: 8px;
  height: 8px;
  border: 1px solid var(--accent-soft);
  border-radius: 50%;
}

.logo:hover {
  color: var(--star);
}

.site-nav {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--text-muted);
  text-decoration: none;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  font-size: 0.9rem;
  transition: color 0.15s, background 0.15s;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--accent-soft);
  background: rgba(56, 189, 248, 0.08);
}

main {
  flex: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
  width: 100%;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  background: var(--bg-panel);
}

.site-footer p {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* Typography */
h1 {
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--star);
}

h2 {
  font-size: 1.35rem;
  font-weight: 600;
  margin: 2rem 0 0.75rem;
  color: var(--accent-soft);
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 1.25rem 0 0.5rem;
  color: var(--text);
}

p {
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.lead {
  font-size: 1.15rem;
  color: var(--text);
  max-width: 38em;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

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

/* Hero */
.hero {
  text-align: center;
  padding: 2rem 0 3rem;
}

.hero .lead {
  margin: 0 auto 1.75rem;
}

.badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
  background: rgba(56, 189, 248, 0.06);
}

/* Cards & grids */
.card-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  margin: 1.5rem 0;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.card:hover {
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 0 24px var(--glow);
}

.card h3 {
  margin-top: 0;
  color: var(--accent-soft);
}

.card p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

/* Observation entries */
.entry {
  border-left: 3px solid var(--accent);
  padding: 0.75rem 0 0.75rem 1.25rem;
  margin: 1.25rem 0;
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.05), transparent);
}

.entry time {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  display: block;
  margin-bottom: 0.35rem;
}

.entry h3 {
  margin: 0 0 0.4rem;
}

/* Instruments list */
.instrument {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.instrument:last-child {
  border-bottom: none;
}

.instrument-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  color: var(--accent);
}

/* CTA / buttons as links */
.btn {
  display: inline-block;
  padding: 0.65rem 1.3rem;
  background: transparent;
  color: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.15s, box-shadow 0.15s;
}

.btn:hover {
  background: rgba(56, 189, 248, 0.12);
  box-shadow: 0 0 16px var(--glow);
  color: var(--star);
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 0.5rem;
}

/* 404 page */
.error-page {
  text-align: center;
  padding: 4rem 1rem;
}

.error-code {
  font-family: var(--font-mono);
  font-size: clamp(4rem, 15vw, 7rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  text-shadow: 0 0 40px var(--glow);
  margin-bottom: 0.5rem;
}

.error-page h1 {
  margin-bottom: 1rem;
}

/* Utility */
.muted {
  color: var(--text-muted);
}

.mt-2 {
  margin-top: 2rem;
}

hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2.5rem 0;
}

/* Responsive tweaks */
@media (max-width: 560px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .site-nav {
    width: 100%;
  }
}
