:root {
  --brand-primary: #6a72b8;
  --brand-deep: #21244a;
  --brand-highlight: #ebe3fb;
  --brand-accent: #e5c86a;
  --text-main: #faf7ff;
  --text-soft: rgba(250, 247, 255, 0.82);
  --card-border: rgba(235, 227, 251, 0.18);
  --shadow-card: 0 20px 60px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text-main);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background: linear-gradient(135deg, #121630 0%, #1a1f45 52%, #22295a 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at top left, rgba(229, 200, 106, 0.16), transparent 32%),
    radial-gradient(circle at bottom right, rgba(235, 227, 251, 0.14), transparent 28%);
}

.topbar,
.page {
  position: relative;
  z-index: 1;
}

.topbar {
  margin: 0 auto;
  padding: 20px 16px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  box-sizing: border-box;
  min-width: 0;
}

.brand {
  color: var(--text-main);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  min-width: 0;
  max-width: 100%;
}

.brand img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 12px;
  background: rgba(235, 227, 251, 0.1);
  border: 1px solid rgba(235, 227, 251, 0.26);
  padding: 5px;
}

.brand span {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topnav {
  display: flex;
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(235, 227, 251, 0.14);
  border-radius: 14px;
  background: rgba(22, 28, 68, 0.3);
  min-width: 0;
}

.topnav a {
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 10px;
  transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.topnav a:hover {
  color: var(--text-main);
  background: rgba(235, 227, 251, 0.12);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(235, 227, 251, 0.2);
  border-radius: 11px;
  background: rgba(22, 28, 68, 0.32);
  color: var(--text-main);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.menu-toggle .bar,
.menu-toggle .bar::before,
.menu-toggle .bar::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  content: "";
  transition: transform 160ms ease, opacity 160ms ease;
}

.menu-toggle .bar::before {
  transform: translateY(-6px);
}

.menu-toggle .bar::after {
  transform: translateY(4px);
}

.menu-toggle[aria-expanded="true"] .bar {
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .bar::before {
  transform: translateY(0) rotate(90deg);
}

.menu-toggle[aria-expanded="true"] .bar::after {
  opacity: 0;
}

.page {
  margin: 0 auto;
  padding: 10px 16px 34px;
}

.card {
  background: linear-gradient(180deg, rgba(106, 114, 184, 0.26), rgba(33, 36, 74, 0.64));
  border: 1px solid var(--card-border);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(12px);
}

.hero {
  display: grid;
  gap: 20px;
  padding: 28px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--brand-highlight);
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 700;
}

h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.08;
}

.lead {
  margin: 14px 0 0;
  color: var(--text-soft);
  line-height: 1.6;
}

.lead-rich p,
.lead-rich ul,
.lead-rich ol {
  margin: 14px 0 0;
  color: var(--text-soft);
}

.lead-rich p:first-child,
.lead-rich ul:first-child,
.lead-rich ol:first-child {
  margin-top: 14px;
}

.lead-rich ul,
.lead-rich ol {
  padding-left: 20px;
}

.lead-rich a {
  color: var(--brand-accent);
  text-decoration: underline;
}

.hero-side {
  display: grid;
  place-items: center;
}

.hero-side img {
  width: min(100%, 240px);
  aspect-ratio: 1 / 1;
  height: auto;
  object-fit: contain;
  padding: 10px;
  background: rgba(235, 227, 251, 0.1);
  border-radius: 24px;
  border: 1px solid rgba(235, 227, 251, 0.26);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: 700;
  min-height: 46px;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, #39d483, #1eaa61);
}

.btn-secondary {
  color: var(--text-main);
  background:
    linear-gradient(180deg, rgba(235, 227, 251, 0.08), rgba(255, 255, 255, 0.02)),
    linear-gradient(135deg, rgba(229, 200, 106, 0.06), transparent);
  border: 1px solid rgba(235, 227, 251, 0.14);
}

.btn-gold {
  color: #24190a;
  background: linear-gradient(135deg, #f2d27a, #c99a2e);
  border: 1px solid rgba(201, 154, 46, 0.42);
}

.btn-gold:hover,
.btn-gold:focus {
  color: #24190a;
  background: linear-gradient(135deg, #f7dd93, #d7ab46);
}

.btn-gold i {
  color: inherit;
}

.btn-whatsapp {
  color: #fff;
  background: linear-gradient(135deg, #39d483, #1eaa61);
  border: 1px solid rgba(30, 170, 97, 0.4);
}

.btn-whatsapp:hover,
.btn-whatsapp:focus {
  color: #fff;
  background: linear-gradient(135deg, #4ae092, #24bb6d);
}

.section {
  margin-top: 18px;
}

.section h2 {
  margin: 0 0 12px;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--brand-accent);
}

.portal-page .topbar,
.portal-page .page,
.meditacoes-page .topbar,
.meditacoes-page .page {
  max-width: 1080px;
}

.portal-page .hero {
  grid-template-columns: 1.45fr 0.75fr;
}

.portal-page h1 {
  font-size: clamp(1.9rem, 4vw, 3rem);
}

.portal-page .lead {
  max-width: 60ch;
}

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

.treatments-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.treatments-grid > .treatment {
  grid-column: span 2;
}

.treatments-grid > .treatment:last-child:nth-child(3n + 1) {
  grid-column: 3 / span 2;
}

.treatments-grid > .treatment:nth-last-child(2):nth-child(3n + 1) {
  grid-column: 2 / span 2;
}

.treatments-grid > .treatment:last-child:nth-child(3n + 2) {
  grid-column: 4 / span 2;
}

.treatment {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.treatment img {
  width: 100%;
  aspect-ratio: 1 / 1;
  height: auto;
  object-fit: cover;
  display: block;
}

.treatment-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.treatment h3 {
  margin: 0 0 8px;
  color: var(--brand-highlight);
}

.treatment p {
  margin: 0 0 10px;
  color: var(--text-soft);
  line-height: 1.5;
}

.treatment ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-soft);
}

.treatment li + li {
  margin-top: 6px;
}

.treatment .btn {
  margin-top: auto;
  align-self: flex-start;
}

.hero-side--cover img {
  width: min(100%, 200px);
  height: auto;
  object-fit: cover;
  display: block;
  margin: 0 auto;
}

.apometria-page .hero-side--cover {
  align-self: center;
}

.apometria-page .hero-side--cover img {
  border-radius: 28px;
  border: 1px solid rgba(235, 227, 251, 0.24);
  box-shadow: var(--shadow-card);
  background: transparent;
  padding: 0;
}

.apometria-copy {
  padding: 28px;
}

.apometria-copy::after {
  content: "";
  display: block;
  clear: both;
}

.apometria-copy p,
.apometria-copy ul,
.apometria-copy h2 {
  margin-left: 0;
  margin-right: 0;
}

.apometria-copy p + p,
.apometria-copy p + ul,
.apometria-copy ul + p,
.apometria-copy h2 + p {
  margin-top: 14px;
}

.apometria-copy ul {
  padding-left: 22px;
}

.apometria-copy li + li {
  margin-top: 8px;
}

.apometria-inline-media {
  margin: 18px 0;
}

.apometria-inline-media--float {
  float: right;
  width: min(24%, 250px);
  margin: 2px 10px 12px 18px;
}

.apometria-inline-media img {
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 24px;
  border: 1px solid rgba(235, 227, 251, 0.2);
  box-shadow: var(--shadow-card);
}

.details {
  padding: 20px;
}

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

.details-grid article {
  border: 1px solid rgba(235, 227, 251, 0.14);
  border-radius: 16px;
  padding: 14px;
  background: rgba(235, 227, 251, 0.04);
}

.details-grid h3 {
  margin: 0 0 8px;
  color: var(--brand-highlight);
}

.details-grid p,
#sobre p,
#contato p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.6;
}

#sobre,
#contato {
  padding: 20px;
}

.about-card {
  padding: 32px;
}

.about-layout {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 720px);
  gap: 40px;
  align-items: start;
  justify-content: space-between;
}

