:root {
  --bg: #eef0f1;
  --panel: #ffffff;
  --ink: #14161c;
  --muted: #6b7280;
  --line: #e4e7ea;
  --green: #1a63f5;
  --green-2: #0f4cd2;
  --pink: #f2a8d8;
  --blue: #7cb0e0;
  --radius: 20px;
  --shadow: 0 24px 55px -34px rgba(15, 23, 42, 0.4);
  --shadow-sm: 0 14px 34px -24px rgba(15, 23, 42, 0.3);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}

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

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

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 13px 24px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.05s ease, box-shadow 0.2s ease, opacity 0.2s ease,
    background 0.2s ease;
  font-family: inherit;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--green), var(--green-2));
  color: #ffffff;
  box-shadow: 0 14px 26px -12px rgba(26, 99, 245, 0.58);
  animation: ctaGlow 3.6s ease-in-out infinite;
}

.btn-primary:hover {
  box-shadow: 0 18px 32px -12px rgba(26, 99, 245, 0.78);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-sm {
  padding: 9px 16px;
  font-size: 14px;
}

/* Header (floating pill) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  padding: 14px 0;
}

.nav-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 12px 9px 22px;
  box-shadow: 0 18px 40px -28px rgba(15, 23, 42, 0.4);
}

.nav-logo {
  display: inline-flex;
  align-items: center;
}

.logo {
  height: 26px;
  width: auto;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  transition: color 0.15s ease;
}

.nav-link:hover {
  color: var(--green-2);
}

/* Language selector (flag circles + dropdown) */
.flag {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  overflow: hidden;
  flex: 0 0 auto;
  display: inline-flex;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.12);
}

.flag img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lang-select {
  position: relative;
}

.lang-current {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.lang-current:hover {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(126, 194, 66, 0.14);
}

.lang-caret {
  color: var(--muted);
  transition: transform 0.18s ease;
}

.lang-select.open .lang-caret {
  transform: rotate(180deg);
}

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 170px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
  z-index: 40;
}

.lang-select.open .lang-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  transition: background 0.12s ease;
}

.lang-option:hover {
  background: #f1f5f9;
}

.lang-option.active {
  background: rgba(126, 194, 66, 0.16);
  color: var(--green-2);
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
}

.hero-decor {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.hero-wave {
  position: absolute;
  top: 40%;
  left: -2%;
  width: 104%;
  height: 300px;
  opacity: 0.95;
  animation: waveSway 9s ease-in-out infinite;
}

.hero-wave path {
  stroke: rgba(26, 99, 245, 0.38);
  stroke-dasharray: 2400;
  stroke-dashoffset: 2400;
  animation: waveDraw 2.6s ease forwards;
}

@keyframes ctaGlow {
  0%,
  100% {
    box-shadow: 0 14px 26px -12px rgba(26, 99, 245, 0.58);
  }
  50% {
    box-shadow: 0 22px 38px -14px rgba(26, 99, 245, 0.78);
  }
}

@keyframes waveDraw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes waveSway {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

.spark {
  position: absolute;
  display: block;
  animation: sparkFloat 6s ease-in-out infinite;
}

.spark svg {
  width: 100%;
  height: 100%;
  transform-origin: center;
  animation: twinkle 3.4s ease-in-out infinite;
}

@keyframes sparkFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

@keyframes twinkle {
  0%,
  100% {
    transform: scale(0.9) rotate(0deg);
    opacity: 0.75;
  }
  50% {
    transform: scale(1.2) rotate(18deg);
    opacity: 1;
  }
}

.spark-1 {
  width: 48px;
  height: 48px;
  top: 12%;
  left: 20%;
  animation-duration: 6.5s;
}

.spark-1 svg {
  animation-duration: 3.6s;
}

.spark-2 {
  width: 26px;
  height: 26px;
  top: 44%;
  right: 21%;
  animation-duration: 5.2s;
  animation-delay: -1.4s;
}

.spark-2 svg {
  animation-duration: 2.8s;
  animation-delay: -0.8s;
}

.spark-3 {
  width: 42px;
  height: 42px;
  top: 70%;
  right: 26%;
  animation-duration: 7.4s;
  animation-delay: -2.6s;
}

.spark-3 svg {
  animation-duration: 4.2s;
  animation-delay: -1.6s;
}

.dot {
  position: absolute;
  border-radius: 50%;
  animation: sparkFloat 5.5s ease-in-out infinite;
}

.dot-blue {
  width: 16px;
  height: 16px;
  background: var(--blue);
  top: 15%;
  right: 33%;
  animation-delay: -0.6s;
}

.dot-pink {
  width: 13px;
  height: 13px;
  background: var(--pink);
  top: 63%;
  left: 30%;
  animation-duration: 6.8s;
  animation-delay: -2.2s;
}

.hero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 780px;
  margin: 0 auto;
  padding: 66px 24px 92px;
}

.hero-inner::before,
.hero-inner::after {
  content: "";
  position: absolute;
  width: 52px;
  height: 52px;
  border: 2px dashed rgba(26, 99, 245, 0.22);
  border-radius: 50%;
  z-index: -1;
  animation: orbit 10s linear infinite;
}

.hero-inner::before {
  left: 14%;
  top: 26%;
}

.hero-inner::after {
  right: 14%;
  top: 48%;
  width: 42px;
  height: 42px;
  animation-duration: 7s;
  animation-direction: reverse;
}

@keyframes orbit {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 18px;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(38px, 7vw, 74px);
  line-height: 1.03;
  letter-spacing: -0.03em;
  font-weight: 800;
  color: var(--ink);
}

.hero p.lead {
  margin: 0 auto 30px;
  font-size: 17px;
  color: #4b5563;
  max-width: 560px;
}

/* Hero form */
.hero-form {
  max-width: 540px;
  margin: 0 auto;
  animation: friendCardIn 0.75s ease both;
}

@keyframes friendCardIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.form-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px;
}

