/* ==========================================================================
   ameloora.com — Meloora official website
   Design tokens first, then layout, then components, then responsive.
   No external dependencies: system fonts only, all artwork is CSS or inline SVG.
   ========================================================================== */

/* ---------- 1. Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: #FFFFFF;
  color: #17161A;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, "Noto Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* `clip` rather than `hidden`: it contains stray decoration without turning
     <body> into a scroll container, which would break the sticky header in
     older Safari. Browsers without `clip` support fall back to the decorative
     blobs already being clipped by .hero { overflow: hidden }. */
  overflow-x: clip;
}

h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
em { font-style: normal; }

/* ---------- 2. Tokens ---------- */
:root {
  --red: #DB2B21;
  --red-dark: #BE1F16;
  --red-deep: #96160F;
  --red-050: #FFF6F5;
  --red-100: #FDE9E7;
  --red-200: #F8CFCB;
  --red-glow: rgba(219, 43, 33, 0.32);

  --ink: #17161A;
  --ink-2: #55535F;
  --ink-3: #7E7C89;
  --line: rgba(23, 22, 26, 0.10);
  --line-strong: rgba(23, 22, 26, 0.16);

  --surface: #FFFFFF;
  --surface-tint: #FFF9F8;
  --surface-sunk: #FBF6F5;

  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --r-xl: 30px;

  --shadow-sm: 0 2px 8px rgba(23, 22, 26, 0.05);
  --shadow-md: 0 12px 30px rgba(23, 22, 26, 0.08);
  --shadow-lg: 0 30px 70px rgba(23, 22, 26, 0.14);
  --shadow-red: 0 14px 30px rgba(219, 43, 33, 0.26);

  --wrap: 1140px;
  --header-h: 70px;
}

/* ---------- 3. Layout ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}
.wrap--narrow { max-width: 860px; }

.section { padding: 54px 0; }
.section__head { max-width: 720px; margin-bottom: 36px; }

.section__title {
  font-size: 30px;
  font-size: clamp(1.7rem, 3.4vw, 2.55rem);
  line-height: 1.16;
  letter-spacing: -0.022em;
  font-weight: 800;
  margin-top: 12px;
  text-wrap: balance;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
}
.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
}

/* ---------- 4. Focus & a11y ---------- */
a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
  border-radius: 6px;
}
a:focus,
button:focus,
summary:focus { outline: 3px solid var(--red); outline-offset: 3px; }
a:focus:not(:focus-visible),
button:focus:not(:focus-visible),
summary:focus:not(:focus-visible) { outline: none; }

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 12px 20px;
  background: var(--ink);
  color: #fff;
  border-radius: 0 0 var(--r-sm) var(--r-sm);
  font-weight: 600;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 0; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- 5. Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 14px 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease,
    background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
  -webkit-appearance: none;
  appearance: none;
  text-align: left;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

/* Spacing between the Play icon and its label is done with a margin on the
   label rather than `gap`, so buttons keep their layout in browsers that do
   not support flexbox gap (Safari < 14.1). */
.btn .play-icon + .btn__stack,
.btn .play-icon + .btn__label { margin-left: 12px; }
.btn--noIcon .play-icon { display: none; }
.btn--noIcon .play-icon + .btn__stack,
.btn--noIcon .play-icon + .btn__label { margin-left: 0; }
.btn--noIcon { padding-left: 26px; }

