/* kcis.kainnne.com — pink-purple glass entry for KCIS AI Tools. Material and shading only: no glow, halo or afterimage. */
:root {
  --paper: #fff6fa;
  --ink: #3b1640;
  --ink-strong: #2a0c30;
  --ink-soft: #77607a;
  --pink: #ff8fb8;
  --pink-deep: #c42d72;
  --lilac: #b48cff;
  --lilac-deep: #6f3fd1;
  --mint: #5cc9b6;
  --glass: rgba(255, 255, 255, .56);
  --glass-strong: rgba(255, 255, 255, .78);
  --glass-line: rgba(255, 255, 255, .86);
  --line: rgba(59, 22, 64, .1);
  --shadow: 0 22px 60px -30px rgba(120, 40, 110, .32);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --wrap: min(1180px, calc(100% - 2 * clamp(20px, 4vw, 48px)));
  --radius: 22px;
  --nav-h: 68px;
  font-family: "Nunito", "PingFang TC", "Noto Sans TC", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 8px) }
body {
  margin: 0; min-width: 320px; overflow-x: clip;
  background:
    radial-gradient(1100px 620px at 8% -8%, #ffd9e8 0, transparent 60%),
    radial-gradient(900px 600px at 100% 10%, #eadcff 0, transparent 62%),
    radial-gradient(900px 700px at 70% 100%, #ffe7f1 0, transparent 60%),
    var(--paper);
  background-attachment: fixed;
}
a { color: inherit; -webkit-tap-highlight-color: transparent }
button { font: inherit; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none }
::selection { background: #ffc6dc; color: var(--ink-strong) }
:focus-visible { outline: 3px solid rgba(196, 45, 114, .5); outline-offset: 3px; border-radius: 12px }
.wrap { width: var(--wrap); margin-inline: auto }
.skip { position: absolute; left: 12px; top: -60px; padding: 10px 14px; border-radius: 12px; background: #fff; z-index: 50 }
.skip:focus { top: 12px }

/* Nav */
.nav { position: sticky; top: 0; z-index: 20; height: var(--nav-h); display: flex; align-items: center;
  background: rgba(255, 246, 250, .72); -webkit-backdrop-filter: blur(18px) saturate(1.3); backdrop-filter: blur(18px) saturate(1.3);
  border-bottom: 1px solid rgba(255, 255, 255, .7) }
.nav-row { display: flex; align-items: center; gap: 18px }
.brand { display: flex; align-items: center; padding: 6px 4px; border-radius: 10px }
.brand img { display: block; height: 26px; width: auto }
.nav-links { display: flex; gap: 4px; margin-left: auto }
.nav-links a { position: relative; padding: 8px 12px; border-radius: 999px; text-decoration: none; font-weight: 700; font-size: 14px; color: var(--ink-soft); transition: color .2s, background-color .2s }
.nav-links a::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 4px; height: 2px; border-radius: 2px; background: var(--pink-deep); transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease) }
.nav-links a:hover { color: var(--ink-strong) }
.nav-links a:hover::after { transform: scaleX(1) }
.nav-links a:active { background: rgba(255, 255, 255, .6) }
.nav-actions { display: flex; align-items: center; gap: 10px }
.lang { display: inline-flex; padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, .55); border: 1px solid var(--glass-line) }
.lang button { min-width: 44px; min-height: 34px; padding: 0 12px; border: 0; border-radius: 999px; background: transparent; font-size: 13px; font-weight: 800; color: var(--ink-soft); transition: background-color .2s, color .2s }
.lang button[aria-pressed="true"] { background: #fff; color: var(--ink-strong); box-shadow: 0 1px 0 rgba(59, 22, 64, .08) }
.ai-pill { position: relative; display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border-radius: 999px; text-decoration: none;
  border: 1px solid rgba(255, 255, 255, .9); background: linear-gradient(120deg, rgba(255, 201, 222, .9), rgba(226, 210, 255, .9));
  box-shadow: inset 0 1px rgba(255, 255, 255, .9), inset 0 -3px rgba(111, 63, 209, .14), 0 3px 0 rgba(111, 63, 209, .14);
  transition: transform .18s var(--ease), box-shadow .18s }
.ai-pill span { font-family: "Comfortaa", "Nunito", sans-serif; font-weight: 700; font-size: 14px; letter-spacing: .02em;
  background: linear-gradient(100deg, #c42d72, #6f3fd1); -webkit-background-clip: text; background-clip: text; color: transparent }
.ai-pill:hover { transform: translateY(-1px); box-shadow: inset 0 1px rgba(255, 255, 255, .9), inset 0 -3px rgba(111, 63, 209, .14), 0 4px 0 rgba(111, 63, 209, .14) }
.ai-pill:active, .ai-pill.pressed { transform: translateY(2px); box-shadow: inset 0 1px rgba(255, 255, 255, .7), inset 0 -1px rgba(111, 63, 209, .14) }

/* Shared */
main > section { min-height: calc(100svh - var(--nav-h)); display: flex; align-items: center; padding-block: clamp(40px, 7vh, 80px) }
main > section > .wrap { width: var(--wrap) }
.eyebrow { margin: 0 0 14px; font: 500 12px/1 "DM Mono", ui-monospace, monospace; letter-spacing: .16em; text-transform: uppercase; color: var(--pink-deep) }
h1, h2, h3 { margin: 0; color: var(--ink-strong); letter-spacing: -.02em }
h1 { font-family: "Comfortaa", "PingFang TC", "Noto Sans TC", sans-serif; text-wrap: balance; font-size: clamp(32px, 4.4vw, 54px); line-height: 1.12; font-weight: 700 }
h2 { font-family: "Comfortaa", "PingFang TC", "Noto Sans TC", sans-serif; font-size: clamp(28px, 3.6vw, 42px); line-height: 1.15; font-weight: 700 }
h3 { font-size: clamp(20px, 2.2vw, 26px); font-weight: 800 }
.section-head { display: grid; gap: 8px; margin-bottom: clamp(22px, 3.5vh, 36px) }
.section-head p { margin: 0; color: var(--ink-soft); font-weight: 600 }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 22px; border-radius: 16px; text-decoration: none; font-weight: 800; font-size: 15px;
  transition: transform .18s var(--ease), box-shadow .18s, background-color .2s, border-color .2s }
.btn svg { transition: transform .25s var(--ease) }
.btn-primary { color: #5b1240; border: 1px solid rgba(255, 255, 255, .85); background: linear-gradient(120deg, #ffc4da, #ffaccb);
  box-shadow: inset 0 1px rgba(255, 255, 255, .85), inset 0 -3px rgba(196, 45, 114, .16), 0 3px 0 rgba(196, 45, 114, .18) }
.btn-ghost { color: var(--ink-strong); border: 1px solid rgba(111, 63, 209, .22); background: rgba(255, 255, 255, .62);
  box-shadow: inset 0 1px rgba(255, 255, 255, .9), 0 3px 0 rgba(111, 63, 209, .08) }
.btn:hover { transform: translateY(-1px) }
.btn:hover svg { transform: translate(2px, -2px) }
.btn-ghost:hover { border-color: rgba(111, 63, 209, .4) }
.btn:active, .btn.pressed { transform: translateY(2px); box-shadow: inset 0 1px rgba(255, 255, 255, .6), inset 0 -1px rgba(196, 45, 114, .12) }

/* Hero */
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(28px, 5vw, 72px); align-items: center }
.hero-lede { margin: 18px 0 0; max-width: 34em; font-size: clamp(16px, 1.4vw, 18px); font-weight: 600; color: var(--ink-soft) }
.facts { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0 0; padding: 0 }
.facts li { display: flex; align-items: baseline; gap: 8px; padding: 10px 14px; border-radius: 14px; background: var(--glass); border: 1px solid var(--glass-line); box-shadow: inset 0 1px rgba(255, 255, 255, .8) }
.facts strong { font: 500 18px/1 "DM Mono", ui-monospace, monospace; color: var(--pink-deep) }
.facts span { font-size: 13px; font-weight: 700; color: var(--ink-soft) }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px }

.app-frame { display: block; text-decoration: none; border-radius: 26px; overflow: hidden; border: 1px solid var(--glass-line); background: var(--glass-strong);
  box-shadow: var(--shadow), inset 0 1px rgba(255, 255, 255, .9); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
  transition: transform .35s var(--ease), box-shadow .35s }
.app-frame:hover { transform: translateY(-2px) }
.app-frame:active { transform: translateY(1px) }
.frame-bar { display: flex; align-items: center; gap: 6px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, .6) }
.frame-bar i { width: 10px; height: 10px; border-radius: 50%; background: #f3c6d8 }
.frame-bar i:nth-child(2) { background: #e3d3fb } .frame-bar i:nth-child(3) { background: #c9ece5 }
.frame-bar span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-left: 10px; padding: 4px 12px; border-radius: 999px; background: rgba(59, 22, 64, .05); font: 500 12px/1.2 "DM Mono", ui-monospace, monospace; color: var(--ink-soft) }
.frame-body { padding: 16px; background: linear-gradient(160deg, #f6f1fd, #fbf7ff 60%, #f3faf8) }
.mini-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px }
.mini-head img { height: 16px; width: auto }
.mini-head span { padding: 4px 10px; border-radius: 999px; font-size: 11px; font-weight: 800; color: #3a2d80; background: rgba(255, 255, 255, .8); border: 1px solid rgba(27, 79, 156, .12) }
.mini-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px }
.mini-card { position: relative; display: grid; grid-template-rows: auto auto 1fr; gap: 8px; min-height: 104px; padding: 12px; border-radius: 16px; border: 1px solid rgba(255, 255, 255, .9); background: #fff;
  box-shadow: 0 10px 24px -18px rgba(27, 40, 110, .5); transition: transform .3s var(--ease) }
.mini-card em { font: 500 9px/1 "DM Mono", monospace; color: #7b82a0; font-style: normal }
.mini-card b { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 9px; color: #fff; font-size: 13px; background: linear-gradient(140deg, #1b4f9c, #6b3d9a) }
.mini-card strong { align-self: end; font-size: 13px; line-height: 1.3; color: #0b285d }
.mini-card.dark { background: linear-gradient(150deg, #26478f, #5a3a93); border-color: rgba(255, 255, 255, .3) }
.mini-card.dark strong, .mini-card.dark em { color: #fff }
.mini-card.dark b { background: #fff; color: #3a2d80 }
.mini-card.mint { background: linear-gradient(150deg, #fff, #e8f7f3) }
.mini-card.lilac { background: linear-gradient(150deg, #fff, #efe7fb) }
.mini-card.is-lit { transform: translateY(-3px) }
.mini-card.is-lit::after { content: ""; position: absolute; inset: -1px; border-radius: inherit; border: 2px solid rgba(196, 45, 114, .55); pointer-events: none }

/* Tools explorer */
.explorer { display: grid; grid-template-columns: minmax(220px, .8fr) minmax(0, 2fr); gap: clamp(16px, 2.4vw, 28px); align-items: stretch }
.tool-list { display: flex; flex-direction: column; gap: 8px }
.tool-list button { display: grid; grid-template-columns: 30px 1fr; grid-template-rows: auto auto; column-gap: 8px; align-items: baseline; text-align: left; width: 100%;
  padding: 14px 16px; border-radius: 16px; border: 1px solid var(--glass-line); background: var(--glass); box-shadow: inset 0 1px rgba(255, 255, 255, .8);
  transition: transform .2s var(--ease), background-color .2s, border-color .2s }
.tool-list em { grid-row: span 2; font: 500 12px/1.6 "DM Mono", monospace; font-style: normal; color: var(--pink-deep) }
.tool-list span { font-weight: 800; color: var(--ink-strong) }
.tool-list small { font-size: 12px; font-weight: 700; color: var(--ink-soft) }
.tool-list button:hover { transform: translateX(3px); border-color: rgba(196, 45, 114, .28) }
.tool-list button:active, .tool-list button.pressed { transform: translateX(3px) scale(.985) }
.tool-list button[aria-selected="true"] { background: linear-gradient(120deg, rgba(255, 210, 228, .85), rgba(236, 224, 255, .85)); border-color: rgba(196, 45, 114, .34) }
.panel { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(18px, 2.4vw, 30px); padding: clamp(18px, 2.4vw, 28px); border-radius: 26px;
  border: 1px solid var(--glass-line); background: var(--glass); box-shadow: var(--shadow), inset 0 1px rgba(255, 255, 255, .9) }
.preview { position: relative; min-height: 260px; border-radius: 18px; padding: 18px; background: linear-gradient(160deg, #fbf8ff, #fff5fa); border: 1px solid rgba(255, 255, 255, .9); overflow: hidden }
.pv { display: grid; gap: 12px; animation: pv-in .38s var(--ease) both }
.pv[hidden] { display: none }
.pv-steps { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 800; font-size: 13px }
.pv-steps span { padding: 6px 12px; border-radius: 999px; background: #fff; border: 1px solid rgba(111, 63, 209, .2) }
.pv-steps i { font-style: normal; color: var(--ink-soft) }
.pv-rows, .pv-thread { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px }
.pv-rows li, .pv-thread li { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 14px; background: #fff; border: 1px solid var(--line); font-size: 13px; animation: row-in .4s var(--ease) both }
.pv-rows li:nth-child(2), .pv-thread li:nth-child(2) { animation-delay: .06s } .pv-rows li:nth-child(3), .pv-thread li:nth-child(3) { animation-delay: .12s }
.pv-rows b { font-size: 14px } .pv-rows span { color: var(--ink-soft); font-weight: 600 } .pv-rows em { font-style: normal; color: var(--pink-deep) }
.pv-thread .tag { padding: 3px 8px; border-radius: 8px; font-size: 11px; font-weight: 800; background: #ffe0ec; color: var(--pink-deep) }
.pv-thread .tag.alt { background: #ece2ff; color: var(--lilac-deep) }
.pv-thread em { font-style: normal; font-size: 12px; color: var(--ink-soft) }
.pv-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px }
.pv-fields span { padding: 10px 12px; border-radius: 12px; background: #fff; border: 1px solid var(--line); font-size: 13px; font-weight: 700 }
.pv-prompt { margin: 0; padding: 14px; white-space: normal !important; border-radius: 14px; background: #2d1236; color: #ffe5f0; font: 400 13px/1.7 "DM Mono", ui-monospace, monospace; white-space: pre-wrap; overflow: hidden }
.pv-prompt span { display: block; opacity: 0; animation: type-in .5s var(--ease) forwards }
.pv-prompt span:nth-child(2) { animation-delay: .35s } .pv-prompt span:nth-child(3) { animation-delay: .7s }
.pv-search { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 14px; background: #fff; border: 1px solid rgba(111, 63, 209, .2); font-weight: 700; color: var(--ink-soft) }
.pv-chips { display: flex; flex-wrap: wrap; gap: 8px }
.pv-chips span { padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: 13px; font-weight: 800; animation: row-in .4s var(--ease) both }
.pv-chips span:nth-child(2) { animation-delay: .05s } .pv-chips span:nth-child(3) { animation-delay: .1s } .pv-chips span:nth-child(4) { animation-delay: .15s }
.pv-videos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px }
.pv-videos span { position: relative; aspect-ratio: 16 / 10; border-radius: 12px; background: linear-gradient(150deg, #e9ddff, #ffd6e7); animation: row-in .4s var(--ease) both }
.pv-videos span:nth-child(even) { background: linear-gradient(150deg, #ffd6e7, #d9f2ec) }
.pv-videos span::after { content: ""; position: absolute; left: 50%; top: 50%; translate: -40% -50%; border-left: 12px solid rgba(255, 255, 255, .95); border-block: 8px solid transparent }
.pv-quiz { display: grid; gap: 8px; padding: 14px; border-radius: 16px; background: #fff; border: 1px solid var(--line) }
.pv-quiz-top { display: flex; gap: 10px; font: 500 11px/1 "DM Mono", monospace; color: var(--ink-soft) }
.pv-quiz-top .pv-lang { margin-left: auto; padding: 3px 8px; border-radius: 999px; background: #f4ecff }
.pv-quiz b { font-size: 14px; line-height: 1.5 }
.pv-quiz .opt { padding: 9px 12px; border-radius: 12px; border: 1px solid var(--line); font-size: 13px; font-weight: 700 }
.pv-quiz .opt.ok { border-color: #8fd2bf; background: #eef9f5; color: #1f6a55 }
.panel-copy { display: flex; flex-direction: column; gap: 14px; animation: pv-in .38s var(--ease) both }
.panel-copy p { margin: 0; font-weight: 600; color: var(--ink-soft); font-size: 16px }
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 0 }
.points li { padding: 10px 0; border-top: 1px solid var(--line); font-weight: 700; font-size: 15px }
.points li::before { content: "·"; margin-right: 10px; color: var(--pink-deep); font-weight: 800 }
.panel-copy .btn { align-self: flex-start; margin-top: auto }

/* KCIS AI */
.ai-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center }
.ai-copy > p { margin: 14px 0 0; font-weight: 600; color: var(--ink-soft); font-size: 17px }
.ai-points { list-style: none; margin: 22px 0 0; padding: 0 }
.ai-points li { display: grid; grid-template-columns: 7.5em 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 15px }
.ai-points b { color: var(--pink-deep) } .ai-points span { font-weight: 600 }
.chips-label { margin: 22px 0 10px; font: 500 12px/1 "DM Mono", monospace; letter-spacing: .1em; color: var(--ink-soft) }
.ask-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px }
.chip { min-height: 42px; padding: 0 14px; border-radius: 999px; border: 1px solid rgba(111, 63, 209, .2); background: rgba(255, 255, 255, .7); font-size: 14px; font-weight: 700; text-align: left;
  transition: transform .18s var(--ease), border-color .2s, background-color .2s }
.chip:hover { transform: translateY(-1px); border-color: rgba(196, 45, 114, .35) }
.chip:active, .chip.pressed { transform: translateY(1px); background: #ffe5ef }
.chip.copied { border-color: #8fd2bf; background: #eef9f5 }
.chat { display: grid; gap: 12px; padding: clamp(18px, 2.4vw, 26px); border-radius: 26px; border: 1px solid var(--glass-line); background: var(--glass); box-shadow: var(--shadow), inset 0 1px rgba(255, 255, 255, .9) }
.bubble { max-width: 88%; padding: 14px 16px; border-radius: 18px; font-size: 15px; font-weight: 600 }
.bubble.me { justify-self: end; background: linear-gradient(120deg, #ffc4da, #ffb3cf); color: #4b0f35; border-bottom-right-radius: 6px }
.bubble.ai { background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 6px }
.bubble.ai p { margin: 0 } .bubble.ai ul { margin: 8px 0; padding-left: 18px } .bubble.ai li { margin: 4px 0 }
.bubble .src { margin-top: 6px !important; font: 500 12px/1.4 "DM Mono", monospace; color: var(--lilac-deep) }
.typing { display: flex; gap: 5px; padding: 12px 16px; width: max-content; border-radius: 16px; background: #fff; border: 1px solid var(--line) }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: #d7b9e8; animation: dot 1.2s infinite ease-in-out }
.typing i:nth-child(2) { animation-delay: .15s } .typing i:nth-child(3) { animation-delay: .3s }

/* Access */
.access-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px }
.acc { position: relative; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto auto; gap: 6px 12px; align-items: center; padding: 20px 20px 18px; min-height: 132px; border-radius: var(--radius); text-decoration: none;
  border: 1px solid var(--glass-line); background: var(--glass); box-shadow: inset 0 1px rgba(255, 255, 255, .85); transition: transform .2s var(--ease), border-color .2s }
.acc em { grid-row: span 3; align-self: start; padding-top: 4px; font: 500 12px/1 "DM Mono", monospace; font-style: normal; color: var(--pink-deep) }
.acc strong { font-size: 16px; color: var(--ink-strong) }
.need { justify-self: start; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 800 }
.need.open { background: #e6f6f1; color: #1f6a55 } .need.school { background: #efe6ff; color: var(--lilac-deep) } .need.code { background: #ffe3ee; color: var(--pink-deep) }
.acc:hover { transform: translateY(-2px); border-color: rgba(196, 45, 114, .3) }
.acc:active, .acc.pressed { transform: translateY(1px) }
.privacy { display: flex; align-items: center; gap: 10px; margin: 22px 0 0; padding: 14px 16px; border-radius: 16px; background: rgba(255, 255, 255, .5); border: 1px dashed rgba(196, 45, 114, .3); font-weight: 700; font-size: 14px }
.privacy svg { color: var(--pink-deep) }

/* Footer */
.foot { padding: 26px 0 calc(26px + env(safe-area-inset-bottom)); border-top: 1px solid rgba(255, 255, 255, .8); background: rgba(255, 255, 255, .4) }
.foot-row { display: flex; align-items: center; gap: 18px; flex-wrap: wrap }
.foot-row img { height: 20px; width: auto; opacity: .85 }
.foot-row nav { display: flex; gap: 14px }
.foot-row nav a, .sign { text-decoration: none; font-weight: 700; font-size: 14px; color: var(--ink-soft); background: linear-gradient(currentColor 0 0) 0 100% / 0 1.5px no-repeat; transition: background-size .25s var(--ease), color .2s }
.foot-row nav a:hover, .sign:hover { color: var(--ink-strong); background-size: 100% 1.5px }
.sign { margin-left: auto; font: 500 12px/1 "DM Mono", monospace }

.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); translate: -50% 20px; opacity: 0; padding: 10px 16px; border-radius: 14px; background: #2d1236; color: #fff; font-weight: 700; font-size: 14px; pointer-events: none; transition: opacity .25s, translate .25s var(--ease); z-index: 40 }
.toast.show { opacity: 1; translate: -50% 0 }

/* Motion */
@keyframes pv-in { from { opacity: 0; transform: translateY(8px) } }
@keyframes row-in { from { opacity: 0; transform: translateY(6px) } }
@keyframes type-in { from { opacity: 0; transform: translateX(-4px) } to { opacity: 1 } }
@keyframes dot { 0%, 80%, 100% { transform: translateY(0); opacity: .5 } 40% { transform: translateY(-4px); opacity: 1 } }
@keyframes enter { from { opacity: 0; transform: translateY(14px) } }
@media (prefers-reduced-motion: no-preference) {
  .hero-copy > * { animation: enter .6s var(--ease) both }
  .hero-copy > :nth-child(2) { animation-delay: .05s } .hero-copy > :nth-child(3) { animation-delay: .1s } .hero-copy > :nth-child(4) { animation-delay: .15s } .hero-copy > :nth-child(5) { animation-delay: .2s }
  .app-frame { animation: enter .7s .12s var(--ease) both }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important }
  .pv-prompt span { opacity: 1 }
}

/* Tablet */
@media (max-width: 900px) { .hero-grid, .ai-grid { grid-template-columns: 1fr } }
@media (max-width: 1024px) {
  .explorer { grid-template-columns: 1fr }
  .tool-list { flex-direction: row; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; margin-inline: calc((100% - 100dvw) / 2 + 0px); padding-inline: calc((100dvw - 100%) / 2); scroll-padding-inline: calc((100dvw - 100%) / 2); scrollbar-width: none }
  .tool-list::-webkit-scrollbar { display: none }
  .tool-list button { flex: 0 0 auto; width: auto; min-width: 190px; scroll-snap-align: start }
  .tool-list button:hover { transform: translateY(-1px) }
  .access-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) }
  main > .access { min-height: auto }
}
/* Phone portrait */
@media (max-width: 640px) {
  :root { --nav-h: 60px }
  .nav-links { display: none }
  .nav-actions { margin-left: auto; gap: 8px }
  .brand img { height: 22px }
  .ai-pill { min-height: 38px; padding: 0 14px }
  .lang button { min-width: 40px; padding: 0 10px }
  .panel { grid-template-columns: 1fr; padding: 14px }
  .preview { min-height: 0 }
  .pv-fields { grid-template-columns: 1fr }
  .section-head { flex-direction: column; align-items: flex-start; gap: 6px }
  .hero-actions .btn, .panel-copy .btn, .ai-copy .btn { width: 100%; justify-content: center }
  .access-grid { grid-template-columns: 1fr }
  .ai-points li { grid-template-columns: 1fr; gap: 2px }
  .mini-card { min-height: 64px; padding: 10px; gap: 4px }
  .mini-card b { width: 22px; height: 22px; font-size: 11px; border-radius: 7px }
  .mini-card strong { font-size: 12px }
  .hero { padding-block: 22px 28px }
  .hero-grid { gap: 22px }
  .hero-lede { margin-top: 12px; font-size: 15px }
  .facts { margin-top: 16px; gap: 6px; flex-wrap: nowrap }
  .facts li { padding: 8px 10px; flex-direction: column; gap: 2px; flex: 1 }
  .facts strong { font-size: 16px } .facts span { font-size: 11px }
  .hero-actions { margin-top: 18px; gap: 8px }
  .frame-body { padding: 12px } .mini-head { margin-bottom: 8px }
  .eyebrow { margin-bottom: 10px }
  .sign { margin-left: 0 }
}
@media (max-width: 380px) { .lang { display: none } }
/* Phone landscape and short screens */
@media (max-height: 520px) and (orientation: landscape) {
  :root { --nav-h: 54px }
  main > section { min-height: auto; padding-block: 28px }
  main > .hero { min-height: calc(100svh - var(--nav-h)); padding-block: 16px }
  .hero-grid { grid-template-columns: 1fr 1fr; gap: 24px }
  h1 { font-size: clamp(26px, 4vw, 36px) }
  .facts { margin-top: 14px } .hero-actions { margin-top: 16px }
  .mini-grid { grid-template-columns: repeat(3, 1fr); gap: 8px }
  .mini-card { min-height: 0; padding: 8px; gap: 3px; grid-template-rows: auto auto }
  .mini-card em { display: none }
  .mini-card b { width: 20px; height: 20px; font-size: 10px; border-radius: 6px }
  .mini-card strong { font-size: 11px }
  .frame-bar { padding: 8px 12px } .frame-body { padding: 10px } .mini-head { margin-bottom: 6px }
  .hero-lede { margin-top: 8px; font-size: 14px }
  .facts { flex-wrap: nowrap; gap: 6px; margin-top: 10px }
  .facts li { padding: 6px 10px } .facts strong { font-size: 14px } .facts span { font-size: 11px }
  .hero-actions .btn { min-height: 44px; padding: 0 16px }
  .eyebrow { margin-bottom: 8px }
  .explorer { grid-template-columns: minmax(180px, .7fr) 2fr }
  .tool-list { flex-direction: column; overflow: visible; margin: 0; padding: 0 }
  .tool-list button { min-width: 0; padding: 10px 12px }
  .panel { grid-template-columns: 1fr 1fr }
  .ai-grid { grid-template-columns: 1fr 1fr }
}
/* Touch: give pressed feedback that matches hover */
@media (hover: none) {
  .btn:active, .chip:active, .acc:active, .tool-list button:active { transition-duration: .06s }
}

.acc small { font-size: 13px; font-weight: 700; color: var(--ink-soft) }
.acc-go { position: absolute; right: 18px; top: 18px; color: var(--ink-soft); transition: transform .25s var(--ease), color .2s }
.acc:hover .acc-go { transform: translate(2px, -2px); color: var(--pink-deep) }
main > .access { min-height: auto; padding-block: clamp(56px, 9vh, 96px) }
