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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #fdf8f5;
  color: #1a1f2e;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow-x: hidden;
  position: relative;
  padding: 20px;
}

/* background layers */
.bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 10%, rgba(232, 117, 106, .12) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 80%, rgba(91, 140, 184, .10) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 50% 50%, rgba(232, 164, 184, .08) 0%, transparent 50%),
    #fdf8f5;
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: .3;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.04'/%3E%3C/svg%3E");
}

.ambient-orbs {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.ambient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: .5;
  animation: orbFloat 20s ease-in-out infinite;
}

.ambient-orb:nth-child(1) {
  width: 500px;
  height: 500px;
  top: -15%;
  left: -10%;
  background: radial-gradient(circle, rgba(232, 117, 106, .18), transparent 70%);
}

.ambient-orb:nth-child(2) {
  width: 400px;
  height: 400px;
  bottom: -10%;
  right: -5%;
  background: radial-gradient(circle, rgba(91, 140, 184, .15), transparent 70%);
  animation-delay: -7s;
}

.ambient-orb:nth-child(3) {
  width: 300px;
  height: 300px;
  top: 40%;
  left: 50%;
  background: radial-gradient(circle, rgba(232, 164, 184, .12), transparent 70%);
  animation-delay: -14s;
}

@keyframes orbFloat {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(30px, -20px) scale(1.05);
  }
  66% {
    transform: translate(-20px, 15px) scale(.95);
  }
}

/* main content */
.prelaunch {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 680px;
  padding: 40px 24px;
  text-align: center;
  animation: fadeInUp .8s ease-out;
}

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

.prelaunch-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: fit-content;
  margin: 0 auto 40px;
}

.prelaunch-logo svg {
  width: 36px;
  height: 36px;
  color: #e8756a;
}

.prelaunch-logo span {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 24px;
  font-weight: 400;
  color: #1a1f2e;
  letter-spacing: -0.01em;
}

.prelaunch-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(232, 117, 106, .08);
  border: 1px solid rgba(232, 117, 106, .15);
  border-radius: 100px;
  padding: 8px 20px;
  font-size: 13px;
  font-weight: 500;
  color: #d4615a;
  width: fit-content;
  margin: 0 auto 28px;
  animation: fadeInUp .8s ease-out .1s both;
}

.prelaunch-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e8756a;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: .5;
    transform: scale(.8);
  }
}

.prelaunch h1 {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(32px, 6vw, 52px);
  font-weight: 400;
  line-height: 1.15;
  color: #1a1f2e;
  margin-bottom: 18px;
  letter-spacing: -0.02em;
  animation: fadeInUp .8s ease-out .2s both;
}

.prelaunch-sub {
  font-size: clamp(16px, 2.5vw, 19px);
  color: #4a5568;
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto 36px;
  animation: fadeInUp .8s ease-out .3s both;
}

/* form */
.email-form {
  display: flex;
  gap: 10px;
  max-width: 460px;
  margin: 0 auto 20px;
  animation: fadeInUp .8s ease-out .4s both;
}

.email-form input[type="email"] {
  flex: 1;
  padding: 14px 18px;
  border: 1.5px solid rgba(0, 0, 0, .06);
  border-radius: 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  background: #fff;
  color: #1a1f2e;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

.email-form input::placeholder {
  color: #8896a8;
}

.email-form input:focus {
  border-color: #e8756a;
  box-shadow: 0 0 0 3px rgba(232, 117, 106, .1);
}

.email-form input.invalid {
  border-color: #e8756a;
  box-shadow: 0 0 0 3px rgba(232, 117, 106, .15);
}

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

.email-form button {
  padding: 14px 28px;
  background: #e8756a;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, transform .15s, box-shadow .2s;
  white-space: nowrap;
}

.email-form button:hover {
  background: #d4615a;
  transform: translateY(-1px);
  box-shadow: 0 8px 32px rgba(232, 117, 106, .25);
}

.email-form button:active {
  transform: translateY(0);
}

.email-form button:disabled {
  opacity: .7;
  cursor: not-allowed;
  transform: none;
}

.email-success,
.email-error {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  max-width: 460px;
  margin: 0 auto 20px;
  animation: fadeInUp .4s ease-out;
}

.email-success {
  background: rgba(34, 197, 94, .08);
  border: 1px solid rgba(34, 197, 94, .2);
  color: #16a34a;
}

.email-error {
  background: rgba(232, 117, 106, .08);
  border: 1px solid rgba(232, 117, 106, .25);
  color: #c0392b;
}

.email-success.show,
.email-error.show {
  display: flex;
}

.email-success svg,
.email-error svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* trust */
.trust-row {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 40px;
  animation: fadeInUp .8s ease-out .5s both;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #4a5568;
  font-weight: 500;
}

.trust-item svg {
  width: 15px;
  height: 15px;
  color: #e8756a;
  opacity: .7;
}

/* features */
.features-preview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: 560px;
  margin: 0 auto;
  animation: fadeInUp .8s ease-out .6s both;
}

