:root {
  --content-max: 480px;
  --teal-950: #082f2b;
  --teal-900: #123d38;
  --teal-700: #007f73;
  --teal-500: #00a995;
  --teal-300: #71cfc0;
  --seafoam-100: #e1f9f3;
  --seafoam-50: #f5fffc;
  --coral-500: #ff6f61;
  --coral-100: #fff1ed;
  --gold-400: #ffb35c;
  --paper: #f5fffc;
  --white: #ffffff;
  --ink: #123e39;
  --muted: #5f817c;
  --line: #d7eee8;
  --shadow: 0 16px 40px rgba(0, 127, 115, 0.12);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 10%, rgba(0, 169, 149, 0.16), transparent 34%),
    radial-gradient(circle at 85% 20%, rgba(255, 111, 97, 0.14), transparent 32%),
    linear-gradient(145deg, #dff8f3, #fff5ef);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.7;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

.site-backdrop {
  min-height: 100vh;
}

.site-shell {
  width: 100%;
  max-width: var(--content-max);
  min-height: 100vh;
  margin-inline: auto;
  overflow: hidden;
  background: var(--paper);
  box-shadow: 0 0 80px rgba(8, 47, 43, 0.14);
}

.site-header {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 66px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(215, 238, 232, 0.84);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
}

.brand {
  color: var(--teal-700);
  font-size: 1.8rem;
  font-weight: 950;
  letter-spacing: -0.08em;
}

.header-actions {
  display: flex;
  gap: 8px;
}

.icon-button,
.mobile-bottom-nav button {
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 13px;
  background: var(--seafoam-100);
  cursor: pointer;
}

.site-menu {
  position: sticky;
  z-index: 29;
  top: 66px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 14px 18px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--white);
  box-shadow: var(--shadow);
}

.site-menu[hidden],
.search-panel[hidden] {
  display: none;
}

.site-menu a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: 12px;
  background: var(--seafoam-50);
  color: var(--teal-900);
  font-size: 0.88rem;
  font-weight: 800;
}

.search-panel {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.search-panel label {
  display: block;
  margin-bottom: 6px;
  color: var(--teal-700);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.search-panel input {
  width: 100%;
  min-height: 44px;
  padding: 10px 13px;
  border: 1px solid var(--teal-300);
  border-radius: 13px;
  outline: none;
  background: var(--seafoam-50);
  color: var(--ink);
}

.search-panel input:focus {
  border-color: var(--teal-700);
  box-shadow: 0 0 0 3px rgba(0, 127, 115, 0.12);
}

.page-content {
  padding-bottom: 82px;
}

.category-hero {
  padding: 24px 18px 18px;
  background: linear-gradient(165deg, #f7fffd 0%, #dff8f2 100%);
}

.category-hero__copy {
  margin-bottom: 16px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--coral-500);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.category-hero h1,
.article-header h1 {
  margin: 0;
  color: var(--teal-950);
  font-size: clamp(2rem, 9vw, 2.72rem);
  font-weight: 950;
  letter-spacing: -0.055em;
  line-height: 1.06;
}

.category-hero p:not(.eyebrow) {
  margin: 10px 0 0;
  color: var(--muted);
}

.category-hero > img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  border-radius: var(--radius-xl);
  object-fit: cover;
  box-shadow: var(--shadow);
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 18px;
}

.category-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 68px;
  padding: 8px 4px;
  border: 1px solid rgba(215, 238, 232, 0.8);
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: 0 8px 20px rgba(0, 127, 115, 0.08);
  color: var(--teal-900);
  font-size: 0.7rem;
  font-weight: 850;
  line-height: 1.25;
  text-align: center;
}

.category-chip__icon {
  display: none;
}

.article-section {
  padding: 8px 18px 18px;
}

.section-heading {
  margin-bottom: 12px;
}

.section-heading h1,
.section-heading h2 {
  margin: 0;
  color: var(--teal-950);
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.25;
}

.article-list {
  display: grid;
  gap: 10px;
}

.article-card {
  overflow: hidden;
  border: 1px solid rgba(215, 238, 232, 0.84);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 10px 26px rgba(0, 127, 115, 0.07);
}

.article-card[hidden] {
  display: none;
}

.article-card > a {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  min-height: 116px;
}

.article-card img {
  width: 100%;
  height: 100%;
  min-height: 116px;
  object-fit: cover;
}

.article-card__copy {
  padding: 11px 12px;
}

.article-card h2 {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--teal-950);
  font-size: 0.96rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.article-card__copy > p:last-child {
  display: -webkit-box;
  margin: 5px 0 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.responsible-note {
  margin: 10px 18px 22px;
  padding: 16px;
  border-radius: var(--radius-lg);
  background: var(--teal-900);
  color: #e8fffa;
  font-size: 0.83rem;
}

.responsible-note strong {
  color: var(--gold-400);
}

.responsible-note p {
  margin: 5px 0 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 16px 18px 0;
  color: var(--muted);
  font-size: 0.76rem;
}

.article-header {
  padding: 22px 18px 15px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.78rem;
}

.article-cover {
  margin: 0 18px 18px;
}

.article-cover img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  border-radius: var(--radius-xl);
  object-fit: cover;
  box-shadow: var(--shadow);
}

.article-body {
  padding: 0 18px 10px;
}

.article-body h2 {
  margin: 1.75em 0 0.5em;
  color: var(--teal-950);
  font-size: 1.4rem;
  line-height: 1.25;
}

.article-body h3 {
  margin: 1.4em 0 0.45em;
  font-size: 1.12rem;
  line-height: 1.35;
}

.article-body p,
.article-body li {
  color: #365f59;
}

.article-body blockquote {
  margin: 1.2em 0;
  padding: 13px 14px;
  border-left: 4px solid var(--coral-500);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--coral-100);
  color: #7a3b35;
}

