/*
Theme Name: Unshackle CIC
Theme URI: https://unshackle.org.uk/
Author: Unshackle CIC
Description: Functional WordPress theme for prison leaver support, parole evidence and official-source updates.
Version: 1.0.0
Text Domain: unshackle
*/

:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root {
  --ink: #10231f;
  --muted: #5b6761;
  --line: #d8dfdc;
  --panel: #f4f7f4;
  --paper: #fffdf7;
  --green: #17624f;
  --green-dark: #0f4639;
  --gold: #bd8b2f;
  --rust: #a24b37;
  --blue: #244f78;
  --white: #ffffff;
  --shadow: 0 22px 60px rgba(16, 35, 31, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

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

.article-shell,
.support-page {
  width: min(900px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(64px, 9vw, 120px) 0;
}

.article-shell h1,
.support-page h1 {
  margin: 0;
  max-width: 850px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.02;
  letter-spacing: 0;
}

.article-meta {
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  padding-bottom: 22px;
}

.article-content {
  max-width: 760px;
  margin: 36px 0;
  font-size: 18px;
}

.hero-copy-dark {
  max-width: 720px;
  color: var(--muted);
  font-size: 20px;
}

.support-page .impact-grid {
  margin: 48px 0;
}

.pagination {
  margin-top: 36px;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(150px, auto) 1fr auto;
  gap: 24px;
  align-items: center;
  padding: 14px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid rgba(16, 35, 31, 0.12);
  background: rgba(255, 253, 247, 0.94);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  color: var(--white);
  background: var(--green);
  font-weight: 800;
}

.brand-logo {
  display: block;
  width: 58px;
  height: 58px;
  object-fit: contain;
  border-radius: 8px;
  background: var(--white);
}

.brand-logo-wide {
  width: clamp(170px, 18vw, 250px);
  height: 66px;
  object-fit: contain;
  object-position: left center;
  background: transparent;
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  color: var(--muted);
  font-size: 12px;
}

.nav {
  display: flex;
  gap: 22px;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
}

.nav a,
.header-cta,
.text-link {
  text-decoration: none;
}

.nav a:hover,
.text-link:hover {
  color: var(--green);
}

.header-cta {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 800;
}

.header-cta.donate-link {
  color: var(--white);
  border-color: var(--green);
  background: var(--green);
}

.hero {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(16, 35, 31, 0.98) 0%, rgba(16, 35, 31, 0.9) 44%, rgba(16, 35, 31, 0.5) 100%),
    linear-gradient(135deg, #0d241f 0%, #1d4038 52%, #846d3e 100%);
  color: var(--white);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(760px, calc(100% - 36px));
  padding: clamp(72px, 11vw, 150px) 0 48px clamp(18px, 7vw, 88px);
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(44px, 7vw, 82px);
  line-height: 0.96;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 660px;
  margin: 26px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(18px, 2vw, 22px);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  color: var(--white);
  background: var(--green);
}

.hero .button.primary {
  background: var(--gold);
  color: #17211d;
}

.button.secondary {
  border-color: rgba(255, 255, 255, 0.36);
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: min(720px, 100%);
  margin: 54px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
}

.trust-strip div {
  padding: 16px 18px 16px 0;
}

.trust-strip dt {
  font-size: 24px;
  font-weight: 900;
}

.trust-strip dd {
  margin: 2px 0 0;
  color: rgba(255, 255, 255, 0.72);
}

.hero-art {
  position: absolute;
  inset: 0;
}

.release-mark {
  position: absolute;
  right: clamp(24px, 8vw, 130px);
  top: clamp(110px, 16vw, 170px);
  width: clamp(270px, 34vw, 540px);
  height: clamp(270px, 34vw, 540px);
}

.chain-link {
  position: absolute;
  top: 34%;
  width: 44%;
  height: 25%;
  border: clamp(14px, 2vw, 26px) solid rgba(255, 253, 247, 0.9);
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(16, 35, 31, 0.24),
    0 26px 70px rgba(0, 0, 0, 0.32);
}

.link-left {
  left: 4%;
  transform: rotate(-27deg);
}

.link-right {
  right: 4%;
  transform: rotate(27deg);
  border-color: rgba(189, 139, 47, 0.88);
}

.chain-gap {
  position: absolute;
  left: 43%;
  top: 43%;
  width: 14%;
  height: 16%;
  transform: rotate(-8deg);
  background: linear-gradient(135deg, transparent 0 40%, rgba(255, 253, 247, 0.96) 40% 58%, transparent 58%);
}

.release-path {
  position: absolute;
  right: -90px;
  bottom: 28px;
  width: min(62vw, 820px);
  height: 320px;
  opacity: 0.5;
}

.release-path span {
  position: absolute;
  right: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 253, 247, 0.7), transparent);
  transform: rotate(-16deg);
}

.release-path span:nth-child(1) {
  top: 68px;
}

.release-path span:nth-child(2) {
  top: 150px;
  width: 86%;
}

.release-path span:nth-child(3) {
  top: 232px;
  width: 72%;
}

.quick-route {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.quick-route a {
  min-height: 120px;
  padding: 24px clamp(18px, 4vw, 46px);
  border-right: 1px solid var(--line);
  text-decoration: none;
}

.quick-route span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.quick-route strong {
  display: block;
  margin-top: 8px;
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.12;
}

.section {
  padding: clamp(58px, 8vw, 110px) clamp(18px, 6vw, 88px);
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(32px, 6vw, 90px);
  align-items: start;
}

h2 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1;
  letter-spacing: 0;
}

.blog-title {
  max-width: 920px;
  margin: 0 0 22px;
  font-size: clamp(42px, 6vw, 70px);
  line-height: 0.98;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 10px;
  font-size: 21px;
  line-height: 1.2;
}

p {
  color: var(--muted);
  font-size: 17px;
}

.service-list {
  display: grid;
  gap: 14px;
}

.service-list article,
.impact-grid article,
.post-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.service-list article {
  padding: 24px;
}

.service-list p,
.impact-grid p,
.post-card p {
  margin-bottom: 0;
}

.parole-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.74fr);
  gap: 32px;
  align-items: center;
  background: var(--ink);
  color: var(--white);
}

