/* meercal marketing site.
   The landing styles are the meerail site's, which are in turn the meerkat
   landing page's: the three sites are one family and should read as one.
   Anything specific to this site is grouped at the bottom under
   "meercal additions"; the shared part above is kept identical on purpose, so
   a fix to one site can be copied to the others without a diff to read. */

html, body {
  margin: 0;
  background: #fff;
  scroll-behavior: smooth;
}

.landing {
  color: #1f2328;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans",
    Helvetica, Arial, sans-serif;
  line-height: 1.55;
}

.landing a { color: #2185d0; text-decoration: none; }
.landing a:hover { text-decoration: underline; }

/* ---- Top nav ---- */
.landing-nav {
  border-bottom: 1px solid #e6e8eb;
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
}
.landing-nav-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: .85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.landing-brand {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-weight: 700;
  font-size: 1.2rem;
  color: #1f2328 !important;
}
.landing-brand img { height: 1.9em; width: auto; }
.landing-brand:hover { text-decoration: none; }
.landing-nav-links { display: flex; align-items: center; gap: 1.4rem; }
.landing-nav-links a { color: #57606a; font-weight: 500; }
.landing-nav-links a:hover { color: #1f2328; text-decoration: none; }
.landing-nav-links .button { color: #fff !important; }

/* ---- Hero ---- */
.landing-hero {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4rem 1.25rem 2rem;
  display: flex;
  align-items: center;
  gap: 3rem;
}
.landing-hero-copy {
  flex: 1 1 0;
  min-width: 0;
}
.landing-logo {
  flex: 0 0 auto;
  width: 320px;
  max-width: 45%;
  height: auto;
  margin: 0;
  display: block;
  filter: drop-shadow(0 10px 22px rgba(0,0,0,.14));
}
.landing-title {
  font-size: 2.7rem;
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: .25rem 0 .9rem;
}
.landing-subtitle {
  font-size: 1.2rem;
  color: #57606a;
  margin: 0;
}

/* ---- Boxed section (used for the AI / skill block) ---- */
.landing-login-section {
  max-width: 1000px;
  margin: 3.5rem auto 0;
  padding: 3.5rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  border: 1px solid #cfe3f6;
  border-radius: 18px;
  background: linear-gradient(180deg, #f1f8ff 0%, #ffffff 70%);
  box-shadow: 0 10px 34px rgba(33,133,208,.12);
}
.landing-login-title {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 .5rem;
  text-align: center;
}
.landing-login-lede {
  color: #57606a;
  font-size: 1.12rem;
  max-width: 620px;
  margin: 0 auto 1.75rem;
  text-align: center;
}

/* ---- Features sections ---- */
.landing-features {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4.5rem 1.25rem 1rem;
  text-align: center;
}
.landing-section-title {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 .5rem;
}
.landing-section-lede {
  font-size: 1.12rem;
  color: #57606a;
  max-width: 620px;
  margin: 0 auto 2.75rem;
}
.landing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  text-align: left;
}
.landing-card {
  border: 1px solid #e6e8eb;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.landing-card:hover {
  border-color: #d0d7de;
  box-shadow: 0 6px 20px rgba(27,31,36,.08);
  transform: translateY(-2px);
}
.landing-card-body { padding: 1.5rem; }
.landing-card-icon {
  font-size: 2rem;
  line-height: 1;
  color: #2185d0;
  margin-bottom: .85rem;
}
.landing-card-icon i.icon { margin: 0; }
.landing-card h3 {
  font-size: 1.18rem;
  font-weight: 700;
  margin: 0 0 .5rem;
}
.landing-card p { color: #57606a; margin: 0; }
/* Every card was one paragraph until the sync card needed two, and margin:0
   ran them together into a single block of text. Only the gap between them. */
.landing-card p + p { margin-top: .85rem; }

/* ---- Footer ---- */
.landing-footer {
  margin-top: 4rem;
  border-top: 1px solid #e6e8eb;
  background: #f6f8fa;
  text-align: center;
  padding: 1.75rem 1.25rem;
}
.landing-footer p {
  max-width: 640px;
  margin: 0 auto;
  color: #6e7781;
  font-size: .9rem;
}

/* ===== meercal additions ===== */

/* Hero call-to-action row. */
.landing-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  margin-top: 1.5rem;
}

/* Shell snippets inside cards and the skill box. */
.landing-code {
  margin: .9rem 0 0;
  padding: .8rem .9rem;
  border: 1px solid #e6e8eb;
  border-radius: 8px;
  background: #f6f8fa;
  color: #1f2328;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .82rem;
  line-height: 1.5;
  white-space: pre;
  overflow-x: auto;
}
.landing code {
  background: #f6f8fa;
  border-radius: 4px;
  padding: .1em .35em;
  font-size: .9em;
}

/* A card that spans the whole grid row, for a feature worth extra room.
   Its body lays out as copy + illustration side by side. */
.landing-card-wide { grid-column: 1 / -1; }
.landing-card-wide .landing-card-body { padding: 2rem; }
.landing-card-wide-inner {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}
.landing-card-wide-copy { flex: 1 1 0; min-width: 0; }
.landing-card-wide h3 { font-size: 1.35rem; }

/* Right-hand column of a wide card, holding a snippet or a stack of buttons
   beside the copy. */
.landing-card-wide-aside {
  flex: 0 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.landing-card-wide-aside .landing-code { margin-top: 0; }
.landing-card-wide-aside .ui.button { margin: 0; white-space: nowrap; }

/* File-type chips under the attachment card's copy. */
.landing-filetypes {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1.1rem;
}
.landing-filetype {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .4rem .7rem;
  border: 1px solid #e6e8eb;
  border-radius: 8px;
  background: #f6f8fa;
  color: #57606a;
  font-size: .85rem;
  font-weight: 600;
}
.landing-filetype .icon { margin: 0; color: #2185d0; }

/* Three headline figures from the statistics panel, on the analytics card.
   Real numbers from the screenshot beside it, so the card and the shot agree. */
.landing-stats {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1.1rem;
}
.landing-stat {
  display: inline-flex;
  flex-direction: column;
  gap: .1rem;
  padding: .5rem .8rem;
  border: 1px solid #e6e8eb;
  border-radius: 8px;
  font-size: .78rem;
  color: #5b5e63;
  background: #fbfcfd;
}
.landing-stat b {
  font-size: 1.15rem;
  font-weight: 600;
  color: #1b1c1d;
}

/* Mock of the composer's live preview, on the markdown card: the markers are
   dimmed rather than dropped, which is the whole point of the feature. */
.landing-md {
  margin-top: 1.1rem;
  padding: .6rem .75rem;
  border: 1px solid #e2e4e8;
  border-radius: 8px;
  background: #fafbfc;
  color: #1b1c1d;
  font-size: .88rem;
  line-height: 1.9;
}
.landing-md-mark { color: #b0b4ba; }
.landing-md-h { font-size: 1.15em; }
.landing-md-link { color: #2185d0; text-decoration: underline; }

/* The two halves of a content window, on the storage card: what is kept whole
   and what is kept as headers. The second row is deliberately not greyed out to
   the point of looking disabled: that mail is still there and still searchable. */
.landing-window {
  margin-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.landing-window-row {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem .65rem;
  border: 1px dashed #d7dade;
  border-radius: 8px;
  font-size: .8rem;
  color: #5b5e63;
  background: #fbfcfd;
}
.landing-window-row.is-full {
  border-style: solid;
  border-color: #c6e0f5;
  background: #f4f9fe;
  color: #1b1c1d;
}

/* Miniature message rows showing the age tint ramping up. --t mirrors the
   --age-t the app sets per row, and the rgb/alpha match mail.css's light theme
   so the card shows the real colour rather than an approximation of it. */
.landing-age {
  margin-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.landing-age-row {
  padding: .4rem .6rem;
  border-radius: 7px;
  font-size: .82rem;
  color: #5b5e63;
  background: rgba(255, 69, 58, calc(var(--t) * .34));
}

/* Keycaps illustrating the keyboard-control card. */
.landing-keys {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-top: 1.1rem;
}
.landing-key {
  min-width: 1.9rem;
  text-align: center;
  padding: .2rem .5rem;
  border: 1px solid #d0d7de;
  border-bottom-width: 3px;
  border-radius: 6px;
  background: #f6f8fa;
  color: #57606a;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .85rem;
  font-weight: 600;
}

/* Generic chip row: the reminder presets, the machines sharing a journal.
   Same shape as .landing-filetype, which was written for one card and then
   wanted by three; this is that look with a name that does not lie. */
.landing-chips {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1.1rem;
}
.landing-chip {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .4rem .7rem;
  border: 1px solid #e6e8eb;
  border-radius: 8px;
  background: #f6f8fa;
  color: #57606a;
  font-size: .85rem;
  font-weight: 600;
}
.landing-chip .icon { margin: 0; color: #2185d0; }

/* Stacked miniature rows: the Outbox holding a message, the Recent actions
   list. Solid rather than dashed (cf. .landing-window-row): every row here is a
   thing that exists, not a state something might be in. */
.landing-rows {
  margin-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.landing-row {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem .65rem;
  border: 1px solid #e6e8eb;
  border-radius: 8px;
  font-size: .8rem;
  color: #5b5e63;
  background: #fbfcfd;
}
.landing-row .icon { margin: 0; color: #2185d0; flex: none; }
/* The trailing control on a row: "Send now", "Undo". Pushed to the end so the
   rows read as a list with an action, which is what they are in the app. */
.landing-row-action {
  margin-left: auto;
  padding: .1rem .45rem;
  border: 1px solid #c6e0f5;
  border-radius: 5px;
  background: #f4f9fe;
  color: #2185d0;
  font-size: .72rem;
  font-weight: 600;
}

/* Skill download block inside the boxed AI section. */
.landing-skill {
  width: 100%;
  max-width: 560px;
  text-align: left;
}
.landing-skill-lede {
  font-weight: 600;
  margin: 0 0 .5rem;
}
.landing-skill .landing-code { background: #fff; margin-bottom: 1rem; }
.landing-skill-note {
  text-align: center;
  color: #6e7781;
  font-size: .9rem;
  margin: .9rem 0 0;
}
.landing-skill-note .icon { color: #8c959f; }

/* Example questions under the AI section. */
.landing-asks {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem;
  margin-top: 2rem;
  max-width: 720px;
}
.landing-ask {
  padding: .35rem .75rem;
  border: 1px solid #bfe0fb;
  border-radius: 999px;
  background: #eef7fe;
  color: #2185d0;
  font-size: .88rem;
  font-weight: 500;
}

/* ---- Responsive ---- */
@media (max-width: 820px) {
  .landing-grid { grid-template-columns: 1fr; }
  /* Four thumbnails across is unreadable on a phone; two is still small. */
  .landing-shot-grid { grid-template-columns: repeat(2, 1fr); }
  .landing-lightbox { padding: 3.5rem 1rem 1rem; }
  .landing-lightbox-figure img { max-height: calc(100vh - 13rem); }
  /* The wide card stacks and its chips go full width. */
  .landing-card-wide .landing-card-body { padding: 1.5rem; }
  .landing-card-wide-inner { flex-direction: column; align-items: stretch; gap: 1.5rem; }
  .landing-card-wide h3 { font-size: 1.18rem; }
  .landing-filetypes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .landing-card-wide-aside .landing-code { font-size: .78rem; }
  .landing-login-section { margin: 2.5rem 1.25rem 0; padding: 2.5rem 1.5rem; }
  .landing-title { font-size: 2.05rem; }
  .landing-subtitle { font-size: 1.08rem; }
  .landing-hero {
    flex-direction: column;
    gap: 2rem;
    padding-top: 2.5rem;
    text-align: center;
  }
  .landing-hero-copy { flex: 0 1 auto; }
  .landing-hero-actions { justify-content: center; }
  .landing-logo { width: 180px; max-width: 60%; margin-left: auto; margin-right: auto; }
  .landing-subtitle { max-width: 560px; margin-left: auto; margin-right: auto; }
}
@media (max-width: 480px) {
  /* The nav links duplicate the in-page sections on small screens. */
  .landing-nav-links a:not(.button) { display: none; }
}

/* --- Screenshots ------------------------------------------------------- */
/* Small thumbnails only: the detail lives in the lightbox, so these just have
   to be recognisable and invite the click. */
.landing-shots {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4.5rem 1.25rem 0;
  text-align: center;
}
.landing-shot-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.landing-shot { margin: 0; }

/* The clickable frame. A button so it's keyboard-reachable for free. */
.landing-shot-btn {
  display: block;
  position: relative;
  width: 100%;
  padding: 0;
  border: 1px solid #e6e8eb;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
  cursor: zoom-in;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.landing-shot-btn:hover,
.landing-shot-btn:focus-visible {
  border-color: #2185d0;
  box-shadow: 0 8px 22px rgba(31, 35, 40, .14);
  transform: translateY(-2px);
  outline: none;
}
.landing-shot-btn img {
  display: block;
  width: 100%;
  height: auto;
  /* Dense UI at thumbnail size: show the whole frame rather than cropping, so
     the three-pane shape stays readable even when the text doesn't. */
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top left;
}

/* Magnifier badge, revealed on hover/focus. */
.landing-shot-zoom {
  position: absolute;
  right: .45rem;
  bottom: .45rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 6px;
  background: rgba(31, 35, 40, .72);
  color: #fff;
  font-size: .8rem;
  opacity: 0;
  transition: opacity .15s ease;
}
.landing-shot-zoom .icon { margin: 0; }
.landing-shot-btn:hover .landing-shot-zoom,
.landing-shot-btn:focus-visible .landing-shot-zoom { opacity: 1; }

.landing-shot figcaption {
  margin-top: .6rem;
  color: #57606a;
  font-size: .88rem;
  font-weight: 600;
}

/* --- Lightbox ---------------------------------------------------------- */
.landing-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1.5rem;
  background: rgba(15, 18, 21, .88);
  cursor: zoom-out;
}
.landing-lightbox[hidden] { display: none; }
.landing-lightbox-figure {
  margin: 0;
  max-width: 1400px;
  width: 100%;
  text-align: center;
}
.landing-lightbox-figure img {
  display: block;
  width: auto;
  max-width: 100%;
  /* Leave room for the caption under the image. */
  max-height: calc(100vh - 11rem);
  margin: 0 auto;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .45);
  cursor: default;
}
.landing-lightbox-figure figcaption {
  max-width: 68ch;
  margin: 1.1rem auto 0;
  color: #d0d7de;
  font-size: .95rem;
  line-height: 1.5;
  cursor: default;
}
.landing-lightbox-figure figcaption strong { color: #fff; font-weight: 600; }
.landing-lightbox-figure figcaption code {
  background: rgba(255, 255, 255, .12);
  border-radius: 4px;
  padding: .1em .35em;
}
.landing-lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  width: 2.4rem;
  height: 2.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background .15s ease;
}
.landing-lightbox-close:hover,
.landing-lightbox-close:focus-visible { background: rgba(255, 255, 255, .24); outline: none; }
.landing-lightbox-close .icon { margin: 0; }

/* ===== meercal additions ===== */

/* A tour of wide screenshots inside a feature section rather than the
   thumbnail grid: the Ribbon needs the width to make its point, and the rest
   of the views are a click sideways instead of another five screens of page.
   The controls are added by the script, so with JS off this is what it
   replaced: one wide screenshot. */
.landing-slider {
  max-width: 1000px;
  margin: 2.5rem auto 0;
}
.landing-slider-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
}
.landing-slider-track {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
  transition: transform .45s cubic-bezier(.4, 0, .2, 1);
}
.landing-slide {
  flex: 0 0 100%;
  min-width: 0;
}
.landing-slide .landing-shot-btn { border-radius: 10px; }
.landing-slide img { border-radius: 10px; }
/* The grid's lift-on-hover would be clipped by the viewport, and a slide that
   moves under the pointer reads as a bug rather than as an invitation. */
.landing-slide .landing-shot-btn:hover,
.landing-slide .landing-shot-btn:focus-visible {
  transform: none;
  box-shadow: none;
}

.landing-slider-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  /* Shown once the script has taken charge; dead arrows are worse than none. */
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  margin-top: -1.3rem;
  padding: 0;
  border: 1px solid rgba(31, 35, 40, .08);
  border-radius: 50%;
  background: rgba(255, 255, 255, .93);
  color: #24292f;
  font-size: .95rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(31, 35, 40, .18);
  transition: background .15s ease, box-shadow .15s ease;
}
.landing-slider.is-ready .landing-slider-arrow { display: flex; }
.landing-slider-arrow:hover,
.landing-slider-arrow:focus-visible {
  background: #fff;
  box-shadow: 0 6px 18px rgba(31, 35, 40, .28);
  outline: none;
}
.landing-slider-arrow .icon { margin: 0; }
.landing-slider-prev { left: .75rem; }
.landing-slider-next { right: .75rem; }

/* Room for three lines held open, so changing slide doesn't shuffle the tabs
   underneath it. Keep the notes short enough to fit. */
.landing-slider-note {
  max-width: 64ch;
  min-height: 4.35rem;
  margin: .9rem auto 0;
  color: #57606a;
  font-size: .95rem;
  line-height: 1.5;
  text-align: center;
}
.landing-slider-tabs {
  display: none;
  flex-wrap: wrap;
  justify-content: center;
  gap: .4rem;
  margin-top: .5rem;
}
.landing-slider.is-ready .landing-slider-tabs { display: flex; }
.landing-slider-tab {
  padding: .3rem .85rem;
  border: 1px solid #e6e8eb;
  border-radius: 999px;
  background: #fff;
  color: #57606a;
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.landing-slider-tab:hover { border-color: #c8ccd1; color: #24292f; }
.landing-slider-tab:focus-visible { outline: 2px solid #1d6ff2; outline-offset: 2px; }
.landing-slider-tab[aria-current="true"] {
  border-color: #1d6ff2;
  background: #1d6ff2;
  color: #fff;
}

@media (max-width: 480px) {
  .landing-slider-arrow { width: 2.2rem; height: 2.2rem; margin-top: -1.1rem; font-size: .85rem; }
  .landing-slider-note { min-height: 0; font-size: .9rem; }
}
@media (prefers-reduced-motion: reduce) {
  .landing-slider-track { transition: none; }
}

/* Keys named in the feature copy. Fomantic has no kbd style of its own. */
.landing-card kbd {
  display: inline-block;
  min-width: 1.4em;
  text-align: center;
  padding: .05rem .35rem;
  border: 1px solid #d8dee4;
  border-bottom-width: 2px;
  border-radius: 5px;
  background: #f6f8fa;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .82em;
  color: #57606a;
}