/* Google Play button — icon supplied by www.gstatic.com, text styled locally */
.btn--play {
  background: #0B0B0F;
  color: #FFFFFF;
  padding: 13px 26px 13px 22px;
  box-shadow: var(--shadow-md);
}
.btn--play:hover { background: #1C1C22; box-shadow: var(--shadow-lg); }
.btn--playOnLight { background: var(--ink); }

.play-icon {
  width: auto;
  height: 28px;
  flex: none;
}

.btn__stack { display: flex; flex-direction: column; line-height: 1.1; }
.btn__small {
  font-size: 10px;
  letter-spacing: 0.12em;
  font-weight: 600;
  opacity: 0.8;
  text-transform: uppercase;
}
.btn__big { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }

.btn--sm { padding: 10px 18px 10px 14px; }
.btn--sm .play-icon { height: 20px; }
.btn--sm .btn__label { font-size: 14px; font-weight: 600; }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost:hover {
  background: #fff;
  border-color: var(--ink);
  box-shadow: var(--shadow-sm);
}

/* ---------- 6. Header ---------- */
.site-header {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
}
.site-header.is-stuck { box-shadow: 0 6px 24px rgba(23, 22, 26, 0.06); }
@supports ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
  .site-header {
    background: rgba(255, 255, 255, 0.74);
    -webkit-backdrop-filter: blur(16px) saturate(1.6);
    backdrop-filter: blur(16px) saturate(1.6);
  }
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: var(--header-h);
}

.brand { display: inline-flex; align-items: center; gap: 11px; }
.brand__mark { display: block; flex: none; line-height: 0; border-radius: 10px; }
.brand__mark svg { border-radius: 10px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.028em;
}
.brand__sub {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ---------- 7. Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 46px 0 52px;
  background:
    radial-gradient(1200px 620px at 78% -6%, #FFE9E6 0%, rgba(255, 233, 230, 0) 62%),
    linear-gradient(180deg, #FFFBFA 0%, #FFFFFF 74%);
}
.hero__glow {
  position: absolute;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.45;
  pointer-events: none;
  background: radial-gradient(circle, rgba(219, 43, 33, 0.16), rgba(219, 43, 33, 0) 68%);
  left: -140px;
  top: 40px;
}
.hero__glow--b { left: auto; right: -160px; top: 260px; opacity: 0.38; }

.hero__inner { position: relative; }

.hero__copy { max-width: 620px; }

.hero__title {
  font-size: 42px;
  font-size: clamp(2.35rem, 6.2vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  font-weight: 800;
  margin: 18px 0 0;
}
.hero__title span { display: block; }
.hero__title em { display: block; color: var(--red); }

.hero__lead {
  margin-top: 22px;
  font-size: 18px;
  color: var(--ink-2);
  max-width: 56ch;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 30px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
}
.tick {
  position: relative;
  width: 18px;
  height: 18px;
  flex: none;
  border-radius: 50%;
  background: var(--red-100);
}
.tick::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 5.5px;
  width: 7px;
  height: 4px;
  border-left: 2px solid var(--red);
  border-bottom: 2px solid var(--red);
  -webkit-transform: rotate(-45deg);
  transform: rotate(-45deg);
}

.hero__art { position: relative; margin-top: 46px; }

/* Floating chips layered over the phone — decorative only */
.floaty {
  position: absolute;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 1px;
  max-width: 190px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-md);
  pointer-events: none;
}
.floaty__k { font-size: 13px; font-weight: 800; letter-spacing: -0.014em; }
.floaty__v { font-size: 11.5px; color: var(--ink-3); }
/* Positioned to overlap the album artwork so they never cover UI text */
.floaty--a { left: 0; top: 20%; }
.floaty--b { right: 0; top: 49%; }
.floaty--b .floaty__k { color: var(--red); }

/* Two-column hero once there is room for it */
@media (min-width: 961px) {
  .hero { padding: 54px 0 62px; }
  .hero__inner {
    display: grid;
    grid-template-columns: 1.06fr 0.94fr;
    gap: 40px;
    align-items: center;
  }
  .hero__copy { max-width: none; }
  .hero__art { margin-top: 0; padding: 0 12px; }
  .phone--hero { max-width: 292px; }
  .hero__glow--b { right: -120px; top: 120px; }
}
@media (max-width: 720px) {
  .floaty { display: none; }
}

/* ---------- 8. Phone mockups (CSS only) ---------- */
.phone { display: flex; justify-content: center; }
.phone--hero { max-width: 288px; margin: 0 auto; }

.phone__frame {
  position: relative;
  width: 100%;
  padding: 12px;
  border-radius: 44px;
  background: linear-gradient(160deg, #2A2933, #121116 55%, #24232C);
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(23, 22, 26, 0.06);
}
.phone__frame::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 12px;
  width: 30%;
  height: 18px;
  border-radius: 0 0 12px 12px;
  background: #121116;
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);
  opacity: 0.9;
  pointer-events: none;
}
.phone__screen {
  position: relative;
  border-radius: 33px;
  overflow: hidden;
  background: linear-gradient(180deg, #FFFFFF 0%, #FFF5F3 100%);
}

.app {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 34px 18px 16px;
}

.app__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-3);
}
.app__dots { display: flex; gap: 3px; }
.app__dots i { display: block; width: 12px; height: 5px; border-radius: 2px; background: rgba(23, 22, 26, 0.16); }

