/* Miaoushi ($MIAO) — shared styles for index.html and whitepaper.html
   Layout: mobile-first single column; sections become 2-column grids from 760px. */
@font-face {
  font-family: "Luckiest Guy";
  src: url("LuckiestGuy-Regular.ttf") format("truetype");
  font-display: swap;
}

:root {
  --cream: #FFF6EC;
  --cream-2: #FCE9D6;
  --coral: #FF7A59;
  --coral-dark: #E85B3A;
  --navy: #2B2140;
  --navy-2: #3D3157;
  --beret: #E63946;
  --salmon: #FFB085;
  --lilac: #9B8FB0;
  --ink-muted: #6B5F7A;
  --line: #EBD9C6;
  --white: #FFFFFF;

  --display: "Luckiest Guy", "Arial Rounded MT Bold", system-ui, sans-serif;
  --body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --radius: 18px;
  --shadow: 0 10px 30px rgba(43, 33, 64, .10);
  --wrap: 1120px;
  --gutter: max(16px, env(safe-area-inset-left, 0px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; background: var(--cream); color: var(--navy); font: 17px/1.65 var(--body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--coral-dark); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 8px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: var(--gutter); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
section { padding-block: 72px; }
section.alt { background: var(--white); }
section.dark { background: var(--navy); color: var(--cream); }

h1, h2, h3 { margin: 0; line-height: 1.1; text-wrap: balance; }
h2 { font: 400 clamp(2rem, 6vw, 3rem)/1.05 var(--display); letter-spacing: .02em; }
h3 { font-size: 1.15rem; font-weight: 800; }
.eyebrow { font-weight: 800; text-transform: uppercase; letter-spacing: .14em; font-size: .78rem; color: var(--coral-dark); margin: 0 0 10px; }
.dark .eyebrow { color: var(--salmon); }
.lead { font-size: 1.12rem; color: var(--ink-muted); max-width: 62ch; margin: 14px 0 0; }
.dark .lead { color: #D9CFE6; }
.head { margin-bottom: 36px; }

/* ---------- header ---------- */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: rgba(255, 246, 236, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 21; background: var(--cream); }
.site-header > .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); font: 400 1.4rem/1 var(--display); letter-spacing: .03em; }
.brand img { width: 38px; height: 38px; }
.brand em { font-style: normal; color: var(--beret); }
.nav { display: none; gap: 22px; }
.nav a { color: var(--navy); text-decoration: none; font-weight: 700; font-size: .95rem; }
.nav a:hover { color: var(--coral-dark); }
@media (min-width: 1100px) { .nav { display: flex; } }
@media (min-width: 1100px) and (max-width: 1240px) { .nav { gap: 16px; } .nav a { font-size: .9rem; } }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border-radius: 999px; font: 800 1rem/1 var(--body); text-decoration: none; border: 2px solid var(--navy); cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--coral); color: var(--navy); box-shadow: 0 4px 0 var(--navy); }
.btn-primary:hover { box-shadow: 0 6px 0 var(--navy); }
.btn-ghost { background: var(--white); color: var(--navy); }
.btn-small { padding: 9px 16px; font-size: .9rem; }
.btn[aria-disabled="true"] { opacity: .55; cursor: default; transform: none; }

/* ---------- hero ---------- */
.hero { padding-block: 40px 64px; overflow: hidden; background:
  radial-gradient(circle at 85% 15%, rgba(255, 122, 89, .22), transparent 45%),
  radial-gradient(circle at 10% 90%, rgba(230, 57, 70, .12), transparent 40%), var(--cream); }
