/* =========================================================
   EduPrime — estilos complementares
   Tailwind cuida do layout utilitário; este arquivo guarda
   componentes visuais, detalhes e ajustes responsivos.
   ========================================================= */

:root {
  --color-purple: #2b0d60;
  --color-purple-deep: #260b4f;
  --color-pink: #f52f83;
  --color-pink-dark: #dc2377;
  --color-ink: #111322;
  --color-muted: #6d7284;
  --color-border: #e9eaf0;
  --shadow-soft: 0 14px 35px rgba(24, 17, 49, 0.12);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  font-family: "DM Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.container-page {
  width: min(1240px, calc(100% - 48px));
  margin-inline: auto;
}

/* Cabeçalho e navegação */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: inherit;
  font-family: "Poppins", sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.logo-mark {
  display: grid;
  width: 29px;
  height: 29px;
  place-items: center;
  border-radius: 9px;
  background: var(--color-pink);
  box-shadow: 0 4px 12px rgb(24 8 58 / 33%);
  color: white;
  font-size: 0.9rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 5px;
  border: 1px solid rgb(255 255 255 / 16%);
  border-radius: 999px;
  background: #ef3687;
  box-shadow: 0 5px 16px rgb(22 6 46 / 18%);
}

.nav-links a {
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  transition: background 180ms ease;
}

.nav-links a:hover {
  background: rgb(255 255 255 / 18%);
}

.profile-btn,
.menu-toggle {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 28%);
  border-radius: 50%;
  background: var(--color-pink);
  color: white;
  cursor: pointer;
}

.menu-toggle {
  font-size: 1.15rem;
}

