:root {
  --nhs-blue: #005eb8;
  --fnd-navy: #002b5f;
  --fnd-deep-navy: #001a3b;
  --fnd-blue: #104778;
  --fnd-magenta: #c9005a;
  --fnd-rose: #ed2b7b;
  --fnd-teal: var(--fnd-magenta);
  --fnd-aqua: var(--fnd-rose);
  --ink: #061b3d;
  --text: #26364d;
  --muted: #637086;
  --border: #dfe6ef;
  --panel: #f7f9fc;
  --pale: #fff1f7;
  --pale-blue: #edf5fc;
  --warning: #ffdd00;
  --white: #ffffff;
  --shadow: 0 14px 34px rgba(0, 43, 95, 0.1), 0 4px 14px rgba(201, 0, 90, 0.05);
  --radius: 8px;
  --max: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
  font-size: 18px;
  line-height: 1.58;
  letter-spacing: 0;
}

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

a {
  color: var(--fnd-magenta);
  text-underline-offset: 0.16em;
  text-decoration-thickness: 0.08em;
}

a:hover {
  color: var(--fnd-navy);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--warning);
  outline-offset: 3px;
}

p,
ul,
ol {
  margin: 0 0 1rem;
}

ul,
ol {
  padding-left: 1.35rem;
}

li + li {
  margin-top: 0.35rem;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 1rem;
  color: var(--ink);
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: 0;
}

h1 {
  max-width: 880px;
  font-size: clamp(2.15rem, 5vw, 4.45rem);
}

h2 {
  font-size: clamp(1.75rem, 3vw, 2.7rem);
}

h3 {
  font-size: clamp(1.25rem, 2vw, 1.55rem);
}

h4 {
  font-size: 1.05rem;
}

.skip-link {
  position: absolute;
  z-index: 20;
  top: 0.75rem;
  left: 0.75rem;
  transform: translateY(-160%);
  padding: 0.65rem 0.9rem;
  color: var(--ink);
  background: var(--warning);
  font-weight: 800;
}

.skip-link:focus {
  transform: translateY(0);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 8px 28px rgba(0, 43, 95, 0.04);
  backdrop-filter: blur(12px);
}

.topbar {
  background: linear-gradient(90deg, var(--fnd-deep-navy), var(--fnd-navy));
  color: var(--white);
  font-size: 0.88rem;
  line-height: 1.35;
  box-shadow: inset 0 -3px 0 rgba(201, 0, 90, 0.34);
}

.topbar .wrap {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
}

.topbar a {
  color: var(--white);
  font-weight: 700;
}

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.nav-row {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  color: var(--ink);
  text-decoration: none;
}

.brand img {
  width: 232px;
  max-height: 92px;
  object-fit: contain;
}

.nav-toggle {
  display: none;
  min-width: 48px;
  min-height: 48px;
  border: 2px solid var(--fnd-navy);
  border-radius: var(--radius);
  color: var(--fnd-navy);
  background: var(--white);
  cursor: pointer;
}

.nav-toggle svg {
  width: 24px;
  height: 24px;
  margin: auto;
}

.site-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.1rem;
}

.site-nav a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 0.55rem 0.52rem;
  border-bottom: 4px solid transparent;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav a[aria-current="page"],
.site-nav a:hover {
  border-bottom-color: var(--fnd-magenta);
  color: var(--fnd-navy);
}

.hero {
  background: linear-gradient(112deg, #f8fbff 0%, #ffffff 54%, #fff1f7 100%);
  border-bottom: 1px solid var(--border);
}

.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  min-height: 610px;
  padding-top: clamp(3rem, 8vw, 6rem);
  padding-bottom: clamp(3rem, 8vw, 6rem);
}

.hero p {
  max-width: 720px;
  font-size: clamp(1.12rem, 2vw, 1.36rem);
  line-height: 1.55;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.72rem 1rem;
  border: 2px solid var(--fnd-magenta);
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--fnd-magenta), #a8004d);
  color: var(--white);
  font-size: 1rem;
  font-weight: 800;
  text-decoration: none;
  line-height: 1.2;
}

