:root {
  color-scheme: light;
  --ink: #1f2933;
  --muted: #65758b;
  --line: #d8e2ec;
  --panel: #ffffff;
  --soft-blue: #d9ecff;
  --soft-green: #dff3e7;
  --soft-peach: #ffe2d1;
  --soft-lilac: #ece5ff;
  --accent: #2563eb;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, #f7fbff 0%, #f9fbf7 48%, #fff7f0 100%);
}

button,
input {
  font: inherit;
}

.shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 42px 0;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 28px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 34px;
}

.status {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft-peach);
  font-weight: 700;
}

.status.ready {
  background: var(--soft-green);
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.tool-card {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 104px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 14px 35px rgba(31, 41, 51, 0.08);
}

.tool-card:hover {
  border-color: #9bc5f2;
}

.tool-card strong,
.tool-card small {
  display: block;
}

.tool-card small {
  margin-top: 6px;
  color: var(--muted);
}

.tool-card.muted {
  cursor: not-allowed;
  opacity: 0.64;
}

.tool-icon {
  display: grid;
  place-items: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--soft-blue);
  font-weight: 800;
}

.workspace {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.workspace.locked {
  opacity: 0.72;
}

.workspace h2 {
  margin-bottom: 8px;
}

.workspace p {
  margin-bottom: 0;
  color: var(--muted);
}

.primary {
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.primary:disabled {
  cursor: not-allowed;
  background: #a8b4c2;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(21, 31, 45, 0.42);
  backdrop-filter: blur(6px);
}

.hidden {
  display: none;
}

.modal {
  position: relative;
  width: min(760px, 100%);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(31, 41, 51, 0.26);
}

.close-button {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 24px;
  cursor: pointer;
}

.carousel {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  min-height: 390px;
}

.gif-panel {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  background:
    linear-gradient(rgba(255,255,255,0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.12) 1px, transparent 1px),
    linear-gradient(135deg, #24364a, #5d7188);
  background-size: 28px 28px, 28px 28px, auto;
}

.scan-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 4px;
  background: #9ee7c5;
  box-shadow: 0 0 22px #9ee7c5;
  animation: scan 2.8s infinite ease-in-out;
}

.bbox {
  position: absolute;
  border: 3px solid #f9cb9c;
  border-radius: 4px;
  animation: pulse 1.8s infinite ease-in-out;
}

.bbox.one {
  width: 35%;
  height: 24%;
  left: 16%;
  top: 22%;
}

.bbox.two {
  width: 24%;
  height: 18%;
  right: 14%;
  top: 48%;
  border-color: #b7d7f0;
  animation-delay: 0.4s;
}

.bbox.three {
  width: 18%;
  height: 14%;
  left: 38%;
  bottom: 14%;
  border-color: #d9ead3;
  animation-delay: 0.8s;
}

.intro-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 46px 38px;
}

.intro-copy h2 {
  margin-bottom: 14px;
  font-size: 28px;
}

.intro-copy p:not(.eyebrow) {
  color: var(--muted);
  line-height: 1.6;
}

.dots {
  display: flex;
  gap: 8px;
  margin-top: 24px;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #cbd5e1;
}

.dot.active {
  background: var(--accent);
}

.login-modal {
  display: grid;
  gap: 16px;
  max-width: 420px;
  padding: 30px;
}

.login-modal h2 {
  margin-bottom: 4px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 700;
}

input {
  width: 100%;
  height: 46px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
}

@keyframes scan {
  0% { top: 8%; }
  50% { top: 88%; }
  100% { top: 8%; }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.82; }
  50% { transform: scale(1.03); opacity: 1; }
}

@media (max-width: 720px) {
  .shell {
    width: min(100% - 24px, 1120px);
    padding: 24px 0;
  }

  .topbar,
  .workspace {
    align-items: flex-start;
    flex-direction: column;
  }

  h1 {
    font-size: 28px;
  }

  .carousel {
    grid-template-columns: 1fr;
  }

  .gif-panel {
    min-height: 260px;
  }

  .intro-copy {
    padding: 28px;
  }
}
