:root {
  --brand-1: #00bf33;
  --brand-2: #4fe0cb;
  --brand-3: #89f336;
  --brand-4: #fffc30;
  --cream: #F5FFEA;
  --cream-2: #E8FBF3;
  --ink: #1E2D22;
  --ink-soft: #5B6F60;
  --white: #FFFFFF;
}

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

html, body {
  height: 100%;
}

body {
  font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-2) 100%);
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.splash-screen {
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-2) 100%);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.splash-screen.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.splash-monkey {
  font-size: 110px;
  animation: splash-bounce 0.9s ease-in-out infinite;
}

@keyframes splash-bounce {
  0%, 100% {
    transform: translateY(0) rotate(-8deg);
  }
  50% {
    transform: translateY(-26px) rotate(8deg);
  }
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 64px;
  flex: 0 0 auto;
}

.logo {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink);
}

.logo span {
  color: var(--brand-1);
}

.lang-switch {
  display: flex;
  gap: 8px;
}

.lang-link {
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 14px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.lang-link:hover {
  color: var(--brand-1);
}

.lang-link.active {
  color: var(--brand-1);
  border-color: var(--brand-1);
}

.hero {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 20px 64px;
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
}

.hero-content {
  flex: 1;
  max-width: 560px;
}

.hero-content h1 {
  font-size: 52px;
  line-height: 1.15;
  font-weight: 800;
  margin-bottom: 24px;
  color: var(--ink);
}

.hero-content p {
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink-soft);
  margin-bottom: 36px;
}

.cta-primary {
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: var(--white);
  border: none;
  padding: 16px 32px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 12px 24px -8px rgba(0, 191, 51, 0.5);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 28px -8px rgba(0, 191, 51, 0.6);
}

.hero-visual {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 420px;
  position: relative;
}

.card-stack {
  position: relative;
  width: 280px;
  height: 380px;
}

.plan-card {
  position: absolute;
  inset: 0;
  border-radius: 28px;
  overflow: hidden;
}

.card-back {
  background: var(--brand-3);
  transform: rotate(10deg) translate(18px, 10px);
  opacity: 0.7;
}

.card-mid {
  background: var(--brand-2);
  transform: rotate(-6deg) translate(-10px, 6px);
  opacity: 0.85;
}

.card-front {
  background: var(--white);
  box-shadow: 0 24px 48px -16px rgba(30, 45, 34, 0.25);
  display: flex;
  flex-direction: column;
  transform: rotate(2deg);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.card-front:hover {
  transform: rotate(0deg) scale(1.03);
}

.card-front.card-flipped {
  transform: rotate(-2deg) scale(1.03);
}

.plan-image {
  width: 100%;
  height: 68%;
  object-fit: cover;
  display: block;
  -webkit-user-drag: none;
}

.plan-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px 16px;
  text-align: center;
}

.plan-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--ink);
}

.plan-sub {
  font-size: 14px;
  color: var(--ink-soft);
}

.footer {
  flex: 0 0 auto;
  text-align: center;
  padding: 20px;
  color: var(--ink-soft);
  font-size: 13px;
}

/* Pantallas grandes (1440px+, ej. 1920x1080) */
@media (min-width: 1440px) {
  .hero {
    max-width: 1680px;
    padding: 20px 96px;
  }

  .hero-content {
    max-width: 680px;
  }

  .hero-content h1 {
    font-size: 64px;
  }

  .hero-content p {
    font-size: 20px;
  }

  .card-stack {
    width: 340px;
    height: 460px;
  }

  .plan-title {
    font-size: 24px;
  }

  .plan-sub {
    font-size: 16px;
  }

  .cta-try {
    padding: 26px 80px;
    font-size: 24px;
  }
}

@media (max-width: 900px) {
  body {
    min-height: 100vh;
  }

  .topbar {
    padding: 20px 24px;
  }

  .hero {
    flex-direction: column;
    padding: 40px 24px 60px;
    text-align: center;
  }

  .hero-content h1 {
    font-size: 36px;
  }
}

