/* Thread & Thimble — quilt shop template. Colours & fonts in :root. */
:root {
  --berry: #e0195f;
  --berry-d: #b80f4b;
  --teal: #1aa39a;
  --mustard: #f2b134;
  --violet: #7b5cff;
  --ink: #2b2230;
  --ink-2: #4c4352;
  --muted: #7a7180;
  --linen: #faf6f0;
  --linen-2: #f3ece1;
  --paper: #fff;
  --line: #e9e0d3;
  --radius: 22px;
  --shadow: 0 18px 40px -18px rgba(43, 34, 48, .35);
  --head: "Fraunces", Georgia, serif;
  --body: "Nunito", system-ui, sans-serif;
  --hand: "Caveat", cursive;
  --stitch: repeating-linear-gradient(90deg, currentColor 0 10px, transparent 10px 18px);
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; font: 400 17px/1.7 var(--body); color: var(--ink-2); background: var(--linen); overflow-x: hidden; }
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; }
svg { width: 1.2em; height: 1.2em; flex: none; }
h1, h2, h3 { font-family: var(--head); color: var(--ink); line-height: 1.12; margin: 0 0 .45em; letter-spacing: -.01em; }
h2 { font-size: clamp(2rem, 4.5vw, 3.2rem); }
h3 { font-size: 1.4rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px dashed var(--berry); outline-offset: 4px; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 28px; } }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; }
.skip:focus { top: 12px; }
.hand { font-family: var(--hand); font-size: 1.7rem; color: var(--berry); margin: 0 0 .1em; line-height: 1.1; }
.section { padding: clamp(70px, 10vw, 120px) 0; position: relative; }
.head { text-align: center; max-width: 680px; margin: 0 auto clamp(36px, 5vw, 60px); }
.head p:last-child { color: var(--muted); }
.head--light h2 { color: #fff; }
.head--light p:last-child { color: #cfc5d6; }

/* buttons: stitched outline that "sews" on hover */
.btn { position: relative; display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 12px 28px; border: 0; border-radius: 999px; background: var(--berry); color: #fff; font: 800 1rem var(--body); text-decoration: none; cursor: pointer; transition: transform .25s, background-color .25s, box-shadow .25s; box-shadow: 0 12px 26px -12px rgba(224, 25, 95, .8); }
.btn::after { content: ""; position: absolute; inset: 5px; border-radius: inherit; border: 2px dashed rgba(255, 255, 255, .55); opacity: 0; transition: opacity .25s; }
.btn:hover { transform: translateY(-3px); background: var(--berry-d); }
.btn:hover::after { opacity: 1; animation: sew 1s linear infinite; }
@keyframes sew { to { border-color: rgba(255, 255, 255, .95); } }
.btn--ghost { background: rgba(255, 255, 255, .12); box-shadow: none; border: 2px solid rgba(255, 255, 255, .7); backdrop-filter: blur(6px); }
.btn--ghost:hover { background: #fff; color: var(--ink); }
.btn--small { min-height: 42px; padding: 8px 20px; font-size: .92rem; }
.round { width: 52px; height: 52px; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, .5); background: rgba(255, 255, 255, .08); color: #fff; display: grid; place-items: center; cursor: pointer; transition: background-color .2s, transform .2s; }
.round:hover { background: var(--berry); border-style: solid; transform: scale(1.06); }

/* tape-measure progress */
.tape { position: fixed; inset: 0 0 auto; height: 12px; z-index: 120; background: #fff8d9; box-shadow: 0 1px 0 #d8c98c; pointer-events: none;
  background-image: repeating-linear-gradient(90deg, #6b5d2a 0 1px, transparent 1px 10px), repeating-linear-gradient(90deg, #6b5d2a 0 1.5px, transparent 1.5px 50px);
  background-size: auto 5px, auto 9px; background-repeat: repeat-x; background-position: 0 0, 0 0; }
.tape__fill { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--mustard); mix-blend-mode: multiply; }

/* ---------- 3D push menu ---------- */
body { perspective: 1600px; }
.stage { position: relative; background: var(--linen); transform-origin: 0% 50%; transition: transform .7s cubic-bezier(.2, .8, .2, 1), border-radius .7s, box-shadow .7s; }
.menu-open { overflow: hidden; }
.menu-open .stage { transform: translateX(min(55vw, 420px)) rotateY(-18deg) scale(.86); border-radius: 26px; overflow: hidden; height: 100vh; box-shadow: -40px 0 80px rgba(0, 0, 0, .45); cursor: pointer; }
.menu3d { position: fixed; inset: 0; z-index: 0; background: radial-gradient(120% 90% at 0 0, #3d2f45, var(--ink)); color: #fff; padding: 100px 28px 40px; display: flex; flex-direction: column; justify-content: center; }
.menu3d::before { content: ""; position: absolute; left: 22px; top: 0; bottom: 0; border-left: 2px dashed rgba(255, 255, 255, .15); }
.menu3d ul { list-style: none; margin: 0; padding: 0; perspective: 800px; }
.menu3d a { display: flex; align-items: baseline; gap: 14px; padding: 6px 18px; font: 700 clamp(1.7rem, 5vw, 2.6rem) / 1.3 var(--head); text-decoration: none; color: #fff; opacity: 0; transform: rotateY(70deg) translateX(-40px); transform-origin: 0 50%; transition: transform .6s cubic-bezier(.2, .8, .2, 1), opacity .5s, color .2s; }
.menu3d a span { font: 800 .8rem var(--body); color: var(--mustard); }
.menu3d a:hover { color: var(--mustard); }
.menu-open .menu3d a { opacity: 1; transform: none; }
.menu-open .menu3d li:nth-child(2) a { transition-delay: .05s; } .menu-open .menu3d li:nth-child(3) a { transition-delay: .1s; }
.menu-open .menu3d li:nth-child(4) a { transition-delay: .15s; } .menu-open .menu3d li:nth-child(5) a { transition-delay: .2s; }
.menu-open .menu3d li:nth-child(6) a { transition-delay: .25s; } .menu-open .menu3d li:nth-child(7) a { transition-delay: .3s; }
@media (max-width: 600px) { .menu-open .stage { transform: translateX(66vw) rotateY(-24deg) scale(.8); } .menu3d a { font-size: 1.55rem; } }
.menu3d__note { margin: 26px 18px 0; color: #cfc5d6; font-family: var(--hand); font-size: 1.5rem; }
.stage { z-index: 1; }

/* ---------- header with flip-cube links ---------- */
.header { position: fixed; top: 12px; left: 0; right: 0; z-index: 100; transition: transform .4s, top .3s; }
.header__in { display: flex; align-items: center; gap: 20px; }
.header.is-solid .header__in { background: rgba(255, 255, 255, .92); backdrop-filter: blur(12px); border-radius: 999px; box-shadow: var(--shadow); padding-top: 8px; padding-bottom: 8px; }
.menu-open .header { position: absolute; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 800 1.35rem var(--head); color: #fff; color: var(--logo, #fff); white-space: nowrap; }
.logo em { color: var(--berry); font-style: normal; }
.logo__mark { width: 40px; height: 40px; color: var(--berry); transition: transform .6s; }
.logo:hover .logo__mark { transform: rotate(360deg); }
.header.is-solid .logo { --logo: var(--ink); }
.logo--light { --logo: #fff; }
.logo--light .logo__mark { color: var(--mustard); }
.nav { display: flex; gap: 2px; margin-left: auto; perspective: 400px; }
.flip { display: block; padding: 8px 12px; text-decoration: none; font-weight: 800; color: #fff; height: 42px; overflow: visible; }
.header.is-solid .flip { color: var(--ink); }
.flip span { position: relative; display: block; line-height: 26px; transform-origin: 50% 0; transform-style: preserve-3d; transition: transform .4s cubic-bezier(.2, .8, .2, 1); }
.flip span::after { content: attr(data-t); position: absolute; left: 0; top: 0; color: var(--berry); transform-origin: 50% 0; transform: translate3d(0, 105%, 0) rotateX(-90deg); }
.flip:hover span, .flip:focus-visible span { transform: translate3d(0, 0, -26px) rotateX(90deg); }
.header__cta { margin-left: 4px; }
.burger { display: none; width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--berry); cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; box-shadow: 0 10px 20px -10px rgba(224, 25, 95, .9); }
.burger span { width: 22px; height: 2.5px; background: #fff; border-radius: 2px; transition: transform .35s, opacity .2s; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
.menu-open .burger { position: fixed; top: 20px; left: 20px; z-index: 300; }
@media (max-width: 1000px) {
  .nav, .header__cta { display: none; }
  .burger { display: flex; margin-left: auto; }
}

/* ---------- hero (3D scene) ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: grid; place-items: center; overflow: hidden; color: #fff; background: var(--ink); perspective: 1000px; isolation: isolate; }
.hero__scene { position: absolute; inset: 0; transform-style: preserve-3d; }
.layer { will-change: transform; transition: transform .25s ease-out; }
.hero__quilt { position: absolute; inset: -8%; background: center / cover no-repeat; transform: translateZ(-30px) scale(1.08); animation: breathe 18s ease-in-out infinite alternate; }
@keyframes breathe { to { background-position: 60% 40%; } }
.hero__shade { position: absolute; inset: 0; background: radial-gradient(80% 70% at 50% 50%, rgba(43, 34, 48, .55), rgba(43, 34, 48, .88)); }
.spool { position: absolute; width: calc(70px * var(--s, 1)); height: calc(94px * var(--s, 1)); filter: drop-shadow(0 18px 18px rgba(0, 0, 0, .45)); animation: float 6s ease-in-out infinite; animation-delay: var(--d, 0s); }
.spool use { transform-origin: 30px 40px; }
@keyframes float { 0%, 100% { translate: 0 0; rotate: -8deg; } 50% { translate: 0 -18px; rotate: 8deg; } }
.button-float { position: absolute; width: calc(46px * var(--s, 1)); height: calc(46px * var(--s, 1)); border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff6, transparent 40%), var(--bc, var(--berry)); box-shadow: inset 0 -4px 8px rgba(0, 0, 0, .3), 0 10px 18px rgba(0, 0, 0, .35); animation: spin 14s linear infinite; }
.button-float::before { content: ""; position: absolute; inset: 0; margin: auto; width: 46%; height: 46%; background: radial-gradient(circle, #0007 0 2.5px, transparent 3px) 0 0 / 50% 50%; }
.button-float::after { content: ""; position: absolute; inset: 12%; border-radius: 50%; border: 1.5px dashed rgba(255, 255, 255, .45); }
@keyframes spin { to { rotate: 360deg; } }
.hero__thread { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; }
.hero__content { position: relative; z-index: 2; text-align: center; padding: 120px 16px 90px; max-width: 940px; }
.hero__content .hand { color: var(--mustard); font-size: 2rem; }
.hero__title { color: #fff; font-size: clamp(2.6rem, 8vw, 6rem); line-height: 1.02; margin-bottom: .2em; text-shadow: 0 6px 30px rgba(0, 0, 0, .35); }
.rotator { display: grid; perspective: 600px; }
.rotator span { grid-area: 1 / 1; opacity: 0; transform: rotateX(-80deg) translateY(30px); transform-origin: 50% 100%; transition: transform .8s cubic-bezier(.2, .8, .2, 1), opacity .6s; }
.rotator span.is-on { opacity: 1; transform: none; }
.rotator span.is-out { opacity: 0; transform: rotateX(80deg) translateY(-30px); }
.stitch-line { width: min(520px, 80%); height: 26px; display: block; margin: 0 auto 20px; overflow: visible; }
.stitch-line path { fill: none; stroke: var(--mustard); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 14 10; animation: march 1.2s linear infinite; }
@keyframes march { to { stroke-dashoffset: -24; } }
.hero__lead { font-size: clamp(1.05rem, 2vw, 1.25rem); max-width: 620px; margin: 0 auto 30px; color: #efe7f3; }
.hero__cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.scroll-cue { position: absolute; bottom: 26px; left: 50%; z-index: 4; width: 30px; height: 50px; margin-left: -15px; border: 2px dashed rgba(255, 255, 255, .7); border-radius: 20px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 10px; margin-left: -2px; border-radius: 2px; background: #fff; animation: cue 1.6s infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(20px); opacity: 0; } }
@media (max-width: 640px) { .spool { --s: .6 !important; } .button-float { display: none; } }

/* ---------- about ---------- */
.about__grid { display: grid; gap: 60px; align-items: center; }
@media (min-width: 900px) { .about__grid { grid-template-columns: 1fr 1fr; } }
.about__media { position: relative; padding: 0 18% 14% 0; perspective: 900px; }
.frame { margin: 0; padding: 12px; background: #fff; border-radius: 18px; box-shadow: var(--shadow); position: relative; transform-style: preserve-3d; }
.frame::before { content: ""; position: absolute; inset: 5px; border: 2px dashed var(--berry); border-radius: 14px; opacity: .55; pointer-events: none; }
.frame img { border-radius: 10px; width: 100%; }
.frame--small { position: absolute; right: 0; bottom: 0; width: 46%; }
.frame--small::before { border-color: var(--teal); }
.badge-stitch { position: absolute; left: -6px; bottom: 6%; padding: 16px 18px; border-radius: 18px; background: var(--mustard); color: var(--ink); font-weight: 800; line-height: 1.2; box-shadow: var(--shadow); outline: 2px dashed rgba(43, 34, 48, .5); outline-offset: -8px; animation: float 7s ease-in-out infinite; }
.badge-stitch strong { display: block; font: 800 2rem var(--head); }
.ticks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 10px; }
@media (min-width: 560px) { .ticks { grid-template-columns: 1fr 1fr; } }
.ticks li { position: relative; padding-left: 34px; font-weight: 700; color: var(--ink); }
.ticks li::before { content: "✂"; position: absolute; left: 0; top: -2px; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: #fde3ec; color: var(--berry); font-size: .85rem; }

/* seam divider */
.seam { height: 60px; color: var(--berry); }
.seam svg { width: 100%; height: 100%; display: block; }
.seam path { fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 12 10; stroke-dashoffset: 1400; transition: stroke-dashoffset 2.4s ease-out; }
.seam.is-in path { stroke-dashoffset: 0; }

/* ---------- services: 3D flip cards ---------- */
.cards { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.card3d { perspective: 1000px; height: 300px; outline: none; }
.card3d__in { position: relative; height: 100%; transform-style: preserve-3d; transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
.card3d:hover .card3d__in, .card3d:focus-visible .card3d__in, .card3d.is-flipped .card3d__in { transform: rotateY(180deg); }
.card3d__front, .card3d__back { position: absolute; inset: 0; border-radius: var(--radius); backface-visibility: hidden; -webkit-backface-visibility: hidden; padding: 28px 24px; display: flex; flex-direction: column; }
.card3d__front { background: var(--c); color: #fff; justify-content: flex-end; box-shadow: var(--shadow); overflow: hidden; }
.card3d__front::before { content: ""; position: absolute; inset: 8px; border: 2px dashed rgba(255, 255, 255, .45); border-radius: 16px; }
.card3d__front::after { content: ""; position: absolute; width: 180px; height: 180px; right: -50px; top: -50px; border-radius: 50%; background: rgba(255, 255, 255, .12); }
.card3d__front svg { width: 60px; height: 60px; margin-bottom: auto; transition: transform .6s; }
.card3d:hover .card3d__front svg { transform: rotate(-12deg) scale(1.1); }
.card3d__front h3 { color: #fff; margin: 0; font-size: 1.6rem; }
.card3d__front p { margin: 0; opacity: .85; font-weight: 700; }
.card3d__back { transform: rotateY(180deg); background: #fff; border: 2px dashed var(--line); justify-content: center; gap: 14px; font-size: .98rem; }
.card3d__back a { color: var(--berry); font-weight: 800; text-decoration: none; }

/* ---------- machine band ---------- */
.band { position: relative; padding: clamp(80px, 12vw, 150px) 0; color: #fff; text-align: center; background: var(--ink) var(--img) center / cover fixed; overflow: hidden; }
@media (hover: none) { .band { background-attachment: scroll; } }
.band::before { content: ""; position: absolute; inset: 0; background: linear-gradient(rgba(43, 34, 48, .78), rgba(43, 34, 48, .88)); }
.band__in { position: relative; }
.band blockquote { margin: 0 auto; max-width: 800px; font: 700 clamp(1.5rem, 3.6vw, 2.5rem) / 1.3 var(--head); }
.band__by { font-family: var(--hand); font-size: 1.6rem; color: var(--mustard); margin-top: 14px; }
.machine { position: relative; width: min(400px, 80%); height: 70px; margin: 0 auto 30px; }
.machine__needle { position: absolute; left: 50%; top: 0; width: 4px; height: 44px; margin-left: -2px; background: linear-gradient(#ddd, #888); border-radius: 0 0 2px 2px; animation: needle .35s ease-in-out infinite alternate; }
.machine__needle::before { content: ""; position: absolute; left: -10px; top: -14px; width: 24px; height: 16px; border-radius: 4px; background: #c9c3cc; }
@keyframes needle { from { transform: translateY(-8px); } to { transform: translateY(14px); } }
.machine__seam { position: absolute; left: 0; bottom: 0; width: 100%; height: 30px; }
.machine__seam path { fill: none; stroke: var(--mustard); stroke-width: 3; stroke-dasharray: 10 8; animation: feed 1.4s linear infinite; }
@keyframes feed { to { stroke-dashoffset: 36; } }

/* ---------- classes (3D tilt) ---------- */
.class-grid { display: grid; gap: 26px; }
@media (min-width: 760px) { .class-grid { grid-template-columns: repeat(3, 1fr); } }
.class { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transform-style: preserve-3d; }
.tilt { transition: transform .3s ease-out, box-shadow .3s; }
.class__img { aspect-ratio: 4 / 3; overflow: hidden; }
.class__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.class:hover .class__img img { transform: scale(1.07); }
.class__body { padding: 24px; transform: translateZ(30px); }
.tag { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: .8rem; font-weight: 800; color: #fff; background: var(--c); margin-bottom: 10px; }
.class__body p { color: var(--muted); }
.price { font: 800 1.6rem var(--head); color: var(--ink) !important; margin: 0; }
.price small { font: 600 .9rem var(--body); color: var(--muted); }
.schedule { margin-top: 50px; padding: 30px; border-radius: var(--radius); background: var(--linen-2); border: 2px dashed #d9cdbb; }
.schedule h3 { text-align: center; }
.schedule ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
@media (min-width: 760px) { .schedule ul { grid-template-columns: repeat(4, 1fr); } }
.schedule li { display: grid; gap: 2px; padding: 16px; background: #fff; border-radius: 14px; }
.schedule strong { color: var(--berry); font-family: var(--head); font-size: 1.3rem; }
.schedule span { font-weight: 800; color: var(--ink); }
.schedule em { font-style: normal; color: var(--muted); font-size: .92rem; }

/* ---------- gallery ring (3D carousel) ---------- */
.gallery { background: radial-gradient(90% 70% at 50% 100%, #4a3a55, var(--ink)); color: #fff; overflow: hidden; padding-bottom: 80px; }
.ring-stage { height: clamp(300px, 46vw, 460px); perspective: 1400px; display: grid; place-items: center; cursor: grab; touch-action: pan-y; user-select: none; }
.ring-stage:active { cursor: grabbing; }
.ring { position: relative; width: clamp(180px, 22vw, 260px); aspect-ratio: 3 / 4; transform-style: preserve-3d; }
.ring figure { position: absolute; inset: 0; margin: 0; border-radius: 18px; overflow: hidden; background: #3d2f45; border: 6px solid #fff; box-shadow: 0 20px 40px rgba(0, 0, 0, .45); -webkit-box-reflect: below 10px linear-gradient(transparent 70%, rgba(255, 255, 255, .18)); }
.ring img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ring-ctrl { display: flex; justify-content: center; gap: 14px; margin-top: 20px; }

/* ---------- reviews ---------- */
.review-grid { display: grid; gap: 24px; }
@media (min-width: 860px) { .review-grid { grid-template-columns: repeat(3, 1fr); } }
.review { margin: 0; padding: 30px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); position: relative; transition: transform .35s; }
.review::before { content: ""; position: absolute; inset: 8px; border: 2px dashed var(--line); border-radius: 16px; pointer-events: none; }
.review:hover { transform: translateY(-6px) rotate(-1deg); }
.review:nth-child(2):hover { transform: translateY(-6px) rotate(1deg); }
.stars { color: var(--mustard); display: flex; gap: 2px; margin-bottom: 12px; }
.review blockquote { margin: 0 0 20px; font-size: 1.05rem; color: var(--ink); }
.review figcaption { display: flex; align-items: center; gap: 12px; font-weight: 800; color: var(--ink); }
.review small { color: var(--muted); font-weight: 600; }
.ava { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--c); color: #fff; font-size: .9rem; }

/* ---------- contact ---------- */
.contact { background: var(--linen-2); }
.contact__grid { display: grid; gap: 40px; }
@media (min-width: 900px) { .contact__grid { grid-template-columns: 1fr 1fr; align-items: start; } }
.info { list-style: none; padding: 0; margin: 20px 0 26px; display: grid; gap: 16px; }
.info li { display: flex; gap: 14px; align-items: flex-start; font-weight: 700; color: var(--ink); }
.info svg { width: 44px; height: 44px; padding: 11px; border-radius: 14px; background: #fff; color: var(--berry); box-shadow: var(--shadow); }
.info a { text-decoration: none; }
.info a:hover { color: var(--berry); }
.socials { display: flex; gap: 10px; }
.socials a { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; border: 2px dashed var(--berry); color: var(--berry); transition: background-color .2s, color .2s, transform .3s; }
.socials a:hover { background: var(--berry); color: #fff; transform: rotate(20deg); }
.form { display: grid; gap: 16px; padding: clamp(24px, 4vw, 40px); background: #fff; border-radius: 26px; box-shadow: var(--shadow); position: relative; }
.form::before { content: ""; position: absolute; inset: 10px; border: 2px dashed var(--line); border-radius: 20px; pointer-events: none; }
.form label { display: grid; gap: 6px; font-weight: 800; color: var(--ink); font-size: .92rem; position: relative; }
.form input, .form select, .form textarea { font: inherit; font-weight: 400; padding: 13px 15px; border-radius: 14px; border: 2px solid var(--line); background: var(--linen); color: var(--ink); transition: border-color .2s, background-color .2s; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--berry); border-style: dashed; background: #fff; }
.form .is-bad { border-color: #d33; }
.form .btn { justify-self: start; position: relative; }
.form__msg { margin: 0; font-weight: 800; color: var(--teal); }
.form__msg:empty { display: none; }

/* ---------- footer ---------- */
.footer { background: var(--ink); color: #cfc5d6; padding: 60px 0 30px; }
.footer__in { display: grid; gap: 30px; justify-items: center; text-align: center; }
.news label { display: block; font-weight: 800; color: #fff; margin-bottom: 10px; }
.news div { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.news input { padding: 10px 16px; border-radius: 999px; border: 2px dashed rgba(255, 255, 255, .3); background: transparent; color: #fff; font: inherit; min-width: 240px; }
.footer__copy { margin: 0; font-size: .9rem; }

.to-top { position: fixed; right: 16px; bottom: 16px; z-index: 90; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; background: var(--berry); color: #fff; box-shadow: var(--shadow); opacity: 0; transform: translateY(20px); transition: opacity .3s, transform .3s; pointer-events: none; }
.to-top.is-on { opacity: 1; transform: none; pointer-events: auto; }
.menu-open .to-top { display: none; }

/* reveal */
.js [data-reveal] { opacity: 0; transform: translateY(30px) rotateX(8deg); transition: opacity .9s, transform .9s cubic-bezier(.2, .8, .2, 1); }
.js [data-reveal].is-in { opacity: 1; transform: none; }
.cards [data-reveal]:nth-child(2), .class-grid [data-reveal]:nth-child(2), .review-grid [data-reveal]:nth-child(2) { transition-delay: .1s; }
.cards [data-reveal]:nth-child(3), .class-grid [data-reveal]:nth-child(3), .review-grid [data-reveal]:nth-child(3) { transition-delay: .2s; }
.cards [data-reveal]:nth-child(4) { transition-delay: .3s; } .cards [data-reveal]:nth-child(5) { transition-delay: .4s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
}
