/* Product, support, privacy and terms pages for every App Factory app (build_site.py).
   Light only, system fonts (rounded digits on Apple devices), no scripts, no outside requests.
   Each app sets its colours in app.json; these are the defaults. */
:root {
  --accent: #4E7D5B;
  --deep: #2B5338;
  --ink: #1E2B22;
  --slate: #5F6B63;
  --paper: #F4F6F1;
  --card: #FFFFFF;
  --line: #E4ECE5;
  --mist: #E3EEE3;
  --t1: #E5EFE3;
  --t2: #F6F1E1;
  --t3: #ECEAF5;
  --t4: #F6E7E3;
  --band-from: #4E7D5B;
  --band-to: #2B5338;
  --radius: 22px;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.75 -apple-system, BlinkMacSystemFont, "Helvetica Neue", "PingFang TC", "Noto Sans CJK TC", "Microsoft JhengHei", sans-serif;
}
html:lang(ja) body {
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans CJK JP", "Yu Gothic", sans-serif;
}
img { max-width: 100%; }
a { color: var(--accent); }
a:hover { color: var(--deep); }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 780px; }
.num { font-family: ui-rounded, -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif; font-variant-numeric: tabular-nums; }

/* Header */
header.site {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 255, 255, 0.88);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.bar { display: flex; align-items: center; gap: 8px 16px; flex-wrap: wrap; min-height: 60px; padding: 8px 0; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--deep); font-weight: 700; font-size: 17px; text-decoration: none; }
.brand img { width: 34px; height: 34px; }
.pages { display: flex; gap: 4px; margin-left: auto; }
.pages a { font-size: 15px; line-height: 1.3; padding: 7px 12px; border-radius: 999px; color: var(--slate); text-decoration: none; white-space: nowrap; }
.pages a:hover { background: var(--mist); color: var(--deep); }
.pages a[aria-current] { background: var(--mist); color: var(--deep); font-weight: 700; }
.langs { display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); }
.langs a { font-size: 13px; line-height: 1; padding: 7px 10px; border-radius: 999px; color: var(--slate); text-decoration: none; white-space: nowrap; }
.langs a[aria-current] { background: var(--card); color: var(--deep); font-weight: 700; box-shadow: 0 1px 3px rgba(30, 43, 34, 0.12); }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 520px at 78% 40%, var(--t1) 0%, rgba(229, 239, 227, 0) 70%),
    linear-gradient(180deg, #FFFFFF 0%, var(--paper) 100%);
  border-bottom: 1px solid var(--line);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 44px; }
