:root {
  --blue: #0ea5e9;
  --blue-dark: #0369a1;
  --blue-soft: #e0f7ff;
  --line: #cfe5f3;
  --ink: #0f172a;
  --text: #334155;
  --muted: #64748b;
  --yellow: #fde68a;
  --orange: #f97316;
  --page: #f8fbff;
  --white: #ffffff;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  min-width: min(320px, 100%);
  overflow-x: clip;
  background: var(--page);
  color: var(--ink);
  font-family: Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

body { margin: 0; min-height: 100vh; overflow-x: clip; }
h1, p, figure { margin: 0; }
img { display: block; max-width: 100%; }

.landing {
  position: relative;
  display: grid;
  min-height: 100svh;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  background: var(--page);
  isolation: isolate;
}

.landing::before {
  content: "";
  position: absolute;
  right: -9vw;
  top: 13%;
  z-index: -2;
  width: 46vw;
  min-width: 500px;
  height: 62%;
  border: 1px solid #9bd8f8;
  border-radius: 74px 0 0 74px;
  background: var(--blue-soft);
  transform: rotate(-4deg);
}

.landing::after {
  content: "";
  position: absolute;
  left: max(20px, calc((100vw - 1120px) / 2 - 70px));
  bottom: 112px;
  width: 190px;
  height: 1px;
  background: #9bd8f8;
  opacity: 0.45;
}

.brand {
  position: absolute;
  top: 25px;
  left: max(24px, calc((100vw - 1120px) / 2));
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 16px;
  font-weight: 900;
}

.hero {
  display: grid;
  width: min(calc(100% - 48px), 1120px);
  min-width: 0;
  margin: 0 auto;
  grid-template-columns: minmax(0, 1.03fr) minmax(360px, 0.97fr);
  align-items: center;
  gap: 70px;
  padding: 118px 0 70px;
}

.hero-copy {
  display: grid;
  min-width: 0;
  gap: 24px;
  animation: copy-in 680ms var(--ease) both;
}

.rule {
  width: 120px;
  height: 7px;
  border-radius: 999px;
  background: var(--blue);
  box-shadow: 31px 0 0 var(--yellow);
}

h1 {
  max-width: 680px;
  font-size: clamp(52px, 5.4vw, 74px);
  font-weight: 900;
  line-height: 1.05;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.hero-copy p {
  color: var(--text);
  font-size: 19px;
  font-weight: 520;
  line-height: 1.8;
}

.hero-copy small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.visual {
  position: relative;
  width: min(100%, 500px);
  aspect-ratio: 1 / 0.9;
  justify-self: center;
  animation: visual-in 800ms 80ms var(--ease) both;
}

.slab {
  position: absolute;
  inset: 10% 3% 2% 9%;
  border: 1px solid #7dd3fc;
  border-radius: 58px 16px 48px 18px;
  background: #dff6ff;
  transform: rotate(4deg);
}

.dots {
  position: absolute;
  right: 5%;
  bottom: 8%;
  display: grid;
  grid-template-columns: repeat(4, 4px);
  gap: 11px;
  opacity: 0.18;
}

.dots i { width: 4px; height: 4px; border-radius: 50%; background: var(--blue); }

.paper-shadow {
  position: absolute;
  inset: 22% 13% 11% 16%;
  border-radius: 22px 7px 25px 7px;
  background: #9bd8f8;
  transform: translate(18px, 22px) rotate(-2deg);
  opacity: 0.58;
}

.paper {
  position: absolute;
  inset: 18% 16% 15% 11%;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: 22px 7px 25px 7px;
  background: var(--white);
  box-shadow: 0 22px 52px rgba(14, 165, 233, 0.13);
  animation: paper-float 6s var(--ease) infinite;
}

.binding {
  position: absolute;
  inset: 0 auto 0 0;
  display: flex;
  width: 52px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  border-right: 1px solid var(--line);
  background: #f1f9ff;
}

.binding i {
  width: 14px;
  aspect-ratio: 1;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  background: var(--blue);
}

.paper-title,
.paper-line {
  position: absolute;
  left: 78px;
  display: block;
  height: 7px;
  border-radius: 999px;
}

.paper-title { top: 58px; width: 42%; height: 10px; background: var(--blue); }
.paper-line { background: #94a3b8; }
.line-dark { top: 101px; width: 58%; background: var(--ink); }
.line-wide { top: 142px; width: 67%; }
.line-short { top: 183px; width: 42%; }

.pen {
  position: absolute;
  right: 2%;
  top: 5%;
  z-index: 4;
  width: 64px;
  height: 320px;
  transform: rotate(34deg);
  transform-origin: 50% 70%;
  filter: drop-shadow(13px 15px 0 rgba(125, 211, 252, 0.44));
  animation: pen-float 6s 220ms var(--ease) infinite;
}

.pen i {
  position: absolute;
  left: 50%;
  display: block;
  border: 2px solid var(--ink);
  transform: translateX(-50%);
}

.pen-cap { top: 0; width: 60px; height: 50px; border-radius: 28px 28px 7px 7px; background: var(--white); }
.pen-body { top: 42px; width: 52px; height: 184px; background: var(--blue); box-shadow: inset 11px 0 0 var(--yellow), inset 17px 0 0 var(--white); }
.pen-grip { top: 224px; width: 52px; height: 43px; background: #fff7d6; }
.pen-nib { top: 265px; width: 42px; height: 42px; background: var(--white); clip-path: polygon(0 0, 100% 0, 50% 100%); }

.frame {
  position: absolute;
  z-index: -1;
  border: 1px solid var(--line);
  pointer-events: none;
}

.frame-left {
  left: max(18px, calc((100vw - 1120px) / 2 - 100px));
  top: 16%;
  width: 110px;
  aspect-ratio: 1;
  border-radius: 44% 56% 48% 52%;
  transform: rotate(12deg);
  opacity: 0.55;
}

.frame-right {
  right: max(18px, calc((100vw - 1120px) / 2 - 70px));
  bottom: 14%;
  width: 72px;
  aspect-ratio: 1;
  border-color: #7dd3fc;
  border-radius: 50%;
  opacity: 0.36;
}

footer {
  display: grid;
  min-height: 72px;
  place-items: center;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  font-size: 12px;
}

footer p { margin: 0; }

@keyframes copy-in {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes visual-in {
  from { opacity: 0; transform: translateY(24px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes paper-float {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-7px) rotate(-0.2deg); }
}

@keyframes pen-float {
  0%, 100% { transform: rotate(34deg) translateY(0); }
  50% { transform: rotate(35deg) translateY(-7px); }
}

@media (max-width: 860px) {
  .landing::before { top: 53%; right: -44%; width: 92vw; min-width: 460px; height: 42%; }
  .landing::after, .frame-right { display: none; }
  .brand { left: 24px; }
  .hero {
    width: min(calc(100% - 32px), 680px);
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 108px 0 44px;
  }
  .hero-copy { gap: 18px; }
  h1 { font-size: clamp(42px, 10vw, 58px); }
  .hero-copy p { font-size: 16px; }
  .visual { width: min(76vw, 370px); }
  .frame-left { top: 39%; left: -38px; opacity: 0.35; }
}

@media (max-width: 520px) {
  .brand { top: 18px; left: 18px; font-size: 15px; }
  .brand img { width: 36px; height: 36px; }
  .hero { width: calc(100% - 28px); gap: 22px; padding: 92px 0 34px; }
  .hero-copy { gap: 16px; }
  .rule { width: 92px; height: 6px; box-shadow: 24px 0 0 var(--yellow); }
  h1 { font-size: 40px; line-height: 1.08; }
  .hero-copy small { font-size: 9px; }
  .visual { width: min(88vw, 320px); }
  .paper-title, .paper-line { left: 60px; }
  .paper-title { top: 42px; }
  .line-dark { top: 74px; }
  .line-wide { top: 106px; }
  .line-short { top: 138px; }
  .binding { width: 41px; gap: 23px; }
  .binding i { width: 11px; }
  .pen { top: 3%; right: 0; transform: rotate(34deg) scale(0.82); transform-origin: top center; }
  footer { min-height: 64px; }
}

@media (max-height: 700px) and (min-width: 861px) {
  .hero { padding-top: 94px; padding-bottom: 36px; }
  .visual { width: min(44vw, 420px); }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
  }
}