.feature-card {
  background: rgba(255, 255, 255, .6);
  backdrop-filter: blur(2px);
  border: 1px solid rgba(0, 0, 0, .04);
  border-radius: 20px;
  padding: 24px 12px;
  transition: transform .2s, box-shadow .2s, background .2s;
}

.feature-card:hover {
  transform: translateY(-3px);
  background: #ffffff;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .06), 0 4px 12px rgba(0, 0, 0, .02);
}

.feature-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
}

.feature-card-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card-icon.coral {
  background: rgba(232, 117, 106, .12);
  color: #e8756a;
}

.feature-card-icon.blue {
  background: rgba(91, 140, 184, .12);
  color: #5b8cb8;
}

.feature-card-icon.green {
  background: rgba(34, 197, 94, .12);
  color: #22c55e;
}

.feature-card h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
  color: #1a1f2e;
}

.feature-card p {
  font-size: 12px;
  color: #4a5568;
  line-height: 1.5;
}

/* footer */
.prelaunch-footer {
  margin-top: 48px;
  font-size: 13px;
  color: #8896a8;
  animation: fadeInUp .8s ease-out .7s both;
}

/* ============================================================
   TABLET (768px - 1023px)
   ============================================================ */
@media (max-width: 1023px) and (min-width: 768px) {
  body {
    padding: 16px;
  }

  .prelaunch {
    padding: 32px 20px;
    max-width: 640px;
  }

  .prelaunch-logo {
    margin-bottom: 32px;
  }

  .prelaunch-logo svg {
    width: 32px;
    height: 32px;
  }

  .prelaunch-logo span {
    font-size: 22px;
  }

  .prelaunch-badge {
    padding: 7px 18px;
    font-size: 12px;
    margin-bottom: 24px;
  }

  .prelaunch h1 {
    font-size: clamp(28px, 5vw, 42px);
    margin-bottom: 16px;
  }

  .prelaunch-sub {
    font-size: clamp(15px, 2.2vw, 17px);
    margin-bottom: 28px;
    max-width: 440px;
  }

  .email-form {
    max-width: 420px;
    gap: 8px;
  }

  .email-form input[type="email"] {
    padding: 12px 16px;
    font-size: 14px;
  }

  .email-form button {
    padding: 12px 24px;
    font-size: 14px;
  }

  .email-success,
  .email-error {
    max-width: 420px;
    padding: 12px 18px;
    font-size: 14px;
  }

  .trust-row {
    gap: 20px;
    margin-bottom: 32px;
  }

  .trust-item {
    font-size: 12px;
  }

  .features-preview {
    max-width: 480px;
    gap: 12px;
  }

  .feature-card {
    padding: 20px 10px;
    border-radius: 16px;
  }

  .feature-card-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }

  .feature-card-icon svg {
    width: 20px;
    height: 20px;
  }

  .feature-card h3 {
    font-size: 13px;
  }

  .feature-card p {
    font-size: 11px;
  }

  .prelaunch-footer {
    margin-top: 36px;
    font-size: 12px;
  }

  /* ambient orbs - slightly smaller */
  .ambient-orb:nth-child(1) {
    width: 400px;
    height: 400px;
  }

  .ambient-orb:nth-child(2) {
    width: 320px;
    height: 320px;
  }

  .ambient-orb:nth-child(3) {
    width: 240px;
    height: 240px;
  }
}

