.legal-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 88% 8%, rgba(255, 255, 255, 0.92) 0 8%, transparent 28%),
    linear-gradient(180deg, #fff9f0 0, #fff4e7 460px, #fbf1e4 100%);
}

.legal-page .site-header {
  border-color: var(--line);
  background: rgba(255, 248, 239, 0.9);
  box-shadow: 0 12px 30px rgba(80, 49, 27, 0.06);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.legal-page .site-nav a[aria-current="page"] {
  color: var(--orange-deep);
}

.legal-page .site-nav a[aria-current="page"]::after {
  right: 0;
}

.legal-main {
  min-height: 72vh;
}

.legal-hero {
  position: relative;
  padding: 158px 0 112px;
  overflow: hidden;
  isolation: isolate;
}

.legal-hero::before {
  content: "";
  position: absolute;
  top: -240px;
  right: -150px;
  z-index: -2;
  width: 640px;
  height: 640px;
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.36);
  box-shadow:
    0 0 0 52px rgba(255, 255, 255, 0.1),
    0 0 0 124px rgba(255, 255, 255, 0.07);
}

.legal-hero__decor,
.legal-content__decor {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.legal-hero__cloud {
  position: absolute;
  top: 138px;
  right: 8%;
  width: 96px;
  opacity: 0.58;
}

.legal-hero__heart {
  position: absolute;
  top: 248px;
  right: 19%;
  width: 24px;
  animation: soft-float 5s ease-in-out infinite;
}

.legal-hero__leaf {
  position: absolute;
  left: 4%;
  bottom: 28px;
  width: 112px;
  opacity: 0.5;
  transform: rotate(-12deg);
}

.legal-hero__inner {
  position: relative;
}

.legal-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--orange-deep);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.legal-eyebrow::before {
  content: "";
  width: 26px;
  height: 2px;
  border-radius: 99px;
  background: var(--orange);
}

.legal-hero h1 {
  max-width: 780px;
  margin-top: 21px;
  font-family: var(--display);
  font-size: clamp(43px, 5.6vw, 68px);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -0.07em;
}

.legal-hero__description {
  max-width: 650px;
  margin-top: 23px;
  color: var(--brown-soft);
  font-size: 15px;
  line-height: 1.9;
  letter-spacing: -0.02em;
}

.legal-meta {
  margin-top: 29px;
  padding: 10px 15px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid rgba(255, 118, 33, 0.24);
  border-radius: 999px;
  color: #8d705d;
  background: rgba(255, 255, 255, 0.65);
  font-size: 11px;
  font-weight: 700;
}

.legal-meta::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px rgba(255, 118, 33, 0.12);
}

.legal-content {
  position: relative;
  padding: 0 0 140px;
}

.legal-content::before {
  content: "";
  position: absolute;
  inset: 70px 0 0;
  z-index: -2;
  background: var(--paper);
}

.legal-content__garden {
  position: absolute;
  left: 50%;
  bottom: -3px;
  width: max(1100px, 100vw);
  max-width: none;
  opacity: 0.34;
  transform: translateX(-50%);
}

.legal-content__decor {
  overflow: hidden;
}

.legal-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  align-items: start;
  gap: 28px;
}