.app__hint {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.artwork {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 20px;
  background: radial-gradient(circle at 30% 24%, #FF9686 0%, #DB2B21 52%, #99170F 100%);
  box-shadow: inset 0 -18px 44px rgba(0, 0, 0, 0.22), 0 12px 26px rgba(219, 43, 33, 0.24);
}
.artwork--lg { height: 178px; }

.app__title { font-size: 16px; font-weight: 800; letter-spacing: -0.02em; }
.app__sub { font-size: 11.5px; color: var(--ink-3); margin-top: -6px; }

.bar {
  position: relative;
  height: 5px;
  border-radius: 99px;
  background: var(--red-100);
  overflow: hidden;
}
.bar__fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 34%;
  border-radius: 99px;
  background: linear-gradient(90deg, #F0554A, var(--red));
}
.app__times {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 600;
  color: var(--ink-3);
  margin-top: -4px;
}

.controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink-2);
  margin-top: 4px;
}
.ctl { display: flex; align-items: center; justify-content: center; opacity: 0.85; }
.ctl--play {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  opacity: 1;
  box-shadow: 0 10px 22px var(--red-glow);
}

.tabs {
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.tabs__item i { display: block; width: 17px; height: 17px; border-radius: 5px; background: rgba(23, 22, 26, 0.14); }
.tabs__item.is-active i { background: var(--red); }

/* ---------- 9. Feature cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.card {
  padding: 26px 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--red-200);
  box-shadow: var(--shadow-md);
}
.card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 20px;
  border-radius: 14px;
  color: var(--red);
  background: var(--red-050);
  border: 1px solid var(--red-100);
}
.card h3 { font-size: 17.5px; font-weight: 700; letter-spacing: -0.018em; }
.card p { margin-top: 9px; font-size: 14.5px; color: var(--ink-2); }

/* ---------- 10. Download CTA ---------- */
.cta {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  padding: 38px 42px;
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, var(--red-dark) 0%, var(--red) 46%, #F0554A 100%);
  color: #fff;
  box-shadow: 0 30px 60px rgba(219, 43, 33, 0.26);
}
.cta__body { max-width: 620px; }
.cta__title { font-size: clamp(1.7rem, 3.6vw, 2.6rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.cta__lead { margin-top: 14px; font-size: 17px; color: rgba(255, 255, 255, 0.9); }
.cta__actions { margin-top: 22px; }
.cta__actions .btn--play { background: #0B0B0F; }
.cta__actions .btn--play:hover { background: #000; }
.cta__note { margin-top: 14px; font-size: 13.5px; color: rgba(255, 255, 255, 0.78); }
.cta__art { flex: none; }
.cta__mark {
  display: block;
  padding: 14px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.16);
  line-height: 0;
}
.cta__mark svg { border-radius: 16px; }

/* ---------- 11. Footer ---------- */
.site-footer {
  padding: 30px 0 38px;
  border-top: 1px solid var(--line);
}
.site-footer__line {
  font-size: 13px;
  color: var(--ink-3);
  text-align: center;
}

/* ---------- 12. Legal pages (privacy.html) ---------- */
.legal { padding-top: 8px; }
.legal__title {
  font-size: clamp(2rem, 5vw, 2.9rem);
  font-weight: 800;
  letter-spacing: -0.032em;
  line-height: 1.08;
  margin-top: 14px;
}
.legal__meta {
  margin-top: 14px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--ink-3);
}
.legal__meta code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-sunk);
  border: 1px solid var(--line);
}
.legal__callout {
  margin: 32px 0 8px;
  padding: 22px 24px;
  border: 1px solid var(--red-100);
  border-left: 4px solid var(--red);
  border-radius: var(--r-md);
  background: var(--red-050);
}
.legal__callout p { font-size: 15px; color: var(--ink-2); }
.legal h2 {
  margin: 44px 0 14px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.legal h2:first-of-type { margin-top: 36px; }
.legal p { font-size: 15.5px; color: var(--ink-2); }
.legal p + p { margin-top: 14px; }
.legal a { color: var(--red); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.legal a:hover { color: var(--red-dark); }
.legal code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  padding: 1px 5px;
  border-radius: 5px;
  background: var(--surface-sunk);
  border: 1px solid var(--line);
}
.legal__list { margin: 14px 0 0; display: grid; gap: 10px; }
.legal__list li {
  position: relative;
  padding-left: 22px;
  font-size: 15px;
  color: var(--ink-2);
}
.legal__list li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
}
.legal__contact {
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface-tint);
}
.legal__contact p { font-size: 15px; line-height: 1.75; }
.legal__fine { margin-top: 28px; font-size: 13px !important; color: var(--ink-3) !important; }
.legal__back { margin-top: 34px; }

