/* Mobile app page (/phone), in the homepage look.
   Shared parts (tokens, body, nav, buttons, footer) are repeated from character-ai-import.css; keep them in step with it.
   Body text is 17px, nothing is smaller than 14px. */

:root {
  --home-ink: #4e3633;
  --home-text: #6b5550;
  --home-muted: #80665f;
  --home-bg: #fffbf7;
  --home-warm-rose: #d67a6d;
  --home-mauve: #9472a5;
  --home-sage: #8c8d66;
  --home-line: rgba(188, 128, 114, 0.22);
  --imp-rose: #bd5a4b;
  --imp-eyebrow: #7d604d;
}

html,
body {
  height: auto;
  min-height: 100%;
}

body {
  overflow-x: hidden;
  color: var(--home-text);
  font-size: 1.0625rem;
  line-height: 1.65;
  background-color: var(--home-bg);
  background-image:
    radial-gradient(circle at 100% 0%, #ffe9d9 0%, transparent 60%),
    radial-gradient(circle at 0% 100%, #fde8e0 0%, transparent 50%);
}

.container {
  width: 100%;
  max-width: 1180px;
  padding: 0 18px;
}

.shell {
  width: 100%;
  margin: 0 auto 34px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

/* header, as on the homepage */
.nav {
  position: sticky;
  top: 10px;
  z-index: 30;
  margin: 16px 0 18px;
  padding: 14px 18px;
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: rgba(255, 250, 245, 0.92);
  box-shadow: 0 18px 44px rgba(88, 50, 44, 0.08);
  backdrop-filter: blur(14px);
}

.brand {
  color: var(--home-ink);
  font-size: 1.12rem;
  font-weight: 900;
}

.brandLogo {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  box-shadow: 0 8px 18px rgba(84, 34, 92, 0.16);
}

.navlinks {
  color: #58434c;
  font-size: 0.95rem;
}

.navlinks a {
  border-radius: 8px;
}

.navlinks a:hover {
  color: var(--home-ink);
  background: rgba(216, 97, 112, 0.08);
}

.btn {
  min-height: 48px;
  border-radius: 8px;
  border-color: rgba(87, 49, 56, 0.2);
  color: var(--home-ink);
  background: rgba(255, 250, 245, 0.84);
  box-shadow: none;
  font-size: 1rem;
  text-decoration: none;
}

.btn.primary {
  border-color: transparent;
  color: #fffaf5;
  background: var(--imp-rose);
  border-radius: 50px;
  padding-left: 28px;
  padding-right: 28px;
  box-shadow: 0 14px 30px rgba(189, 90, 75, 0.24);
}

.btn.primary:hover {
  filter: none;
  background: #a94d40;
}

.btn.outline {
  background: rgba(255, 250, 245, 0.72);
}

.btn.outline:hover {
  background: #fff;
}

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

.btnIcon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

/* footer, as on the homepage, but readable */
.footer {
  border-top: 1px solid var(--home-line);
  color: var(--home-muted);
  font-size: 0.92rem;
}

.footerTitle {
  font-size: 0.95rem;
  color: var(--home-ink);
}

.footer a:hover {
  color: var(--home-ink);
}

.footer a,
.footerLine {
  color: var(--home-muted);
}

/* page */
.phPage {
  overflow-wrap: break-word;
}

.phPage a:not(.btn) {
  color: var(--imp-rose);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.phPage a:not(.btn):hover {
  color: var(--home-ink);
}

.phPage :focus-visible {
  outline: 3px solid #9472a5;
  outline-offset: 3px;
  border-radius: 4px;
}

.phPage .eyebrow {
  margin: 0 0 12px;
  color: var(--imp-eyebrow);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* hero: the headline and the button on the left, the code to scan on the right */
.phHero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(24px, 4vw, 52px);
  align-items: center;
  margin-top: 16px;
  padding: clamp(22px, 4.5vw, 60px);
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background:
    radial-gradient(520px 320px at 6% 0%, rgba(244, 180, 141, 0.3), transparent 70%),
    radial-gradient(460px 340px at 100% 100%, rgba(214, 122, 109, 0.16), transparent 70%),
    linear-gradient(135deg, #fff8f1, #ffeadc);
  box-shadow: 0 34px 70px rgba(91, 58, 48, 0.12);
}

.phHero h1 {
  margin: 0;
  color: var(--home-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.5rem, 4.8vw, 3.9rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0;
}

.phHero h1 span {
  display: block;
  color: var(--imp-rose);
  font-style: italic;
}

.phLead {
  max-width: 32em;
  margin: 18px 0 0;
  color: var(--home-text);
  font-size: clamp(1.12rem, 1.7vw, 1.26rem);
  line-height: 1.6;
}

.phChips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.phChips li {
  padding: 7px 14px;
  border: 1px solid var(--home-line);
  border-radius: 50px;
  color: var(--home-ink);
  background: rgba(255, 252, 247, 0.8);
  font-size: 0.97rem;
  font-weight: 700;
}

.phActions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: 26px;
}

.phFine {
  margin: 14px 0 0;
  color: var(--home-muted);
  font-size: 0.97rem;
}

.phQr {
  justify-self: center;
  width: min(100%, 340px);
  margin: 0;
  padding: 10px 10px 20px;
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 50px rgba(91, 58, 48, 0.14);
  text-align: center;
}

.phQrCode {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  shape-rendering: crispEdges;
}

.phQr figcaption {
  margin-top: 14px;
  color: var(--home-ink);
  font-size: 1.05rem;
  line-height: 1.45;
}

.phQr figcaption strong {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
}

/* sections under the hero */
.phSection {
  padding-top: 64px;
}

.phHead {
  max-width: 760px;
  margin: 0 0 26px;
}

.phHead h2 {
  margin: 0;
  color: var(--home-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.1rem, 3.6vw, 2.9rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0;
}

.phHead h2 span {
  color: var(--imp-rose);
  font-style: italic;
}

.phSteps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: phStep;
}

.phSteps li,
.phCard {
  padding: 26px 24px;
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: rgba(255, 252, 247, 0.9);
  box-shadow: 0 18px 44px rgba(91, 58, 48, 0.08);
}

.phSteps li {
  counter-increment: phStep;
}

.phSteps li::before {
  content: counter(phStep);
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 14px;
  border-radius: 50%;
  color: #fffaf5;
  background: var(--imp-rose);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
  font-weight: 700;
}

.phSteps h3,
.phCard h3 {
  margin: 0 0 8px;
  color: var(--home-ink);
  font-size: 1.22rem;
  line-height: 1.3;
}

.phSteps p,
.phCard p {
  margin: 0;
  color: var(--home-text);
  font-size: 1.06rem;
  line-height: 1.6;
}

.phCards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.phCardIcon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 14px;
  border-radius: 50%;
  color: var(--imp-rose);
  background: #fde7df;
}

.phCardIcon svg {
  width: 22px;
  height: 22px;
}

.phBottom {
  margin: 64px 0 40px;
  padding: clamp(24px, 4vw, 44px);
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: linear-gradient(135deg, #fff8f1, #ffeadc);
  text-align: center;
}

.phBottom h2 {
  margin: 0 0 18px;
  color: var(--home-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.9rem, 3.2vw, 2.5rem);
  line-height: 1.15;
}

@media (max-width: 980px) {
  .phHero,
  .phSteps,
  .phCards {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* on a phone there is nothing to scan: the button opens the app */
@media (max-width: 640px), (hover: none) and (pointer: coarse) {
  .phQr,
  .phScanOnly {
    display: none;
  }
}

@media (max-width: 640px) {
  .container {
    max-width: 100%;
    padding: 0 12px;
  }

  .shell,
  main {
    min-width: 0;
    overflow-x: hidden;
  }

  .nav {
    top: 8px;
    margin-top: 10px;
    padding: 13px 14px;
  }

  .navlinks,
  .nav > .btn {
    display: none;
  }

  .phHero {
    padding: 26px 16px;
  }

  .phActions .btn {
    width: 100%;
  }

  .phSection {
    padding-top: 48px;
  }
}
