@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@600;700&family=Source+Sans+3:wght@400;600;700&display=swap');

:root {
  --bg: #f0ecd9;
  --ink: #1e1d17;
  --panel: #fff8e8;
  --line: #ccb98f;
  --accent: #c1440e;
  --accent-2: #1f5b72;
  --accent-3: #2f7d56;
  --muted: #655f50;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Source Sans 3", "Trebuchet MS", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 4%, #fff7d9 0%, transparent 35%),
    radial-gradient(circle at 88% 10%, #d9efe8 0%, transparent 34%),
    linear-gradient(180deg, #f5efdd 0%, #ece2c7 100%);
}

h1,
h2,
h3,
h4,
.brand {
  font-family: "Baloo 2", "Trebuchet MS", sans-serif;
  letter-spacing: 0.01em;
}

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

.site-header {
  border-bottom: 3px solid var(--line);
  background: rgba(255, 249, 234, 0.95);
  backdrop-filter: blur(4px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  margin: 0;
  font-size: 1.4rem;
  letter-spacing: 0.02em;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
}

.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  box-shadow: 0 4px 0 #1f5b7233;
}

.nav { display: flex; gap: 12px; flex-wrap: wrap; }

.nav a {
  text-decoration: none;
  color: var(--ink);
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  font-size: 0.95rem;
}

.nav a[aria-current="page"] {
  background: #e6f3ee;
  border-color: #95bea7;
}

.tools-menu {
  position: relative;
}

.tools-menu summary {
  list-style: none;
  cursor: pointer;
  color: var(--ink);
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  font-size: 0.95rem;
}

.tools-menu summary::-webkit-details-marker {
  display: none;
}

.tools-list {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 210px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.14);
  padding: 8px;
  display: grid;
  gap: 6px;
  z-index: 20;
}

.tools-list a {
  border-radius: 8px;
  padding: 8px 10px;
  text-decoration: none;
}

.tools-list a:hover {
  background: #f0e7ce;
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px;
}

.hero {
  border: 2px solid var(--line);
  border-radius: 18px;
  background:
    linear-gradient(135deg, #fff9eb 0%, #fff3d9 50%, #f7efe2 100%);
  padding: 22px;
  margin-bottom: 26px;
  box-shadow: 0 9px 0 #dfd2b2;
}

.hero h1 {
  margin-top: 0;
  margin-bottom: 8px;
  font-size: clamp(1.9rem, 2.8vw, 2.8rem);
}

.hero p { color: var(--muted); max-width: 80ch; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 18px;
}

.grid.featured {
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
}

.card {
  background: var(--panel);
  border: 2px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 0 #dfd2b2;
}

.card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  min-height: 280px;
  object-fit: cover;
  display: block;
}

.card-body { padding: 16px; }
.card h3 { margin: 0 0 8px; font-size: 1.28rem; }
.meta { margin: 6px 0; color: var(--muted); font-size: 0.93rem; }

.badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 4px 9px;
  margin-right: 6px;
  border: 1px solid var(--line);
}

.badge-link {
  text-decoration: none;
}

.badge.live-now {
  background: #c32020;
  color: #fff;
  border-color: #8d1313;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
  padding: 6px 12px;
  box-shadow: 0 2px 0 #8d1313;
}

.badge.upcoming {
  background: #e0ebff;
  color: #1c4578;
  border-color: #92afd8;
}

.badge.promo {
  background: #ffe7f3;
  color: #8b1b53;
  border-color: #d69ab8;
  font-size: 0.82rem;
  letter-spacing: 0.03em;
}

.badge.archived { background: #f3e2cf; color: #7a3d17; }

.issue-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}

.issue-item {
  background: var(--panel);
  border: 2px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  box-shadow: 0 6px 0 #dfd2b2;
}

.cta {
  display: inline-block;
  margin-top: 12px;
  padding: 11px 15px;
  border-radius: 11px;
  border: 1px solid #8f3209;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
}

.form-panel {
  max-width: 800px;
  border: 2px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  padding: 16px;
  box-shadow: 0 6px 0 #dfd2b2;
}

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid .full { grid-column: 1 / -1; }