/* ============================================================
   MOBILE (up to 767px)
   ============================================================ */
@media (max-width: 767px) {
  body {
    padding: 12px;
    justify-content: flex-start;
    min-height: 100dvh;
  }

  .prelaunch {
    padding: 24px 16px;
    max-width: 100%;
  }

  .prelaunch-logo {
    margin-bottom: 24px;
    gap: 8px;
  }

  .prelaunch-logo svg {
    width: 28px;
    height: 28px;
  }

  .prelaunch-logo span {
    font-size: 20px;
  }

  .prelaunch-badge {
    padding: 6px 16px;
    font-size: 12px;
    margin-bottom: 20px;
    gap: 6px;
  }

  .prelaunch-badge .dot {
    width: 6px;
    height: 6px;
  }

  .prelaunch h1 {
    font-size: clamp(26px, 8vw, 36px);
    line-height: 1.2;
    margin-bottom: 14px;
  }

  .prelaunch-sub {
    font-size: clamp(14px, 4vw, 16px);
    line-height: 1.55;
    margin-bottom: 24px;
    max-width: 100%;
  }

  .email-form {
    flex-direction: column;
    max-width: 100%;
    gap: 10px;
  }

  .email-form input[type="email"] {
    width: 100%;
    padding: 14px 16px;
    font-size: 16px; /* prevents iOS zoom */
    border-radius: 14px;
  }

  .email-form button {
    width: 100%;
    padding: 14px;
    font-size: 15px;
    border-radius: 14px;
  }

  .email-success,
  .email-error {
    max-width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    border-radius: 14px;
  }

  .trust-row {
    gap: 12px;
    margin-bottom: 28px;
  }

  .trust-item {
    font-size: 12px;
    gap: 5px;
  }

  .trust-item svg {
    width: 14px;
    height: 14px;
  }

  .features-preview {
    grid-template-columns: 1fr;
    max-width: 100%;
    gap: 12px;
    margin: 0 auto;
  }

  .feature-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    text-align: left;
    border-radius: 16px;
  }

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

  .feature-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    margin: 0;
    flex-shrink: 0;
  }

  .feature-card-icon svg {
    width: 20px;
    height: 20px;
  }

  .feature-card h3 {
    font-size: 14px;
    margin-bottom: 2px;
  }

  .feature-card p {
    font-size: 12px;
    line-height: 1.45;
  }

  .prelaunch-footer {
    margin-top: 32px;
    font-size: 12px;
    line-height: 1.5;
  }

  /* ambient orbs - much smaller on mobile */
  .ambient-orb:nth-child(1) {
    width: 280px;
    height: 280px;
    top: -10%;
    left: -15%;
  }

  .ambient-orb:nth-child(2) {
    width: 220px;
    height: 220px;
    bottom: -5%;
    right: -10%;
  }

  .ambient-orb:nth-child(3) {
    width: 180px;
    height: 180px;
    top: 50%;
    left: 40%;
  }
}

/* ============================================================
   SMALL MOBILE (up to 374px)
   ============================================================ */
@media (max-width: 374px) {
  body {
    padding: 8px;
  }

  .prelaunch {
    padding: 20px 12px;
  }

  .prelaunch-logo span {
    font-size: 18px;
  }

  .prelaunch h1 {
    font-size: 24px;
  }

  .prelaunch-sub {
    font-size: 13px;
  }

  .prelaunch-badge {
    padding: 5px 14px;
    font-size: 11px;
  }

  .feature-card {
    padding: 14px 14px;
    gap: 12px;
  }

  .feature-card-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
  }

  .feature-card-icon svg {
    width: 18px;
    height: 18px;
  }

  .feature-card h3 {
    font-size: 13px;
  }

  .feature-card p {
    font-size: 11px;
  }

  .trust-row {
    gap: 10px;
  }

  .trust-item {
    font-size: 11px;
  }
}