/*
  Home page (index.html). Everything is prefixed hm- so it stays isolated from the rest of the app.
  Sizes are in px on purpose: the body is font-size: 40px (fs-pix-40), so em/rem-style units would inherit that.
  The font is not set here: the page uses the font-mooli class, which makes every descendant inherit Mooli.
  Colours come from the :root variables in styles.css.
*/

.hm-wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
  box-sizing: border-box;
}

/* ---------- top bar ---------- */
.hm-top {
  background: var(--primary);
}
.hm-top .hm-wrap {
  /* full width with the same 3% side margins the old page used, so the logo sits where it does on other pages */
  max-width: none;
  padding: 0 3%;
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.hm-logo {
  display: flex;
}
.hm-logo img {
  width: 100px;
  height: 100px;
}
.hm-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px 28px;
}
.hm-nav a {
  color: var(--secondary);
  font-size: 18px;
  text-decoration: none;
  transition: color 0.2s ease;
}
.hm-nav a:hover {
  color: var(--hover);
}

/* ---------- buttons (same invert-on-hover behaviour the old buttons had) ---------- */
.hm-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 24px;
  border: 2px solid var(--primary);
  border-radius: 3px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.hm-btn-primary {
  background: var(--primary);
  color: #FFFFFF;
}
.hm-btn-primary:hover {
  background: #FFFFFF;
  color: var(--primary);
}
.hm-btn-outline {
  background: transparent;
  color: var(--primary);
}
.hm-btn-outline:hover {
  background: var(--primary);
  color: #FFFFFF;
}
.hm-btn-light {
  background: #FFFFFF;
  border-color: #FFFFFF;
  color: var(--primary);
}
.hm-btn-light:hover {
  background: transparent;
  color: #FFFFFF;
}

/* ---------- hero: dog on the left, headline in the middle, cat on the right, both sitting on the bottom edge ---------- */
.hm-hero {
  background: var(--secondary);
  overflow: hidden;
}
.hm-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr) minmax(0, 1fr);
  align-items: end;
  gap: 24px;
  min-height: 560px;
}
.hm-hero-copy {
  align-self: center;
  padding: 56px 0;
  text-align: center;
}
.hm-hero-copy h1 {
  margin: 0 0 18px 0;
  color: var(--primary);
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 700;
  line-height: 1.12;
}
.hm-lead {
  margin: 0 auto 28px auto;
  max-width: 520px;
  color: var(--dark);
  font-size: 19px;
  line-height: 1.55;
}
.hm-hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
.hm-signin {
  margin: 18px 0 0 0;
  color: var(--dark);
  font-size: 15px;
}
.hm-signin a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}
.hm-signin a:hover {
  text-decoration: underline;
}
.hm-pet img {
  display: block;
  width: 100%;
  height: auto;
}
.hm-pet-dog img {
  max-height: 470px;
  object-fit: contain;
  object-position: bottom;
}

/* ---------- sections ---------- */
.hm-section {
  padding: 80px 0;
}
.hm-white {
  background: #FFFFFF;
}
.hm-gray {
  background: var(--secondary);
}
.hm-blue {
  background: var(--primary);
}
.hm-h2 {
  margin: 0 0 10px 0;
  color: var(--primary);
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}
.hm-sub {
  margin: 0 auto 40px auto;
  max-width: 640px;
  color: #4B5563;
  font-size: 17px;
  line-height: 1.55;
  text-align: center;
}
.hm-blue .hm-h2 {
  color: #FFFFFF;
}
.hm-blue .hm-sub {
  color: #E6F0FF;
}

/* feature cards */
.hm-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}
.hm-card {
  padding: 24px;
  border: 1px solid #D9DDE3;
  border-top: 3px solid var(--primary);
  border-radius: 3px;
  background: #FFFFFF;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.06);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.hm-card:hover {
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.12);
  transform: translateY(-2px);
}
.hm-card h3 {
  margin: 0 0 8px 0;
  color: var(--primary);
  font-size: 21px;
  font-weight: 700;
}
.hm-card p {
  margin: 0;
  color: #374151;
  font-size: 16px;
  line-height: 1.55;
}

