:root {
  --bg: #190b03;
  --bg-2: #2b1103;
  --text: #fff6ea;
  --muted: #e8b47d;
  --orange: #ff821c;
  --font-body: "Manrope", sans-serif;
  --font-display: "Syne", sans-serif;
  --font-accent: "Space Grotesk", sans-serif;
}

* { box-sizing: border-box; }

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  overflow: hidden;
  color: var(--text);
  font-family: var(--font-body);
  background:
    radial-gradient(circle at 16% 18%, rgba(255, 119, 20, 0.2), transparent 25%),
    radial-gradient(circle at 84% 78%, rgba(255, 172, 62, 0.15), transparent 26%),
    linear-gradient(145deg, #080300 0%, var(--bg) 48%, var(--bg-2) 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 174, 94, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 174, 94, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
}

.ambient {
  position: fixed;
  border-radius: 50%;
  filter: blur(96px);
  pointer-events: none;
}

.ambient-left {
  width: 340px;
  height: 340px;
  left: -110px;
  top: 12vh;
  background: rgba(255, 104, 15, 0.24);
}

.ambient-right {
  width: 400px;
  height: 400px;
  right: -130px;
  bottom: 8vh;
  background: rgba(255, 155, 35, 0.2);
}

.grid-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.09;
  background-image: radial-gradient(rgba(255, 240, 220, 0.8) 0.45px, transparent 0.45px);
  background-size: 6px 6px;
  mix-blend-mode: soft-light;
}

.fullscreen-shell {
  position: relative;
  z-index: 1;
  height: 100svh;
  padding: 0.45rem;
}

.landing {
  position: relative;
  --spot-x: 50%;
  --spot-y: 50%;
  display: grid;
  height: 100%;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(255, 161, 76, 0.3);
  border-radius: 34px;
  background:
    radial-gradient(circle at var(--spot-x) var(--spot-y), rgba(255, 164, 76, 0.14), transparent 25%),
    linear-gradient(160deg, rgba(30, 11, 2, 0.94), rgba(42, 16, 3, 0.82));
  box-shadow: 0 36px 92px rgba(0, 0, 0, 0.42);
}

.landing::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: inherit;
  pointer-events: none;
}

.tool-panel {
  --panel-fill: linear-gradient(155deg, #7b2f08, #9d410e);
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  overflow: hidden;
  color: var(--text);
  border: 1.8px solid rgba(255, 153, 65, 0.4);
  text-decoration: none;
  transition: filter 200ms ease, border-color 200ms ease;
}

.tool-panel:hover,
.tool-panel:focus-visible {
  border-color: rgba(255, 203, 145, 0.78);
  filter: saturate(1.12) brightness(1.08);
}

.tool-panel:focus-visible {
  outline: 2px solid rgba(255, 188, 116, 0.65);
  outline-offset: 3px;
}

.tool-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.025) 44%, rgba(52, 14, 1, 0.1)),
    var(--panel-fill);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.06),
    inset 0 0 0 2px rgba(91, 31, 3, 0.3);
}

.tool-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(160deg, rgba(255, 190, 112, 0.11), transparent 38%),
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.07), transparent 30%);
}

.tool-core {
  position: relative;
  z-index: 2;
  display: grid;
  width: min(43vw, 680px);
  min-height: clamp(150px, 19vh, 210px);
  max-width: calc(100% - 2rem);
  place-content: center;
  justify-items: center;
  gap: 0.25rem;
  padding: 1rem 1.4rem 1.05rem;
  overflow: visible;
  border: 1.8px solid rgba(255, 150, 61, 0.38);
  border-radius: 34px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 149, 57, 0.14), transparent 48%),
    linear-gradient(160deg, rgba(42, 15, 3, 0.98), rgba(53, 20, 4, 0.96));
  box-shadow:
    0 28px 70px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 48px rgba(255, 110, 17, 0.06);
  backdrop-filter: blur(22px);
}

.tool-core::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-radius: 24px;
  pointer-events: none;
}

.tool-core h1 {
  position: relative;
  margin: 0;
  color: var(--text);
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.7vw, 3.8rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.09em;
  white-space: nowrap;
  text-shadow: 0 4px 24px rgba(35, 9, 0, 0.3);
}

.owentools-two {
  position: absolute;
  top: -0.14em;
  left: 100%;
  color: var(--orange);
  font-family: var(--font-accent);
  font-size: 0.78em;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
  transform: rotate(20deg);
  transform-origin: 50% 70%;
  text-shadow: 0 0 28px rgba(255, 121, 25, 0.48);
}

.owentools-one-secret {
  position: absolute;
  top: -0.08em;
  right: 100%;
  width: 0.72em;
  height: 1.12em;
  cursor: default;
  text-decoration: none;
}