.field {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.field input {
  flex: 1 1 220px;
  min-width: 0;
  padding: 14px 18px;
  border: 1px solid #d6dde4;
  border-radius: 999px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(126, 194, 66, 0.18);
}

.form-note {
  margin: 12px 4px 0;
  font-size: 12.5px;
  color: var(--muted);
}

.form-msg {
  margin-top: 12px;
  font-size: 14px;
  font-weight: 600;
  display: none;
}

.form-msg.error {
  display: block;
  color: #c0392b;
}

/* Promo result */
.promo-result {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.promo-result.show {
  display: flex;
}

.promo-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 10px 10px 18px;
  box-shadow: var(--shadow-sm);
}

.promo-pill-label {
  color: var(--muted);
  font-size: 14px;
}

.promo-code {
  font-weight: 800;
  color: var(--green-2);
  letter-spacing: 0.05em;
  font-size: 15px;
}

.promo-copy {
  border: 0;
  background: transparent;
  cursor: pointer;
  color: var(--muted);
  display: inline-flex;
  padding: 6px;
  border-radius: 8px;
  transition: background 0.12s ease, color 0.12s ease;
}

.promo-copy:hover {
  color: var(--ink);
  background: #f1f5f9;
}

/* Scroll hint */
.scroll-hint {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  padding-bottom: 26px;
  color: #9aa3ad;
}

/* Sections */
section.block {
  padding: 78px 0;
}

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 48px;
}

.section-head h2 {
  margin: 0 0 10px;
  font-size: clamp(26px, 3.4vw, 38px);
  letter-spacing: -0.02em;
  font-weight: 800;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  max-width: 920px;
  margin: 0 auto;
}

.step {
  text-align: center;
}

.step-num {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 20px;
  color: #fff;
  background: linear-gradient(135deg, var(--green), var(--green-2));
  margin: 0 auto 18px;
  box-shadow: 0 14px 26px -12px rgba(26, 99, 245, 0.72);
  animation: popPulse 2.8s ease-in-out infinite;
}

@keyframes popPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.07);
  }
}

.step-num .step-spark {
  position: absolute;
  top: -8px;
  right: -12px;
  width: 20px;
  height: 20px;
}

.step h3 {
  margin: 0 0 8px;
  font-size: 17px;
}

