/* ReallyCache plugin page. Shared tokens and components live in landing.css. */

.lp section[id] { scroll-margin-top: 80px; }
.lp .w-nowrap { white-space: nowrap; }

/* Hero: the plugin's switch and what it turns on */

.lp .w-rc {
  margin-top: 12px;
  padding: 24px 26px 22px;
  border-radius: 18px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 34px 60px -28px rgba(0, 0, 0, 0.65);
}

.lp .w-rc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.lp .w-rc-name strong {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 2.3rem;
  line-height: 1;
}

.lp .w-rc-name small { font-size: 0.82rem; color: var(--mute); }

/* The switch, on; in a right-to-left screen "on" sits on the left */
.lp .w-switch {
  position: relative;
  flex: none;
  width: 64px;
  height: 36px;
  border-radius: 18px;
  background: var(--magenta);
  transition: background-color 0.35s;
}

.lp .w-switch::after {
  content: '';
  position: absolute;
  top: 4px;
  inset-inline-end: 4px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
  transition: transform 0.35s cubic-bezier(0.3, 1.5, 0.6, 1);
}

.lp .w-rc.is-off .w-switch { background: var(--rule); }
.lp .w-rc.is-off .w-switch::after { transform: translateX(28px); }

.lp .w-rc-sub { margin: 14px 0 4px; font-size: 0.88rem; font-weight: 700; color: var(--mute); }

.lp .w-rc-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.95rem;
  transition: opacity 0.3s;
}

.lp .w-rc-list i {
  display: grid;
  flex: none;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: var(--good);
  font-size: 0.6rem;
  color: #fff;
  transition: transform 0.3s cubic-bezier(0.3, 1.6, 0.6, 1);
}

.lp .w-rc-list li.is-pending { opacity: 0.3; }
.lp .w-rc-list li.is-pending i { transform: scale(0); }

.lp .w-rc-foot {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 14px;
  font-weight: 700;
}

/* In the body face: Karantina's zero reads as a solid block at this size */
.lp .w-rc-foot b {
  display: inline-block;
  font-size: 1.9rem;
  font-weight: 800;
  line-height: 1;
  color: var(--magenta);
}

/* Two lanes: one visitor waits for the page to be built, others get the ready copy */

.lp .w-lanes { display: grid; gap: 20px; max-width: 960px; margin: 0 auto; }

.lp .w-lane {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) 130px;
  align-items: center;
  gap: 24px;
  padding: 22px 24px;
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 0 0 0 1px var(--rule);
}

.lp .w-lane-label strong {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 2rem;
  line-height: 1;
}

.lp .w-lane-label span { font-size: 0.88rem; color: var(--mute); }

.lp .w-lane-track {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-around;
  height: 56px;
  border-radius: 28px;
  background: var(--blush);
}

.lp .w-stop {
  padding: 5px 12px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 0 1px var(--rule);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--mute);
  white-space: nowrap;
  transition: background-color 0.2s, color 0.2s;
}

.lp .w-stop.is-on { background: var(--ink); color: #fff; }
.lp .w-stop-cache { color: var(--magenta); }
.lp .w-stop-cache.is-on { background: var(--magenta); }

/* --p runs from 0 (start of the track) to 1 (the end) */
.lp .w-token {
  --p: 1;
  position: absolute;
  top: 50%;
  inset-inline-start: calc(6px + (100% - 56px) * var(--p));
  z-index: 1;
  display: grid;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  place-items: center;
  border-radius: 50%;
  background: var(--plum);
  box-shadow: 0 6px 14px -6px rgba(42, 20, 48, 0.6);
  font-size: 0.95rem;
  color: #fff;
}

.lp .w-lane-fast .w-token { background: var(--magenta); }

.lp .w-lane-count { font-size: 0.85rem; color: var(--mute); }

.lp .w-lane-count b {
  display: block;
  font-family: var(--display);
  font-size: 3.2rem;
  line-height: 0.85;
  color: var(--ink);
}

.lp .w-lane-fast .w-lane-count b { color: var(--magenta); }

.lp .w-lanes-note { margin-top: 16px; font-size: 0.85rem; color: var(--mute); text-align: center; }

/* The cache refreshes itself: what changed, and which pages get refreshed */

.lp .w-when {
  margin-bottom: 80px;
  padding: 34px 36px 20px;
  border-radius: 20px;
  background: var(--blush);
}

.lp .w-when-head { max-width: 46em; margin-bottom: 14px; }

.lp .w-when-head h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 2.8rem;
  line-height: 1;
}

.lp .w-when-head p { margin-top: 8px; color: var(--mute); }

.lp .w-when-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  align-items: center;
  gap: 24px;
  padding: 16px 0;
  border-top: 1px solid var(--rule);
}

.lp .w-when-if strong { display: block; font-size: 1.12rem; }
.lp .w-when-if span { display: block; font-size: 0.9rem; color: var(--mute); }

.lp .w-when-then {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-weight: 700;
}

/* A refresh mark before what gets refreshed; it spins once as its row refreshes */
.lp .w-when-then::before {
  content: '\f2f1';
  flex: none;
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  font-size: 0.9rem;
  color: var(--magenta);
}