.about-media {
  display: grid;
  gap: 18px;
  justify-items: center;
}

.about-media img {
  width: min(100%, 220px);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 28px;
  border: 4px solid rgba(229, 200, 106, 0.45);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.32);
}

.about-badge {
  width: 100%;
  max-width: 260px;
  padding: 14px 18px;
  text-align: center;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(235, 227, 251, 0.1), rgba(255, 255, 255, 0.04)),
    linear-gradient(135deg, rgba(229, 200, 106, 0.08), transparent);
  border: 1px solid rgba(235, 227, 251, 0.16);
}

.about-badge .eyebrow {
  display: block;
  margin-bottom: 8px;
}

.about-copy h2 {
  margin-bottom: 18px;
}

.about-copy {
  max-width: 64ch;
}

.about-copy p + p {
  margin-top: 18px;
}

#sobre p {
  font-size: 1.06rem;
  line-height: 1.78;
}

.meditacoes-page .hero {
  grid-template-columns: 1.3fr 0.8fr;
  gap: 22px;
}

.meditacoes-page h1 {
  font-size: clamp(1.9rem, 4vw, 2.8rem);
}

.meditacoes-page .lead {
  line-height: 1.62;
  max-width: 62ch;
}

.section-intro {
  margin: 8px 0 0;
  color: var(--text-soft);
}

.featured-video {
  margin-top: 14px;
  overflow: hidden;
}

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

.video-card {
  overflow: hidden;
}

.video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-wrap iframe,
.local-video-wrap video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}

.local-video-wrap video {
  object-fit: cover;
}

.video-body {
  padding: 12px 14px;
}

.video-body h3 {
  margin: 0;
  font-size: 0.98rem;
  color: var(--brand-highlight);
}

.video-body p {
  margin: 8px 0 0;
  color: var(--text-soft);
  line-height: 1.5;
  font-size: 0.93rem;
}

.featured-body {
  padding: 14px 16px 16px;
}

.featured-body h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  color: var(--brand-highlight);
}

.featured-body p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.55;
}

.featured-body p + p {
  margin-top: 8px;
}

