:root {
  --ink: #0e1a24;
  --ink-soft: #3a4a58;
  --paper: #f3f6f4;
  --paper-2: #e7eee9;
  --surface: #ffffff;
  --line: rgba(14, 26, 36, 0.12);
  --green: #149817;
  --green-deep: #0d6b12;
  --blue: #1b6be3;
  --slate: #5a646c;
  --amber: #d97706;
  --brand: #0f3d2e;
  --accent: #1faa4a;
  --shadow: 0 18px 40px rgba(14, 26, 36, 0.08);
  --radius: 18px;
  --font: "Manrope", system-ui, sans-serif;
  --display: "Righteous", "Manrope", sans-serif;
  --max: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(31, 170, 74, 0.16), transparent 60%),
    radial-gradient(900px 420px at 100% 0%, rgba(27, 107, 227, 0.12), transparent 55%),
    linear-gradient(180deg, #f7faf8 0%, var(--paper) 40%, #eef3f0 100%);
  min-height: 100vh;
  line-height: 1.55;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--blue);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--green-deep);
}

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

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(247, 250, 248, 0.88);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.25rem;
}

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

.brand__logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 10px;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(15, 61, 46, 0.18);
}

.brand__name {
  font-family: var(--display);
  font-size: 1.55rem;
  letter-spacing: 0.02em;
  color: var(--brand);
}

.nav-desktop {
  display: none;
  gap: 0.35rem 1.15rem;
  align-items: center;
}

.nav-desktop a,
.nav-mobile a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

.nav-desktop a[aria-current="page"],
.nav-desktop a:hover,
.nav-mobile a:hover {
  color: var(--brand);
}

.menu-toggle {
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 1.05rem;
  height: 2px;
  background: var(--ink);
}

.nav-mobile {
  display: grid;
  gap: 0.85rem;
  padding-bottom: 1rem;
}

.nav-mobile[hidden] {
  display: none;
}