.hero .wrap { display: grid; gap: 32px; align-items: center; }
.hero h1 { font: 400 clamp(3.2rem, 14vw, 6rem)/.95 var(--display); letter-spacing: .02em; }
.hero h1 span { color: var(--beret); }
.ticker { display: inline-block; margin-top: 10px; background: var(--navy); color: var(--cream); font-weight: 800; padding: 4px 12px; border-radius: 8px; letter-spacing: .08em; }
.slogan { font-size: 1.3rem; font-weight: 800; margin: 18px 0 0; }
.slogan em { font-style: normal; color: var(--coral-dark); }
.hero p.lead { margin-top: 10px; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-art { position: relative; justify-self: center; width: min(420px, 86vw); }
.hero-art img { width: 100%; filter: drop-shadow(0 22px 30px rgba(43, 33, 64, .25)); animation: bob 5s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-10px) rotate(-2deg); } }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; padding: 0; list-style: none; }
.badges li { background: var(--white); border: 1.5px solid var(--line); border-radius: 999px; padding: 6px 12px; font-weight: 700; font-size: .88rem; }
.badges li::before { content: "✓ "; color: #1F8A5B; font-weight: 900; }
@media (min-width: 860px) { .hero .wrap { grid-template-columns: 1.1fr .9fr; } .hero { padding-block: 64px 90px; } }

/* ---------- contract box ---------- */
.ca { margin-top: 26px; background: var(--white); border: 2px solid var(--navy); border-radius: 14px; padding: 12px 14px; display: grid; gap: 6px; max-width: 560px; box-shadow: 0 4px 0 var(--navy); }
.ca small { font-weight: 800; letter-spacing: .1em; text-transform: uppercase; font-size: .72rem; color: var(--ink-muted); }
.ca-row { display: flex; gap: 10px; align-items: center; min-width: 0; }
.ca code { flex: 1; min-width: 0; font: 600 .86rem/1.4 var(--mono); word-break: break-all; }
.copy { flex: none; border: 0; background: var(--navy); color: var(--cream); font: 800 .85rem/1 var(--body); padding: 10px 14px; border-radius: 10px; cursor: pointer; }
.copy.done { background: #1F8A5B; }

/* ---------- generic grids & cards ---------- */
.grid { display: grid; gap: 16px; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-5 { grid-template-columns: repeat(5, 1fr); } }
.card { background: var(--white); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 22px; min-width: 0; }
.alt .card { background: var(--cream); }
.card .ico { font-size: 1.8rem; line-height: 1; margin-bottom: 10px; }
.card p { margin: 8px 0 0; color: var(--ink-muted); }

/* ---------- story ---------- */
.story { display: grid; gap: 28px; align-items: center; }
.story p { margin: 0 0 14px; max-width: 62ch; }
.story-quote { font: 400 clamp(1.6rem, 5vw, 2.3rem)/1.15 var(--display); color: var(--beret); margin: 0; }
.chapters { display: grid; gap: 14px; counter-reset: ch; padding: 0; margin: 0; list-style: none; }
.chapters li { background: var(--white); border-left: 5px solid var(--coral); border-radius: 12px; padding: 16px 18px; }
.chapters b { display: block; font-size: 1.05rem; }
.chapters span { color: var(--ink-muted); }
@media (min-width: 860px) { .story { grid-template-columns: 1fr 1fr; } }

/* ---------- token info table ---------- */
.table-wrap { overflow-x: auto; background: var(--white); border-radius: var(--radius); border: 1.5px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 14px 18px; border-top: 1px solid var(--line); vertical-align: top; }
tr:first-child th, tr:first-child td { border-top: 0; }
th { width: 38%; color: var(--ink-muted); font-weight: 700; font-size: .95rem; }
td { font-weight: 700; word-break: break-word; }
td code { font: 600 .85rem/1.5 var(--mono); word-break: break-all; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .8rem; font-weight: 800; }
.pill.ok { background: #DDF3E8; color: #156B45; }
.pill.soon { background: #FFE7DA; color: #A63E1E; }

/* ---------- tokenomics ---------- */
.tokenomics { display: grid; gap: 32px; align-items: center; }
.donut { position: relative; width: min(340px, 82vw); justify-self: center; }
.donut svg { width: 100%; height: auto; transform: rotate(-90deg); }
.donut .center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donut .center b { font: 400 2.4rem/1 var(--display); color: var(--cream); }
.donut .center span { color: #D9CFE6; font-weight: 700; font-size: .9rem; }
.legend { display: grid; gap: 12px; padding: 0; margin: 0; list-style: none; }
.legend li { display: grid; grid-template-columns: 16px 1fr auto; gap: 14px; align-items: center; background: var(--navy-2); border-radius: 14px; padding: 14px 16px; }
.legend i { width: 16px; height: 16px; border-radius: 5px; }
.legend b { display: block; }
.legend small { color: #D9CFE6; }
.legend .pct { font: 400 1.6rem/1 var(--display); }
.supply-note { margin-top: 22px; color: #D9CFE6; font-size: .95rem; }
@media (min-width: 860px) { .tokenomics { grid-template-columns: .9fr 1.1fr; } }

/* ---------- steps (airdrop) ---------- */
.steps { display: grid; gap: 14px; padding: 0; margin: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; background: var(--white); border: 1.5px solid var(--line); border-radius: 16px; padding: 16px; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--coral); color: var(--navy); font: 400 1.3rem/1 var(--display); border: 2px solid var(--navy); }
.steps p { margin: 4px 0 0; color: var(--ink-muted); }
.notice { margin-top: 18px; background: #FFF0EE; border: 1.5px solid #F4B6B0; color: #7A1E1E; border-radius: 14px; padding: 14px 16px; font-weight: 700; }
.airdrop-box { display: grid; gap: 24px; }
.airdrop-stat { background: var(--navy); color: var(--cream); border-radius: var(--radius); padding: 26px; display: grid; gap: 6px; align-content: start; }
.airdrop-stat b { font: 400 clamp(2.2rem, 8vw, 3.2rem)/1 var(--display); color: var(--salmon); }
@media (min-width: 860px) { .airdrop-box { grid-template-columns: .8fr 1.2fr; } }

/* ---------- links ---------- */
.link-card { display: flex; flex-direction: column; gap: 10px; text-decoration: none; color: var(--navy); }
.link-card .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.link-card:hover h3 { color: var(--coral-dark); }

/* ---------- roadmap ---------- */
.roadmap { display: grid; gap: 16px; }
.phase { background: var(--navy-2); border-radius: var(--radius); padding: 22px; position: relative; }
.phase h3 { font: 400 1.5rem/1.1 var(--display); letter-spacing: .02em; color: var(--cream); }
.phase .when { color: var(--salmon); font-weight: 800; font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; }
.phase ul { margin: 12px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.phase li { padding-left: 28px; position: relative; color: #E6DDF0; }
.phase li::before { content: "○"; position: absolute; left: 4px; color: var(--lilac); font-weight: 900; }
.phase li.done::before { content: "✓"; color: #6EE0A6; }
.phase.current { outline: 3px solid var(--coral); }
@media (min-width: 760px) { .roadmap { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1060px) { .roadmap { grid-template-columns: repeat(4, 1fr); } }

/* ---------- whitepaper teaser ---------- */
.wp { display: grid; gap: 24px; align-items: center; background: var(--coral); border: 2px solid var(--navy); border-radius: 26px; padding: 30px; box-shadow: 0 6px 0 var(--navy); }
.wp h2 { color: var(--navy); }
.wp p { margin: 10px 0 0; max-width: 60ch; }
@media (min-width: 860px) { .wp { grid-template-columns: 1fr auto; padding: 40px; } }

/* ---------- footer ---------- */
footer { background: var(--navy); color: #D9CFE6; padding-block: 48px calc(32px + env(safe-area-inset-bottom, 0px)); font-size: .92rem; }
footer .wrap { display: grid; gap: 22px; }
footer .brand { color: var(--cream); }
footer a { color: var(--salmon); }
.socials { display: flex; flex-wrap: wrap; gap: 10px; }
.socials a { background: var(--navy-2); color: var(--cream); text-decoration: none; font-weight: 800; padding: 9px 14px; border-radius: 999px; }
.disclaimer { border-top: 1px solid var(--navy-2); padding-top: 18px; line-height: 1.6; max-width: 90ch; }

/* ---------- whitepaper page ---------- */
.doc { max-width: 780px; margin: 0 auto; padding-block: 40px 80px; padding-left: var(--gutter); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.doc h1 { font: 400 clamp(2.4rem, 9vw, 3.6rem)/1 var(--display); }
.doc h2 { font-size: clamp(1.6rem, 5vw, 2.1rem); margin-top: 48px; }
.doc h3 { margin-top: 24px; }
.doc p, .doc li { max-width: 68ch; }
.doc .meta { color: var(--ink-muted); font-weight: 700; margin-top: 10px; }
.doc .toc { background: var(--white); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 18px 22px; margin-top: 28px; }
.doc .toc ol { margin: 8px 0 0; padding-left: 1.2em; display: grid; gap: 4px; }
.doc .table-wrap { margin-top: 16px; }
.doc pre { background: var(--navy); color: var(--cream); padding: 16px; border-radius: 12px; overflow-x: auto; font: .85rem/1.5 var(--mono); }

/* ---------- listing plan ---------- */
.ex-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px 14px; counter-reset: ex; }
@media (min-width: 640px) { .ex-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .ex-grid { grid-template-columns: repeat(5, 1fr); } }
.ex { counter-increment: ex; position: relative; display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; background: var(--white); border: 1.5px solid var(--line); border-radius: 16px; padding: 14px; min-width: 0; }
.ex::before { content: counter(ex); position: absolute; top: -9px; left: -6px; width: 24px; height: 24px; border-radius: 50%; background: var(--navy); color: var(--cream); font: 800 .75rem/24px var(--body); text-align: center; }
.ex-mark { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--cream-2); color: var(--navy); font: 400 1.1rem/1 var(--display); letter-spacing: .04em; }
.ex b { display: block; }
.ex small { color: var(--ink-muted); }
.ex.next { border: 2px solid var(--navy); box-shadow: 0 4px 0 var(--navy); }
.ex.next .ex-mark { background: var(--coral); }
@media (min-width: 1000px) { .ex { grid-template-columns: 1fr; justify-items: start; } }
.pill.plan { background: #ECE7F3; color: var(--navy-2); }
.ex-note { margin-top: 18px; color: var(--ink-muted); font-size: .92rem; max-width: 80ch; }
.ex-h { margin: 34px 0 16px; font-size: 1.05rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-muted); }
.head + .ex-h { margin-top: 0; }
.ex-logo { width: 48px; height: 48px; border-radius: 14px; object-fit: contain; background: var(--white); box-shadow: 0 0 0 1px var(--line); }
.pill.next { background: var(--coral); color: var(--navy); }

/* ---------- mobile menu ---------- */
.hdr-actions { display: flex; align-items: center; gap: 10px; }
.menu-btn { width: 44px; height: 44px; border: 2px solid var(--navy); border-radius: 12px; background: var(--white); display: grid; place-content: center; gap: 5px; cursor: pointer; padding: 0; }
.menu-btn span { display: block; width: 20px; height: 2.5px; border-radius: 2px; background: var(--navy); transition: transform .2s ease, opacity .2s ease; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
.mobile-menu { border-top: 1px solid var(--line); background: var(--cream); max-height: calc(100vh - 64px - env(safe-area-inset-top, 0px)); overflow-y: auto; box-shadow: 0 18px 30px rgba(43, 33, 64, .12); }
.mobile-menu .wrap { display: grid; padding-block: 8px 20px; }
.mobile-menu a { color: var(--navy); text-decoration: none; font-weight: 800; font-size: 1.1rem; padding: 14px 4px; border-bottom: 1px solid var(--line); }
.mobile-menu a:hover, .mobile-menu a[aria-current="page"] { color: var(--coral-dark); }
.mm-social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.mobile-menu .mm-social a { border: 1.5px solid var(--navy); border-radius: 999px; padding: 9px 14px; font-size: .9rem; }
.nav a[aria-current="page"] { color: var(--coral-dark); }
@media (min-width: 1100px) { .menu-btn, .mobile-menu { display: none !important; } }
@media (max-width: 359px) { .hdr-actions .btn { display: none; } }

/* ---------- about (extended) ---------- */
.stats { list-style: none; margin: 0 0 36px; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.stats li { background: var(--navy); color: var(--cream); border-radius: 16px; padding: 18px; display: grid; gap: 4px; min-width: 0; }
.stats b { font: 400 clamp(1.7rem, 7vw, 2.4rem)/1 var(--display); color: var(--salmon); letter-spacing: .02em; }
.stats span { font-size: .9rem; color: #D9CFE6; font-weight: 700; }
@media (min-width: 860px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.about-grid { display: grid; gap: 28px; align-items: start; margin-bottom: 36px; }
.about-text { min-width: 0; }
.about-text h3 { font-size: 1.3rem; margin: 26px 0 8px; }
.about-text h3:first-child { margin-top: 0; }
.about-text p { margin: 0 0 12px; max-width: 64ch; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; max-width: 64ch; }
.ticks li { position: relative; padding-left: 30px; }
.ticks li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--coral); color: var(--navy); font-weight: 900; font-size: .8rem; display: grid; place-items: center; margin-top: 3px; }
.about-art { margin: 0; justify-self: center; text-align: center; width: min(320px, 70vw); position: sticky; top: 96px; }
.about-art img { width: 100%; filter: drop-shadow(0 16px 24px rgba(43, 33, 64, .2)); }
.about-art figcaption { margin-top: 12px; font: 400 1.3rem/1.2 var(--display); color: var(--beret); }
@media (min-width: 860px) { .about-grid { grid-template-columns: 1.4fr .8fr; gap: 48px; } }
@media (max-width: 859px) { .about-art { position: static; } }
.vest-h { color: var(--cream); font-size: 1.3rem; margin: 44px 0 14px; }
.vest { background: var(--navy-2); border-color: var(--navy-2); }
.vest th, .vest td { border-color: rgba(255, 246, 236, .12); color: var(--cream); }
.vest th { color: #D9CFE6; }
.vest td { font-weight: 600; }
.vest-grid { display: grid; gap: 12px; }
@media (min-width: 700px) { .vest-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1060px) { .vest-grid { grid-template-columns: repeat(4, 1fr); } .vest-card:first-child { grid-column: span 2; } }
.vest-card { background: var(--navy-2); border-radius: 16px; padding: 16px 18px; min-width: 0; }
.vest-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.vest-top b { font-size: 1.05rem; }
.vest-top span { font: 400 1.5rem/1 var(--display); color: var(--salmon); }
.vest-card dl { margin: 10px 0 0; display: grid; gap: 8px; }
.vest-card dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--lilac); font-weight: 800; }
.vest-card dd { margin: 2px 0 0; color: var(--cream); font-weight: 600; }

/* ---------- airdrop rounds ---------- */
.rounds { display: grid; gap: 14px; margin-bottom: 28px; }
@media (min-width: 860px) { .rounds { grid-template-columns: repeat(3, 1fr); } }
.round { background: var(--white); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 20px; display: grid; gap: 8px; align-content: start; min-width: 0; }
.round.live { border: 2px solid var(--navy); box-shadow: 0 4px 0 var(--navy); }
.round .when { font-weight: 800; font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--coral-dark); }
.round b { font: 400 1.6rem/1.1 var(--display); letter-spacing: .02em; }
.round p { margin: 0; color: var(--ink-muted); }
.round ul { list-style: none; margin: 6px 0 4px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.round li { background: var(--cream); border-radius: 10px; padding: 8px 10px; display: grid; }
.round li span { font-size: .75rem; color: var(--ink-muted); font-weight: 700; }
.round li strong { font-variant-numeric: tabular-nums; }
.round .pill { justify-self: start; }
.airdrop-value { color: var(--salmon); font-weight: 800; }
.airdrop-stat { align-self: start; }

/* ---------- airdrop rules box (home page) ---------- */
.rules-box { margin-top: 18px; background: var(--white); border: 1.5px solid var(--line); border-radius: 16px; padding: 16px 18px; }
.rules-box h3 { margin: 0 0 8px; font-size: 1.05rem; }
.rules-box ul { margin: 0 0 10px; padding-left: 1.2em; display: grid; gap: 6px; color: var(--ink-muted); font-size: .95rem; }
.rules-box b { color: var(--navy); }
.rules-box a { font-weight: 800; }
