/* Mission Control Plus page. Loaded after main.css; page classes are prefixed "mcp-" and the
   Mission Control scenes' classes "mc-" and "mcw-", so nothing touches Bulma or the
   other pages. */

.mcp {
  /* Brand colors come from the app icon: its slate tile, the three windows and the blue plus. */
  --mcp-slate: #6A7284;
  --mcp-slate-dark: #4A5060;
  --mcp-orange: #D9772F;
  --mcp-teal: #13A08F;
  --mcp-blue: #3F6BE0;
  --mcp-accent: #2F62E0;
  --mcp-ink: #121418;
  --mcp-text: #1D1D1F;
  --mcp-muted: #5E6370;
  --mcp-line: rgba(18, 20, 40, 0.09);
  --mcp-light: #F4F5F7;
  --mcp-card: #FFFFFF;
  --mcp-button: linear-gradient(180deg, #7A8296 0%, #4A5060 100%);
  --mcp-radius: 20px;
  --mcp-max: 1160px;
  --mcp-gutter: clamp(20px, 4vw, 40px);

  color: var(--mcp-text);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

.mcp strong {
  color: inherit;
  font-weight: 600;
}

.mcp a {
  color: var(--mcp-accent);
}

.mcp a:hover {
  color: var(--mcp-ink);
}

.mcp :focus-visible {
  outline: 3px solid var(--mcp-accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Layout ---------- */

.mcp-wrap {
  width: 100%;
  max-width: var(--mcp-max);
  margin: 0 auto;
  padding-left: var(--mcp-gutter);
  padding-right: var(--mcp-gutter);
}

.mcp-section {
  padding-top: clamp(72px, 9vw, 120px);
  padding-bottom: clamp(72px, 9vw, 120px);
}

.mcp-section--light {
  background: var(--mcp-light);
}

.mcp-section-head {
  max-width: 700px;
  margin: 0 auto clamp(36px, 5vw, 56px);
  text-align: center;
}

/* ---------- Type ---------- */

.mcp-eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mcp-accent);
}

.mcp-h1,
.mcp-h2,
.mcp-h3 {
  margin: 0;
  text-wrap: balance;
  color: inherit;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.mcp-h1 em {
  font-style: italic;
  padding-right: 0.04em;
}

.mcp-h1 {
  font-size: clamp(2.5rem, 5.6vw, 4.25rem);
  line-height: 1.03;
  font-weight: 800;
  letter-spacing: -0.035em;
}

.mcp-h2 {
  font-size: clamp(2rem, 4.2vw, 3rem);
  line-height: 1.08;
}

.mcp-h3 {
  font-size: 1.125rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.mcp-lead {
  margin: 20px 0 0;
  text-wrap: pretty;
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  color: var(--mcp-muted);
}

.mcp kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.9em;
  height: 1.9em;
  padding: 0 0.45em;
  border-radius: 7px;
  background: #FFFFFF;
  box-shadow: inset 0 0 0 1px rgba(18, 20, 40, 0.14), 0 1.5px 0 rgba(18, 20, 40, 0.14);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  color: var(--mcp-text);
}

/* ---------- Buttons ---------- */

.mcp-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

.mcp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.mcp-btn svg {
  width: 20px;
  height: 20px;
  flex: none;
}

.mcp .mcp-btn--primary,
.mcp .mcp-btn--primary:hover {
  color: #FFFFFF;
  background: var(--mcp-button);
  box-shadow: 0 10px 28px -8px rgba(40, 46, 60, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.mcp .mcp-btn--primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px -10px rgba(40, 46, 60, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.mcp .mcp-btn--secondary,
.mcp .mcp-btn--secondary:hover {
  color: var(--mcp-text);
  background: #FFFFFF;
  box-shadow: inset 0 0 0 1.5px rgba(18, 20, 40, 0.14);
}

.mcp .mcp-btn--secondary:hover {
  box-shadow: inset 0 0 0 1.5px rgba(18, 20, 40, 0.32);
}

.mcp-btn .paddle-gross {
  font-weight: 500;
  color: var(--mcp-muted);
}

/* Setapp's script fills this div with its own badge. */
.mcp .setapp-button {
  height: 52px;
  padding: 0;
  border: 0;
  background: transparent;
}

.mcp-fineprint {
  margin: 18px 0 0;
  font-size: 0.875rem;
  color: var(--mcp-muted);
}

/* ---------- Hero ---------- */

.mcp-hero {
  position: relative;
  overflow: hidden;
  padding-top: clamp(40px, 6vw, 72px);
  padding-bottom: clamp(56px, 8vw, 104px);
  text-align: center;
  background:
    radial-gradient(42% 38% at 12% 8%, rgba(217, 119, 47, 0.10), transparent 70%),
    radial-gradient(40% 40% at 90% 4%, rgba(63, 107, 224, 0.12), transparent 70%),
    radial-gradient(50% 40% at 70% 100%, rgba(19, 160, 143, 0.08), transparent 70%),
    linear-gradient(180deg, #FFFFFF 0%, var(--mcp-light) 100%);
}

.mcp-app-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 26px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--mcp-text);
}

.mcp-app-badge img {
  width: 60px;
  height: 60px;
  margin: -4px;
  filter: drop-shadow(0 6px 12px rgba(40, 46, 60, 0.22));
}

.mcp-app-badge span {
  color: var(--mcp-muted);
  font-weight: 500;
}

.mcp-hero .mcp-lead {
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}

.mcp-hero-stage {
  margin-top: clamp(48px, 6vw, 72px);
}

/* ---------- MacBook Pro around a scene ----------
   The MacBook Pro is a Rititi render with its screen cut out; the scene sits behind the hole.
   Positions are shares of the 2200×1561 render, with a little bleed under the bezel. */

.mcp-mac {
  position: relative;
  width: 100%;
  margin: 0 auto;
  aspect-ratio: 2200 / 1561;
}

.mcp-mac--hero {
  max-width: 1080px;
}

.mcp-mac::after {
  /* Contact shadow under the base. */
  content: "";
  position: absolute;
  left: 5%;
  right: 5%;
  bottom: -1.2%;
  height: 4%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(20, 24, 40, 0.32), transparent);
  filter: blur(6px);
  z-index: -1;
}

.mcp-mac-frame {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.mcp-mac .mc-scene {
  position: absolute;
  left: 7.32%;
  top: 1.96%;
  width: 85.36%;
  height: 79.09%;
}

/* ---------- Mission Control ---------- */

.mc-scene {
  position: relative;
  overflow: hidden;
  background: #1B2638;
  container-type: size;
  user-select: none;
  -webkit-user-select: none;
}

.mc-scene img {
  -webkit-user-drag: none;
}

.mc-screen {
  position: absolute;
  inset: 0;
  /* Sizes that follow the screen, not the window they sit on (each window is its own
     container). Registered as lengths so they resolve here, against the scene. */
  --mc-close: clamp(11px, 1.85cqw, 28px);
  --mc-ring: clamp(2px, 0.3cqw, 4px);
}

@property --mc-close {
  syntax: "<length>";
  inherits: true;
  initial-value: 20px;
}

@property --mc-ring {
  syntax: "<length>";
  inherits: true;
  initial-value: 3px;
}

/* macOS Tahoe's default wallpaper. */
.mc-wallpaper {
  position: absolute;
  inset: 0;
  background: #2B4C7E url("../assets/mission_control_plus/tahoe-wallpaper.jpg") center / cover no-repeat;
}

/* Mission Control darkens and softens the desktop behind the windows. */
.mc-dim {
  position: absolute;
  inset: 0;
  background: rgba(6, 10, 22, 0.26);
  -webkit-backdrop-filter: blur(0.35cqw) saturate(110%);
  backdrop-filter: blur(0.35cqw) saturate(110%);
  transition: opacity 0.5s ease;
}

/* The Spaces bar, collapsed, under the camera notch. */
.mc-spaces {
  position: absolute;
  top: 5.2%;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 3.4cqw;
  font: 500 clamp(6px, 0.95cqw, 13px) / 1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  color: rgba(255, 255, 255, 0.7);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  transition: opacity 0.4s ease;
}

.mc-spaces .is-on {
  color: #FFFFFF;
}

/* ---------- Windows ---------- */

.mc-windows {
  position: absolute;
  inset: 0;
}

.mcw {
  position: absolute;
  container-type: inline-size;
  transition:
    left 0.55s cubic-bezier(0.2, 0.8, 0.2, 1),
    top 0.55s cubic-bezier(0.2, 0.8, 0.2, 1),
    width 0.55s cubic-bezier(0.2, 0.8, 0.2, 1),
    height 0.55s cubic-bezier(0.2, 0.8, 0.2, 1),
    opacity 0.28s ease,
    transform 0.28s ease;
}

.mcw.no-anim,
.mcw.no-anim * {
  transition: none !important;
}

.mcw-frame {
  position: absolute;
  inset: 0;
  border-radius: var(--mcw-r, 2cqw);
  box-shadow: 0 1.6cqw 4cqw rgba(0, 0, 0, 0.42), 0 0 0 0.5px rgba(0, 0, 0, 0.4);
  transition: box-shadow 0.15s ease;
}

.mcw-frame img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
}

/* Mission Control rings the window under the pointer, or selected with the keyboard. */
.mcw.is-hover .mcw-frame,
.mcw.is-selected .mcw-frame {
  box-shadow: 0 0 0 var(--mc-ring) #3B82F6, 0 1.6cqw 4cqw rgba(0, 0, 0, 0.42);
}

/* The ✕ that Mission Control Plus adds, centered on the window's top-left corner. */
.mcw-close {
  position: absolute;
  left: calc(var(--mcw-r, 2cqw) * 0.29);
  top: calc(var(--mcw-r, 2cqw) * 0.29);
  z-index: 2;
  width: var(--mc-close);
  height: var(--mc-close);
  margin: calc(var(--mc-close) / -2) 0 0 calc(var(--mc-close) / -2);
  border-radius: 50%;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Cpath d='M9.5 9.5l9 9m0-9l-9 9' stroke='%23686868' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% no-repeat,
    linear-gradient(180deg, #FDFDFD, #E9E9EB);
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.22), 0 1px 3px rgba(0, 0, 0, 0.35);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.16s ease, transform 0.16s ease, filter 0.1s ease;
}

.mcw.is-hover .mcw-close {
  opacity: 1;
  transform: scale(1);
}

.mcw.is-pressing .mcw-close {
  filter: brightness(0.82);
}

.mcw.is-closing {
  opacity: 0;
  transform: scale(0.82);
}

.mcw.is-hiding {
  opacity: 0;
  transform: scale(0.9);
}

.mcw.is-minimizing {
  opacity: 0;
  transform: var(--mc-fly);
  transition: opacity 0.5s ease 0.1s, transform 0.5s cubic-bezier(0.5, 0, 0.75, 0);
}

.mcw.is-opening {
  z-index: 3;
}

/* ---------- Dock ---------- */

.mc-dock {
  position: absolute;
  left: 50%;
  bottom: 0.9%;
  display: flex;
  align-items: center;
  gap: 0.35cqw;
  height: 7.6%;
  padding: 0 0.6cqw;
  border-radius: 1.9cqw;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.18);
  -webkit-backdrop-filter: blur(16px) saturate(170%);
  backdrop-filter: blur(16px) saturate(170%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28), 0 8px 24px rgba(0, 0, 0, 0.25);
}

.mc-dock-apps,
.mc-dock-min {
  display: flex;
  align-items: center;
  gap: 0.35cqw;
  height: 100%;
}

.mc-dock-icon {
  position: relative;
  width: 4cqw;
  height: 4cqw;
}

.mc-dock-icon img {
  display: block;
  width: 100%;
  height: 100%;
}

.mc-dot {
  position: absolute;
  left: 50%;
  bottom: -0.5cqw;
  width: 0.34cqw;
  height: 0.34cqw;
  margin-left: -0.17cqw;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.is-running .mc-dot {
  opacity: 1;
}

.mc-dock-sep {
  width: 1px;
  height: 62%;
  margin: 0 0.3cqw;
  background: rgba(255, 255, 255, 0.35);
}

.mc-dock-thumb {
  display: flex;
  align-items: center;
  width: 0;
  height: 4cqw;
  opacity: 0;
  transition: width 0.3s ease, opacity 0.3s ease;
}

.mc-dock-thumb img {
  width: 100%;
  height: auto;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
}

.mc-dock-thumb.is-in {
  width: 4cqw;
  opacity: 1;
}

/* ---------- Pointer and keys ---------- */

.mc-cursor {
  position: absolute;
  z-index: 5;
  width: clamp(12px, 1.7cqw, 24px);
  height: clamp(12px, 1.7cqw, 24px);
  margin: -2px 0 0 -4px;
  filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.35));
  transition-property: left, top;
  transition-timing-function: cubic-bezier(0.45, 0.05, 0.25, 1);
}

.mc-cursor path {
  transition: transform 0.1s ease;
  transform-origin: 5px 3px;
}

.mc-cursor.is-clicking path {
  transform: scale(0.86);
}

.mc-cursor.is-hidden {
  opacity: 0;
}

.mc-hud {
  position: absolute;
  z-index: 6;
  left: 50%;
  bottom: 12%;
  display: flex;
  align-items: center;
  gap: 1cqw;
  padding: 0.9cqw 1.4cqw;
  border-radius: 1.6cqw;
  transform: translate(-50%, 10%) scale(0.96);
  background: rgba(24, 26, 32, 0.72);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12), 0 10px 30px rgba(0, 0, 0, 0.35);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.mc-hud.is-on {
  opacity: 1;
  transform: translate(-50%, 0) scale(1);
}

.mc-keys {
  display: flex;
  gap: 0.5cqw;
}

.mc-hud kbd {
  min-width: 3.2cqw;
  height: 3.2cqw;
  padding: 0 0.8cqw;
  border-radius: 0.7cqw;
  font-size: clamp(9px, 1.6cqw, 20px);
  background: linear-gradient(180deg, #FFFFFF, #E7E8EC);
  box-shadow: 0 0.25cqw 0 rgba(0, 0, 0, 0.35);
}

.mc-hud-label {
  font: 600 clamp(8px, 1.3cqw, 17px) / 1 -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  color: #FFFFFF;
  white-space: nowrap;
}

.mc-hud-label:empty {
  display: none;
}

/* ---------- Entering and leaving Mission Control ---------- */

.mc-screen.is-exiting .mc-dim,
.mc-screen.is-exiting .mc-spaces {
  opacity: 0;
}

.mc-screen.is-exiting .mcw:not(.is-opening) {
  opacity: 0;
  transform: scale(1.15);
  transition-duration: 0.55s;
}

.mc-screen.is-exiting .mcw-close {
  opacity: 0;
}

.mc-screen.is-entering .mcw {
  opacity: 0;
  transform: scale(1.12);
  transition: none;
}

.mc-screen.is-entering .mc-dim,
.mc-screen.is-entering .mc-spaces {
  opacity: 0;
  transition: none;
}


/* ---------- Spotlights ---------- */

.mcp-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(36px, 5vw, 64px);
  align-items: center;
}

@media (min-width: 960px) {
  .mcp-split {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  }

  .mcp-split--flip > :first-child {
    order: 2;
  }
}

.mcp-split .mcp-lead {
  margin-top: 16px;
}

.mcp-shortcuts {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.mcp-shortcuts li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 1.0625rem;
  transition: background-color 0.25s ease, box-shadow 0.25s ease;
}

.mcp-shortcuts li + li {
  margin-top: 4px;
}

.mcp-shortcuts li.is-playing {
  background: #FFFFFF;
  box-shadow: 0 0 0 1px var(--mcp-line), 0 6px 16px -8px rgba(20, 24, 40, 0.25);
}

.mcp-shortcuts .mcp-keys {
  display: inline-flex;
  flex: 0 0 72px;
  gap: 4px;
}

/* ---------- Press and quotes ---------- */

.mcp-videos {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
}

@media (min-width: 760px) {
  .mcp-videos {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.mcp-videos iframe {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border: 0;
  border-radius: 14px;
  background: #E7E8EC;
}

.mcp-quotes {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  margin: clamp(40px, 5vw, 56px) 0 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 760px) {
  .mcp-quotes {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.mcp-quotes figure {
  height: 100%;
  margin: 0;
  padding: 26px;
  border-radius: 18px;
  background: var(--mcp-card);
  box-shadow: 0 0 0 1px var(--mcp-line), 0 14px 30px -20px rgba(20, 24, 40, 0.3);
}

.mcp-quotes blockquote {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--mcp-text);
}

.mcp-quotes figcaption {
  margin-top: 14px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--mcp-muted);
}

.mcp-ph {
  display: flex;
  justify-content: center;
  margin-top: 36px;
}

/* ---------- FAQ ---------- */

.mcp-faq {
  max-width: 800px;
  margin: 0 auto;
}

.mcp-faq details {
  border-bottom: 1px solid rgba(18, 20, 40, 0.12);
}

.mcp-faq details:first-child {
  border-top: 1px solid rgba(18, 20, 40, 0.12);
}

.mcp-faq summary {
  position: relative;
  display: block;
  padding: 22px 48px 22px 0;
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--mcp-text);
  cursor: pointer;
  list-style: none;
}

.mcp-faq summary::-webkit-details-marker {
  display: none;
}

.mcp-faq summary::before,
.mcp-faq summary::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 50%;
  width: 16px;
  height: 2px;
  margin-top: -1px;
  border-radius: 1px;
  background: var(--mcp-accent);
  transition: transform 0.2s ease;
}

.mcp-faq summary::after {
  transform: rotate(90deg);
}

.mcp-faq details[open] summary::after {
  transform: rotate(0deg);
}

.mcp-faq summary:hover {
  color: var(--mcp-accent);
}

.mcp-faq-answer {
  padding: 0 48px 24px 0;
  color: var(--mcp-muted);
}

.mcp-faq-answer p {
  margin: 0;
}

.mcp-faq-answer p + p {
  margin-top: 10px;
}

.mcp-help {
  margin: 40px 0 0;
  text-align: center;
  color: var(--mcp-muted);
}

/* ---------- Final call to action ---------- */

.mcp-final {
  text-align: center;
  background:
    radial-gradient(50% 70% at 50% 0%, rgba(63, 107, 224, 0.1), transparent 70%),
    var(--mcp-light);
}

.mcp-final img {
  width: 112px;
  height: 112px;
  margin: 0 auto 18px;
  filter: drop-shadow(0 8px 16px rgba(40, 46, 60, 0.22));
}

.mcp-final .mcp-lead {
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Small screens ---------- */

@media (max-width: 480px) {
  .mcp-buttons .mcp-btn {
    width: 100%;
  }


  .mcp-faq summary {
    font-size: 1.0625rem;
  }

  .mcp-faq-answer {
    padding-right: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mcp-btn,
  .mcw,
  .mc-cursor,
  .mc-hud {
    transition: none;
    animation: none;
  }
}

/* The site's nav draws a 2px shadow under its bar; on this page's tinted hero it reads as a
   stray line. */
.hero-head .navbar.has-shadow {
  box-shadow: none;
}