.parole-band p {
  color: rgba(255, 255, 255, 0.76);
}

.evidence-panel {
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
}

.evidence-panel ul {
  display: grid;
  gap: 12px;
  margin: 18px 0;
  padding-left: 20px;
}

.small-note {
  font-size: 13px;
}

.section-head {
  display: flex;
  gap: 24px;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 26px;
}

.text-link {
  color: var(--green);
  font-weight: 900;
}

.blog-tools {
  display: grid;
  grid-template-columns: minmax(220px, 420px) 1fr;
  gap: 16px;
  align-items: center;
  margin-bottom: 24px;
}

.search-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cbd4cf;
  border-radius: 8px;
  padding: 13px 14px;
  color: var(--ink);
  background: var(--white);
  font: inherit;
}

.topic-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 13px;
  color: var(--ink);
  background: var(--white);
  font-weight: 800;
  cursor: pointer;
}

.chip.active {
  color: var(--white);
  border-color: var(--green);
  background: var(--green);
}

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

.post-card {
  display: flex;
  min-height: 260px;
  flex-direction: column;
  padding: 22px;
}

.post-card .tag {
  width: fit-content;
  margin-bottom: 18px;
  border-radius: 999px;
  padding: 6px 10px;
  color: var(--green-dark);
  background: #dcefe7;
  font-size: 12px;
  font-weight: 900;
}

.post-card time {
  margin-top: auto;
  padding-top: 22px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.article-page {
  max-width: 920px;
}

.article-page h2 {
  margin-top: 40px;
  font-size: clamp(26px, 3.4vw, 38px);
}

.article-page li {
  margin: 10px 0;
  color: var(--muted);
  font-size: 17px;
}

.article-meta {
  color: var(--green-dark);
  font-weight: 800;
}

.readable-plan blockquote {
  margin: 24px 0;
  border-left: 5px solid var(--green);
  padding: 18px 22px;
  border-radius: 0 8px 8px 0;
  color: var(--ink);
  background: #eef5f1;
  font-size: 18px;
}

.readable-plan ol {
  padding-left: 22px;
}

.review-hero {
  padding-bottom: 28px;
}

.review-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
  gap: clamp(28px, 6vw, 82px);
  padding-top: 36px;
}

.draft-list {
  display: grid;
  gap: 14px;
}

.draft-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: var(--white);
}

.draft-card[data-status="approved"] {
  border-color: #8fc6a9;
  background: #f1faf5;
}

.draft-card[data-status="rejected"] {
  border-color: #d5a49a;
  background: #fff4f1;
}

.draft-actions {
  display: grid;
  gap: 10px;
  min-width: 130px;
}

.draft-status {
  color: var(--green-dark);
  text-transform: capitalize;
}

.button.reject {
  color: var(--ink);
  border-color: var(--line);
  background: var(--white);
}

.impact-section {
  background: #eef2ef;
}

.impact-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 30px;
}

.impact-grid article {
  padding: 22px;
}

.donation-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 32px 0;
}

.donation-grid article {
  display: grid;
  gap: 14px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  background: var(--white);
}

.donation-grid h2 {
  font-size: clamp(24px, 3vw, 34px);
}

.donation-grid .button {
  width: fit-content;
}

.support-callout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  background: #fff8e8;
}

.quiet {
  background: var(--white);
}

.referral {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
  gap: clamp(28px, 6vw, 82px);
}

.referral-form {
  display: grid;
  gap: 16px;
}

.referral-form label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-weight: 800;
}

.referral-form .button {
  width: fit-content;
}

.site-footer {
  display: flex;
  gap: 24px;
  justify-content: space-between;
  padding: 34px clamp(18px, 6vw, 88px);
  color: var(--white);
  background: var(--ink);
}

.site-footer p {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.7);
}

address {
  display: grid;
  gap: 6px;
  font-style: normal;
}

@media (max-width: 940px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .nav {
    grid-column: 1 / -1;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .hero {
    min-height: 720px;
  }

  .release-mark {
    top: auto;
    right: -70px;
    bottom: 70px;
    opacity: 0.38;
  }

  .release-path {
    right: -170px;
    bottom: -24px;
    width: 760px;
    opacity: 0.34;
  }

  .quick-route,
  .two-column,
  .parole-band,
  .blog-tools,
  .referral,
  .review-layout,
  .draft-card,
  .support-callout,
  .donation-grid,
  .post-grid,
  .impact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .site-header {
    gap: 12px;
  }

  .brand small,
  .header-cta {
    display: none;
  }

  .brand-logo {
    width: 52px;
    height: 52px;
  }

  .brand-logo-wide {
    width: 150px;
    height: 52px;
  }

  .hero-inner {
    padding-top: 44px;
    padding-bottom: 28px;
  }

  .hero {
    min-height: 620px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero-copy {
    font-size: 17px;
  }

  .hero-actions {
    margin-top: 24px;
  }

  .trust-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 34px;
  }

  .trust-strip div {
    padding: 10px 8px 10px 0;
  }

  .trust-strip dt {
    font-size: 18px;
  }

  .trust-strip dd {
    font-size: 12px;
  }

  .quick-route a {
    min-height: 96px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .section-head,
  .site-footer {
    display: grid;
  }
}