.button:hover {
  background: var(--fnd-navy);
  border-color: var(--fnd-navy);
  color: var(--white);
}

.button.secondary {
  color: var(--fnd-magenta);
  background: var(--white);
}

.button.secondary:hover {
  color: var(--fnd-navy);
  border-color: var(--fnd-navy);
}

.button svg {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
}

.hero-panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero-panel-header {
  padding: 1rem 1.1rem;
  background: linear-gradient(90deg, var(--fnd-navy), var(--fnd-magenta));
  color: var(--white);
  font-weight: 800;
}

.hero-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.hero-list li {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 0.8rem;
  align-items: start;
  margin: 0;
  padding: 1rem 1.1rem;
  border-top: 1px solid var(--border);
}

.icon-dot {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--fnd-magenta);
  background: var(--pale);
}

.icon-dot svg {
  width: 20px;
  height: 20px;
}

.section {
  padding: clamp(3rem, 7vw, 5.5rem) 0;
}

.section.alt {
  background: var(--panel);
}

.section.teal {
  background: var(--pale);
}

.section.navy {
  background: linear-gradient(135deg, var(--fnd-deep-navy), var(--fnd-navy));
  color: var(--white);
}

.section.navy h2,
.section.navy h3,
.section.navy p,
.section.navy li {
  color: var(--white);
}

.section.navy a {
  color: var(--white);
}

.section-head {
  max-width: 820px;
  margin-bottom: 2rem;
}

.section-head p,
.lead {
  max-width: 820px;
  color: var(--muted);
  font-size: 1.14rem;
}

.section.navy .section-head p,
.section.navy .lead {
  color: #e6f0fb;
}

