/* Indrava marketing site. Colours and typeface are the web app's (apps/web/src/styles.css). */
@font-face {
  font-family: "Schibsted Grotesk Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 400 900;
  src: url("/fonts/schibsted-grotesk.woff2") format("woff2-variations");
}

:root {
  color-scheme: light dark;
  --bg: #f4f5f8;
  --surface: #ffffff;
  --tone: #e9ecf2;
  --ink: #141a25;
  --muted: #586273;
  --primary: #2447d5;
  --on-primary: #ffffff;
  --field: #141a25;
  --on-field: #e6e9ef;
  --field-muted: #a3adbd;
  --line: #dde1e9;
  /* delivery states: the same five colours as the app */
  --st-draft: #5f6979;
  --st-scheduled: #2447d5;
  --st-publishing: #946005;
  --st-published: #19794a;
  --st-failed: #c2332a;
  --gutter: 20px;
  --gap: clamp(88px, 13vw, 176px);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1218;
    --surface: #161b23;
    --tone: #1c222c;
    --ink: #e6e9ef;
    --muted: #97a1b1;
    --primary: #8098ff;
    --on-primary: #0b1024;
    --field: #161b23;
    --line: #272e3a;
    --st-draft: #97a1b1;
    --st-scheduled: #8098ff;
    --st-publishing: #e5a93f;
    --st-published: #4cc38a;
    --st-failed: #f0766c;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    400 1.0625rem / 1.55 "Schibsted Grotesk Variable",
    ui-sans-serif,
    system-ui,
    sans-serif;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure,
pre,
table {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 0.08em;
}

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.wrap {
  width: min(100% - 2 * var(--gutter), 1200px);
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: var(--gutter);
  top: 12px;
  z-index: 2;
  padding: 10px 14px;
  background: var(--surface);
}

/* type: one very large size, one heading size, one text size */
h1 {
  font-size: clamp(2rem, 6.4vw, 5rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.hero h1 {
  font-size: clamp(2.5rem, 8.6vw, 6.75rem);
}

.hero .split {
  margin-top: clamp(28px, 4vw, 56px);
}

h2 {
  font-size: clamp(1.75rem, 4.4vw, 3.25rem);
  font-weight: 750;
  line-height: 1.04;
  letter-spacing: -0.028em;
  text-wrap: balance;
}

h3 {
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.3;
}

.lede {
  max-width: 34em;
  font-size: clamp(1.125rem, 1.9vw, 1.375rem);
  line-height: 1.42;
}

.note {
  color: var(--muted);
  font-size: 0.9375rem;
}

.prose {
  max-width: 38em;
}

.prose > * + * {
  margin-top: 1em;
}

/* header */
.top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 28px;
  padding-block: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-decoration: none;
}

/* phone: name and actions on one row, the links on the next */
.top nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 18px;
  order: 3;
  flex-basis: 100%;
}

.top nav a,
.top .signin {
  padding-block: 8px;
  font-size: 1rem;
  text-decoration: none;
}

.top nav a:hover,
.top .signin:hover,
.top nav a[aria-current="page"] {
  text-decoration: underline;
}

.top .acts {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

/* buttons: square-cornered like the app, one fill */
.btn {
  display: inline-block;
  padding: 13px 20px;
  border-radius: 4px;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 0.12s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn.small {
  padding: 9px 14px;
}

.btn.quiet {
  background: var(--tone);
  color: var(--ink);
}

.acts-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: 28px;
}

/* page rhythm */
main > section {
  padding-top: var(--gap);
}

main > section:first-child {
  padding-top: clamp(40px, 7vw, 96px);
}

main > section:last-child {
  padding-bottom: var(--gap);
}

.head + * {
  margin-top: clamp(28px, 4vw, 48px);
}

.split > .head + * {
  margin-top: 0;
}

.head h1 + *,
.head h2 + * {
  margin-top: clamp(18px, 2.4vw, 30px);
}

.split {
  display: grid;
  gap: 36px;
}

.band {
  background: var(--tone);
}

.band,
.field {
  margin-top: var(--gap);
  padding-block: clamp(64px, 9vw, 120px);
}

.field {
  background: var(--field);
  color: var(--on-field);
}

.field .note {
  color: var(--field-muted);
}

.field :focus-visible {
  outline-color: var(--on-field);
}

.band + section:not(.band, .field),
.field + section:not(.band, .field) {
  padding-top: var(--gap);
}

.band + .band,
.field + .band,
.band + .field {
  margin-top: 0;
}

main > .band:last-child,
main > .field:last-child {
  padding-bottom: clamp(64px, 9vw, 120px);
}

/* definition-style lists: a term and what it does, two columns on wide screens */
.facts {
  display: grid;
  gap: 26px 48px;
}

.facts dt {
  font-weight: 700;
}

.facts dd {
  margin-top: 4px;
}

.ticks li {
  position: relative;
  padding-left: 1.5em;
}

.ticks li + li {
  margin-top: 0.5em;
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 0.1em;
  top: 0.55em;
  width: 0.6em;
  height: 0.6em;
  border-radius: 50%;
  background: var(--st-published);
}

/* interface fragments: drawn as the app draws them */
.ui {
  padding: 18px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 0.9375rem;
  line-height: 1.4;
}

.field .ui {
  background: var(--bg);
}

.ui-title {
  font-weight: 700;
}

.ui-post {
  margin-top: 6px;
  padding: 12px 14px;
  border-radius: 5px;
  background: var(--bg);
}

.field .ui-post {
  background: var(--surface);
}

.ui-rows {
  margin-top: 12px;
}

.ui-rows li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 16px;
  padding-block: 10px;
}

.ui-rows li + li {
  border-top: 1px solid var(--line); /* taste-skill-ignore: the app's own row line, inside a data-ui fragment */
}

.ui-rows .why {
  grid-column: 1 / -1;
  color: var(--muted);
}

.st {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 650;
  white-space: nowrap;
  color: var(--c);
}

.st::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--c);
}

