/* Device frames + concept mini-sites.
   Mini-sites are sized in em; .ms font-size is tied to the screen width (cqi),
   so the same markup renders as a desktop site in a laptop and a mobile site in a phone. */

/* ---------- Devices ---------- */
.phone {
  position: relative;
  aspect-ratio: 9 / 19;
  padding: 3.4%;
  border-radius: 14% / 6.6%;
  background: #0c0d0d;
  box-shadow: 0 0 0 1px #2c2f2f inset, 0 40px 80px -30px rgba(0, 0, 0, .55), 0 18px 36px -18px rgba(0, 0, 0, .4);
}
.phone::before {
  content: "";
  position: absolute; z-index: 2;
  top: 5%; left: 50%;
  width: 26%; height: 2.4%;
  border-radius: 99px;
  background: #0c0d0d;
  transform: translateX(-50%);
}
.phone .screen { height: 100%; border-radius: 11% / 5.2%; }
.phone .ms > :first-child { padding-top: 2.6em; } /* clear the camera cut-out */

.laptop .lid {
  padding: 2.2% 2.2% 2.6%;
  border-radius: 2.2% 2.2% 0 0 / 3.4% 3.4% 0 0;
  background: #0c0d0d;
  box-shadow: 0 0 0 1px #2c2f2f inset;
}
.laptop .screen { aspect-ratio: 16 / 10; border-radius: 3px; }
.laptop .base {
  position: relative;
  aspect-ratio: 70 / 1;
  margin: 0 -6%;
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  background: linear-gradient(#d7d9d9, #9da1a1);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .5);
}
.laptop .base::before {
  content: "";
  position: absolute; top: 0; left: 50%;
  width: 14%; height: 45%;
  border-radius: 0 0 8px 8px;
  background: #8b8f8f;
  transform: translateX(-50%);
}

.screen {
  container-type: inline-size;
  overflow: hidden auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
  background: #fff;
}
.screen::-webkit-scrollbar { display: none; }

/* ---------- Mini-site base ---------- */
.ms { display: none; min-height: 100%; font-size: 1.25cqi; line-height: 1.5; }
.ms.on { display: block; animation: ms-in .5s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes ms-in { from { opacity: 0; transform: translateY(12px); } }
.ms p { margin: 0; }

.ms-nav { display: flex; align-items: center; justify-content: space-between; padding: 1.4em 3em; }
.ms-logo { display: flex; align-items: center; gap: .55em; font-weight: 700; font-size: 1.15em; }
.ms-mark { display: grid; place-items: center; width: 1.9em; height: 1.9em; border-radius: .45em; font-size: .9em; }
.ms-links { display: flex; gap: 2.2em; font-size: .9em; opacity: .75; }
.ms-burger { display: none; position: relative; width: 1.4em; height: .95em; border-block: 2px solid currentColor; }
.ms-burger::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 2px solid currentColor; transform: translateY(-50%); }

.ms-hero { display: grid; grid-template-columns: 1.15fr 1fr; gap: 3em; align-items: center; padding: 4.5em 3em 5em; }
.ms-kicker { font-size: .85em; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 1em !important; }
.ms-h1 { font-size: 3.5em; font-weight: 700; line-height: 1.04; letter-spacing: -.02em; margin-bottom: .4em !important; }
.ms-lead { font-size: 1.2em; opacity: .8; max-width: 26em; margin-bottom: 1.7em !important; }
.ms-btns { display: flex; flex-wrap: wrap; gap: .8em; }
.ms-btn { display: inline-block; padding: .95em 1.6em; border-radius: .6em; font-weight: 700; }
.ms-btn-ghost { box-shadow: inset 0 0 0 2px currentColor; }
.ms-art { position: relative; aspect-ratio: 1; }
.ms-art i { position: absolute; display: block; }

.ms-sec { padding: 3.6em 3em; }
.ms-h2 { font-size: 2.1em; font-weight: 700; letter-spacing: -.01em; line-height: 1.15; margin-bottom: 1.1em !important; }
.ms-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2em; }
.ms-card { padding: 1.7em; border-radius: 1em; }
.ms-card b { display: block; font-size: 1.15em; margin-bottom: .35em; }
.ms-card span { opacity: .75; }
.ms-foot { padding: 2em 3em; font-size: .9em; opacity: .8; }