/* Botões */
.btn {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 700;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

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

.btn-primary {
  background: linear-gradient(110deg, #ff397f, #e72d90);
  box-shadow: 0 7px 18px rgb(245 47 131 / 20%);
  color: white;
}

.btn-primary:hover {
  box-shadow: 0 10px 24px rgb(245 47 131 / 30%);
}

.btn-outline {
  border-color: var(--color-purple);
  background: transparent;
  color: var(--color-purple);
}

.btn-outline-light {
  border-color: rgb(255 255 255 / 35%);
  background: transparent;
  color: white;
}

/* Hero */
.hero-section {
  min-height: 620px;
  padding: 118px 0 76px;
  background:
    radial-gradient(ellipse at 23% 57%, #451583 0, #35106d 36%, transparent 66%),
    var(--color-purple);
}

.hero-section::before,
.hero-section::after {
  position: absolute;
  border: 1px solid rgb(255 255 255 / 6%);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.hero-section::before {
  top: -95px;
  left: -110px;
  width: 600px;
  height: 600px;
}

.hero-section::after {
  top: 73px;
  left: -20px;
  width: 430px;
  height: 430px;
}

.hero-grid {
  grid-template-columns: 0.86fr 1.14fr;
}

.script-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  color: #f7d8eb;
  font-family: "Poppins", sans-serif;
  font-size: 0.9rem;
  font-style: italic;
}

.script-label::after {
  width: 34px;
  height: 1px;
  background: var(--color-pink);
  content: "";
}

.script-label-dark {
  color: var(--color-pink);
}

.hero-description {
  color: #e1d8ef;
}

.avatars {
  display: flex;
  padding-left: 4px;
}

.avatar {
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  margin-left: -4px;
  border: 2px solid var(--color-purple);
  border-radius: 50%;
  background: #f84d89;
  color: white;
  font-size: 0.6rem;
  font-weight: 800;
}

.avatar:nth-child(2) { background: #ffb43b; }
.avatar:nth-child(3) { background: #13a6d7; }

.rating-stars,
.stars {
  color: #ff9f28;
  letter-spacing: 1px;
  white-space: nowrap;
}

.hero-gallery {
  position: relative;
}

.hero-photo {
  overflow: hidden;
  border: 2px solid rgb(255 255 255 / 42%);
  border-radius: 22px;
  background: #51258a;
  box-shadow: 0 12px 28px rgb(22 5 43 / 22%);
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 450ms ease;
}

.hero-photo:hover img {
  transform: scale(1.04);
}

.hero-photo-tall {
  height: 255px;
}

.hero-photo-short {
  height: 205px;
}

.hero-photo-round {
  width: 68%;
  aspect-ratio: 1;
  justify-self: center;
  overflow: hidden;
  border-radius: 50%;
}

.hero-photo-round img {
  aspect-ratio: 1;
}

/* Indicadores */
.stat strong {
  display: block;
  color: var(--color-purple);
  font-family: "Poppins", sans-serif;
  font-size: clamp(1.65rem, 2.5vw, 2.25rem);
  line-height: 1.2;
}

.stat span {
  color: var(--color-muted);
  font-size: 0.78rem;
}

/* Cursos */
.courses-section {
  padding-block: 78px 82px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--color-pink);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow::before,
.eyebrow::after {
  width: 18px;
  height: 1px;
  background: currentColor;
  content: "";
}

.course-card {
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: 14px;
  background: white;
  box-shadow: 0 3px 8px rgb(30 23 61 / 2%);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.course-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-soft);
}

.course-image {
  position: relative;
  height: 165px;
  overflow: hidden;
  background: #e9e4ef;
}

.course-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

.course-card:hover .course-image img {
  transform: scale(1.05);
}

.category {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  background: white;
  box-shadow: 0 2px 8px rgb(0 0 0 / 7%);
  color: var(--color-purple);
  font-size: 0.66rem;
  font-weight: 700;
}

.course-body {
  padding: 14px 15px 16px;
}

.course-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 9px;
  color: var(--color-muted);
  font-size: 0.66rem;
}

.muted {
  color: var(--color-muted);
  letter-spacing: 0;
}

.course-card h3 {
  min-height: 43px;
  margin: 0 0 14px;
  font-family: "Poppins", sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.45;
}

.course-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid #f0f0f3;
}

.price {
  font-size: 1rem;
  font-weight: 800;
}

.old-price {
  margin-left: 5px;
  color: #a5a8b3;
  font-size: 0.65rem;
  font-weight: 400;
  text-decoration: line-through;
}

.add-course {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  place-items: center;
  border: 1px solid #ffd0e4;
  border-radius: 8px;
  background: white;
  color: var(--color-pink);
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.add-course:hover,
.add-course[aria-pressed="true"] {
  background: var(--color-pink);
  color: white;
}

/* Benefícios */
.why-section {
  padding-block: 82px 88px;
}

.why-copy > p,
.benefit p {
  color: var(--color-muted);
}

.benefit-icon {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  place-items: center;
  border-radius: 10px;
  background: #fff0f7;
  color: var(--color-pink);
  font-size: 1.05rem;
}

.benefit-icon-purple {
  background: #f2e9ff;
  color: #873cf1;
}

.benefit h3 {
  margin: 0 0 3px;
  font-size: 0.9rem;
  font-weight: 700;
}

.benefit p {
  margin: 0;
  font-size: 0.77rem;
  line-height: 1.55;
}

.why-visual {
  padding: 0 0 28px 18px;
}

.why-image {
  height: 340px;
  border-radius: 23px;
  box-shadow: var(--shadow-soft);
}

.floating-note {
  position: absolute;
  bottom: 0;
  left: 0;
  max-width: 290px;
  box-shadow: 0 10px 30px rgb(24 16 45 / 13%);
}

.check {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  place-items: center;
  border-radius: 50%;
  background: var(--color-pink);
  color: white;
}

.floating-note strong,
.floating-note span {
  display: block;
}

.floating-note strong {
  font-size: 0.78rem;
}

.floating-note div span {
  color: var(--color-muted);
  font-size: 0.68rem;
}

/* Chamada para ação e rodapé */
.cta-section {
  background: radial-gradient(ellipse at center, #3a1178, #260b4f 70%);
}

.site-footer {
  background: #101827;
  color: #d4d7e1;
}

.footer-brand .logo {
  margin-bottom: 14px;
  color: white;
}

.footer-brand > p {
  max-width: 240px;
  margin: 0;
  color: #b2b8c8;
  font-size: 0.75rem;
}

.footer-column h3 {
  margin: 3px 0 14px;
  color: white;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.footer-column > a {
  display: block;
  width: fit-content;
  margin-block: 8px;
  color: #bfc4d1;
  font-size: 0.73rem;
  transition: color 180ms ease;
}

.footer-column > a:hover,
.legal-links a:hover {
  color: white;
}

.newsletter > p {
  margin-bottom: 10px;
  color: #bfc4d1;
  font-size: 0.7rem;
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.newsletter-form input {
  width: 100%;
  min-height: 39px;
  padding-inline: 12px;
  border: 1px solid #3a4355;
  border-radius: 8px;
  outline: none;
  background: #202a3b;
  color: white;
  font-size: 0.76rem;
}

.newsletter-form input:focus {
  border-color: var(--color-pink);
}

.newsletter-form button {
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  background: var(--color-pink-dark);
  color: white;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
}

.form-message {
  min-height: 1em;
  margin: 3px 0 0 !important;
  color: #ffd1e4 !important;
}

.toast {
  position: fixed;
  z-index: 50;
  right: 22px;
  bottom: 22px;
  max-width: calc(100% - 44px);
  padding: 13px 18px;
  border-radius: 12px;
  background: #24104b;
  box-shadow: var(--shadow-soft);
  color: white;
  font-size: 0.86rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 200ms ease, transform 200ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* Acessibilidade */
:focus-visible {
  outline: 3px solid #ff8abb;
  outline-offset: 3px;
}

/* Tablet e telas médias */
@media (max-width: 1023px) {
  .hero-grid {
    grid-template-columns: 0.95fr 1.05fr;
    gap: 30px;
  }

  .hero-photo-tall { height: 220px; }
  .hero-photo-short { height: 175px; }
  .course-image { height: 190px; }
  .footer-grid { gap: 32px; }
}

/* Menu mobile e layout empilhado */
@media (max-width: 767px) {
  .container-page {
    width: min(100% - 36px, 1240px);
  }

  .site-header .container-page {
    min-height: 70px;
  }

  .menu-toggle {
    display: grid;
    margin-left: auto;
  }

  .profile-btn {
    width: 35px;
    height: 35px;
  }

  .nav-links {
    position: absolute;
    top: 62px;
    right: 18px;
    left: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 3px;
    padding: 10px;
    border: 1px solid rgb(255 255 255 / 18%);
    border-radius: 16px;
    background: #35106d;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 11px 14px;
    font-size: 0.9rem;
  }

  .hero-section {
    min-height: auto;
    padding: 105px 0 52px;
  }

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

  .hero-gallery {
    max-width: 560px;
    width: 100%;
    margin-inline: auto;
  }

  .hero-photo-tall { height: clamp(165px, 43vw, 245px); }
  .hero-photo-short { height: clamp(140px, 36vw, 205px); }
  .hero-photo-round { width: 72%; }

  .courses-section,
  .why-section {
    padding-block: 60px;
  }

  .course-image {
    height: clamp(150px, 30vw, 205px);
  }

  .course-body {
    padding: 12px;
  }

  .course-card h3 {
    min-height: 48px;
    font-size: 0.82rem;
  }

  .why-grid {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .why-visual {
    margin-left: 6px;
  }

  .why-image {
    height: clamp(240px, 62vw, 360px);
  }
}

/* Celulares pequenos */
@media (max-width: 439px) {
  .container-page {
    width: calc(100% - 30px);
  }

  .logo { font-size: 1.05rem; }

  .hero-copy .btn {
    flex: 1;
    padding-inline: 14px;
  }

  .course-image { height: 205px; }

  .course-card h3 {
    min-height: auto;
  }

  .course-meta { font-size: 0.72rem; }
  .old-price { display: block; margin-left: 0; }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 16px;
  }

  .footer-brand,
  .newsletter {
    grid-column: 1 / -1;
  }

  .footer-bottom {
    align-items: flex-start;
  }

  .floating-note {
    max-width: 260px;
    padding: 12px;
  }
}

/* Respeita a preferência de movimento reduzido do sistema. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