.grid {
  display: grid;
  gap: 1rem;
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card,
.support-card,
.fact-row,
.info-box {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 24px rgba(0, 43, 95, 0.04);
}

.card,
.support-card,
.info-box {
  padding: 1.25rem;
}

.card h3,
.support-card h3 {
  margin-bottom: 0.55rem;
}

.card p:last-child,
.support-card p:last-child,
.info-box p:last-child {
  margin-bottom: 0;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.65rem;
  font-weight: 800;
}

.card-link svg {
  width: 18px;
  height: 18px;
}

.fact-row {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  overflow: hidden;
}

.fact-row strong {
  padding: 1rem;
  color: var(--ink);
  background: var(--pale-blue);
}

.fact-row span {
  padding: 1rem;
}

.alert {
  padding: 1rem 1.2rem;
  border-left: 8px solid var(--warning);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: #fff8cf;
}

.alert.blue {
  border-left-color: var(--nhs-blue);
  background: var(--pale-blue);
}

.alert.teal {
  border-left-color: var(--fnd-magenta);
  background: var(--pale);
}

.alert p:last-child {
  margin-bottom: 0;
}

.page-hero {
  background: linear-gradient(105deg, #f8fbff 0%, #ffffff 58%, #fff1f7 100%);
  border-bottom: 1px solid var(--border);
}

.page-hero .wrap {
  padding-top: clamp(2.5rem, 6vw, 4.6rem);
  padding-bottom: clamp(2.5rem, 6vw, 4.6rem);
}

.breadcrumbs {
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.breadcrumbs a {
  color: var(--muted);
}

.content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.content-main > * + h2 {
  margin-top: 2.4rem;
}

.content-main > * + h3 {
  margin-top: 1.7rem;
}

.toc {
  position: sticky;
  top: 118px;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.toc h2 {
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.toc a {
  display: block;
  padding: 0.38rem 0;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
}

.symptom-list,
.treatment-list {
  display: grid;
  gap: 0.8rem;
  margin: 1.25rem 0;
  padding: 0;
  list-style: none;
}

.symptom-list li,
.treatment-list li {
  margin: 0;
  padding: 1rem;
  border-left: 6px solid var(--fnd-magenta);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--panel);
}

.check-list {
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  margin-top: 0.65rem;
  padding-left: 2rem;
}

.check-list li::before {
  content: "";
  position: absolute;
  top: 0.35rem;
  left: 0;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: var(--fnd-magenta);
}

.check-list li::after {
  content: "";
  position: absolute;
  top: 0.59rem;
  left: 0.32rem;
  width: 0.42rem;
  height: 0.22rem;
  border-bottom: 2px solid var(--white);
  border-left: 2px solid var(--white);
  transform: rotate(-45deg);
}

.support-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.support-meta {
  display: grid;
  gap: 0.35rem;
  margin: 0.8rem 0 1rem;
  padding: 0.85rem;
  border-radius: var(--radius);
  background: var(--panel);
  font-size: 0.95rem;
}

.support-meta span {
  overflow-wrap: anywhere;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.5rem 0 1rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0.2rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--white);
  color: var(--fnd-navy);
  font-size: 0.82rem;
  font-weight: 800;
}

.faq-list {
  display: grid;
  gap: 0.75rem;
}

details {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

summary {
  cursor: pointer;
  padding: 1rem 3rem 1rem 1rem;
  color: var(--ink);
  font-weight: 800;
  list-style: none;
  position: relative;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 1rem;
  transform: translateY(-50%);
  color: var(--fnd-magenta);
  font-size: 1.45rem;
}

details[open] summary::after {
  content: "-";
}

details > div {
  padding: 0 1rem 1rem;
}

.source-list {
  display: grid;
  gap: 0.7rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.source-list li {
  margin: 0;
  padding: 0.85rem;
  border-left: 5px solid var(--fnd-magenta);
  background: var(--white);
}

.community-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(260px, 0.55fr);
  gap: 1.5rem;
  align-items: center;
  padding: clamp(1.25rem, 4vw, 2rem);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.community-icon {
  display: grid;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--fnd-navy), var(--fnd-magenta) 68%, var(--fnd-rose));
  color: var(--white);
}

.community-icon svg {
  width: 45%;
  height: 45%;
}

.product-hero {
  background: linear-gradient(115deg, #f8fbff 0%, #ffffff 54%, #fff1f7 100%);
  border-bottom: 1px solid var(--border);
}

.product-hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding-top: clamp(3rem, 7vw, 5.5rem);
  padding-bottom: clamp(3rem, 7vw, 5.5rem);
}

.product-logo {
  max-width: 360px;
  margin-bottom: 1.25rem;
}

.product-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.25rem 0.7rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(201, 0, 90, 0.22);
  border-radius: 999px;
  color: var(--fnd-navy);
  background: rgba(255, 241, 247, 0.95);
  font-size: 0.9rem;
  font-weight: 800;
}

.product-board {
  border-radius: var(--radius);
  border: 1px solid rgba(0, 43, 95, 0.18);
  background: linear-gradient(150deg, var(--fnd-deep-navy), var(--fnd-navy));
  color: var(--white);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.product-board-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.product-board-head img {
  width: 188px;
  max-height: 72px;
  object-fit: contain;
}

.product-status {
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  color: #ffe6f1;
  background: rgba(237, 43, 123, 0.18);
  font-size: 0.82rem;
  font-weight: 800;
}

.product-board-body {
  display: grid;
  gap: 0.85rem;
  padding: 1rem;
}

.product-chart {
  padding: 1rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
}

.product-chart h2,
.product-mini h3 {
  color: var(--white);
  font-size: 1.1rem;
}

.product-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.product-mini {
  padding: 0.85rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
}

.product-mini p {
  margin: 0;
  color: #e6f0fb;
  font-size: 0.95rem;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
}

.metric {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.metric strong {
  display: block;
  color: var(--fnd-navy);
  font-size: 1.5rem;
  line-height: 1.1;
}

.metric span {
  color: var(--muted);
  font-size: 0.95rem;
}

.product-feature {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.product-feature .icon-dot {
  width: 48px;
  height: 48px;
}

.product-link-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
}

.product-link-card h3,
.product-link-card p {
  color: var(--white);
}

.site-footer {
  background: linear-gradient(135deg, var(--fnd-deep-navy), var(--fnd-navy));
  color: var(--white);
}

.site-footer .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
}

.site-footer h2,
.site-footer h3,
.site-footer p {
  color: var(--white);
}

.site-footer a {
  color: var(--white);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.4rem 1rem;
}

.small {
  color: var(--muted);
  font-size: 0.94rem;
}

.site-footer .small {
  color: #dbe9f8;
}

/* FND Connect Community */
.community-body {
  min-height: 100vh;
  background: linear-gradient(180deg, #f8fbff 0%, #fff7fb 100%);
  color: var(--text);
}

.community-site-header {
  box-shadow: 0 8px 24px rgba(0, 43, 95, 0.07);
}

.community-site-nav {
  gap: 0;
}

.community-site-nav a,
.community-site-nav .nav-logout {
  font-size: 0.86rem;
}

.site-nav form {
  display: inline-flex;
  margin: 0;
}

.nav-logout {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 0.55rem 0.52rem;
  border: 0;
  border-bottom: 4px solid transparent;
  background: transparent;
  color: var(--fnd-magenta);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.nav-logout:hover {
  border-bottom-color: var(--fnd-magenta);
  color: var(--fnd-navy);
}

.community-top {
  position: sticky;
  z-index: 12;
  top: 0;
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem clamp(1rem, 3vw, 2rem);
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 8px 24px rgba(0, 43, 95, 0.08);
}

.community-brand {
  display: inline-flex;
  align-items: center;
}

.community-brand img {
  width: 206px;
  max-height: 64px;
  object-fit: contain;
}

.community-top-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.95rem;
  font-weight: 800;
}

.link-button {
  border: 0;
  padding: 0;
  color: var(--fnd-magenta);
  background: transparent;
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.community-app {
  display: grid;
  grid-template-columns: 230px minmax(0, 720px) 300px;
  gap: 1.15rem;
  width: min(100% - 1.5rem, 1320px);
  margin: 0 auto;
  padding: 1.1rem 0 2rem;
  align-items: start;
}

.community-app.simple {
  grid-template-columns: 230px minmax(0, 890px);
}

.community-sidebar,
.community-rail {
  position: sticky;
  top: 126px;
}

.community-sidebar nav {
  display: grid;
  gap: 0.25rem;
}

.community-sidebar a {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: 0.65rem;
  padding: 0.62rem 0.75rem;
  border-radius: var(--radius);
  color: var(--ink);
  font-size: 0.96rem;
  font-weight: 800;
  text-decoration: none;
}

.community-sidebar a span {
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: var(--pale);
  color: var(--fnd-magenta);
  font-size: 0.78rem;
}

.community-sidebar a:hover,
.community-sidebar a.is-active {
  background: var(--white);
  box-shadow: 0 5px 18px rgba(0, 43, 95, 0.08);
}

.community-sidebar a.is-active {
  color: var(--fnd-magenta);
}

.community-sidebar a.is-active span {
  background: var(--fnd-magenta);
  color: var(--white);
}

.community-main {
  display: grid;
  gap: 1rem;
}

.community-app .community-panel,
.community-rail .community-panel {
  display: block;
  padding: 1.05rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: none;
}

.community-rail {
  display: grid;
  gap: 1rem;
}

.community-rail h2,
.community-app .community-panel h2 {
  margin-bottom: 0.45rem;
  font-size: 1.05rem;
}

.urgent-panel {
  border-left: 8px solid var(--warning) !important;
  background: #fff8cf !important;
}

.community-page-title,
.profile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 24px rgba(0, 43, 95, 0.04);
}

.community-page-title h1,
.profile-header h1 {
  margin-bottom: 0.25rem;
  font-size: clamp(1.6rem, 2.5vw, 2.25rem);
}

.community-page-title p,
.profile-header p {
  margin-bottom: 0;
  color: var(--muted);
}

.community-flash {
  padding: 0.85rem 1rem;
  border-left: 6px solid var(--fnd-magenta);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--pale);
  color: var(--ink);
  font-weight: 700;
}

.community-flash-error {
  border-left-color: #d5281b;
  background: #fde9e7;
}

.composer,
.post-card,
.auth-card,
.settings-form,
.resource-row,
.community-empty,
.admin-review {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 24px rgba(0, 43, 95, 0.04);
}

.composer,
.post-card,
.settings-form,
.community-empty,
.admin-review {
  padding: 1.05rem;
}

.composer {
  display: grid;
  gap: 0.85rem;
}

.composer-head,
.post-card-head,
.profile-header-main,
.comment,
.panel-title-row,
.profile-editor {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.profile-editor {
  align-items: center;
  padding: 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
}

.composer-head p,
.post-card-head p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.avatar {
  display: inline-grid;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--fnd-navy), var(--fnd-magenta) 68%, var(--fnd-rose));
  color: var(--white);
  font-size: 0.92rem;
  font-weight: 900;
  text-decoration: none;
}

.avatar.small {
  width: 34px;
  height: 34px;
  font-size: 0.78rem;
}

.avatar.large {
  width: 80px;
  height: 80px;
  font-size: 1.35rem;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.composer textarea,
.comment-form textarea,
.settings-form textarea,
.auth-card textarea,
.auth-card input,
.auth-card select,
.settings-form input,
.settings-form select,
.composer input,
.composer select,
.report-box input,
.report-box select,
.report-box textarea,
.feed-controls select,
.admin-review input,
.admin-review select,
.admin-review textarea {
  width: 100%;
  min-height: 44px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 0.65rem 0.75rem;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-size: 0.98rem;
}

input[type="file"] {
  padding: 0.45rem;
  background: var(--panel);
}

input[type="file"]::file-selector-button {
  min-height: 36px;
  margin-right: 0.75rem;
  border: 2px solid var(--fnd-magenta);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--fnd-magenta);
  font-weight: 800;
  cursor: pointer;
}

input[type="file"]::file-selector-button:hover {
  border-color: var(--fnd-navy);
  color: var(--fnd-navy);
}

input[type="checkbox"] {
  appearance: none;
  display: inline-grid;
  width: 22px !important;
  height: 22px;
  min-height: 22px !important;
  flex: 0 0 22px;
  place-content: center;
  border: 2px solid var(--fnd-magenta);
  border-radius: 4px;
  padding: 0;
  background: var(--white);
  cursor: pointer;
}

input[type="checkbox"]::before {
  content: "";
  width: 12px;
  height: 12px;
  transform: scale(0);
  transition: transform 0.12s ease-in-out;
  background: var(--fnd-magenta);
  clip-path: polygon(14% 44%, 0 59%, 40% 100%, 100% 18%, 84% 5%, 38% 68%);
}

input[type="checkbox"]:checked::before {
  transform: scale(1);
}

.composer textarea,
.comment-form textarea,
.settings-form textarea,
.report-box textarea,
.admin-review textarea {
  resize: vertical;
}

.composer-grid,
.form-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.form-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

label span {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
}

.composer-alert {
  padding: 0.75rem;
  border-left: 6px solid var(--warning);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: #fff8cf;
  font-weight: 700;
}

.composer-details summary,
.report-box summary {
  padding: 0.55rem 2.4rem 0.55rem 0;
  font-size: 0.95rem;
}

.media-upload-row {
  display: grid;
  gap: 0.35rem;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
}

.media-upload-row p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.composer-details > div {
  padding: 0.5rem 0 0;
}

.composer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.composer-foot p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.feed-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: end;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.feed-controls label {
  min-width: 190px;
}

.feed-stack,
.resource-list,
.admin-list,
.admin-actions-stack {
  display: grid;
  gap: 1rem;
}

.post-card {
  display: grid;
  gap: 0.8rem;
}

.post-card-head h2 {
  margin: 0 0 0.1rem;
  font-size: 1.08rem;
}

.post-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.post-meta-line span,
.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0.2rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: capitalize;
}

.post-body {
  color: var(--ink);
  font-size: 1.03rem;
}

.link-preview {
  display: block;
  padding: 0.75rem;
  border-left: 5px solid var(--fnd-magenta);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--pale);
  word-break: break-word;
  font-weight: 800;
}