.st.draft {
  --c: var(--st-draft);
}

.st.scheduled {
  --c: var(--st-scheduled);
}

.st.publishing {
  --c: var(--st-publishing);
}

.st.published {
  --c: var(--st-published);
}

.st.failed {
  --c: var(--st-failed);
}

.ui-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.ui-btn {
  padding: 8px 12px;
  border-radius: 5px;
  background: var(--tone);
  font-weight: 650;
}

.ui-btn.go {
  background: var(--primary);
  color: var(--on-primary);
}

.week {
  display: grid;
  grid-template-columns: repeat(5, minmax(116px, 1fr));
  overflow-x: auto;
  gap: 6px;
  margin-top: 12px;
}

.week > div {
  min-height: 132px;
  padding: 8px;
  border-radius: 5px;
  background: var(--bg);
}

.week b {
  display: block;
  margin-bottom: 6px;
}

.week span {
  display: block;
  margin-top: 4px;
  padding: 4px 6px;
  border-left: 3px solid var(--c, var(--st-scheduled));
  border-radius: 2px;
  background: var(--surface);
  font-size: 0.8125rem;
  overflow-wrap: anywhere;
}

/* the first screen's receipt arrives row by row, once */
@media (prefers-reduced-motion: no-preference) {
  .arrive > * {
    animation: arrive 0.5s cubic-bezier(0.2, 0.7, 0.2, 1) both;
    animation-delay: calc(var(--i, 0) * 110ms + 150ms);
  }

  @keyframes arrive {
    from {
      opacity: 0;
      transform: translateY(14px);
    }
  }

  .st.publishing::before {
    animation: pulse 1.2s ease-in-out infinite alternate;
  }

  @keyframes pulse {
    to {
      opacity: 0.25;
    }
  }
}

/* code */
pre {
  overflow-x: auto;
  padding: 18px;
  border-radius: 8px;
  background: var(--field);
  color: var(--on-field);
  font:
    0.875rem / 1.55 ui-monospace,
    SFMono-Regular,
    Menlo,
    Consolas,
    monospace;
  tab-size: 2;
}

.field pre {
  background: var(--bg);
  color: var(--ink);
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
}

/* tables */
.scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
}

caption {
  padding-bottom: 12px;
  color: var(--muted);
  font-size: 0.9375rem;
  text-align: left;
}

