:root {
  --accent: #ffd60a;
  --bg: #000000;
  --text: #ffffff;
  --card-bg: rgba(142, 142, 148, 0.2);
  --card-border: rgba(142, 142, 148, 0.2);
  --separator: rgba(142, 142, 148, 0.25);
  --separator-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.8);
  --pill-bg: rgba(255, 255, 255, 0.1);
  --overlay-bg: rgba(0, 0, 0, 0.1);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --transition: 160ms ease;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition);
}

a:hover,
.nav-item:hover,
.dropdown-item:hover,
.header-links a:hover,
.mobile-menu-button:hover,
.mobile-back-button:hover {
  color: var(--accent);
}

/* ---------- Desktop header ---------- */

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 36px 40px 16px;
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 10;
}

.dropdown {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: default;
  padding-bottom: 12px;
  margin-bottom: -12px;
}

.dropdown-label {
  font-weight: 600;
  font-size: 17px;
  line-height: 24px;
  letter-spacing: -0.04px;
  color: var(--text);
  transition: color var(--transition);
}

.dropdown:hover .dropdown-label,
.dropdown:hover .dropdown-icon {
  color: var(--accent);
}

.dropdown-icon {
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  transition: color var(--transition);
}

.dropdown-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: -16px;
  width: 303px;
  padding: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--card-bg);
  -webkit-backdrop-filter: blur(25px);
  backdrop-filter: blur(25px);
  border-radius: 30px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity var(--transition), transform var(--transition);
}

.dropdown:hover .dropdown-menu,
.dropdown:focus-within .dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 0 16px;
  font-weight: 600;
  font-size: 17px;
  line-height: 24px;
  letter-spacing: -0.04px;
  color: var(--text);
}

.header-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.header-links a {
  font-weight: 600;
  font-size: 17px;
  line-height: 22px;
  letter-spacing: -0.04px;
  text-align: center;
  color: var(--text);
}

/* ---------- Mobile menu button + overlay ---------- */

.mobile-menu-button,
.mobile-back-button {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 16px;
  background: var(--pill-bg);
  border: none;
  border-radius: 100px;
  color: var(--text);
  font-family: var(--font);
  font-weight: 700;
  font-size: 15px;
  line-height: 22px;
  letter-spacing: -0.04px;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--transition);
}

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  flex-direction: column;
  align-items: center;
  padding: 70px 0 32px;
  gap: 24px;
  background: var(--overlay-bg);
  -webkit-backdrop-filter: blur(50px);
  backdrop-filter: blur(50px);
  overflow-y: auto;
}

body.menu-open .mobile-menu-overlay {
  display: flex;
}

.mobile-menu-overlay .nav-item {
  font-weight: 600;
  font-size: 17px;
  line-height: 24px;
  letter-spacing: -0.04px;
  color: var(--text);
  text-align: center;
}

.mobile-menu-overlay .nav-item.is-current {
  color: var(--accent);
}

/* ---------- Card with content ---------- */

.card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 16px;
  width: min(100% - 40px, 600px);
  margin: 32px auto 64px;
  padding: 16px 0;
  background: var(--card-bg);
  border: 2px solid var(--card-border);
  border-radius: 30px;
}

.card-title {
  margin: 0;
  padding: 0 16px;
  font-weight: 600;
  font-size: 17px;
  line-height: 24px;
  letter-spacing: -0.04px;
  text-align: center;
  color: var(--text);
}

.card-separator {
  height: 2px;
  width: 100%;
  margin: 0;
  border: none;
  background: var(--separator);
  box-shadow: var(--separator-shadow);
}

.card-body {
  padding: 0 16px;
  font-weight: 500;
  font-size: 15px;
  line-height: 20px;
  letter-spacing: -0.06px;
  color: var(--text);
}

.card-body p {
  margin: 0 0 14px;
}

.card-body p:last-child {
  margin-bottom: 0;
}

.card-body strong {
  font-weight: 700;
  color: var(--text);
}

.card-body em {
  font-style: italic;
}

.card-body a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.card-body a:hover {
  color: var(--accent);
}

.card-body ol {
  margin: 0 0 14px;
  padding-left: 22px;
  list-style-type: decimal;
}

.card-body ol ol {
  margin-top: 6px;
  margin-bottom: 6px;
  list-style-type: lower-roman;
}

.card-body ol ol ol {
  list-style-type: lower-alpha;
}

.card-body ol ol ol ol {
  list-style-type: decimal;
}

.card-body li {
  margin-bottom: 6px;
}

.card-body li > p {
  margin-top: 4px;
  margin-bottom: 4px;
}

/* ---------- Mobile breakpoint ---------- */

@media (max-width: 620px) {
  .header {
    display: none;
  }

  body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 124px;
    background: var(--bg);
    z-index: 40;
    pointer-events: none;
  }

  .mobile-menu-button {
    display: flex;
    width: max-content;
    position: fixed;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    z-index: 50;
  }

  .mobile-back-button {
    display: flex;
    width: max-content;
  }

  .card {
    width: calc(100% - 20px);
    margin: 132px auto 40px;
  }
}