.post-image {
  width: 100%;
  max-height: 460px;
  object-fit: cover;
  border-radius: var(--radius);
}

.post-media {
  width: 100%;
  max-height: 520px;
  border-radius: var(--radius);
  background: var(--fnd-deep-navy);
}

.post-stats,
.reaction-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.post-stats {
  color: var(--muted);
  font-size: 0.9rem;
}

.reaction-row {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 0.45rem 0;
}

.reaction-row form {
  margin: 0;
}

.reaction-row button {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 0.35rem;
  border: 0;
  border-radius: var(--radius);
  padding: 0.42rem 0.6rem;
  background: transparent;
  color: var(--fnd-magenta);
  font-weight: 800;
  cursor: pointer;
}

.reaction-row button:hover {
  background: var(--pale);
}

.reaction-row button span {
  color: var(--muted);
}

.comment-list {
  display: grid;
  gap: 0.7rem;
}

.comment {
  align-items: flex-start;
  padding: 0.7rem;
  border-radius: var(--radius);
  background: var(--panel);
}

.comment p {
  margin-bottom: 0;
  font-size: 0.96rem;
}

.comment-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.6rem;
  align-items: end;
}

.report-box {
  font-size: 0.94rem;
}

.report-box form {
  display: grid;
  gap: 0.6rem;
  padding-top: 0.5rem;
}