/* ---------- Concept 1: education ---------- */
.ms-edu { background: #f2f5fa; color: #13284a; }
.ms-edu .ms-mark { background: #f2b33d; color: #13284a; }
.ms-edu .ms-kicker { color: #3e6db5; }
.ms-edu .ms-btn { background: #13284a; color: #fff; }
.ms-edu .ms-art i:nth-child(1) { inset: 8% 20% 20% 8%; border-radius: 50%; background: #3e6db5; }
.ms-edu .ms-art i:nth-child(2) { right: 6%; bottom: 8%; width: 42%; height: 42%; border-radius: 18%; background: #f2b33d; transform: rotate(-12deg); }
.ms-edu .ms-art i:nth-child(3) { right: 14%; top: 6%; width: 18%; height: 18%; border-radius: 50%; background: #13284a; }
.ms-edu .ms-art i:nth-child(4) { left: 4%; bottom: 4%; width: 26%; height: 26%; border: .5em solid #13284a; border-radius: 50%; }
.ms-edu .ms-card { background: #fff; box-shadow: 0 1px 0 #dfe6f0; }
.ms-edu .ms-card::before { content: ""; display: block; width: 2.4em; height: .45em; border-radius: 9px; margin-bottom: 1.2em; background: #f2b33d; }
.ms-edu .ms-card:nth-child(2)::before { background: #3e6db5; }
.ms-edu .ms-card:nth-child(3)::before { background: #13284a; }
.ms-news { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2em; }
.ms-news > div { padding: 1.5em 1.7em; border-radius: 1em; background: #13284a; color: #fff; }
.ms-news > div + div { background: #fff; color: #13284a; }
.ms-news small { display: block; font-size: .85em; opacity: .7; margin-bottom: .4em; }
.ms-doc { display: flex; gap: .7em; align-items: center; margin-top: .6em; }
.ms-doc::before { content: "PDF"; padding: .25em .45em; border-radius: .3em; background: #f2b33d; color: #13284a; font-size: .7em; font-weight: 700; }
.ms-edu .ms-foot { background: #13284a; color: #fff; opacity: 1; }

/* ---------- Concept 2: coffee shop ---------- */
.ms-cafe { background: #f4ece1; color: #2a1c15; }
.ms-cafe .ms-top { background: #2a1c15; color: #f4ece1; }
.ms-cafe .ms-mark { background: #c65f35; color: #f4ece1; border-radius: 50%; }
.ms-cafe .ms-kicker { color: #e39a6f; }
.ms-cafe .ms-btn { background: #c65f35; color: #fff; }
.ms-cafe .ms-btn-ghost { background: none; color: #f4ece1; }
.ms-cafe .ms-art i:nth-child(1) { inset: 6%; border-radius: 50%; background: #f4ece1; box-shadow: 0 2em 3em -1em rgba(0, 0, 0, .5); }
.ms-cafe .ms-art i:nth-child(2) { inset: 19%; border-radius: 50%; background: #c65f35; }
.ms-cafe .ms-art i:nth-child(3) { inset: 25%; border-radius: 50%; background: radial-gradient(circle at 42% 40%, #8a4a2c 0 18%, #5a2f1c 40%, #3a1e12 72%); }
.ms-cafe .ms-art i:nth-child(4) { top: 44%; right: -6%; width: 18%; height: 12%; border: .7em solid #f4ece1; border-left: 0; border-radius: 0 40% 40% 0; }
.ms-menu { display: grid; grid-template-columns: 1fr 1fr; gap: .2em 3em; }
.ms-menu p { display: flex; gap: .6em; padding: .75em 0; border-bottom: 1px solid #ddcdb8; font-size: 1.05em; }
.ms-menu p::after { content: attr(data-price); margin-left: auto; font-weight: 700; color: #c65f35; }
.ms-where { display: grid; grid-template-columns: 1fr 1.3fr; gap: 1.5em; align-items: center; }
.ms-map {
  aspect-ratio: 16 / 9; border-radius: 1em; position: relative;
  background: linear-gradient(90deg, transparent 47%, #fff 47% 51%, transparent 51%), linear-gradient(transparent 58%, #fff 58% 62%, transparent 62%), linear-gradient(30deg, transparent 30%, #f7f1e8 30% 33%, transparent 33%), #e4d6c3;
}
.ms-map::after { content: ""; position: absolute; left: 49%; top: 60%; width: 1.4em; height: 1.4em; border-radius: 50% 50% 50% 0; background: #c65f35; transform: translate(-50%, -100%) rotate(-45deg); }

/* ---------- Concept 3: specialist ---------- */
.ms-psy { background: #f3f1ec; color: #22302a; }
.ms-psy .ms-mark { background: #5e7f6c; color: #fff; border-radius: 50%; }
.ms-psy .ms-kicker { color: #5e7f6c; }
.ms-psy .ms-btn { background: #22302a; color: #fff; }
.ms-psy .ms-art i:nth-child(1) { inset: 4%; border-radius: 50%; background: #dfe6df; }
.ms-psy .ms-art i:nth-child(2) { inset: 18% 18% 4% 18%; border-radius: 50% 50% 0 0; background: #5e7f6c; }
.ms-psy .ms-art i:nth-child(3) { inset: 20% 30% 46% 30%; border-radius: 50%; background: #c9d6cb; }
.ms-psy .ms-art i:nth-child(4) { left: 0; right: 0; bottom: 4%; height: 2px; background: #22302a; }
.ms-prices p { display: grid; grid-template-columns: 1fr auto auto; gap: 2em; align-items: baseline; padding: 1.1em 0; border-top: 1px solid #d9d6cc; }
.ms-prices span { opacity: .6; }
.ms-prices b { font-size: 1.1em; }
.ms-psy .ms-card { background: #fff; }
.ms-psy .ms-card i { display: block; font-style: normal; font-weight: 700; color: #5e7f6c; font-size: 1.6em; margin-bottom: .4em; }

/* ---------- Phone-width layout ---------- */
@container (max-width: 520px) {
  .ms { font-size: 4.2cqi; }
  .ms-nav { padding: 1.1em 1.4em; }
  .ms-links { display: none; }
  .ms-burger { display: block; }
  .ms-hero { grid-template-columns: 1fr; gap: 2em; padding: 1.6em 1.4em 2.6em; }
  .ms-art { order: -1; width: 70%; margin: 0 auto; }
  .ms-h1 { font-size: 2.3em; }
  .ms-sec { padding: 2.4em 1.4em; }
  .ms-h2 { font-size: 1.6em; }
  .ms-cards, .ms-news, .ms-menu, .ms-where { grid-template-columns: 1fr; }
  .ms-prices p { grid-template-columns: 1fr auto; gap: .2em 1em; }
  .ms-prices span { grid-row: 2; }
  .ms-foot { padding: 1.6em 1.4em; }
}

@media (prefers-reduced-motion: reduce) {
  .ms.on { animation: none; }
}