.article-body ul,
.article-body ol {
  padding-left: 1.3em;
}

.article-body strong {
  color: var(--teal-900);
}

.article-toc {
  margin: 0 18px 20px;
  padding: 15px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 8px 22px rgba(0, 127, 115, 0.07);
}

.article-toc strong {
  color: var(--teal-900);
}

.article-toc ol {
  margin: 8px 0 0;
  padding-left: 1.25em;
  color: var(--muted);
  font-size: 0.86rem;
}

.article-toc a {
  display: inline-block;
  padding-block: 3px;
  text-decoration: underline;
  text-decoration-color: var(--teal-300);
  text-underline-offset: 3px;
}

.article-prev-next {
  display: grid;
  gap: 8px;
  padding: 10px 18px 4px;
}

.article-prev-next a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: var(--seafoam-100);
  color: var(--teal-900);
  font-weight: 800;
}

.related-categories,
.related-articles {
  padding: 10px 18px 20px;
}

.related-categories h2,
.related-articles > h2 {
  margin: 0 0 12px;
  color: var(--teal-950);
  font-size: 1.3rem;
  line-height: 1.25;
}

.related-category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.related-category {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--white);
  color: var(--teal-900);
  font-size: 0.78rem;
  font-weight: 850;
  text-align: center;
}

.primary-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 16px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  background: var(--teal-700);
  color: var(--white);
  font-weight: 850;
}

.site-footer {
  padding: 24px 18px 88px;
  background: var(--teal-900);
  color: #dffbf5;
}

.site-footer strong {
  color: var(--gold-400);
  font-size: 1.35rem;
}

.site-footer p {
  margin: 5px 0;
}

.site-footer small {
  opacity: 0.72;
}

.mobile-bottom-nav {
  position: fixed;
  z-index: 40;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: 100%;
  max-width: var(--content-max);
  min-height: 64px;
  margin-inline: auto;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 -12px 30px rgba(8, 47, 43, 0.08);
  backdrop-filter: blur(18px);
}

.mobile-bottom-nav a,
.mobile-bottom-nav button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--teal-900);
  font-size: 1rem;
  cursor: pointer;
}

.mobile-bottom-nav span {
  margin-top: 1px;
  font-size: 0.65rem;
  font-weight: 800;
}

@media (max-width: 380px) {
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .category-chip {
    min-height: 52px;
  }
}

@media (min-width: 481px) {
  .site-shell {
    border-right: 1px solid rgba(255, 255, 255, 0.72);
    border-left: 1px solid rgba(255, 255, 255, 0.72);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