label {
  font-size: 0.9rem;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

input,
textarea,
select {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}

button {
  padding: 11px 14px;
  border-radius: 9px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

small { color: var(--muted); }

.footer {
  border-top: 2px solid var(--line);
  margin-top: 36px;
  color: var(--muted);
  padding: 24px;
  text-align: center;
}

@media (max-width: 820px) {
  .site-header .inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .grid.featured,
  .grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .form-grid { grid-template-columns: 1fr; }
  .card img { min-height: 220px; }
}

.person-link {
  color: var(--accent-2);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.person-link:hover {
  color: #144154;
}

.profile-hero {
  border-left: 8px solid var(--accent-2);
}

.home-stage {
  display: grid;
  gap: 18px;
  margin-bottom: 24px;
  justify-items: center;
}

.featured-carousel {
  position: relative;
  width: min(100%, calc(100vw - 48px));
  max-width: 100%;
  margin-inline: auto;
  border: 2px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 10px 0 #dfd2b2;
  background: #0f2630;
}

.carousel-track {
  position: relative;
  aspect-ratio: 16 / 7;
  min-height: 360px;
}

.carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 420ms ease;
  pointer-events: none;
}

.carousel-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.carousel-slide a {
  display: block;
  width: 100%;
  height: 100%;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carousel-overlay {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  background: linear-gradient(180deg, rgba(7, 15, 20, 0.08) 0%, rgba(7, 15, 20, 0.88) 60%);
  color: #fff;
  border-radius: 12px;
  padding: 14px 16px;
}

.carousel-overlay h2 {
  margin: 0 0 4px;
  font-size: clamp(1.1rem, 2.1vw, 1.7rem);
}

.carousel-overlay p {
  margin: 0;
  color: #f4f4f4;
  font-size: 0.95rem;
}

.carousel-controls {
  position: absolute;
  top: 50%;
  left: 10px;
  right: 10px;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  pointer-events: none;
}

.carousel-controls button {
  pointer-events: auto;
  border: 1px solid #ffffff66;
  background: #00000055;
  color: #fff;
  border-radius: 999px;
  width: 38px;
  height: 38px;
  padding: 0;
  font-size: 1.25rem;
  line-height: 1;
}

.carousel-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  display: flex;
  justify-content: center;
  gap: 6px;
}

.carousel-dots button {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  border: 0;
  padding: 0;
  background: #ffffff77;
}

.carousel-dots button.active {
  background: #fff;
}

.live-strip h3 {
  margin: 0 0 10px;
}

.live-strip {
  width: min(100%, calc(100vw - 48px));
  max-width: 100%;
}

.tile-strip-wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  width: 100%;
}

.tile-handle {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  padding: 0;
  font-size: 1.2rem;
  line-height: 1;
}

.tile-handle:disabled {
  opacity: 0.45;
  cursor: default;
}

.tile-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(210px, 260px);
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
  max-width: 100%;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.tile-row::-webkit-scrollbar {
  display: none;
}

.tile {
  min-width: 210px;
  border: 2px solid var(--line);
  border-radius: 13px;
  overflow: hidden;
  background: var(--panel);
}

.tile img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}

.tile-body {
  padding: 10px;
}

.tile-body h4 {
  margin: 8px 0 0;
  font-size: 0.98rem;
}

.tile-body h4 a {
  text-decoration: none;
  color: var(--ink);
}

@media (max-width: 900px) {
  .carousel-track {
    aspect-ratio: 16 / 9;
    min-height: 280px;
  }

  .featured-carousel {
    width: min(100%, calc(100vw - 24px));
  }

  .live-strip {
    width: min(100%, calc(100vw - 24px));
  }
}

.card.card-click,
.tile.tile-click {
  cursor: pointer;
}

.card.card-click h3 a,
.tile.tile-click h4 a {
  color: var(--ink);
  text-decoration: none;
}

.card.card-click h3 a:hover,
.tile.tile-click h4 a:hover {
  text-decoration: underline;
}

.blog-feed {
  display: grid;
  gap: 18px;
}

.blog-post-card {
  border: 2px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 8px 0 #dfd2b2;
}

.blog-cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.blog-post-body {
  padding: 16px 18px 18px;
}

.blog-post-body h1,
.blog-post-body h2 {
  margin: 6px 0 10px;
}

.blog-post-full {
  max-width: 980px;
  margin: 0 auto;
}

.blog-collage {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, clamp(90px, 14vw, 145px));
  gap: 4px;
  background: #111;
  border-bottom: 1px solid var(--line);
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  overflow: hidden;
}

.blog-collage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 760px) {
  .blog-collage {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(3, clamp(88px, 26vw, 135px));
  }
}
