:root {
  --paper: #050505;
  --ink: #ffffff;
  --muted: #c7c7c7;
  --line: rgba(255, 255, 255, 0.13);
  --panel: rgba(0, 0, 0, 0.62);
  --red: #dc2626;
  --red-soft: rgba(220, 38, 38, 0.18);
  --blue: #ff5a5f;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Yu Gothic", "Hiragino Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  isolation: isolate;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}

body::before {
  z-index: -3;
  background:
    radial-gradient(circle at 16% 10%, rgba(220, 38, 38, 0.34), transparent 30%),
    radial-gradient(circle at 80% 24%, rgba(220, 38, 38, 0.2), transparent 28%),
    #050505;
}

body::after {
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.76)),
    linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.66));
  backdrop-filter: blur(1px);
}

.resource-backdrops {
  position: absolute;
  inset: 0;
  z-index: -2;
  height: 100%;
  overflow: hidden;
  opacity: 0.7;
  pointer-events: none;
}

.resource-backdrops img {
  display: block;
  width: 100%;
  height: auto;
  filter: saturate(1.12) contrast(1.06);
}

.page-header,
main {
  position: relative;
  z-index: 1;
}

.page-header {
  padding: 42px clamp(18px, 5vw, 76px) 30px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.44));
  backdrop-filter: blur(18px);
}

h1 {
  margin: 0;
  font-size: clamp(2.8rem, 7vw, 5rem);
  line-height: 1;
}

.resource-note {
  max-width: 640px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.super-pills,
.category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.super-pills a,
.category-pills a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.56);
  color: var(--ink);
  font-weight: 900;
  text-decoration: none;
  backdrop-filter: blur(14px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.super-pills a:hover,
.category-pills a:hover {
  border-color: rgba(248, 113, 113, 0.72);
  background: rgba(220, 38, 38, 0.2);
}

.super-section {
  padding: clamp(34px, 5vw, 64px) clamp(18px, 5vw, 76px);
  border-bottom: 1px solid var(--line);
}

.super-section h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.6rem);
  line-height: 1;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.category-section {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
}

.category-section h3 {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: 1.35rem;
}

.category-title-row {
  display: flex;
  gap: 16px;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 0;
  padding: 18px 18px 0;
}

.category-title-row h3 {
  margin: 0;
}

label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

select {
  min-height: 40px;
  min-width: min(260px, 100%);
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.72);
  color: var(--ink);
  font: inherit;
  font-weight: 850;
  text-transform: none;
}

.amazon-browser,
.discovery-browser {
  max-width: 880px;
  margin-top: 24px;
}

.link-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 18px;
  list-style: none;
}

.link-list li {
  display: grid;
  gap: 8px;
  padding: 0;
  border-top: 0;
}

.link-list li:first-child { border-top: 0; }

.link-list a {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  min-height: 44px;
  align-items: center;
  padding: 9px 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.6);
  color: var(--ink);
  font-size: 1.02rem;
  font-weight: 900;
  text-decoration: none;
  backdrop-filter: blur(14px);
  box-shadow: 0 14px 42px rgba(0, 0, 0, 0.26);
}

.link-list a:hover {
  border-color: rgba(248, 113, 113, 0.78);
  background: rgba(220, 38, 38, 0.22);
}

.link-list p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

@media (max-width: 820px) {
  .page-header {
    padding-top: 24px;
  }

  .resource-backdrops {
    opacity: 0.42;
  }

  h1 {
    font-size: 2.35rem;
  }

  .resource-note {
    font-size: 0.92rem;
  }

  .super-pills,
  .category-pills {
    gap: 8px;
  }

  .super-pills a,
  .category-pills a {
    min-height: 38px;
    padding: 7px 11px;
    font-size: 0.84rem;
  }

  .super-section h2 {
    font-size: 1.95rem;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .category-title-row {
    align-items: stretch;
    flex-direction: column;
  }
}