.hero-text { text-align: center; }
.hero-icon { width: 84px; height: 84px; border-radius: 19px; box-shadow: 0 1px 3px rgba(43, 83, 56, 0.16), 0 10px 24px rgba(43, 83, 56, 0.16); }
.hero h1 { margin: 18px 0 10px; font-size: clamp(36px, 7vw, 56px); line-height: 1.15; letter-spacing: 0.02em; color: var(--deep); }
.tagline { margin: 0 auto; max-width: 30em; font-size: clamp(17px, 2.2vw, 20px); line-height: 1.7; color: var(--slate); }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; list-style: none; margin: 22px 0 0; padding: 0; }
.chips li { display: inline-flex; align-items: center; gap: 7px; padding: 6px 13px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 14px; font-weight: 600; color: var(--deep); }
.chips li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 20px; margin-top: 24px; }
.soon { display: inline-flex; align-items: center; gap: 10px; padding: 12px 20px; border-radius: 999px; background: var(--ink); color: #FFFFFF; font-size: 15px; font-weight: 600; }
.soon::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #9BD3A8; box-shadow: 0 0 0 4px rgba(155, 211, 168, 0.25); }
.hero-actions a { font-size: 15px; font-weight: 600; }
.measure-note { margin: 16px auto 0; max-width: 30em; font-size: 14px; color: var(--slate); }

.phones { position: relative; width: 100%; max-width: 560px; height: 440px; margin: 0 auto -44px; }
.phones::before {
  content: ""; position: absolute; left: 50%; top: 44%; width: 440px; height: 440px; border-radius: 50%;
  transform: translate(-50%, -50%);
  border: 2px solid rgba(78, 125, 91, 0.14);
  box-shadow: 0 0 0 44px rgba(78, 125, 91, 0.05), 0 0 0 88px rgba(78, 125, 91, 0.03);
}
.phone { position: absolute; top: 0; left: 50%; width: 186px; margin: 0; padding: 7px; border-radius: 34px; background: var(--ink); box-shadow: 0 28px 56px rgba(30, 43, 34, 0.22), 0 6px 16px rgba(30, 43, 34, 0.14); }
.phone img { display: block; width: 100%; height: auto; border-radius: 27px; }
.phone.center { transform: translateX(-50%); z-index: 2; }
.phone.left { transform: translate(-108%, 40px) rotate(-7deg) scale(0.86); }
.phone.right { transform: translate(8%, 40px) rotate(7deg) scale(0.86); }

/* Sections */
.section { padding: 64px 0; }
.section.tinted { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section h2, .band h2 { margin: 0; font-size: clamp(26px, 4vw, 34px); line-height: 1.3; letter-spacing: 0.01em; color: var(--deep); }
.section .lead { margin: 10px 0 0; max-width: 40em; font-size: 17px; color: var(--slate); }

.features { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-top: 28px; }
.feature { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 22px 20px; }
.feature h3 { margin: 14px 0 6px; font-size: 18px; line-height: 1.4; color: var(--ink); }
.feature p { margin: 0; font-size: 15px; line-height: 1.7; color: var(--slate); }
.tile { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 14px; color: var(--deep); background: var(--t1); }
.tile svg { width: 24px; height: 24px; }
.tile.t2 { background: var(--t2); }
.tile.t3 { background: var(--t3); }
.tile.t4 { background: var(--t4); }

.standards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-top: 28px; }
.standard { background: var(--paper); border-radius: var(--radius); padding: 22px; }
.standard .where { font-size: 14px; font-weight: 700; color: var(--accent); }
.standard .num { display: block; margin: 4px 0 6px; font-size: 40px; font-weight: 700; line-height: 1.15; color: var(--deep); }
.standard .num small { margin-left: 4px; font-size: 15px; font-weight: 600; color: var(--slate); }
.standard p { margin: 0; font-size: 14px; line-height: 1.65; color: var(--slate); }

.band { padding: 64px 0; background: linear-gradient(135deg, var(--band-from), var(--band-to)); color: #FFFFFF; }
.band h2 { color: #FFFFFF; }
.band p { margin: 12px 0 0; max-width: 34em; font-size: 17px; color: #FFFFFF; }
.band a { color: #FFFFFF; font-weight: 700; }
.band-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
.band-points { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 20px; }
.band-points li { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; }
.band-points svg { width: 22px; height: 22px; flex-shrink: 0; }

.plans { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-top: 28px; }
.plan { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.plan.pro { background: linear-gradient(180deg, var(--t1), var(--card) 70%); border-color: #C9DCCB; }
.plan h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 0; font-size: 20px; color: var(--deep); }
.plan h3 small { font-size: 14px; font-weight: 600; color: var(--slate); }
.checks { list-style: none; display: grid; gap: 10px; margin: 16px 0 0; padding: 0; }
.checks li { position: relative; padding-left: 32px; font-size: 16px; line-height: 1.6; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: 0.15em; width: 22px; height: 22px; border-radius: 50%;
  background: var(--mist) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.6 6.2l2.2 2.2 4.6-4.8' fill='none' stroke='%232B5338' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.faq { display: grid; gap: 10px; margin-top: 24px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 0 20px; }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; list-style: none; cursor: pointer; font-size: 17px; font-weight: 700; line-height: 1.5; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex-shrink: 0; font-size: 24px; font-weight: 400; line-height: 1; color: var(--accent); }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0 0 18px; font-size: 16px; color: var(--slate); }

.contact { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 28px; padding: 22px 24px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); }
.contact h3 { margin: 0 0 4px; font-size: 18px; color: var(--deep); }
.contact p { margin: 0; max-width: 32em; font-size: 15px; color: var(--slate); }
.button { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; padding: 12px 20px; border-radius: 999px; background: var(--accent); color: #FFFFFF; font-size: 15px; font-weight: 700; text-decoration: none; overflow-wrap: anywhere; }
.button:hover { background: var(--deep); color: #FFFFFF; }
.button svg { width: 18px; height: 18px; flex-shrink: 0; }
.note { margin: 20px 0 0; padding: 14px 16px; border-radius: 14px; background: var(--mist); font-size: 14px; line-height: 1.7; color: var(--deep); }

/* Documents: privacy policy, terms */
main.doc { max-width: 820px; padding-top: 32px; padding-bottom: 56px; }
article { background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 40px 36px; }
article h1 { margin: 0 0 12px; font-size: clamp(28px, 4.5vw, 34px); line-height: 1.3; color: var(--deep); }
article h2 { margin: 34px 0 8px; font-size: 20px; line-height: 1.4; color: var(--deep); }
article h3 { margin: 22px 0 4px; font-size: 17px; line-height: 1.5; }
article p { margin: 8px 0; }
article ul { margin: 8px 0; padding-left: 1.3em; }
article li + li { margin-top: 6px; }
.lead { margin: 0 0 8px; font-size: 18px; color: var(--slate); }
.summary { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 18px 0 8px; padding: 0; }
.summary li { margin: 0; padding: 6px 13px; border-radius: 999px; background: var(--mist); font-size: 14px; font-weight: 600; color: var(--deep); }
.summary li + li { margin-top: 0; }
.updated { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--slate); }

/* Footer */
footer.site { padding: 32px 0 44px; background: var(--card); border-top: 1px solid var(--line); font-size: 14px; color: var(--slate); }
.foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.foot-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--deep); }
.foot-brand img { width: 26px; height: 26px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.foot a { color: var(--slate); }
.foot p { width: 100%; margin: 0; }

/* Language chooser */
.chooser {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 40px 20px;
  background: radial-gradient(800px 500px at 50% 0%, var(--t1) 0%, rgba(229, 239, 227, 0) 70%), var(--paper);
}
.chooser-card { width: 100%; max-width: 440px; text-align: center; }
.chooser h1 { margin: 18px 0 6px; font-size: 28px; line-height: 1.35; color: var(--deep); }
.chooser .lead { font-size: 15px; }
.choices { display: grid; gap: 10px; margin-top: 24px; }
.choices a { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); color: var(--deep); font-weight: 700; text-decoration: none; }
.choices a span { font-weight: 500; color: var(--slate); }
.choices a:hover { border-color: var(--accent); }

@media (min-width: 640px) {
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 760px) {
  .standards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 860px) {
  .band-grid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: center; }
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; gap: 40px; padding-top: 64px; }
  .hero-text { text-align: left; padding-bottom: 48px; }
  .tagline, .measure-note { margin-left: 0; }
  .chips, .hero-actions { justify-content: flex-start; }
  .phones { height: 560px; margin-bottom: -64px; }
  .phones::before { width: 520px; height: 520px; }
  .phone { width: 220px; padding: 8px; border-radius: 40px; }
  .phone img { border-radius: 32px; }
  .phone.left { transform: translate(-100%, 48px) rotate(-7deg) scale(0.86); }
  .phone.right { transform: translate(0%, 48px) rotate(7deg) scale(0.86); }
}
@media (min-width: 1100px) {
  .phones { height: 600px; }
  .phones::before { width: 560px; height: 560px; }
  .phone { width: 248px; padding: 9px; border-radius: 44px; }
  .phone img { border-radius: 35px; }
  .phone.left { transform: translate(-100%, 52px) rotate(-7deg) scale(0.86); }
  .phone.right { transform: translate(0%, 52px) rotate(7deg) scale(0.86); }
}
@media (min-width: 960px) {
  .features { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .pages { order: 3; width: 100%; margin-left: -6px; overflow-x: auto; }
  .langs { margin-left: auto; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .section, .band { padding: 48px 0; }
  article { padding: 26px 18px; border-radius: 18px; }
  .band-points { grid-template-columns: minmax(0, 1fr); }
}
