/* V7 header/footer shell for the Start page (matches About / Guide pages) */
:root {
  --ink: #171720;
  --text: #29293a;
  --muted: #6c6f83;
  --soft: #f8f5ff;
  --white: #fff;
  --purple: #7350e6;
  --purple-deep: #5832d8;
  --pink: #d97cf0;
  --yellow: #ffcf5a;
  --orange: #ff8a2a;
  --lime: #c7f84d;
  --green: #28c76f;
  --line: rgba(115, 80, 230, 0.14);
  --line-strong: rgba(115, 80, 230, 0.24);
  --shadow-sm: 0 14px 36px rgba(52, 36, 112, 0.08);
  --shadow-md: 0 24px 64px rgba(52, 36, 112, 0.14);
  --shadow-lg: 0 34px 100px rgba(52, 36, 112, 0.2);
  --max: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body,
body.mirl-v7-homepage,
body.mirl-start-page {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 10% 0%, rgba(255, 207, 90, 0.24), transparent 30%),
    linear-gradient(180deg, #fffdfa 0%, #f8f5ff 42%, #fff 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::before,
body.mirl-v7-homepage::before,
body.mirl-start-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.42;
  background-image:
    linear-gradient(rgba(115, 80, 230, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(115, 80, 230, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, #000, transparent 72%);
}

a {
  text-decoration: none;
  color: inherit;
}

.wrap {
  width: min(calc(100% - 44px), var(--max));
  margin: 0 auto;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.screen-reader-text:focus {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 9999;
  width: auto;
  height: auto;
  padding: 12px 16px;
  margin: 0;
  overflow: visible;
  clip: auto;
  background: var(--purple-deep);
  color: #fff;
  border-radius: 12px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 16px 0 10px;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 12px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 14px 45px rgba(52, 36, 112, 0.08);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.025em;
  color: var(--ink);
}

.nav {
  display: flex;
  gap: 22px;
  align-items: center;
  color: #5c5f73;
  font-size: 14px;
  font-weight: 700;
}

.nav a:not(.nav-cta):hover {
  color: var(--purple-deep);
}

.nav .menu,
.nav > ul {
  display: contents;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-cta {
  min-height: 42px;
  padding: 0 17px;
  border-radius: 999px;
  color: #fff;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--purple), var(--purple-deep));
  box-shadow: 0 14px 26px rgba(88, 50, 216, 0.24);
}

.v7-nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(115, 80, 230, 0.16);
  background: rgba(255, 255, 255, 0.88);
  color: var(--purple-deep);
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

body.v7-nav-open {
  overflow: hidden;
}

@media (max-width: 1020px) {
  .v7-nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: fixed;
    inset: 72px 16px auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 16px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    z-index: 30;
  }

  .nav.is-open {
    display: flex;
  }

  .nav a:not(.nav-cta) {
    display: flex;
    min-height: 44px;
    align-items: center;
    padding: 0 12px;
    border-radius: 12px;
  }

  .nav a:not(.nav-cta):hover {
    background: rgba(115, 80, 230, 0.08);
  }

  .nav .nav-cta {
    width: 100%;
    margin-top: 4px;
  }
}

@media (max-width: 680px) {
  .wrap {
    width: min(calc(100% - 28px), var(--max));
  }

  .topbar {
    padding-top: 10px;
  }

  .topbar-inner {
    border-radius: 24px;
  }
}