.collective-form {
  margin-top: 20px;
}

.honeypot-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.collective-table-shell {
  overflow-x: auto;
  border: 1px solid rgba(235, 227, 251, 0.14);
  border-radius: 20px;
  background: rgba(8, 11, 30, 0.22);
}

.collective-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.collective-table th,
.collective-table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(235, 227, 251, 0.12);
  text-align: left;
  vertical-align: middle;
}

.collective-table thead th {
  color: var(--brand-accent);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.collective-table tbody tr:last-child td {
  border-bottom: 0;
}

.collective-table input {
  width: 100%;
  min-height: 56px;
  border: 1px solid rgba(235, 227, 251, 0.16);
  border-radius: 18px;
  padding: 14px 18px;
  background: rgba(235, 227, 251, 0.08);
  color: var(--text-main);
  font: inherit;
  box-shadow: none;
}

.collective-table input::placeholder {
  color: rgba(255, 248, 255, 0.5);
}

.collective-table input:focus {
  outline: none;
  border-color: rgba(229, 200, 106, 0.55);
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  box-shadow: 0 0 0 0.2rem rgba(229, 200, 106, 0.18);
}

.collective-table__action {
  width: 140px;
}

.collective-table__action .btn {
  min-height: 40px;
  padding: 10px 14px;
}

.form-feedback {
  margin-top: 18px;
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(235, 227, 251, 0.16);
}

.form-feedback--success {
  background: rgba(33, 148, 89, 0.18);
  border-color: rgba(74, 224, 146, 0.4);
}

.form-feedback--error {
  background: rgba(168, 52, 68, 0.2);
  border-color: rgba(255, 142, 159, 0.34);
}

.form-feedback ul {
  margin: 10px 0 0;
  padding-left: 20px;
}

.collective-table--single {
  min-width: 0;
}

.collective-field {
  display: grid;
  gap: 8px;
}

.collective-field span {
  margin-bottom: 0;
  font-weight: 600;
  color: var(--text-main);
}

.collective-field .form-control::-webkit-calendar-picker-indicator {
  filter: invert(1) brightness(1.4);
}

@media (max-width: 1180px) {
  .topbar {
    padding-left: 18px;
    padding-right: 18px;
  }

  .topnav {
    gap: 4px;
    padding: 4px;
  }

  .topnav a {
    padding: 7px 10px;
    font-size: 0.9rem;
  }
}

@media (max-width: 980px) {
  .hero {
    display: block;
    padding: 18px 14px;
  }

  .portal-page .hero-side,
  .meditacoes-page .hero-side {
    display: none;
  }

  .portal-page .hero > div:first-child,
  .meditacoes-page .hero > div:first-child {
    width: 100%;
    max-width: 100%;
  }

  .portal-page .hero h1,
  .meditacoes-page .hero h1,
  .portal-page .lead,
  .meditacoes-page .lead {
    max-width: 100%;
  }

  .portal-page h1,
  .meditacoes-page h1 {
    font-size: clamp(1.75rem, 8vw, 2.4rem);
  }

  .meditacoes-page .hero-side img {
    max-width: 220px;
  }

  .meditacoes-page .video-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .topbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 10px;
    row-gap: 10px;
    padding: 20px 16px 10px;
    overflow: hidden;
  }

  .brand {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
  }

  .menu-toggle {
    display: inline-flex;
    justify-self: end;
    grid-column: 2;
    grid-row: 1;
  }

  .topnav {
    width: 100%;
    max-width: 100%;
    display: none;
    flex-direction: column;
    gap: 6px;
    padding: 8px;
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .topnav.is-open {
    display: flex;
  }

  .topnav a {
    width: 100%;
    text-align: left;
    padding: 10px 12px;
    font-size: 0.92rem;
  }

  .portal-page .hero-side img {
    width: 100%;
    max-width: 240px;
  }

  .portal-page .grid,
  .portal-page .details-grid,
  .meditacoes-page .video-grid {
    grid-template-columns: 1fr;
  }

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

  .treatments-grid > .treatment,
  .treatments-grid > .treatment:last-child:nth-child(3n + 1),
  .treatments-grid > .treatment:nth-last-child(2):nth-child(3n + 1),
  .treatments-grid > .treatment:last-child:nth-child(3n + 2) {
    grid-column: auto;
  }

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

}

@media (max-width: 768px) {
  .apometria-inline-media--float {
    float: none;
    width: 100%;
    max-width: 420px;
    margin: 16px auto;
  }

  .collective-table {
    min-width: 0;
  }

  .collective-table thead {
    display: none;
  }

  .collective-table,
  .collective-table tbody,
  .collective-table tr,
  .collective-table td {
    display: block;
    width: 100%;
  }

  .collective-table tr + tr {
    border-top: 1px solid rgba(235, 227, 251, 0.12);
  }

  .collective-table td {
    border-bottom: 0;
    padding: 10px 14px;
  }

  .collective-table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 6px;
    color: var(--brand-accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }

  .collective-table__action {
    width: 100%;
  }

  .collective-table__action .btn {
    width: 100%;
    justify-content: center;
  }
}
