/*
 * druipe.com home page. Loaded after site.css, only on the home page.
 * No scripts and no inline styles (the page's Content-Security-Policy
 * forbids both), so every mockup is plain HTML and CSS.
 *
 * Source colours: each data source has one dot colour, used the same way
 * everywhere. Text always stays in ink; the dot carries the identity.
 */

.home {
  --gsc: #2a78d6;
  --ga: #eb6834;
  --crawl: #8a2f6b;
  --speed: #0b8a57;
  --links: #c98a00;
  --ai: #1d1630;
  --good: #0b8a57;
  --good-soft: #e3f4ec;
  --warn: #b26a00;
  --warn-soft: #fdf1dc;
  --bad: #c0362c;
  --bad-soft: #fbeceb;
  --mist: #f3f4fb;
  --radius: 14px;
  font-size: 18px;
}

/* ---- Header ---------------------------------------------------------- */

.home .top {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgb(255 255 255 / 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
}

.home .top nav {
  gap: 28px;
}

.home .top nav .button {
  padding: 9px 16px;
}

/* ---- Buttons ----------------------------------------------------------- */

.button.big {
  padding: 15px 26px;
  border-radius: 10px;
  font-size: 17px;
}

.button.light {
  background: #fff;
  color: var(--ink) !important;
}

.button.light:hover {
  background: var(--plum-soft);
}

/* ---- Hero -------------------------------------------------------------- */

.home .hero {
  padding: 88px 0 0;
  background: linear-gradient(180deg, var(--mist) 0%, var(--mist) 62%, #fff 62%);
}

.hero-copy {
  max-width: 900px;
  text-align: center;
}

.home .hero h1 {
  margin: 0 auto;
  max-width: 17ch;
  font-size: clamp(40px, 6.2vw, 72px);
  line-height: 1.02;
  font-weight: 760;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.home .hero .lede {
  margin: 26px auto 0;
  max-width: 60ch;
  font-size: 20px;
  line-height: 1.55;
  color: var(--ink-2);
  text-wrap: pretty;
}

.home .hero .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 36px;
}

.fine {
  margin: 18px 0 0;
  font-size: 14px;
  color: var(--ink-3);
}

/* ---- Product frame ------------------------------------------------------ */

.frame {
  margin: 64px auto 0;
  max-width: 1080px;
  border-radius: 16px;
  background: #fff;
  box-shadow:
    0 0 0 1px rgb(29 22 48 / 0.08),
    0 30px 60px -20px rgb(29 22 48 / 0.25),
    0 12px 24px -12px rgb(29 22 48 / 0.12);
  overflow: hidden;
}

.frame-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 42px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  background: #fbfafd;
}

.dots {
  display: flex;
  gap: 6px;
}

.dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #dcd9e4;
}

.address {
  flex: 0 1 320px;
  margin: 0 auto;
  padding: 4px 12px;
  border-radius: 6px;
  background: #f0eef4;
  color: var(--ink-3);
  font-size: 13px;
  text-align: center;
}

.frame-body {
  display: grid;
  grid-template-columns: 196px 1fr;
  min-height: 440px;
}

.side {
  padding: 18px 12px;
  border-right: 1px solid var(--line);
  background: #fbfafd;
  font-size: 14px;
}

.side p {
  margin: 0;
}

.side-site {
  padding: 8px 10px 14px;
  font-weight: 650;
}

.side-group {
  padding: 14px 10px 4px;
  font-size: 12px;
  color: var(--ink-3);
}

.side-item {
  padding: 6px 10px;
  border-radius: 7px;
  color: var(--ink-2);
}

.side-item.on {
  background: var(--plum-soft);
  color: var(--plum-ink);
  font-weight: 600;
}

.screen {
  padding: 22px 24px 24px;
  background: #f6f5f9;
}

.screen-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}

.screen-head p {
  margin: 0;
}

.screen-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.screen-range {
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  font-size: 13px;
  color: var(--ink-2);
}

.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.kpi {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.kpi p {
  margin: 0;
}

.kpi-label {
  font-size: 13px;
  color: var(--ink-2);
}

.kpi-value {
  margin-top: 4px !important;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.up {
  margin-left: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--good);
  letter-spacing: 0;
}

/* The motif: every figure carries the name of its source. */
.src {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px !important;
  padding: 2px 9px 2px 7px;
  border-radius: 999px;
  background: #f3f1f7;
  font-size: 12px;
  color: var(--ink-2);
}

.dot {
  display: inline-block;
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ink-3);
}