th,
td {
  padding: 13px 20px 13px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

thead th {
  border-bottom: 2px solid var(--ink);
  font-weight: 700;
  white-space: nowrap;
}

tbody th {
  font-weight: 650;
}

td.num,
th.num {
  font-variant-numeric: tabular-nums;
}

.plans thead th {
  min-width: 7.5em;
  font-size: 1.25rem;
}

.plans .price {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

/* channel filter: radios and :has(), no script; without :has() every row simply shows */
.filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  border: 0;
  margin: 0 0 22px;
}

.filter legend {
  padding: 0;
  margin-bottom: 10px;
  font-weight: 700;
}

.filter label {
  padding: 9px 14px;
  border-radius: 4px;
  background: var(--tone);
  font-weight: 600;
  cursor: pointer;
}

.filter input {
  position: absolute;
  opacity: 0;
}

.filter label:has(input:checked) {
  background: var(--ink);
  color: var(--bg);
}

.filter label:has(input:focus-visible) {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.channels:has(#f-signin:checked) tbody tr:not([data-signin]),
.channels:has(#f-key:checked) tbody tr:not([data-key]),
.channels:has(#f-long:checked) tbody tr:not([data-long]),
.channels:has(#f-stats:checked) tbody tr:not([data-stats]),
.channels:has(#f-inbox:checked) tbody tr:not([data-inbox]) {
  display: none;
}

/* changelog and long lists */
.log h3 {
  margin-top: 1.6em;
}

.log ul {
  margin-top: 0.5em;
  padding-left: 1.2em;
  list-style: disc;
}

.log li + li {
  margin-top: 0.35em;
}

/* footer: links, then the name at full width */
footer {
  overflow: hidden;
  padding-block: clamp(56px, 8vw, 96px) 28px;
  background: var(--field);
  color: var(--on-field);
}

footer .cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px 24px;
}

footer h2 {
  margin-bottom: 10px;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.5;
}

footer li a {
  display: inline-block;
  padding-block: 5px;
  color: var(--field-muted);
  text-decoration: none;
}

footer li a:hover {
  color: var(--on-field);
  text-decoration: underline;
}

footer :focus-visible {
  outline-color: var(--on-field);
}

.name {
  margin-top: clamp(40px, 6vw, 72px);
  font-size: clamp(4.5rem, 23vw, 19rem);
  font-weight: 800;
  line-height: 0.8;
  letter-spacing: -0.055em;
}

footer .note {
  margin-top: 28px;
  color: var(--field-muted);
}

@media (min-width: 760px) {
  :root {
    --gutter: 32px;
  }

  .top nav {
    order: 0;
    flex: 1;
    gap: 4px 22px;
  }

  .split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(40px, 6vw, 96px);
    align-items: start;
  }

  .split.wide-left {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  }

  .facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  footer .cols {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1040px) {
  .facts.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* free tools */
.toollist {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 28px 40px;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  margin-block: 32px;
}
.toollist h2 {
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}
.toollist p {
  color: var(--muted);
  margin-top: 6px;
}
.tool {
  display: grid;
  gap: 18px;
  margin-block: 28px;
  max-width: 880px;
}
.tool .fld {
  display: grid;
  gap: 6px;
  align-content: start;
}
.tool label {
  font-weight: 650;
  font-size: 0.9375rem;
}
.tool textarea,
.tool input[type="text"],
.tool input[type="number"],
.tool input[type="time"],
.tool select,
.tool input[type="file"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}
.tool input[type="color"] {
  width: 64px;
  height: 40px;
  padding: 2px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.tool textarea {
  resize: vertical;
}
.tool .grid2 {
  display: grid;
  gap: 14px 18px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.tool .row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.tool .row select,
.tool .row input {
  width: auto;
  flex: 1 1 140px;
}
.tool .result {
  min-height: 1.5em;
  font-weight: 650;
}
.tool .big {
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  min-height: 1.2em;
}
.tool .bad,
.tool .bad:is(td, li) {
  color: var(--st-failed);
}
.tool .ok {
  color: var(--st-published);
}
.tool .checks {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 8px;
}
.tool .parts {
  display: grid;
  gap: 12px;
  padding-inline-start: 0;
  list-style: none;
}
.tool .parts li {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.tool .parts li span {
  flex: 1 1 100%;
  white-space: pre-wrap;
}
.tool .btn.ghost,
.tool .ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}
.tool .pic {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.tool .slides,
.tool .cards {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.tool .slide {
  display: grid;
  gap: 8px;
  margin: 0;
}
.tool .slide canvas {
  width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.tool .card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.tool .card.bad {
  border-color: var(--st-failed);
}
.tool .card .who {
  font-weight: 700;
  margin-block: 4px 8px;
}
.tool .card p {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.tool .more {
  color: var(--muted);
  font-weight: 600;
}
.tool .split2 {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  align-items: start;
}
.tool .phone {
  max-width: 320px;
  margin-inline: auto;
  padding: 28px 18px;
  border: 8px solid var(--ink);
  border-radius: 32px;
  text-align: center;
  background: var(--surface);
  width: 100%;
}
.tool .phone h2 {
  font-size: 1.25rem;
  margin-top: 10px;
}
.tool .phone ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 10px;
  margin-top: 16px;
}
.tool .pill {
  display: block;
  padding: 12px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 650;
}
.tool .av {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin-inline: auto;
  display: grid;
  place-items: center;
  background: var(--tone);
  font-size: 1.5rem;
  font-weight: 800;
}
.tool .weekgrid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}
.tool .day {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  display: grid;
  gap: 8px;
  align-content: start;
}
.tool .item {
  display: grid;
  gap: 4px;
  padding: 8px;
  border-radius: 8px;
  background: var(--tone);
  overflow-wrap: anywhere;
}
.tool .addpost {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  display: grid;
  gap: 12px;
  background: var(--surface);
}
.tool .sub {
  font-size: 1.25rem;
}
.langs {
  display: flex;
  gap: 10px;
  font-size: 0.875rem;
}
.langs a[aria-current] {
  font-weight: 700;
  text-decoration: none;
}

/* home: capabilities and plans at poster scale, the channel names, steps, questions */
.soft {
  color: var(--muted);
}

.poster {
  margin-top: clamp(20px, 3vw, 36px);
}

.poster li {
  display: grid;
  gap: 4px 48px;
  padding-block: 0.18em;
  align-items: first baseline;
}

.poster .pn {
  font-size: clamp(2rem, 6.2vw, 5.25rem);
  font-weight: 750;
  line-height: 1.04;
  letter-spacing: -0.035em;
}

.poster .pd {
  max-width: 30em;
  margin-bottom: 18px;
}

.names {
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  line-height: 1.5;
  color: var(--field-muted);
  text-wrap: pretty;
}

.steps {
  display: grid;
  gap: 40px;
  max-width: 36em;
}

.steps b {
  display: block;
  font-size: 1.375rem;
  letter-spacing: -0.01em;
}

.faq {
  margin-top: clamp(28px, 4vw, 56px);
  max-width: 48em;
}

.faq details {
  padding: 18px 20px;
  border-radius: 8px;
}

.faq details[open] {
  background: var(--tone);
}

.faq summary {
  cursor: pointer;
  font-size: 1.3125rem;
  font-weight: 600;
}

.faq details p {
  margin-top: 10px;
  max-width: 44em;
}

@media (min-width: 900px) {
  .poster li {
    grid-template-columns: 2fr 1fr;
  }

  .poster .pd {
    margin-bottom: 0;
  }

  .field .names {
    max-width: 62em;
  }

  .faq {
    margin-inline-start: 33%;
  }
}

/* entrances and hover feedback: scroll-driven where the browser has it, plain content elsewhere */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    main > section:not(:first-child) .head,
    .poster li,
    .steps li,
    .faq details,
    main > section:not(:first-child) .ui,
    .names,
    .facts > div {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 55%;
    }

    @keyframes rise {
      from {
        transform: translateY(28px);
      }
    }
  }

  .poster li,
  .faq details,
  .ui {
    transition: background-color 0.15s ease;
  }

  .poster li:hover .pn {
    color: var(--primary);
  }

  .faq details:hover {
    background: var(--tone);
  }
}

/* the language switcher is not part of the main links' row */
.top .acts .langs {
  flex: none;
  order: 0;
  display: none;
  gap: 14px;
}

@media (min-width: 1560px) {
  .top .acts .langs {
    display: flex;
  }
}

@media (min-width: 760px) {
  .top > nav {
    flex-wrap: nowrap;
    white-space: nowrap;
  }
}