/* Móvil */
@media (max-width: 600px) {
  .topbar {
    padding: 16px 20px;
  }

  .logo {
    font-size: 18px;
  }

  .lang-link {
    padding: 5px 10px;
    font-size: 12px;
  }

  .hero {
    padding: 32px 20px 40px;
    gap: 24px;
  }

  .hero-content h1 {
    font-size: 30px;
  }

  .hero-content p {
    font-size: 16px;
    margin-bottom: 0;
  }

  .hero-visual {
    display: none;
  }

  .try-section {
    padding: 12px 20px 56px;
  }

  .cta-try {
    width: 100%;
    padding: 18px 32px;
    font-size: 19px;
  }

  .swipe-overlay {
    padding: 20px 16px;
  }

  .swipe-close {
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
  }

  .swipe-heading {
    font-size: 20px;
    margin-bottom: 18px;
  }

  .swipe-deck {
    width: 100%;
    max-width: 320px;
    height: 56vh;
    max-height: 440px;
  }

  .swipe-card .swipe-card-title {
    font-size: 19px;
  }

  .swipe-card .swipe-card-desc {
    font-size: 13px;
  }

  .swipe-buttons {
    gap: 22px;
    margin-top: 22px;
  }

  .swipe-btn {
    width: 56px;
    height: 56px;
    font-size: 22px;
  }

  .match-card {
    padding-bottom: 24px;
  }

  .match-card-body {
    padding: 20px 24px 0;
  }

  .match-image {
    height: 140px;
  }

  .match-title {
    font-size: 23px;
  }

  .match-plan-title {
    font-size: 19px;
  }
}

@media (max-width: 340px) {
  .swipe-deck {
    height: 52vh;
  }
}

/* Botón "Probar" */
.try-section {
  flex: 0 0 auto;
  display: flex;
  justify-content: center;
  padding: 8px 24px 40px;
}

.cta-try {
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: var(--white);
  border: none;
  padding: 22px 64px;
  border-radius: 999px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: 0 16px 32px -10px rgba(0, 191, 51, 0.55);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-try:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 20px 36px -10px rgba(0, 191, 51, 0.65);
}

/* Overlay de swipe estilo Tinder */
.swipe-overlay {
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-2) 100%);
  z-index: 100;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.swipe-overlay.active {
  display: flex;
}

.swipe-close {
  position: absolute;
  top: 24px;
  right: 32px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--white);
  color: var(--ink-soft);
  font-size: 18px;
  cursor: pointer;
  box-shadow: 0 6px 16px -4px rgba(30, 45, 34, 0.2);
  transition: color 0.2s ease, transform 0.2s ease;
}

.swipe-close:hover {
  color: var(--brand-1);
  transform: scale(1.08);
}

.swipe-heading {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 28px;
  color: var(--ink);
}

.swipe-deck {
  position: relative;
  width: 320px;
  height: 440px;
  touch-action: none;
}

.swipe-card {
  position: absolute;
  inset: 0;
  background: var(--white);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 24px 48px -16px rgba(30, 45, 34, 0.28);
  display: flex;
  flex-direction: column;
  cursor: grab;
  user-select: none;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.35s ease;
  will-change: transform;
}

.swipe-card:active {
  cursor: grabbing;
}

.swipe-card .swipe-card-image {
  width: 100%;
  height: 66%;
  object-fit: cover;
  display: block;
  -webkit-user-drag: none;
}

.swipe-card .swipe-card-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
}

.swipe-card .swipe-card-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink);
  text-align: center;
}

.swipe-card .swipe-card-desc {
  font-size: 14px;
  color: var(--ink-soft);
  text-align: center;
}

.swipe-card .stamp {
  position: absolute;
  top: 36px;
  padding: 8px 18px;
  border: 4px solid;
  border-radius: 12px;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 1px;
  opacity: 0;
  transition: opacity 0.15s ease;
  text-transform: uppercase;
}

.stamp-like {
  left: 24px;
  color: var(--brand-1);
  border-color: var(--brand-1);
  transform: rotate(-14deg);
}

.stamp-nope {
  right: 24px;
  color: #E24A4A;
  border-color: #E24A4A;
  transform: rotate(14deg);
}

.swipe-buttons {
  display: flex;
  gap: 28px;
  margin-top: 32px;
}

.swipe-btn {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: none;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 12px 24px -8px rgba(30, 45, 34, 0.25);
  transition: transform 0.2s ease;
  background: var(--white);
}

.swipe-btn:hover {
  transform: translateY(-3px) scale(1.06);
}

.swipe-btn-no {
  color: #E24A4A;
}

.swipe-btn-yes {
  color: var(--brand-1);
}

/* Popup de match */
.match-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 45, 34, 0.55);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.match-overlay.active {
  display: flex;
}

.match-card {
  background: var(--white);
  border-radius: 28px;
  overflow: hidden;
  padding-bottom: 40px;
  max-width: 380px;
  width: 100%;
  text-align: center;
  box-shadow: 0 32px 64px -20px rgba(0, 0, 0, 0.4);
  animation: match-pop 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.match-card-body {
  padding: 24px 40px 0;
}

.match-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

@keyframes match-pop {
  from {
    opacity: 0;
    transform: scale(0.85);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.match-title {
  font-size: 28px;
  font-weight: 900;
  color: var(--brand-1);
  margin-bottom: 16px;
}

.match-plan-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 10px;
}

.match-plan-desc {
  font-size: 15px;
  color: var(--ink-soft);
  line-height: 1.5;
  margin-bottom: 28px;
}

.match-card .cta-primary {
  width: 100%;
}