.step p {
  margin: 0 auto;
  color: var(--muted);
  font-size: 14.5px;
  max-width: 270px;
}

/* Events */
.events-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.event-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  animation: cardFloatIn 0.65s ease both;
}

.events-grid .event-card:nth-child(2n) {
  animation-delay: 0.08s;
}

.events-grid .event-card:nth-child(3n) {
  animation-delay: 0.14s;
}

@keyframes cardFloatIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.event-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 46px -26px rgba(15, 23, 42, 0.4);
}

.event-media {
  aspect-ratio: 16 / 9;
  margin: 10px 10px 0;
  border-radius: 14px;
  overflow: hidden;
  background: #e9eef2;
  position: relative;
}

.event-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-body {
  padding: 16px 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.event-name {
  font-size: 16.5px;
  font-weight: 700;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.event-meta {
  font-size: 13.5px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.event-meta span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.event-meta svg {
  flex: 0 0 auto;
  color: #9aa3ad;
}

.event-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.badge-cat,
.badge-disc {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
}

.badge-cat {
  background: #eaf1ff;
  color: #3b6fd4;
}

.badge-disc {
  background: #e8f0ff;
  color: var(--green-2);
}

.events-status {
  text-align: center;
  color: var(--muted);
  padding: 30px 0;
  font-size: 15px;
}

/* Footer */
.site-footer {
  background: #fff;
  border-top: 1px solid var(--line);
  padding: 56px 0 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 34px;
}

.footer-logo {
  height: 26px;
  margin-bottom: 16px;
}

.footer-tag {
  color: var(--muted);
  font-size: 13.5px;
  max-width: 340px;
  margin: 0 0 14px;
}

.footer-tag:last-child {
  margin-bottom: 0;
}

.footer-col-arrow a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-col-arrow a::after {
  content: "›";
  color: #b5bcc4;
  font-size: 16px;
  line-height: 1;
  font-weight: 600;
}

.footer-col h4 {
  margin: 0 0 16px;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}

.footer-col a {
  display: block;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 11px;
  transition: color 0.12s ease;
}

.footer-col a:hover {
  color: var(--green-2);
}

.footer-copy {
  text-align: center;
  margin-top: 36px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: #9aa3ad;
  font-size: 12.5px;
}

/* Back to top */
.to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 0;
  background: linear-gradient(135deg, var(--green), var(--green-2));
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 14px 30px -12px rgba(26, 99, 245, 0.82);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.15s ease;
  z-index: 50;
}

.to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

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

@media (prefers-reduced-motion: reduce) {
  .hero-wave,
  .hero-wave path,
  .spark,
  .spark svg,
  .dot,
  .hero-inner::before,
  .hero-inner::after,
  .hero-form,
  .step-num,
  .event-card,
  .btn-primary {
    animation: none !important;
  }
  .hero-wave path {
    stroke-dashoffset: 0;
  }
}

/* Responsive */
@media (max-width: 900px) {
  .hero h1 {
    font-size: clamp(34px, 9vw, 52px);
  }
  .steps {
    grid-template-columns: 1fr;
    gap: 34px;
    max-width: 420px;
  }
  .events-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 620px) {
  .container {
    padding: 0 16px;
  }
  .nav-pill {
    padding: 8px 10px 8px 16px;
    gap: 10px;
  }
  .nav-menu {
    gap: 12px;
  }
  .nav-link {
    display: none;
  }
  .logo {
    height: 22px;
  }
  .lang-current .lang-label {
    display: none;
  }
  .lang-current {
    padding: 6px 8px;
  }
  .hero-inner {
    padding: 40px 16px 64px;
  }
  .eyebrow {
    margin-bottom: 14px;
  }
  .hero p.lead {
    font-size: 15.5px;
    margin-bottom: 24px;
  }
  .hero-wave {
    top: 46%;
  }
  section.block {
    padding: 56px 0;
  }
  .section-head {
    margin-bottom: 34px;
  }
  .events-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .form-card {
    padding: 18px;
  }
  .field input {
    flex-basis: 100%;
  }
  .field .btn {
    width: 100%;
  }
  .promo-pill {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .to-top {
    right: 16px;
    bottom: 16px;
  }
}
