/* Rnai.io landing pages — shared styles (dark + terracotta brand) */
:root { --accent: #D77757; }
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: "Outfit", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #050505; color: #e8e8ea; line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 24px; backdrop-filter: blur(14px);
  background: rgba(5,5,5,.6); border-bottom: 1px solid rgba(255,255,255,.06);
}
.brand { font-weight: 800; font-size: 20px; letter-spacing: -.02em; }
.brand span { color: var(--accent); }
.nav-cta {
  font-size: 14px; font-weight: 600; color: #cfcfd4;
  padding: 8px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.12);
  transition: all .2s;
}
.nav-cta:hover { color: #fff; background: rgba(255,255,255,.06); }

/* Hero */
.hero {
  position: relative; overflow: hidden; text-align: center;
  padding: 52px 24px 32px; max-width: 900px; margin: 0 auto;
}
.hero-compact { padding-top: 40px; padding-bottom: 16px; }
.hero-compact h1 { font-size: clamp(30px, 5vw, 46px); margin: 6px 0 10px; }
.hero-glow {
  position: absolute; top: -120px; left: 50%; transform: translateX(-50%);
  width: 620px; height: 620px; border-radius: 50%;
  background: var(--accent); opacity: .16; filter: blur(140px);
  pointer-events: none; z-index: 0;
}
.hero > *:not(.hero-glow) { position: relative; z-index: 1; }
.app-icon {
  width: 104px; height: 104px; border-radius: 28px; margin: 0 auto 20px;
  display: flex; align-items: center; justify-content: center; font-size: 56px;
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  box-shadow: 0 20px 60px color-mix(in srgb, var(--accent) 25%, transparent);
}
.app-icon.sm { width: 60px; height: 60px; border-radius: 16px; font-size: 30px; margin: 0; }
.hero h1 {
  font-size: clamp(34px, 6vw, 58px); font-weight: 800; letter-spacing: -.03em; margin: 8px 0 12px;
  background: linear-gradient(135deg, #fff, #F0CBB6 60%, var(--accent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.tagline { color: #a9a9b2; font-size: clamp(15px, 2.4vw, 19px); max-width: 620px; margin: 0 auto; }
.badges { display: flex; gap: 8px; justify-content: center; margin-bottom: 8px; }
.badge {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  padding: 5px 12px; border-radius: 999px; color: #cfcfd4;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1);
}
.badge.accent {
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
}
.cta-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 28px; }
.btn {
  padding: 14px 28px; border-radius: 14px; font-weight: 700; font-size: 15px;
  transition: transform .2s, opacity .2s, background .2s;
}
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 10px 30px color-mix(in srgb, var(--accent) 30%, transparent); }
.btn.primary:hover { transform: translateY(-2px); opacity: .95; }
.btn.ghost { background: rgba(255,255,255,.06); color: #fff; border: 1px solid rgba(255,255,255,.12); }
.btn.ghost:hover { background: rgba(255,255,255,.12); }
.btn.web {
  background: color-mix(in srgb, var(--accent) 14%, transparent); color: #fff;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
}
.btn.web:hover { background: color-mix(in srgb, var(--accent) 26%, transparent); transform: translateY(-2px); }

/* Features */
.features {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px; max-width: 980px; margin: 40px auto; padding: 0 24px;
}
.feat {
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.06);
  border-radius: 20px; padding: 26px; transition: transform .3s, border-color .3s;
}
.feat:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--accent) 35%, transparent); }
.feat-ic {
  width: 48px; height: 48px; border-radius: 14px; font-size: 24px; margin-bottom: 14px;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--accent) 15%, transparent);
}
.feat h3 { font-size: 17px; font-weight: 700; margin-bottom: 6px; }
.feat p { color: #9a9aa2; font-size: 14px; }

/* Notify form */
.notify { padding: 30px 24px 70px; max-width: 640px; margin: 0 auto; }
.notify-card {
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.08);
  border-radius: 24px; padding: 36px; text-align: center;
}
.notify-card h2 { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.notify-card p { color: #9a9aa2; font-size: 15px; margin-bottom: 22px; }
.form-row { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.form-row input[type=email] {
  flex: 1; min-width: 220px; padding: 14px 18px; border-radius: 12px; font-size: 15px;
  background: rgba(0,0,0,.4); border: 1px solid rgba(255,255,255,.12); color: #fff;
}
.form-row input[type=email]:focus { outline: none; border-color: var(--accent); }
.form-row button {
  padding: 14px 26px; border-radius: 12px; border: none; cursor: pointer;
  font-weight: 700; font-size: 15px; background: var(--accent); color: #fff; transition: opacity .2s;
}
.form-row button:hover { opacity: .9; }
.hp { position: absolute; left: -9999px; }

/* Hub grid */
.hub-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px; max-width: 1000px; margin: 30px auto 70px; padding: 0 24px;
}
.hub-card {
  display: flex; gap: 18px; align-items: flex-start;
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.06);
  border-radius: 20px; padding: 24px; transition: transform .3s, border-color .3s;
}
.hub-card:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
.hub-card h3 { font-size: 19px; font-weight: 700; margin-bottom: 4px; }
.hub-card p { color: #9a9aa2; font-size: 14px; margin-bottom: 10px; }

/* Footer */
footer { border-top: 1px solid rgba(255,255,255,.06); padding: 28px 24px; text-align: center; }
footer p { color: #7c7c85; font-size: 13px; }
footer a { color: var(--accent); }

/* ── Animations ── */
@keyframes fadeUp { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 10px 30px color-mix(in srgb, var(--accent) 28%, transparent); }
  50% { box-shadow: 0 16px 48px color-mix(in srgb, var(--accent) 50%, transparent); }
}
@keyframes glowDrift { 0%, 100% { opacity: .12; transform: translateX(-50%) scale(1); } 50% { opacity: .22; transform: translateX(-50%) scale(1.12); } }
@keyframes shine { 0% { left: -60%; } 60%, 100% { left: 140%; } }

/* Hero entrance (staggered) */
.hero .badges { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both; }
.hero h1 { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) .08s both; }
.hero .tagline { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) .16s both; }
.hero .cta-row { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) .24s both; }
.app-icon { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both, floaty 5s ease-in-out 1s infinite; }
.hero-glow { animation: glowDrift 8s ease-in-out infinite; }

