:root {
  --color-primary: #0B1220;
  --color-secondary: #10B981;
  --color-accent: #F59E0B;
  --color-background: #F6F7FB;
  --color-surface: #FFFFFF;
  --color-text-primary: #0F172A;
  --color-text-secondary: #475569;
  --color-border: #E6EAF2;
  --font-heading: "ui-serif", Georgia, "Times New Roman", Times, serif;
  --font-body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  background: radial-gradient(circle at top, rgba(16, 185, 129, 0.18), transparent 45%), var(--color-background);
  color: var(--color-text-primary);
  min-height: 100vh;
}

main {
  overflow: visible;
}

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

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

a:hover {
  color: var(--color-secondary);
}

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

.container {
  width: min(1200px, 100% - 2.5rem);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.section {
  background: var(--color-surface);
  padding: 4rem 0;
  border-bottom: 1px solid var(--color-border);
  position: relative;
}

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

.section-card {
  border-radius: 26px;
  border: 1px solid var(--color-border);
  padding: 2rem;
  background: #fff;
  box-shadow: 0 20px 40px rgba(11, 18, 32, 0.08);
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  align-items: center;
}

.about-grid.reverse {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.about-grid .about-text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  z-index: 1;
}

.process-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.process-item {
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 1rem 1.25rem;
  background: #F6F7FB;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.process-item h3 {
  font-size: 1.05rem;
}
.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.topic-card {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.topic-card h3 {
  font-size: 20px;
}

.band-cta {
  background: var(--color-secondary);
  color: #fff;
}

.section-label {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.75rem;
  color: var(--color-secondary);
}

.section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.section-line {
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-heading);
  color: var(--color-primary);
  margin-bottom: 1rem;
}

h1 {
  font-size: 44px;
  line-height: 1.2;
}

h2 {
  font-size: 32px;
}

h3 {
  font-size: 24px;
}

p {
  color: var(--color-text-secondary);
}

.hero {
  position: relative;
  padding: 3rem 0 2rem;
}

.hero-inner {
  display: grid;
  gap: 2rem;
  align-items: start;
}

.page-home .hero-inner {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.hero-panel {
  background: #0B1220;
  color: #fff;
  border-radius: 26px;
  padding: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: grid;
  gap: 1.25rem;
  max-width: 460px;
  margin-left: auto;
}

.hero-panel .media {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.hero-panel .quick-title {
  color: rgba(255, 255, 255, 0.85);
}

.hero-panel .media {
  margin-bottom: 0;
}

.quick-tools {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.quick-title {
  font-weight: 600;
  letter-spacing: 0.2em;
}

.quick-link {
  display: block;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  text-decoration: none;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

.btn {
  padding: 0.95rem 1.8rem;
  border-radius: 999px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn.primary {
  background: var(--color-secondary);
  color: #0B1220;
  box-shadow: 0 10px 20px rgba(16, 185, 129, 0.35);
}

.btn.primary:hover {
  transform: translateY(-2px);
}

.btn.ghost {
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-primary);
}

.featured-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 1.5rem;
}

.featured-card {
  background: var(--color-surface);
  border-radius: 24px;
  border: 1px solid var(--color-border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.featured-card .card-body,
.featured-card .media {
  padding: 1rem 1.5rem;
}

.featured-card.large {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.featured-smalls {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.link-button {
  margin-top: auto;
  color: var(--color-secondary);
  font-weight: 600;
  text-decoration: none;
}

.basic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.basic-card {
  background: var(--color-surface);
  border-radius: 20px;
  border: 1px solid var(--color-border);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.checklist-list {
  list-style: none;
  margin-top: 1.5rem;
  display: grid;
  gap: 1rem;
}

.checklist-list li {
  border: 1px solid var(--color-border);
  border-radius: 20px;
  padding: 1rem;
  background: var(--color-surface);
}

.check-toggle {
  width: 100%;
  background: transparent;
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  padding: 0;
}

.check-toggle .checkmark {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
}

.check-toggle.active .checkmark {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
}

.checklist-list p {
  margin-top: 0.75rem;
  color: var(--color-text-secondary);
}

.cta-band {
  border-radius: 28px;
  padding: 2.75rem 2rem;
}

.cta-band .btn {
  background: #fff;
  color: var(--color-primary);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: rgba(255, 255, 255, 0.85);
  border-bottom: 1px solid rgba(14, 23, 42, 0.1);
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 40px rgba(11, 18, 32, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  width: min(1200px, 100% - 2rem);
  margin: 0 auto;
}

.logo {
  font-family: var(--font-heading);
  letter-spacing: 0.1em;
  color: var(--color-primary);
  text-decoration: none;
}

.primary-nav {
  display: flex;
  gap: 1.25rem;
  font-weight: 600;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.menu-toggle {
  display: none;
  border: none;
  background: transparent;
  flex-direction: column;
  gap: 6px;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-primary);
}

.mobile-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-surface);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  border-bottom: 1px solid var(--color-border);
}

.mobile-menu.is-open {
  max-height: 260px;
}

.mobile-menu ul {
  list-style: none;
  padding: 1rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mobile-menu a {
  text-decoration: none;
  color: var(--color-primary);
  font-weight: 600;
}

.mobile-menu-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 950;
  pointer-events: none;
}

body.menu-open {
  overflow: hidden;
}

body.menu-open .mobile-menu-backdrop {
  display: block;
  background: rgba(11, 18, 32, 0.4);
  pointer-events: auto;
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.media {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  border-radius: 18px;
  background: #E9EEF5;
}

.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.site-footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

.footer-inner {
  padding: 2rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-items: center;
  text-align: center;
}

.footer-inner .footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.support-copy a {
  color: var(--color-secondary);
}

.guide-toolbar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.guide-sections {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  position: relative;
  z-index: 2;
}

.guide-section {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  padding: 2rem;
  border-radius: 26px;
  background: #fff;
  border: 1px solid var(--color-border);
  box-shadow: 0 20px 40px rgba(11, 18, 32, 0.08);
  position: relative;
  z-index: 3;
}

.guide-toolbar input {
  padding: 1rem;
  border-radius: 16px;
  border: 1px solid var(--color-border);
  background: transparent;
}

.guide-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip {
  border-radius: 999px;
  border: 1px solid var(--color-border);
  padding: 0.5rem 1rem;
  background: #fff;
  cursor: pointer;
  transition: background 0.3s ease;
}

.chip.active {
  background: var(--color-secondary);
  color: #fff;
  border-color: var(--color-secondary);
}

.guides-layout {
  padding: 2rem 0;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 26px;
  border: 1px solid var(--color-border);
  box-shadow: 0 20px 40px rgba(11, 18, 32, 0.08);
  position: relative;
  z-index: 2;
}

.guides-layout .container {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 2rem;
}

.on-page-nav {
  border: 1px solid var(--color-border);
  border-radius: 18px;
  padding: 1rem;
  background: var(--color-surface);
}

.on-page-nav nav {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.on-page-nav a {
  text-decoration: none;
  color: var(--color-text-primary);
}

.guide-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  position: relative;
  z-index: 2;
}

.guide-card {
  border: 1px solid var(--color-border);
  border-radius: 20px;
  background: var(--color-surface);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.guide-card .guide-content {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.read-more {
  align-self: flex-start;
  border: 0;
  background: transparent;
  color: var(--color-secondary);
  font-weight: 600;
  cursor: pointer;
}

.guide-details {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.4s ease;
}

.guide-card.active .guide-details {
  max-height: 500px;
  opacity: 1;
}

.guide-details ul {
  list-style: disc;
  margin-left: 1rem;
  color: var(--color-text-secondary);
}

.guide-details h4 {
  margin-bottom: 0.5rem;
}

.calc-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.tool-card {
  border: 1px solid var(--color-border);
  border-radius: 24px;
  background: var(--color-surface);
  padding: 1.5rem;
  display: grid;
  gap: 1rem;
}

.tool-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.tool-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.tool-form label {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-weight: 600;
}

.tool-form input,
.tool-form textarea,
.tool-form select {
  border-radius: 16px;
  border: 1px solid var(--color-border);
  padding: 0.85rem 1rem;
  background: #fff;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
}

.tool-form button {
  border-radius: 999px;
  border: none;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
}

.tool-form button[type="submit"] {
  background: var(--color-primary);
  color: #fff;
}

.tool-form .calc-reset {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid var(--color-border);
}

.form-error {
  min-height: 1.2rem;
  color: var(--color-accent);
  font-size: 0.9rem;
}

.tool-result {
  border-top: 1px solid var(--color-border);
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.contact-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.section-card.contact-card .contact-layout {
  gap: 2.5rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.5rem;
  border: 1px solid var(--color-border);
  border-radius: 20px;
  background: var(--color-surface);
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  border-radius: 12px;
  border: 1px solid var(--color-border);
  padding: 0.8rem 1rem;
}

.contact-form button[type="submit"] {
  border-radius: 999px;
  border: none;
  padding: 0.9rem 1.5rem;
  background: var(--color-primary);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.contact-info {
  padding: 1.5rem;
  border-radius: 20px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
}

.contact-success {
  min-height: 1.6rem;
  color: var(--color-secondary);
  font-weight: 600;
}

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

@media (max-width: 1024px) {
  .featured-grid {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    grid-template-columns: 1fr;
  }

}

@media (max-width: 768px) {
  .hero {
    padding-top: 0;
  }

  .primary-nav {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .guides-layout {
    grid-template-columns: 1fr;
  }

  .on-page-nav {
    position: static;
    order: 2;
  }
}

@media (min-width: 768px) {
  .on-page-nav {
    position: sticky;
    top: 110px;
    align-self: flex-start;
  }

  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    text-align: left;
  }

  .footer-inner .footer-links {
    justify-content: flex-end;
  }
}

@media (max-width: 640px) {
  h1 {
    font-size: 34px;
  }

  .hero-ctas {
    flex-direction: column;
  }

  .cta-band {
    text-align: center;
  }
}

@media (min-width: 1280px) {
  h1 {
    font-size: clamp(44px, 3vw, 56px);
  }
}