.dot.gsc {
  background: var(--gsc);
}

.dot.ga {
  background: var(--ga);
}

.dot.crawl {
  background: var(--crawl);
}

.dot.speed {
  background: var(--speed);
}

.dot.links {
  background: var(--links);
}

.dot.ai {
  background: var(--ai);
}

.chart-card {
  margin-top: 12px;
  padding: 16px 18px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.chart-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.chart-head p {
  margin: 0;
}

.chart-head p:first-child {
  font-weight: 650;
}

.legend {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-2);
  font-size: 13px;
}

.key {
  display: inline-block;
  width: 16px;
  height: 0;
  margin-left: 8px;
  border-top: 2px solid var(--gsc);
}

.key.before {
  border-top: 2px dashed #a3a0b2;
}

.chart {
  display: block;
  width: 100%;
  height: 190px;
  margin-top: 10px;
}

.chart .grid {
  stroke: #ecebf1;
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.chart .now {
  fill: none;
  stroke: var(--gsc);
  stroke-width: 2;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.chart .before {
  fill: none;
  stroke: #a3a0b2;
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
  vector-effect: non-scaling-stroke;
}

.chart .area {
  fill: rgb(42 120 214 / 0.09);
}

.frame figcaption {
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-3);
}

/* ---- Sources strip ----------------------------------------------------- */

.sources {
  padding: 72px 0 24px;
  text-align: center;
}

.sources h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-3);
  letter-spacing: 0;
}

.sources ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 12px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.sources li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 550;
}

/* ---- Feature rows ------------------------------------------------------ */

.feature {
  padding: 88px 0;
}

.feature + .feature {
  border-top: 1px solid var(--line);
}

.feature-grid {
  display: grid;
  grid-template-columns: 5fr 6fr;
  gap: 72px;
  align-items: center;
}

.feature.flip .feature-copy {
  order: 2;
}

.kicker {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 650;
  color: var(--plum);
}

.feature h2 {
  margin: 0;
  font-size: clamp(30px, 3.4vw, 42px);
  line-height: 1.1;
  font-weight: 720;
  letter-spacing: -0.028em;
  text-wrap: balance;
}

.feature-copy > p {
  margin: 20px 0 0;
  color: var(--ink-2);
  max-width: 52ch;
}

.checks {
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.checks li {
  position: relative;
  padding-left: 30px;
  font-size: 17px;
}

.checks li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--good-soft);
}

.checks li::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  width: 5px;
  height: 9px;
  border: solid var(--good);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.feature-copy .from {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--ink-3);
}


/* ---- Panels (static mockups) ------------------------------------------- */

.panel {
  padding: 22px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow:
    0 0 0 1px rgb(29 22 48 / 0.08),
    0 24px 48px -24px rgb(29 22 48 / 0.22);
}

.feature:nth-child(odd) .panel {
  outline: 14px solid var(--mist);
}

.feature:nth-child(even) .panel {
  outline: 14px solid var(--plum-soft);
}

.panel p {
  margin: 0;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 14px;
  font-weight: 650;
}

.muted {
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-3);
}

.mock-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.mock-table th {
  padding: 0 0 8px;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-3);
  text-align: right;
}

.mock-table th:first-child,
.mock-table td:first-child {
  text-align: left;
}

.mock-table td {
  padding: 10px 0;
  border-top: 1px solid var(--line);
  text-align: right;
}

.mock-table td + td,
.mock-table th + th {
  padding-left: 12px;
}

.pos {
  display: inline-block;
  min-width: 42px;
  padding: 1px 8px;
  border-radius: 6px;
  text-align: center;
  font-weight: 600;
}

.pos.top3 {
  background: #e4effb;
  color: #1c5aa6;
}

.pos.top10 {
  background: #eef0f6;
  color: #3e4a66;
}

.pos.rest {
  background: #f3f2f6;
  color: var(--ink-3);
}