.owentools-one-secret:focus-visible { outline: none; }

.tool-core p {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-accent);
  font-size: clamp(0.78rem, 0.82vw, 0.9rem);
}

.edge-content {
  position: absolute;
  z-index: 2;
  display: flex;
  width: min(16vw, 220px);
  max-width: 220px;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
  text-align: center;
  pointer-events: none;
}

.panel-title {
  max-width: 15ch;
  color: var(--text);
  font-family: var(--font-accent);
  font-size: clamp(0.82rem, 0.84vw, 0.98rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.035em;
  text-wrap: balance;
  text-shadow: 0 2px 10px rgba(40, 9, 0, 0.42);
}

.slot-a { --panel-fill: linear-gradient(155deg, #b84b0b, #9f3c08); clip-path: polygon(50% 50%, 0 0, 37% 0); }
.slot-b { --panel-fill: linear-gradient(155deg, #ad4309, #963707); clip-path: polygon(50% 50%, 37% 0, 63% 0); }
.slot-c { --panel-fill: linear-gradient(155deg, #a33d08, #8d3206); clip-path: polygon(50% 50%, 63% 0, 100% 0); }
.slot-d { --panel-fill: linear-gradient(155deg, #993707, #842e06); clip-path: polygon(50% 50%, 100% 0, 100% 25%); }
.slot-e { --panel-fill: linear-gradient(155deg, #903106, #7c2a05); clip-path: polygon(50% 50%, 100% 25%, 100% 50%); }
.slot-f { --panel-fill: linear-gradient(155deg, #872d06, #742605); clip-path: polygon(50% 50%, 100% 50%, 100% 75%); }
.slot-n { --panel-fill: linear-gradient(155deg, #7e2905, #6c2204); clip-path: polygon(50% 50%, 100% 75%, 100% 100%); }
.slot-g { --panel-fill: linear-gradient(155deg, #762505, #651f04); clip-path: polygon(50% 50%, 100% 100%, 66% 100%); }
.slot-h { --panel-fill: linear-gradient(155deg, #6e2204, #5f1c03); clip-path: polygon(50% 48%, 66% 100%, 34% 100%); }
.slot-i { --panel-fill: linear-gradient(155deg, #681f04, #581a03); clip-path: polygon(50% 50%, 34% 100%, 0 100%); }
.slot-j { --panel-fill: linear-gradient(155deg, #621d03, #521703); clip-path: polygon(50% 50%, 0 100%, 0 75%); }
.slot-k { --panel-fill: linear-gradient(155deg, #5d1a03, #4c1502); clip-path: polygon(50% 50%, 0 75%, 0 50%); }
.slot-l { --panel-fill: linear-gradient(155deg, #571803, #461302); clip-path: polygon(50% 50%, 0 50%, 0 25%); }
.slot-m { --panel-fill: linear-gradient(155deg, #511602, #401102); clip-path: polygon(50% 50%, 0 25%, 0 0); }

.slot-a .edge-content { top: 16.7%; left: 28.8%; }
.slot-b .edge-content { top: 16.7%; left: 49.7%; }
.slot-c .edge-content { top: 16.7%; left: 71.5%; }
.slot-d .edge-content { top: 25%; left: 83.33%; }
.slot-e .edge-content { top: 41.67%; left: 83.33%; }
.slot-f .edge-content { top: 58.33%; left: 83.33%; }
.slot-n .edge-content { top: 75%; left: 83.33%; }
.slot-g .edge-content { top: 83.33%; left: 72.33%; }
.slot-h .edge-content { top: 80%; left: 50.33%; }
.slot-i .edge-content { top: 83.33%; left: 28%; }
.slot-j .edge-content { top: 75%; left: 16.67%; }
.slot-k .edge-content { top: 58.33%; left: 16.67%; }
.slot-l .edge-content { top: 41.67%; left: 16.67%; }
.slot-m .edge-content { top: 25%; left: 16.67%; }

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 720px) {
  body { overflow-y: auto; }
  .fullscreen-shell { height: auto; min-height: 100svh; }
  .landing {
    display: grid;
    min-height: calc(100svh - 0.9rem);
    height: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: minmax(150px, auto);
    gap: 0.6rem;
    padding: 0.6rem;
  }
  .tool-core {
    position: relative;
    width: auto;
    max-width: none;
    min-height: 30svh;
    grid-column: 1 / -1;
  }
  .tool-panel {
    position: relative;
    inset: auto;
    min-height: 150px;
    border-radius: 22px;
    clip-path: none !important;
  }
  .edge-content {
    inset: auto 0.8rem 0.8rem !important;
    width: auto;
    max-width: none;
    transform: none;
  }
}

@media (max-width: 500px) {
  .landing { grid-template-columns: 1fr; }
}
