@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600&display=swap");

:root {
  color-scheme: light;
  --paper: #f7f6f3;
  --surface: #f1efe9;
  --paper-alpha: rgba(247, 246, 243, 0.78);
  --surface-alpha: rgba(241, 239, 233, 0.82);
  --ink: #1e1b17;
  --muted: #4f4a43;
  --line: #ddd5c8;
  --accent: #b2262d;
  --accent-dark: #8f1d23;
  --footer: #8b171c;
  --footer-ink: #fdf5ee;
  --scroll-shift: 0px;
  --size-base: clamp(1rem, 0.8vw + 0.85rem, 1.125rem);
  --size-md: clamp(1.35rem, 1.6vw + 0.95rem, 1.9rem);
  --size-lg: clamp(2.25rem, 2.6vw + 1.2rem, 4rem);
}

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

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  padding: 0;
  background: #f7f4ee;
  color: var(--ink);
  font-family: "Manrope", "Inter", "SF Pro Display", "SF Pro Text", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: var(--size-base);
  line-height: 1.75;
  letter-spacing: 0.01em;
  text-rendering: optimizeLegibility;
  position: relative;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 0.55 0 0 0 0 0.64 0 0 0 0 0.82 0 0 0 0.35 0'/></filter><rect width='120' height='120' filter='url(%23n)' opacity='0.5'/></svg>");
  opacity: 0.08;
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: "";
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 42vw;
  background-image: radial-gradient(120% 140% at 100% calc(0% + var(--scroll-shift)), rgba(74, 120, 198, 0.55) 0%, rgba(74, 120, 198, 0) 72%),
    radial-gradient(120% 160% at 100% calc(50% + var(--scroll-shift)), rgba(92, 170, 199, 0.45) 0%, rgba(92, 170, 199, 0) 76%),
    radial-gradient(120% 160% at 100% calc(100% + var(--scroll-shift)), rgba(72, 160, 210, 0.38) 0%, rgba(72, 160, 210, 0) 78%);
  opacity: 0.55;
  pointer-events: none;
  z-index: 25;
}

.site-header,
main,
.site-footer,
.fab-cta {
  position: relative;
  z-index: 2;
}

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

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

h1,
h2 {
  line-height: 1.15;
  letter-spacing: 0.004em;
  margin: 0 0 1.4rem;
  font-weight: 600;
  text-wrap: balance;
}

h1 {
  font-size: var(--size-lg);
  position: relative;
}

h2 {
  font-size: var(--size-md);
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}

h1::after {
  content: "";
  display: block;
  width: 3.6rem;
  height: 2px;
  margin-top: 1.4rem;
  background: var(--accent);
}

h2::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  background: var(--accent);
  transform: translateY(0.08em);
}

p {
  margin: 0 0 1.5rem;
  text-wrap: pretty;
}

.container {
  width: min(1080px, 92vw);
  margin: 0 auto;
}

.content {
  --content-width: 60ch;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.content > * {
  width: 100%;
  max-width: var(--content-width);
}

.content.wide {
  --content-width: 68ch;
}

.section {
  padding: clamp(3.5rem, 8vw, 6.5rem) 0;
  scroll-margin-top: 6.5rem;
}

.hero {
  padding-top: clamp(4rem, 6vw, 5rem);
  padding-bottom: clamp(3rem, 6vw, 4.5rem);
}

.section + .section {
  border-top: 1px solid var(--line);
}

.paper {
  background: var(--paper-alpha);
}

.surface {
  background: var(--surface-alpha);
}

.site-header {
  padding: 1.2rem 0;
  position: sticky;
  top: 0;
  z-index: 20;
  background: linear-gradient(140deg, #2f4c68 0%, #213a52 100%);
  color: #f6f1e8;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: flex;
  flex-direction: row;
  gap: 0.85rem;
  align-items: center;
  flex-wrap: nowrap;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  line-height: 1.1;
  text-align: left;
}

.logo {
  font-size: clamp(1.6rem, 1.6vw + 1rem, 2.2rem);
  font-weight: 600;
  margin: 0;
}

.brand-tagline {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
}

.brand-illustration {
  height: clamp(56px, 6vw, 72px);
  width: auto;
  display: block;
}

.toc {
  display: flex;
  gap: 1.6rem;
  align-items: center;
  color: rgba(255, 255, 255, 0.8);
  text-transform: none;
  letter-spacing: 0.02em;
  font-weight: 500;
  white-space: nowrap;
  font-size: 0.9em;
}

.toc a {
  padding-bottom: 0.15rem;
  border-bottom: 1px solid transparent;
}

.toc a:hover {
  color: #ffffff;
  border-bottom-color: #ffffff;
}

.toc-mobile {
  display: none;
  position: relative;
}

.toc-mobile summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.85);
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  justify-content: center;
  padding: 0.35rem 0;
  line-height: 1;
  height: 32px;
}

.toc-mobile summary::-webkit-details-marker {
  display: none;
}

.toc-mobile summary::after {
  content: "";
  width: 1.4rem;
  height: 0.1rem;
  background: currentColor;
  box-shadow: 0 -0.35rem 0 0 currentColor, 0 0.35rem 0 0 currentColor;
}

.toc-mobile-panel {
  position: absolute;
  right: 0;
  margin-top: 0.8rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.8rem 1rem;
  display: grid;
  gap: 0.6rem;
  min-width: 12rem;
  box-shadow: 0 18px 30px rgba(20, 16, 12, 0.12);
}

.toc-mobile-panel a {
  color: var(--ink);
}

.toc-mobile[open] summary {
  color: var(--accent);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3.5rem;
  align-items: start;
}

.hero-side {
  display: grid;
  gap: 1.6rem;
  justify-items: start;
}