/* Features reveal (staggered) */
.feat { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both; }
.features .feat:nth-child(2) { animation-delay: .1s; }
.features .feat:nth-child(3) { animation-delay: .2s; }
.notify-card { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) .1s both; }

/* Primary button: living glow + shine sweep */
.btn.primary { position: relative; overflow: hidden; animation: pulseGlow 3.5s ease-in-out infinite; }
.btn.primary::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.35), transparent);
  transform: skewX(-18deg); animation: shine 4s ease-in-out infinite;
}

/* Hub cards entrance */
.hub-card { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both; }
.hub-grid .hub-card:nth-child(2) { animation-delay: .07s; }
.hub-grid .hub-card:nth-child(3) { animation-delay: .14s; }
.hub-grid .hub-card:nth-child(4) { animation-delay: .21s; }
.hub-grid .hub-card:nth-child(5) { animation-delay: .28s; }

/* ── Real app icons ── */
.app-icon img { width: 74%; height: 74%; object-fit: contain; border-radius: 20px; }
.app-icon.sm { overflow: hidden; }
.app-icon.sm img { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; }

/* ── Device mockup showcase ── */
.showcase { display: flex; justify-content: center; padding: 24px 24px 8px; }
.phone {
  position: relative; width: 244px; height: 496px; border-radius: 46px; padding: 14px;
  background: linear-gradient(160deg, #1b1b20, #0c0c0e);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 34px 90px rgba(0,0,0,.6), 0 0 70px color-mix(in srgb, var(--accent) 22%, transparent);
  animation: floaty 6s ease-in-out infinite;
}
.phone-cam {
  position: absolute; top: 18px; left: 50%; transform: translateX(-50%);
  width: 64px; height: 7px; border-radius: 999px; background: rgba(255,255,255,.16); z-index: 2;
}
.phone-screen {
  width: 100%; height: 100%; border-radius: 34px; padding: 26px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; gap: 12px;
  background: radial-gradient(circle at 50% 28%, color-mix(in srgb, var(--accent) 38%, #0c0c0e), #0a0a0c 74%);
}
.screen-icon { width: 100px; height: 100px; border-radius: 26px; box-shadow: 0 14px 34px rgba(0,0,0,.55); }
.screen-name { font-weight: 800; font-size: 21px; color: #fff; }
.screen-tag { font-size: 13px; color: #cfcfd6; }
.screen-btn {
  margin-top: 6px; padding: 10px 24px; border-radius: 999px; font-size: 13px; font-weight: 700;
  background: var(--accent); color: #fff; box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 40%, transparent);
}

/* ── Real screenshot inside phone mockup ── */
.phone.shot .phone-screen { padding: 0; overflow: hidden; }
.screen-shot { width: 100%; height: 100%; object-fit: cover; border-radius: 34px; }

/* ── Screenshot gallery ── */
.gallery { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; padding: 4px 24px 24px; max-width: 900px; margin: 0 auto; }
.gallery img {
  width: 150px; border-radius: 18px; border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 14px 30px rgba(0,0,0,.45); transition: transform .3s, box-shadow .3s;
}
.gallery img:hover {
  transform: translateY(-6px) scale(1.04);
  box-shadow: 0 18px 42px color-mix(in srgb, var(--accent) 42%, transparent);
}

/* ── App logo showcase (clickable, in hero) ── */
.applogos { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; margin-top: 28px; }
.applogos a {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: 88px; text-align: center; animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both;
}
.applogos a:nth-child(2){animation-delay:.06s}
.applogos a:nth-child(3){animation-delay:.12s}
.applogos a:nth-child(4){animation-delay:.18s}
.applogos a:nth-child(5){animation-delay:.24s}
.applogos img {
  width: 70px; height: 70px; border-radius: 18px; object-fit: cover;
  border: 1px solid rgba(255,255,255,.1); box-shadow: 0 8px 24px rgba(0,0,0,.4);
  transition: transform .3s, box-shadow .3s, border-color .3s;
}
.applogos a:hover img {
  transform: translateY(-6px) scale(1.07);
  box-shadow: 0 14px 32px color-mix(in srgb, var(--accent) 45%, transparent);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
}
.applogos span { font-size: 12px; font-weight: 600; color: #b9b9c0; transition: color .3s; }
.applogos a:hover span { color: #fff; }

/* ── Continuous running marquee ── */
.marquee {
  position: relative; width: 100%; overflow: hidden; padding: 6px 0 8px; margin: -6px 0 8px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
}
.marquee-track { display: flex; gap: 20px; width: max-content; animation: marquee 28s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.mq { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 104px; text-align: center; flex: 0 0 auto; }
.mq img {
  width: 78px; height: 78px; border-radius: 20px; object-fit: cover;
  border: 1px solid rgba(255,255,255,.1); box-shadow: 0 10px 26px rgba(0,0,0,.45);
  transition: transform .3s, box-shadow .3s, border-color .3s;
}
.mq:hover img {
  transform: translateY(-6px) scale(1.07);
  box-shadow: 0 16px 36px color-mix(in srgb, var(--accent) 48%, transparent);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
}
.mq span { font-size: 12px; font-weight: 600; color: #b9b9c0; transition: color .3s; }
.mq:hover span { color: #fff; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; }
  .marquee-track { flex-wrap: wrap; justify-content: center; }
}
