:root {
  --bg-1: #07111f;
  --bg-2: #0d1b2a;
  --panel-border: rgba(148, 163, 184, 0.18);
  --text: #e5eefb;
  --text-soft: #a7b5c8;
  --primary: #7c3aed;
  --primary-2: #22d3ee;
  --shadow: rgba(15, 23, 42, 0.7);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
  font-family: "Segoe UI", Inter, Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(124, 58, 237, 0.18), transparent 32%),
    radial-gradient(circle at bottom right, rgba(34, 211, 238, 0.12), transparent 30%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2));
  color: var(--text);
}

body {
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at center, black 38%, transparent 100%);
  pointer-events: none;
}

.shell {
  position: relative;
  width: min(980px, calc(100vw - 32px));
  padding: 24px;
}

.card {
  position: relative;
  background: rgba(10, 17, 28, 0.74);
  border: 1px solid var(--panel-border);
  border-radius: 28px;
  box-shadow: 0 30px 80px var(--shadow);
  backdrop-filter: blur(16px);
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.15), transparent 35%, rgba(34, 211, 238, 0.12));
  pointer-events: none;
}

.inner {
  position: relative;
  min-height: 520px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 32px 40px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  font-size: 0.78rem;
}

.hero {
  flex: 1;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 16px 0;
}

h1 {
  margin: 0;
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.lead {
  margin: 18px auto 0;
  max-width: 620px;
  color: var(--text-soft);
  font-size: 1.08rem;
  line-height: 1.7;
}

.error-wrap {
  position: relative;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.error-wrap .topbar {
  position: absolute;
  top: 24px;
  left: 0;
  width: 100%;
  padding: 0 40px;
  margin-bottom: 0;
}

.kicker {
  display: inline-block;
  margin-bottom: 18px;
  padding: 8px 12px;
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.2);
  border-radius: 999px;
  color: #d9c6ff;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.error-code {
  font-size: clamp(4rem, 12vw, 8rem);
  font-weight: 800;
  letter-spacing: -0.08em;
  line-height: 1;
  background: linear-gradient(90deg, #e2e8f0, var(--primary-2), #c084fc);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.error-message {
  margin: 18px auto 0;
  max-width: 560px;
  color: var(--text-soft);
  font-size: 1.08rem;
  line-height: 1.7;
}

@media (max-width: 760px) {
  .inner {
    padding: 28px 22px;
  }
}