.lp .w-when-list li.is-refreshing .w-when-then::before { animation: w-spin 0.7s ease-in-out; }

@keyframes w-spin { to { transform: rotate(-360deg); } }

/* Features in four groups */

.lp .w-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 64px;
}

.lp .w-group h3 {
  margin-bottom: 16px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1;
  color: var(--magenta);
}

/* "Only here": stamped beside the answers only ReallyCache has, of the three */
.lp .w-only {
  display: inline-block;
  margin-inline-start: 8px;
  padding: 2px 7px 0;
  border: 1.5px solid var(--magenta);
  border-radius: 4px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.1rem;
  line-height: 1.1;
  color: var(--magenta);
  white-space: nowrap;
  transform: rotate(-4deg);
}

/* Comparison, printed */

.lp .w-cmp { padding: 30px 34px calc(30px + var(--zz)); }
.lp .w-cmp table { width: 100%; border-collapse: collapse; }

.lp .w-cmp th,
.lp .w-cmp td {
  padding: 16px 12px;
  border-bottom: 1px dashed var(--rule);
  font-size: 0.92rem;
  text-align: right;
  vertical-align: top;
}

.lp .w-cmp thead th {
  padding-bottom: 14px;
  border-bottom: 3px solid var(--ink);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.7rem;
  line-height: 1;
  vertical-align: bottom;
}

.lp .w-cmp thead th.is-rc { color: var(--magenta); }
.lp .w-cmp tbody th { width: 18%; font-weight: 700; }
.lp .w-cmp td.is-rc { width: 20%; }
.lp .w-cmp tbody tr:last-child > * { border-bottom: 0; }
.lp .w-cmp td.is-rc { font-weight: 700; }

/* A highlighter stroke under ReallyCache's answers, drawn from the right */
.lp .w-cmp mark {
  padding: 0 2px;
  background: linear-gradient(rgba(242, 179, 207, 0.8), rgba(242, 179, 207, 0.8)) no-repeat right 88% / 100% 0.55em;
  color: inherit;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

/* Fits most sites, not all of them */
.lp .w-fit-note {
  max-width: 760px;
  margin: 40px auto 0;
  padding: 22px 26px;
  border-inline-start: 4px solid var(--magenta);
  border-radius: 14px 4px 4px 14px;
  background: var(--paper);
}

.lp .w-fit-note h3 { font-size: 1.15rem; font-weight: 700; }
.lp .w-fit-note p { margin-top: 6px; color: var(--mute); }

.lp .w-cmp-note {
  max-width: 52em;
  margin: 28px auto 0;
  font-size: 0.92rem;
  color: var(--mute);
  text-align: center;
}

/* Install */

.lp .w-download { margin-top: 64px; }
.lp .w-download-note { margin-top: 12px; font-size: 0.9rem; color: rgba(255, 255, 255, 0.65); }

/* Responsive */

@media (max-width: 900px) {
  .lp .w-rc { width: min(100%, 440px); margin-inline: auto; }

  .lp .w-lane { grid-template-columns: minmax(0, 1fr) auto; gap: 14px 16px; padding: 18px; }
  .lp .w-lane-track { grid-column: 1 / -1; grid-row: 2; }
  .lp .w-lane-count { text-align: left; }
  .lp .w-lane-count b { display: inline-block; margin-inline-end: 6px; font-size: 2.4rem; }

  .lp .w-groups { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .lp .w-when { margin-bottom: 64px; padding: 26px 20px 12px; }
  .lp .w-when-list li { grid-template-columns: minmax(0, 1fr); gap: 8px; }
}

/* The table becomes one block per row, each answer labeled with its plugin */
@media (max-width: 1000px) {
  .lp .w-cmp { padding: 18px 18px calc(20px + var(--zz)); }

  .lp .w-cmp table,
  .lp .w-cmp tbody,
  .lp .w-cmp tr,
  .lp .w-cmp th,
  .lp .w-cmp td { display: block; width: auto; }

  .lp .w-cmp thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .lp .w-cmp tbody tr { padding: 16px 0; border-bottom: 2px dashed var(--rule); }
  .lp .w-cmp tbody tr:last-child { border-bottom: 0; }

  .lp .w-cmp th,
  .lp .w-cmp td { padding: 4px 0; border: 0; }

  .lp .w-cmp tbody th,
  .lp .w-cmp td.is-rc { width: auto; }

  .lp .w-cmp tbody th {
    margin-bottom: 6px;
    font-family: var(--display);
    font-size: 1.7rem;
    line-height: 1;
  }

  .lp .w-cmp td { display: flex; gap: 12px; font-size: 0.92rem; }

  .lp .w-cmp td::before {
    content: attr(data-label);
    flex: none;
    width: 134px;
    font-weight: 600;
    color: var(--mute);
  }
}

@media (max-width: 560px) {
  .lp .w-stop { padding: 4px 8px; font-size: 0.74rem; }
  .lp .w-token { width: 38px; height: 38px; margin-top: -19px; }
}
