:root {
  --bg: #ffffff;
  --bg-alt: #f7fbff;
  --card: #ffffff;
  --muted: #64748b;
  --text: #0f172a;
  --brand: #0ea5a6; /* teal */
  --brand-strong: #0891b2;
  --ring: rgba(14, 165, 166, 0.25);
  --sk-base: #e5e7eb;   /* skeleton base */
  --sk-shine: #f3f4f6;  /* skeleton shine */
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 100%);
  letter-spacing: 0.2px;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255,255,255, 0.7);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e5e7eb;
}
.brand {
  display: inline-block;
  padding: 16px 0;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: .2px;
}
.brand .dot { color: var(--brand); }

.hero {
  position: relative;
  overflow: hidden;
}
.hero__inner { padding: 80px 0 48px; }
.hero h1 {
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.08;
  margin: 0 0 14px;
}
.hero .sub {
  margin: 0 0 28px;
  color: var(--muted);
  max-width: 60ch;
}
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 0;
  text-decoration: none;
  color: var(--text);
  border: 1px solid #e5e7eb;
  background: #ffffff;
  transition: transform 120ms ease, background 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}
.btn:hover { transform: translateY(-1px); background: #ffffff; border-color: #d1d5db; box-shadow: 0 10px 24px -10px rgba(2, 8, 23, 0.12); }
.btn.primary { background: linear-gradient(135deg, var(--brand) 0%, var(--brand-strong) 100%); border-color: transparent; color: white; }
.btn.primary:hover { box-shadow: 0 12px 24px -10px rgba(8,145,178,0.35); }

.hero__bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(600px 200px at 20% -20%, rgba(14,165,166,0.18), transparent),
    radial-gradient(800px 260px at 80% -40%, rgba(8,145,178,0.14), transparent),
    radial-gradient(700px 300px at 50% -30%, rgba(99,102,241,0.10), transparent);
  pointer-events: none;
}

/* 404 page hero layout */
.hero--404 { min-height: 60vh; display: flex; align-items: center; }

.places { padding: 36px 0 72px; }
.section-title {
  font-size: 1.25rem;
  letter-spacing: .2px;
  margin: 12px 0 16px;
}

.grid {
  --cols: 3;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0,1fr));
  gap: 16px;
}

@media (max-width: 1000px) { .grid { --cols: 2; } }
@media (max-width: 640px)  { .grid { --cols: 1; } }

/* Small-screen tweaks */
@media (max-width: 640px) {
  .hero__inner { padding: 64px 0 32px; text-align: center; }
  .cta-row { justify-content: center; }
}

.card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0;
  padding: 18px;
  min-height: 170px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 20px -12px rgba(2, 8, 23, 0.15);
}
.card::after {
  content: "";
  position: absolute; inset: -1px;
  border-radius: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(14,165,166,0.05);
}
.card .icon { font-size: 22px; line-height: 1; }
.card__title { margin: 4px 0 2px; font-size: 1.05rem; }
.card__text { margin: 0; color: var(--muted); }
.card__meta { margin-top: auto; font-size: 0.9rem; color: #a8b3c7; opacity: .9; }

.site-footer {
  border-top: 1px solid #e5e7eb;
  color: var(--muted);
  background: #ffffffcc;
}
.footer__inner { padding: 18px 0; display: flex; gap: 10px; justify-content: space-between; flex-wrap: wrap; }

/* Reduce motion for those who prefer it */
@media (prefers-reduced-motion: reduce) {
  .btn, .btn:hover { transition: none; }
}

/* Skeleton loading */
@keyframes skeleton-shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.skeleton-block {
  background: linear-gradient(90deg, var(--sk-base) 25%, var(--sk-shine) 37%, var(--sk-base) 63%);
  background-size: 400% 100%;
  animation: skeleton-shimmer 1.2s ease-in-out infinite;
}

.hero-skeleton { display: none; gap: 12px; max-width: 720px; }
.hero-skeleton .sk-title { height: 40px; width: 70%; }
.hero-skeleton .sk-sub { height: 14px; width: 100%; }
.hero-skeleton .sk-sub.small { width: 80%; }
.hero-skeleton .sk-btn { height: 44px; width: 220px; }

.skeleton-grid { display: none; }
.skeleton-card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  padding: 18px;
  min-height: 170px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 8px 20px -12px rgba(2, 8, 23, 0.08);
}
.skeleton-card .sk-icon { height: 22px; width: 22px; }
.skeleton-card .sk-title { height: 18px; width: 60%; margin-top: 6px; }
.skeleton-card .sk-text { height: 12px; width: 100%; }
.skeleton-card .sk-text.small { width: 80%; }
.skeleton-card .sk-meta { margin-top: auto; height: 12px; width: 40%; }

/* Toggle visibility when loading */
body.loading .grid:not(.skeleton-grid) { display: none; }
body.loading .skeleton-grid { display: grid; }
body.loading .hero-skeleton { display: grid; }