.bands {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.bar {
  display: flex;
  gap: 2px;
  height: 12px;
  margin-top: 8px;
}

.bar span {
  border-radius: 3px;
}

.b1 {
  flex: 18;
  background: #1c5aa6;
}

.b2 {
  flex: 31;
  background: #4a8fdf;
}

.b3 {
  flex: 24;
  background: #9cc2ef;
}

.b4 {
  flex: 27;
  background: #d6e5f8;
}

.bar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin-top: 10px !important;
  font-size: 12px;
  color: var(--ink-2);
}

.bar-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.k {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

.k.good {
  background: var(--good);
}

.k.ni {
  background: #e8a33d;
}

.k.poor {
  background: var(--bad);
}

/* Site audit */

.health {
  display: grid;
  grid-template-columns: 104px 1fr;
  gap: 20px;
  align-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.ring {
  width: 104px;
  height: 104px;
  transform: rotate(-90deg);
}

.ring-track {
  fill: none;
  stroke: #efedf3;
  stroke-width: 12;
}

.ring-fill {
  fill: none;
  stroke: var(--good);
  stroke-width: 12;
  stroke-linecap: round;
  stroke-dasharray: 286 314;
}

.health-value {
  font-size: 34px;
  font-weight: 720;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.tally {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px !important;
}

.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.tag.err {
  background: var(--bad-soft);
  color: var(--bad);
}

.tag.warn {
  background: var(--warn-soft);
  color: var(--warn);
}

.tag.note {
  background: #eceaf2;
  color: var(--ink-2);
}

.tag.ok {
  background: var(--good-soft);
  color: var(--good);
}

.tag.gone {
  background: var(--bad-soft);
  color: var(--bad);
}

.issues,
.links,
.share {
  margin: 0;
  padding: 0;
  list-style: none;
}

.issues li {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.issues li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.issues .tag {
  justify-self: start;
}

.count {
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

/* Speed */

.verdict {
  padding: 2px 10px;
  border-radius: 6px;
  font-size: 13px;
}

.verdict.pass {
  background: var(--good-soft);
  color: var(--good);
}

.vitals {
  display: grid;
  gap: 16px;
}

.vital {
  display: grid;
  grid-template-columns: 52px 88px 1fr;
  gap: 14px;
  align-items: center;
}

.vital-name {
  font-weight: 650;
}

.vital-value {
  font-size: 20px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.dist {
  display: flex;
  gap: 2px;
  height: 12px;
}

.dist span {
  border-radius: 3px;
}

.dist .g {
  background: var(--good);
}

.dist .n {
  background: #e8a33d;
}

.dist .p {
  background: var(--bad);
}

.w78 { flex: 78; }
.w15 { flex: 15; }
.w7 { flex: 7; }
.w84 { flex: 84; }
.w12 { flex: 12; }
.w4 { flex: 4; }
.w91 { flex: 91; }
.w6 { flex: 6; }
.w3 { flex: 3; }

.panel .bar-legend {
  margin-top: 18px !important;
}

/* Backlinks */

.links li {
  display: grid;
  grid-template-columns: 1fr auto 64px;
  gap: 14px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  font-size: 15px;
}

.links .via {
  font-size: 13px;
  color: var(--ink-3);
}

.links .tag {
  justify-self: end;
}

/* AI visibility */

.ai-cells {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.ai-cells div {
  padding: 12px 14px;
  border-radius: 10px;
  background: #f6f5f9;
}

.share {
  margin-top: 18px;
  display: grid;
  gap: 12px;
}

.share li {
  display: grid;
  grid-template-columns: 130px 1fr 42px;
  gap: 12px;
  align-items: center;
  font-size: 14px;
}

.share li span:last-child {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.track {
  height: 10px;
  border-radius: 999px;
  background: #efedf3;
  overflow: hidden;
}

.fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #a3a0b2;
}

.share .own {
  font-weight: 650;
}

.share .own .fill {
  background: var(--plum);
}

.s18 { width: 18%; }
.s34 { width: 34%; }
.s27 { width: 27%; }
.s21 { width: 21%; }

/* ---- How it measures ---------------------------------------------------- */

.how {
  padding: 104px 0;
  background: var(--night);
  color: #fff;
}

.how h2,
.steps h2,
.faq h2 {
  margin: 0;
  font-size: clamp(32px, 3.6vw, 46px);
  line-height: 1.08;
  font-weight: 720;
  letter-spacing: -0.03em;
}

.how .intro {
  margin: 16px 0 0;
  max-width: 52ch;
  font-size: 20px;
  color: #c9c3d8;
}

.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 56px;
  border-radius: var(--radius);
  background: rgb(255 255 255 / 0.12);
  overflow: hidden;
}

.principles div {
  padding: 28px 24px 30px;
  background: var(--night);
}

.principles h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.principles h3::before {
  content: '';
  display: block;
  width: 28px;
  height: 3px;
  margin-bottom: 18px;
  border-radius: 2px;
  background: #a5b4fc;
}

.principles p {
  margin: 12px 0 0;
  font-size: 16px;
  color: #c9c3d8;
}

/* ---- Steps ----------------------------------------------------------- */

.steps {
  padding: 104px 0 24px;
}

.steps ol {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps li {
  counter-increment: step;
  padding: 28px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-bottom: 20px;
  border-radius: 50%;
  background: var(--plum-soft);
  color: var(--plum-ink);
  font-weight: 700;
}

.steps h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 680;
}

.steps li p {
  margin: 8px 0 0;
  font-size: 16px;
  color: var(--ink-2);
}

/* ---- FAQ ----------------------------------------------------------------- */

.faq {
  padding: 96px 0;
}

.faq-grid {
  display: grid;
  grid-template-columns: 4fr 8fr;
  gap: 48px;
}

details {
  border-bottom: 1px solid var(--line);
}

details:first-child {
  border-top: 1px solid var(--line);
}

summary {
  position: relative;
  padding: 22px 44px 22px 0;
  font-size: 19px;
  font-weight: 620;
  cursor: pointer;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: '';
  position: absolute;
  right: 6px;
  top: 28px;
  width: 9px;
  height: 9px;
  border: solid var(--ink-2);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  transition: transform 0.15s ease;
}

details[open] summary::after {
  transform: rotate(-135deg);
  top: 32px;
}

details p {
  margin: 0 0 24px;
  max-width: 62ch;
  color: var(--ink-2);
}

/* ---- Closing ------------------------------------------------------------- */

.closing-band {
  padding: 0 0 8px;
}

.closing-band .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 56px 56px;
  border-radius: 20px;
  background: var(--plum);
  color: #fff;
}

.closing-band h2 {
  margin: 0;
  max-width: 20ch;
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.1;
  font-weight: 720;
  letter-spacing: -0.025em;
}

/* ---- Footer ---------------------------------------------------------- */

.mark.small {
  margin-bottom: 14px;
  font-size: 18px;
}

.mark.small svg {
  width: 24px;
  height: 24px;
}

/* ---- Small screens -------------------------------------------------------- */

@media (max-width: 960px) {
  .feature-grid,
  .faq-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .feature.flip .feature-copy {
    order: 0;
  }

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

  .frame-body {
    grid-template-columns: 1fr;
  }

  .side {
    display: none;
  }

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

@media (max-width: 640px) {
  .home {
    font-size: 17px;
  }

  .home .hero {
    padding-top: 56px;
  }

  .home .hero .lede {
    font-size: 18px;
  }

  .frame {
    margin-top: 44px;
  }

  .screen {
    padding: 16px;
  }

  .chart-head {
    flex-direction: column;
  }

  .chart {
    height: 140px;
  }

  .feature {
    padding: 64px 0;
  }

  .panel {
    padding: 16px;
  }

  .feature:nth-child(odd) .panel,
  .feature:nth-child(even) .panel {
    outline-width: 8px;
  }

  .principles,
  .steps ol {
    grid-template-columns: 1fr;
  }

  .ai-cells {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
  }

  .share li {
    grid-template-columns: 100px 1fr 40px;
  }

  .closing-band .wrap {
    padding: 36px 28px;
  }

  .how,
  .steps {
    padding-top: 72px;
  }
}

/* ---- Additions ---------------------------------------------------------- */

.from-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}


.lab {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.lab div {
  padding: 12px 14px;
  border-radius: 10px;
  background: #f6f5f9;
}

.lab .muted {
  grid-column: 1 / -1;
}

.fine a {
  color: var(--ink-2);
}

.steps li p a {
  color: var(--plum-ink);
}

.closing-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
}

.closing-signin {
  color: #fff;
  font-weight: 600;
}

.closing-signin:hover {
  color: #e0e7ff;
}