@media (min-width: 900px) {
  .nav-desktop {
    display: flex;
  }
  .menu-toggle,
  .nav-mobile {
    display: none !important;
  }
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 3.5rem 0 2.5rem;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 8% 5% auto auto;
  width: min(46vw, 420px);
  height: min(46vw, 420px);
  border-radius: 40% 60% 55% 45%;
  background: linear-gradient(145deg, rgba(20, 152, 23, 0.22), rgba(27, 107, 227, 0.12));
  filter: blur(2px);
  animation: drift 12s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes drift {
  from { transform: translate(0, 0) rotate(0deg); }
  to { transform: translate(-18px, 24px) rotate(8deg); }
}

.hero__inner {
  position: relative;
  max-width: 40rem;
}

.hero__brand {
  margin: 0 0 0.75rem;
  font-family: var(--display);
  font-size: clamp(2.4rem, 7vw, 4rem);
  line-height: 1;
  color: var(--brand);
  letter-spacing: 0.02em;
  animation: rise 0.7s ease both;
}

.hero__title {
  margin: 0 0 0.85rem;
  font-size: clamp(1.55rem, 3.4vw, 2.15rem);
  line-height: 1.2;
  font-weight: 800;
  animation: rise 0.7s ease 0.08s both;
}

.hero__lead {
  margin: 0 0 1.5rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
  max-width: 34rem;
  animation: rise 0.7s ease 0.16s both;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  animation: rise 0.7s ease 0.24s both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.btn--primary {
  background: linear-gradient(180deg, #1fbf4f, var(--green));
  color: #fff;
  box-shadow: 0 10px 24px rgba(20, 152, 23, 0.28);
}

.btn--primary:hover {
  color: #fff;
  filter: brightness(1.05);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.72);
  border-color: var(--line);
  color: var(--ink);
}

.btn--ghost:hover {
  color: var(--brand);
  border-color: rgba(15, 61, 46, 0.35);
}

/* Hub tiles */
.section {
  padding: 1.5rem 0 3rem;
}

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

@media (min-width: 720px) {
  .hub-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.hub-tile {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1.35rem 1.4rem;
  border-radius: var(--radius);
  text-decoration: none;
  color: #fff;
  min-height: 8.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, filter 0.2s ease;
}

.hub-tile:hover {
  transform: translateY(-3px);
  color: #fff;
  filter: brightness(1.04);
}

.hub-tile__title {
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.hub-tile__text {
  opacity: 0.95;
  font-size: 0.98rem;
}

.hub-tile--green { background: linear-gradient(135deg, #149817, #0f6f14); }
.hub-tile--blue { background: linear-gradient(135deg, #1b6be3, #124fad); }
.hub-tile--slate { background: linear-gradient(135deg, #6a737a, #4a535a); }
.hub-tile--amber { background: linear-gradient(135deg, #f0a202, #c77700); }

/* Page head */
.page-head {
  margin-bottom: 1.75rem;
  max-width: 46rem;
}

.page-head h1 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.25;
}

.lead,
.page-head__sub {
  margin: 0;
  color: var(--ink-soft);
}

.page-head__sub {
  margin-top: 0.5rem;
  font-weight: 700;
  color: var(--brand);
}

.page-foot {
  margin-top: 2rem;
}

.page-updated {
  padding-bottom: 2rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.crumbs {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

/* Offers */
.offer-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 720px) {
  .offer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .offer-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.offer-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.offer-card__body {
  padding: 1rem 1.05rem 1.15rem;
  font-size: 0.92rem;
}

.offer-card__body table {
  width: 100%;
  border-collapse: collapse;
}

.offer-card__body img {
  max-height: 48px;
  width: auto;
}

.offer-card__body .btn,
.offer-card__body a.btn,
.offer-card__body .push-app a,
.offer-card__body a[href*="/product/"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.5rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  background: linear-gradient(180deg, #1fbf4f, var(--green));
  color: #fff !important;
  text-decoration: none;
  font-weight: 700;
  border: 0;
}

/* Legacy TinyMCE helpers inside cards */
.offer-card__body .push-app,
.offer-card__body .artstyle {
  margin-top: 0.35rem;
}

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

.wiki-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem 1.15rem;
  box-shadow: var(--shadow);
}

.wiki-card__title {
  margin: 0;
  font-size: 1.1rem;
}

.wiki-card__title a {
  color: var(--ink);
  text-decoration: none;
}

.wiki-card__title a:hover {
  color: var(--green-deep);
}

/* Prose */
.prose {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem 1.6rem;
  box-shadow: var(--shadow);
}

.prose h1 {
  margin-top: 0;
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1.25rem 0;
}

/* Calculator */
.calc-form {
  display: grid;
  gap: 1rem;
  max-width: 28rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}

.calc-form__field {
  display: grid;
  gap: 0.35rem;
}

.calc-form__field span,
.calc-form__field legend {
  font-weight: 700;
  font-size: 0.92rem;
}

.calc-form input[type="text"],
.calc-form select {
  width: 100%;
  min-height: 2.6rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.45rem 0.7rem;
  font: inherit;
  background: #fff;
}

.calc-form__radio {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-right: 1rem;
  font-weight: 500;
}

.calc-form fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

.calc-form small {
  color: var(--ink-soft);
}

.table-wrap {
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.credit-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.credit-table th,
.credit-table td {
  padding: 0.55rem 0.7rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

.credit-table th {
  background: var(--paper-2);
}

.credit-table__total td {
  background: #f0f7f2;
}

/* Footer */
.site-footer {
  margin-top: 2rem;
  padding: 2.5rem 0 1.5rem;
  background: linear-gradient(180deg, rgba(15, 61, 46, 0.94), #0a2a20);
  color: rgba(255, 255, 255, 0.88);
}

.site-footer a {
  color: #d7f5e2;
  text-decoration: none;
}

.site-footer a:hover {
  color: #fff;
}

.footer-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 800px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}

.footer-brand {
  font-family: var(--display);
  font-size: 1.6rem;
  margin-bottom: 0.5rem;
}

.footer-note {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.92rem;
}

.site-footer h3 {
  margin: 0 0 0.7rem;
  font-size: 1rem;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.65);
}

/* Badge leftover from old content */
.badge.bg-success {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  font-size: 0.85em;
  font-weight: 700;
}