.hero-text {
  max-width: 60ch;
}

.hero-card {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  border-radius: 16px;
  padding: 1.3rem 1.4rem;
  box-shadow: none;
  max-width: 320px;
  align-self: start;
}

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

.telegram-avatars {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.telegram-avatar {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #efe9e1;
}

.telegram-avatar.secondary {
  width: 1.7rem;
  height: 1.7rem;
}

.telegram-meta {
  display: grid;
  gap: 0.1rem;
  line-height: 1.1;
}

.telegram-name {
  margin: 0;
  font-weight: 600;
}

.telegram-app {
  margin: 0;
  font-size: 0.85em;
  color: var(--muted);
}

.telegram-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: var(--accent);
  margin-left: auto;
}

.telegram-bubble {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 1.1rem;
  background: #ffffff;
  line-height: 1.4;
}

.telegram-bubble p {
  margin: 0;
}

.telegram-bubble p + p {
  margin-top: 0.4rem;
  color: var(--muted);
}

.small {
  color: var(--muted);
}

.cta {
  margin-top: 2rem;
  display: flex;
  flex-wrap: nowrap;
  gap: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.8rem;
  border-radius: 6px;
  border: 1px solid var(--ink);
  font-size: inherit;
  letter-spacing: 0.02em;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  width: 250px;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.steps {
  list-style: none;
  margin: 2.2rem 0 0;
  padding: 0;
  display: grid;
  gap: 1.6rem;
  position: relative;
  margin-bottom: 1.8rem;
}

.step {
  display: grid;
  grid-template-columns: 2.2rem 1fr;
  gap: 1.6rem;
  align-items: start;
}

.step-number {
  font-size: var(--size-md);
  font-weight: 600;
  line-height: 1;
  color: var(--accent);
  text-align: center;
}

.step-content {
  display: grid;
  gap: 0.35rem;
}

.step-title {
  margin: 0;
  font-weight: 600;
}

.step-text {
  margin: 0;
  color: var(--muted);
}

.accordion {
  margin-top: 2.5rem;
  width: 100%;
}

.accordion-item {
  padding: 1.4rem 0;
  border-top: 1px solid var(--line);
}

.accordion-item:last-of-type {
  border-bottom: 1px solid var(--line);
}

.accordion-item summary {
  font-size: inherit;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.accordion-item summary::-webkit-details-marker {
  display: none;
}

.accordion-item summary::marker {
  display: none;
}

.accordion-body {
  margin-top: 1rem;
}

.category-meta {
  margin: 0 0 0.6rem;
  color: var(--muted);
}

.category-note {
  margin: 0 0 0.8rem;
  color: var(--muted);
}

.category-list {
  margin: 0;
  padding-left: 1.2rem;
}

.category-list li {
  margin: 0.35rem 0;
}

.faq-item {
  border-top: 1px solid var(--line);
  padding: 1.2rem 0;
}

.faq-item:last-of-type {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-weight: 400;
  color: var(--muted);
}

.faq-item[open] summary::after {
  content: "—";
}

.faq-answer {
  margin-top: 0.8rem;
}

.testimonials {
  display: flex;
  gap: 1.6rem;
  margin-top: 2rem;
  overflow-x: auto;
  padding-bottom: 0.8rem;
  scroll-snap-type: x mandatory;
  scroll-padding: 1rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.testimonials::-webkit-scrollbar {
  display: none;
}

.testimonial {
  flex: 0 0 min(520px, 85vw);
  border: 1px solid var(--line);
  padding: 1.4rem 1.6rem;
  background: transparent;
  box-shadow: none;
  scroll-snap-align: start;
}

.testimonial-meta {
  font-weight: 600;
}

.cta-final .btn-primary {
  margin-top: 1.6rem;
}

.site-footer {
  padding: clamp(2.5rem, 6vw, 4rem) 0;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  background: linear-gradient(160deg, #2b4966 0%, #1c3146 100%);
  color: var(--footer-ink);
}

.site-footer p {
  margin: 0;
}

.footer-links {
  color: var(--footer-ink);
  font-weight: 500;
}

.footer-links a {
  color: inherit;
}

.contact-row {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.telegram-icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
}

.telegram-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2.5rem;
  align-items: start;
}

.footer-brand {
  display: grid;
  gap: 1rem;
}

.footer-logo {
  font-size: 1.4rem;
  font-weight: 600;
  margin: 0;
}

.footer-tagline {
  max-width: 36ch;
}

.footer-meta {
  display: grid;
  gap: 1.5rem;
  justify-items: start;
}

.footer-contact {
  font-weight: 500;
}

.footer-illustration {
  margin-top: 2.5rem;
  display: flex;
  justify-content: flex-start;
}

.footer-illustration img {
  height: 72px;
  width: auto;
  display: block;
}

.footer-contact a {
  color: inherit;
  text-decoration: none;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.2fr 0.8fr;
    gap: 3.5rem;
  }
}

@media (max-width: 900px) {
  .header-inner {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 1rem;
  }

  .toc {
    display: none;
  }

  .toc-mobile {
    display: block;
    margin-left: 0;
    justify-self: end;
    align-self: center;
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 720px) {

  .step {
    grid-template-columns: auto;
  }

  .step-number {
    margin-bottom: 0.4rem;
    text-align: left;
    justify-self: start;
  }
}

.fab-cta {
  position: fixed;
  bottom: 1.2rem;
  right: 1.2rem;
  background: var(--accent);
  color: #fff;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  box-shadow: 0 18px 30px rgba(178, 38, 45, 0.2);
  display: none;
  z-index: 30;
  width: 250px;
  text-align: center;
}

@media (max-width: 900px) {
  .fab-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}