.report-box.inline {
  min-width: 240px;
}

.compact-list {
  display: grid;
  gap: 0.55rem;
}

.compact-list a {
  font-weight: 800;
}

.community-landing-hero {
  border-bottom: 1px solid var(--border);
  background: linear-gradient(110deg, #f8fbff 0%, #ffffff 56%, #fff1f7 100%);
}

.community-landing-hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.75fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  min-height: 580px;
  padding-top: clamp(3rem, 7vw, 5.5rem);
  padding-bottom: clamp(3rem, 7vw, 5.5rem);
}

.community-landing-hero p {
  max-width: 760px;
  color: var(--text);
  font-size: clamp(1.08rem, 1.8vw, 1.28rem);
}

.community-preview-panel {
  display: grid;
  gap: 1rem;
}

.preview-post {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.preview-post div {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.preview-post span {
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  background: var(--pale);
  color: var(--fnd-navy);
  font-size: 0.82rem;
  font-weight: 800;
}

.community-page-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.community-page-card {
  display: grid;
  gap: 0.7rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.community-page-card h2,
.community-page-card h3 {
  margin-bottom: 0;
  font-size: 1.2rem;
}

.profile-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.65rem;
}

.profile-bio {
  font-size: 1.02rem;
}

.resource-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 1rem;
}

.resource-row h2 {
  margin-bottom: 0.3rem;
  font-size: 1.2rem;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.75rem;
}

.admin-stats article {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.admin-stats strong {
  display: block;
  color: var(--fnd-navy);
  font-size: 1.8rem;
  line-height: 1;
}

.admin-stats span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.panel-title-row {
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.admin-item {
  padding: 0.75rem 0;
  border-top: 1px solid var(--border);
}

.admin-item p,
.admin-review p,
.community-empty p {
  margin-bottom: 0.35rem;
}

.admin-review {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.45fr);
  gap: 1rem;
}

.admin-review.compact {
  grid-template-columns: minmax(0, 1fr) 240px;
}

.admin-review form {
  display: grid;
  gap: 0.55rem;
  align-content: start;
}

blockquote {
  margin: 0.7rem 0;
  padding: 0.65rem 0.85rem;
  border-left: 5px solid var(--fnd-magenta);
  background: var(--pale);
}

.auth-page {
  background: var(--panel);
}

.auth-card {
  width: min(100% - 2rem, 520px);
  margin: 0 auto;
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

.auth-card h1 {
  font-size: clamp(2.15rem, 5vw, 3.15rem);
}

.auth-card.wide {
  width: min(100% - 2rem, 860px);
}

.auth-card form,
.settings-form {
  display: grid;
  gap: 0.85rem;
}

.auth-alt {
  margin-top: 0.85rem;
}

.consent-list {
  display: grid;
  gap: 0.65rem;
  padding: 0.95rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
}

.consent-list label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.55rem;
  align-items: start;
  line-height: 1.45;
}

.consent-list label > span {
  margin: 0;
  color: var(--text);
  font-size: 1rem;
  font-weight: 400;
}

.consent-list input {
  margin-top: 0.15rem;
}

.back-link {
  font-weight: 800;
}

@media (max-width: 1040px) {
  .nav-row {
    min-height: 76px;
  }

  .brand img {
    width: 212px;
  }

  .nav-toggle {
    display: inline-grid;
    place-items: center;
  }

  .site-nav {
    position: absolute;
    inset: 100% 0 auto 0;
    display: none;
    padding: 0.75rem 1rem 1rem;
    border-bottom: 1px solid var(--border);
    background: var(--white);
    box-shadow: 0 20px 30px rgba(0, 43, 95, 0.12);
  }

  .site-nav.is-open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.2rem 0.7rem;
  }

  .site-nav a {
    border-bottom-width: 0;
    border-left: 4px solid transparent;
    padding-left: 0.8rem;
  }

  .site-nav form,
  .nav-logout {
    width: 100%;
  }

  .nav-logout {
    justify-content: flex-start;
    border-bottom-width: 0;
    border-left: 4px solid transparent;
    padding-left: 0.8rem;
  }

  .site-nav a[aria-current="page"],
  .site-nav a:hover,
  .nav-logout:hover {
    border-left-color: var(--fnd-magenta);
  }

  .community-app,
  .community-app.simple {
    grid-template-columns: 190px minmax(0, 1fr);
  }

  .community-rail {
    display: none;
  }

  .admin-grid,
  .admin-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .hero .wrap,
  .product-hero .wrap,
  .content,
  .community-panel,
  .site-footer .wrap {
    grid-template-columns: 1fr;
  }

  .hero .wrap {
    min-height: auto;
  }

  .grid.two,
  .grid.three,
  .grid.four {
    grid-template-columns: 1fr;
  }

  .toc {
    position: static;
  }

  .site-footer .wrap {
    gap: 1rem;
  }

  .community-landing-hero .wrap,
  .community-page-grid,
  .admin-review,
  .admin-review.compact {
    grid-template-columns: 1fr;
  }

  .community-app,
  .community-app.simple {
    width: min(100% - 1rem, 760px);
    grid-template-columns: 1fr;
  }

  .community-sidebar {
    position: static;
  }

  .community-sidebar nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .community-sidebar a {
    justify-content: center;
  }

  .community-sidebar a span {
    display: none;
  }

  .community-site-header {
    position: static;
  }

  .composer-grid,
  .form-grid.two {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  body {
    font-size: 17px;
  }

  .wrap {
    width: min(100% - 1.25rem, var(--max));
  }

  .topbar .wrap {
    display: block;
  }

  .topbar span {
    display: block;
  }

  .brand img {
    width: 176px;
  }

  .site-nav.is-open {
    grid-template-columns: 1fr;
  }

  .hero-actions,
  .button-row {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .fact-row {
    grid-template-columns: 1fr;
  }

  .footer-links {
    grid-template-columns: 1fr;
  }

  .product-mini-grid,
  .metric-strip,
  .product-link-card {
    grid-template-columns: 1fr;
  }

  .product-board-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .community-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .community-top-actions {
    width: 100%;
    justify-content: space-between;
    font-size: 0.88rem;
  }

  .community-brand img {
    width: 172px;
  }

  .community-sidebar nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .community-page-title,
  .profile-header,
  .resource-row,
  .composer-foot,
  .comment-form {
    align-items: stretch;
    flex-direction: column;
    grid-template-columns: 1fr;
  }

  .profile-header-main {
    align-items: center;
  }

  .admin-stats {
    grid-template-columns: 1fr;
  }

  .reaction-row button {
    font-size: 0.9rem;
  }
}