/* ---------- 13. Reveal on scroll (additive only) ---------- */
/* Elements are visible by default; JS adds .in to animate. If JS never runs,
   or the browser lacks IntersectionObserver, content simply stays visible. */
.reveal.in {
  -webkit-animation: rise 0.62s cubic-bezier(0.22, 0.75, 0.28, 1) both;
  animation: rise 0.62s cubic-bezier(0.22, 0.75, 0.28, 1) both;
}
@-webkit-keyframes rise {
  from { opacity: 0; -webkit-transform: translateY(18px); }
  to { opacity: 1; -webkit-transform: translateY(0); }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
.cards > .card.in:nth-child(2),
.cards > .card.in:nth-child(3),

/* ---------- 14. Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal.in,
  .cards > .card.in {
    -webkit-animation: none !important;
    animation: none !important;
  }
  *, *::before, *::after {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }
  .btn:hover, .card:hover { transform: none; }
}

/* ---------- 15. Responsive ---------- */
@media (max-width: 960px) {
  .section { padding: 44px 0; }
  .hero { padding: 48px 0 66px; }
  .hero__inner { text-align: left; }
  .hero__art { margin-top: 44px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .cta { flex-direction: column; align-items: flex-start; padding: 44px 32px; }
  .cta__art { align-self: flex-start; }
}

@media (max-width: 720px) {
  .wrap { padding: 0 18px; }
  .section { padding: 38px 0; }
  .hero__lead { font-size: 16.5px; }
  .hero__cta .btn { width: 100%; }
  .hero__cta .btn--ghost { width: auto; }
  .chips { gap: 10px 16px; }
  .cards { grid-template-columns: 1fr; }
  .cta { padding: 36px 24px; border-radius: var(--r-lg); }
  .cta__art { display: none; }
}

@media (max-width: 380px) {
  .brand__sub { display: none; }
}

/* ---------- 16. Print ---------- */
@media print {
  .site-header { position: static; box-shadow: none; }
  .hero__glow, .phone, .cta__art { display: none; }
  body { color: #000; }
}