.legal-aside {
  position: sticky;
  top: 98px;
  padding: 25px;
  border: 1px solid #f0d9c5;
  border-radius: 27px;
  background: rgba(255, 249, 241, 0.9);
  box-shadow: 0 20px 48px rgba(103, 62, 30, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.legal-aside__mark {
  width: 45px;
  height: 45px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: white;
  background: var(--orange);
  box-shadow: 0 10px 22px rgba(233, 88, 10, 0.2);
  font-family: var(--display);
  font-size: 20px;
}

.legal-aside h2 {
  margin-top: 17px;
  font-family: var(--display);
  font-size: 21px;
  font-weight: 400;
  letter-spacing: -0.045em;
}

.legal-aside p {
  margin-top: 8px;
  color: #8e7868;
  font-size: 11px;
  line-height: 1.7;
}

.legal-aside nav {
  margin-top: 22px;
  display: grid;
  border-top: 1px solid var(--line);
}

.legal-aside nav a {
  padding: 12px 2px;
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  color: #765e4d;
  font-size: 12px;
  font-weight: 800;
}

.legal-aside nav a::after {
  content: "→";
  color: var(--orange);
}

.legal-aside nav a[aria-current="page"] {
  color: var(--orange-deep);
}

.legal-paper {
  padding: clamp(30px, 5vw, 58px);
  overflow: hidden;
  border: 1px solid #eedac9;
  border-radius: 36px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.legal-paper__intro {
  margin-bottom: 42px;
  padding: 22px 24px;
  border-left: 4px solid var(--orange);
  border-radius: 0 18px 18px 0;
  color: #665043;
  background: #fff7ed;
  font-size: 14px;
  line-height: 1.85;
}

.legal-paper section + section {
  margin-top: 41px;
  padding-top: 39px;
  border-top: 1px solid rgba(103, 73, 51, 0.12);
}

.legal-paper h2,
.deletion-card h2 {
  color: var(--brown);
  font-family: var(--display);
  font-size: 23px;
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: -0.045em;
}

.legal-paper p,
.legal-paper li,
.deletion-card p,
.deletion-card li,
.deletion-card label {
  color: #6d5a4d;
  font-size: 14px;
  line-height: 1.85;
}

.legal-paper h2 + p,
.legal-paper h2 + ul,
.deletion-card h2 + p,
.deletion-card h2 + ul,
.deletion-card h2 + .form-grid {
  margin-top: 14px;
}

.legal-paper ul,
.deletion-card ul {
  margin: 0;
  padding-left: 21px;
}

.legal-paper li + li,
.deletion-card li + li {
  margin-top: 7px;
}

.legal-paper li::marker,
.deletion-card li::marker {
  color: var(--orange);
}

.legal-paper a,
.deletion-card a {
  color: var(--orange-deep);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(233, 88, 10, 0.26);
  text-underline-offset: 3px;
}

.deletion-stack {
  display: grid;
  gap: 20px;
}

.deletion-card {
  padding: clamp(25px, 4vw, 42px);
  border: 1px solid #eedac9;
  border-radius: 31px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 22px 56px rgba(104, 63, 31, 0.1);
}

.deletion-card--form {
  border-color: #efc9aa;
  box-shadow: var(--shadow);
}

.deletion-card p.deletion-card__number {
  margin-bottom: 11px;
  color: var(--orange);
  font-family: var(--display);
  font-size: 34px;
  line-height: 1;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 17px 14px;
}

.field {
  display: grid;
  align-content: start;
  gap: 7px;
}

.field:nth-child(5),
.field:nth-child(6) {
  grid-column: 1 / -1;
}

.field label {
  color: #5f493a;
  font-size: 12px;
  font-weight: 800;
}

.field input:not([type="checkbox"]),
.field select,
.field textarea {
  width: 100%;
  min-height: 50px;
  padding: 13px 15px;
  border: 1px solid #ead2bf;
  border-radius: 15px;
  outline: 0;
  color: var(--brown);
  background: #fffaf4;
  font-size: 14px;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.field textarea {
  min-height: 124px;
  resize: vertical;
}

.field input:not([type="checkbox"]):focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--orange);
  background: white;
  box-shadow: 0 0 0 4px rgba(255, 118, 33, 0.11);
}

.field input::placeholder,
.field textarea::placeholder {
  color: #b5a69b;
}

.field:has(input[type="checkbox"]) label {
  padding: 15px 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid #edd8c8;
  border-radius: 15px;
  background: #fffaf5;
}

.field input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 4px 0 0;
  flex: 0 0 auto;
  accent-color: var(--orange);
}

.form-actions {
  margin-top: 21px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.form-button {
  min-height: 50px;
  padding: 0 19px;
  border: 1px solid var(--orange);
  border-radius: 15px;
  color: white;
  background: var(--orange);
  box-shadow: 0 11px 24px rgba(233, 88, 10, 0.17);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.form-button:hover {
  background: var(--orange-deep);
  box-shadow: 0 14px 28px rgba(233, 88, 10, 0.23);
  transform: translateY(-2px);
}

.form-button--secondary {
  color: var(--orange-deep);
  background: white;
  box-shadow: none;
}

.form-button--secondary:hover {
  color: white;
}

.form-note {
  margin-top: 17px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: #8f7a6b !important;
  font-size: 12px !important;
}

.form-status {
  min-height: 0;
  margin-top: 12px;
  padding: 0;
  border-radius: 13px;
  color: #77533c !important;
  background: #fff0df;
  font-size: 12px !important;
  font-weight: 700;
}

.form-status:not(:empty) {
  padding: 11px 13px;
}

.legal-page .site-footer {
  position: relative;
  z-index: 2;
}

@media (max-width: 860px) {
  .legal-hero {
    padding: 132px 0 86px;
  }

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

  .legal-aside {
    position: relative;
    top: auto;
  }

  .legal-aside__mark,
  .legal-aside h2,
  .legal-aside p {
    display: none;
  }

  .legal-aside nav {
    margin-top: 0;
    grid-template-columns: repeat(3, 1fr);
    border: 0;
  }

  .legal-aside nav a {
    padding: 9px 8px;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    text-align: center;
  }

  .legal-aside nav a::after {
    display: none;
  }

  .legal-aside nav a[aria-current="page"] {
    background: white;
    box-shadow: 0 8px 18px rgba(104, 63, 31, 0.08);
  }
}

@media (max-width: 560px) {
  .legal-hero {
    padding: 116px 0 70px;
  }

  .legal-hero h1 {
    font-size: 42px;
  }

  .legal-hero__description {
    font-size: 13px;
    line-height: 1.8;
  }

  .legal-hero__cloud {
    top: 112px;
    right: -18px;
    width: 76px;
  }

  .legal-hero__heart {
    top: 215px;
    right: 8%;
  }

  .legal-hero__leaf {
    left: -30px;
  }

  .legal-meta {
    align-items: flex-start;
    border-radius: 16px;
    line-height: 1.5;
  }

  .legal-content {
    padding-bottom: 100px;
  }

  .legal-aside {
    padding: 8px;
    border-radius: 18px;
  }

  .legal-aside nav a {
    font-size: 10px;
  }

  .legal-paper {
    padding: 27px 21px;
    border-radius: 26px;
  }

  .legal-paper__intro {
    margin-bottom: 33px;
    padding: 17px 16px;
    font-size: 13px;
  }

  .legal-paper section + section {
    margin-top: 33px;
    padding-top: 31px;
  }

  .legal-paper h2,
  .deletion-card h2 {
    font-size: 20px;
  }

  .legal-paper p,
  .legal-paper li,
  .deletion-card p,
  .deletion-card li,
  .deletion-card label {
    font-size: 13px;
  }

  .deletion-card {
    padding: 27px 21px;
    border-radius: 25px;
  }

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

  .field:nth-child(5),
  .field:nth-child(6) {
    grid-column: auto;
  }

  .form-actions {
    display: grid;
  }

  .form-button {
    width: 100%;
  }
}