/* example chart PDF */
.hm-frame {
  overflow: hidden;
  border: 1px solid #D9DDE3;
  border-radius: 3px;
  background: #FFFFFF;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.06), 0 4px 16px rgba(16, 24, 40, 0.06);
}
.hm-caption {
  margin: 0;
  padding: 12px 16px;
  border-top: 1px solid #D9DDE3;
  color: #4B5563;
  font-size: 14px;
}
.hm-pdf object {
  display: block;
  width: 100%;
  height: 560px;
}
.hm-pdf p {
  margin: 0;
  padding: 16px;
  font-size: 15px;
}

/* call to action bands (live demo, final sign-up) */
.hm-cta {
  text-align: center;
}
.hm-cta .hm-sub {
  margin-bottom: 28px;
}

/* pricing */
.hm-plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 340px));
  justify-content: center;
  gap: 24px;
}
.hm-plan {
  position: relative;
  padding: 36px 28px 32px 28px;
  border: 1px solid #D9DDE3;
  border-radius: 3px;
  background: #FFFFFF;
  text-align: center;
}
.hm-plan-featured {
  border: 2px solid var(--primary);
  box-shadow: 0 8px 24px rgba(47, 129, 248, 0.18);
}
.hm-plan-tag {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 12px;
  border-radius: 3px;
  background: var(--primary);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}
.hm-plan h3 {
  margin: 0 0 8px 0;
  color: var(--dark);
  font-size: 20px;
  font-weight: 700;
}
.hm-price {
  margin: 0 0 4px 0;
  color: var(--primary);
  font-size: 44px;
  font-weight: 700;
  line-height: 1.1;
}
.hm-price span {
  color: #6B7280;
  font-size: 16px;
  font-weight: 400;
}
.hm-plan-note {
  min-height: 20px;
  margin: 0 0 24px 0;
  color: #6B7280;
  font-size: 14px;
}

/* ---------- footer ---------- */
.hm-footer {
  padding: 24px 0;
  border-top: 1px solid #D9DDE3;
  background: var(--secondary);
}
.hm-footer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
}
.hm-footer-copy {
  margin: 0;
  color: #6B7280;
  font-size: 14px;
}
.hm-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}
.hm-footer-links a {
  color: var(--primary);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}
.hm-footer-links a:hover {
  text-decoration: underline;
}

/* ---------- privacy policy page (privacy.html). Long text, so it uses Noto Sans instead of Mooli ---------- */
.font-mooli .hm-policy * {
  font-family: "Noto Sans", sans-serif;
}
.hm-policy {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 72px 24px;
}
.hm-policy h1 {
  margin: 0 0 6px 0;
  color: var(--primary);
  font-size: 34px;
  font-weight: 700;
}
.hm-policy .hm-updated {
  margin: 0 0 28px 0;
  color: #6B7280;
  font-size: 14px;
}
.hm-policy h2 {
  margin: 32px 0 8px 0;
  color: var(--dark);
  font-size: 20px;
  font-weight: 700;
}
.hm-policy p,
.hm-policy li {
  color: #374151;
  font-size: 16px;
  line-height: 1.65;
}
.hm-policy p {
  margin: 0 0 12px 0;
}
.hm-policy ul {
  margin: 0 0 12px 0;
  padding-left: 22px;
}
.hm-policy li {
  margin-bottom: 6px;
}
.hm-policy a {
  color: var(--primary);
  font-weight: 700;
}

/* ---------- narrow screens ---------- */
@media (max-width: 900px) {
  .hm-hero-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "copy copy"
      "dog cat";
    min-height: 0;
    gap: 16px;
  }
  .hm-hero-copy {
    grid-area: copy;
    padding: 40px 0 8px 0;
  }
  .hm-pet-dog {
    grid-area: dog;
  }
  .hm-pet-cat {
    grid-area: cat;
  }
  .hm-pet-dog img {
    max-height: 280px;
  }
  .hm-section {
    padding: 56px 0;
  }
  .hm-nav {
    gap: 6px 18px;
  }
  .hm-nav a {
    font-size: 16px;
  }
}
