/**
 * StillSafe home page (index.php only)
 *
 * Editorial look built around the hand-drawn hero: pen-and-ink art on cream
 * paper, a Fraunces display serif, brand ink green, and the golden sunlight
 * accent (--ss-accent) the illustration already uses. Everything is scoped to
 * body.page-landing and the hm- prefix, so no other page changes.
 *
 * The hero art and its muted loop come from Grok Imagine; sources and prompts
 * live in _notes/hero-art/.
 */

/* ---------- Fraunces (SIL OFL, assets/fonts/OFL-fraunces.txt) ---------- */
@font-face {
    font-family: 'Fraunces';
    font-style: normal;
    font-weight: 300 800;
    font-display: swap;
    src: url('../fonts/fraunces-latin-var.woff2') format('woff2');
}
@font-face {
    font-family: 'Fraunces';
    font-style: italic;
    font-weight: 300 800;
    font-display: swap;
    src: url('../fonts/fraunces-latin-var-italic.woff2') format('woff2');
}

/* Design tokens this page relies on. They match the --ss-* palette in the newer
   style.css, and are declared here so the home page renders the same whether or
   not that stylesheet is deployed. */
.page-landing {
    --ss-green-100: #E8F3EE;
    --ss-green-600: #157347;
    --ss-green-700: #146C43;
    --ss-green-800: #0F5132;
    --ss-link: #11603C;
    --ss-ink: #12372A;
    --ss-text: #2B3A33;
    --ss-text-muted: #4F5B55;
    --ss-accent: #E9A23B;
    --ss-accent-wash: #FDF3E1;
    --ss-accent-text: #8A5A00;
    --ss-focus: #0F5132;
    --ss-font-heading: 'Outfit', ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --ss-font-body: 'Atkinson Hyperlegible', ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

.page-landing main :where(h1, h2, h3, h4, h5, h6) {
    color: var(--ss-ink);
}

.page-landing main {
    color: var(--ss-text);
}

.page-landing {
    --hm-paper: #f8f3e8;      /* sampled from the hero art's paper */
    --hm-paper-deep: #f1eadb;
    --hm-line: #e4dccb;
    --hm-ink: var(--ss-ink);  /* #12372A */
    --hm-text: var(--ss-text);
    --hm-muted: var(--ss-text-muted);
    --hm-green: var(--ss-green-600);
    --hm-green-deep: var(--ss-green-800);
    --hm-sun: var(--ss-accent);       /* #E9A23B */
    --hm-sun-wash: var(--ss-accent-wash);
    --hm-sun-text: var(--ss-accent-text);
    --hm-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
    --hm-ease: cubic-bezier(.2, .7, .2, 1);
    background: #fff;
}

.page-landing main :where(.hm-display, .hm-h2) {
    font-family: var(--hm-serif);
    font-optical-sizing: auto;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--hm-ink);
}

.hm-h2 {
    font-size: clamp(2rem, 1.3rem + 2.6vw, 3.25rem);
    line-height: 1.08;
    margin-bottom: 1rem;
}

.hm-h2 em,
.hm-display em {
    font-style: italic;
    font-weight: 500;
    color: var(--hm-green);
}

.hm-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    font-family: var(--ss-font-heading);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--hm-sun-text);
    margin-bottom: 1rem;
}

.hm-eyebrow::before {
    content: "";
    width: 28px;
    height: 2px;
    border-radius: 2px;
    background: var(--hm-sun);
}

.hm-lede {
    font-size: clamp(1.1rem, 1rem + .35vw, 1.3rem);
    line-height: 1.6;
    color: var(--hm-text);
    max-width: 38rem;
}

.hm-section {
    padding-block: clamp(64px, 8vw, 120px);
}

.hm-section--paper {
    background: var(--hm-paper);
}

.hm-head {
    max-width: 44rem;
    margin: 0 auto clamp(40px, 5vw, 64px);
    text-align: center;
}

.hm-head .hm-eyebrow {
    justify-content: center;
}

.hm-head p,
.hm-cta p {
    text-align: center;
}

.hm-head p {
    color: var(--hm-muted);
    font-size: 1.15rem;
    margin: 0 auto;
    max-width: 38rem;
}

/* ---------- Buttons ---------- */
.hm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    min-height: 54px;
    padding: .85rem 1.6rem;
    border-radius: 999px;
    font-family: var(--ss-font-heading);
    font-weight: 600;
    font-size: 1.075rem;
    text-decoration: none;
    border: 2px solid transparent;
    transition: transform .2s var(--hm-ease), box-shadow .2s var(--hm-ease), background-color .2s, border-color .2s, color .2s;
}

.hm-btn:focus-visible {
    outline: 3px solid var(--ss-focus);
    outline-offset: 3px;
}

.hm-btn--primary {
    background: var(--hm-green);
    color: #fff;
    box-shadow: 0 10px 24px -10px rgba(21, 115, 71, .7);
}

.hm-btn--primary:hover {
    background: var(--ss-green-700);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 16px 30px -12px rgba(21, 115, 71, .75);
}

.hm-btn--ghost {
    background: rgba(255, 255, 255, .7);
    border-color: rgba(18, 55, 42, .22);
    color: var(--hm-ink);
}

.hm-btn--ghost:hover {
    background: #fff;
    border-color: var(--hm-ink);
    color: var(--hm-ink);
}

.hm-btn--light {
    background: #fff;
    color: var(--hm-ink);
}

.hm-btn--light:hover {
    background: var(--hm-sun-wash);
    color: var(--hm-ink);
    transform: translateY(-2px);
}

.hm-btn--light:focus-visible {
    outline-color: #fff;
}

/* ---------- Navigation: cream on the home page so it melts into the art ---------- */
.page-landing .navbar.bg-success {
    background-color: var(--hm-paper) !important;
    box-shadow: 0 1px 0 rgba(18, 55, 42, .08);
    --bs-navbar-color: var(--hm-ink);
    --bs-navbar-hover-color: var(--hm-green);
    --bs-navbar-active-color: var(--hm-ink);
    --bs-navbar-brand-color: var(--hm-ink);
    --bs-navbar-brand-hover-color: var(--hm-ink);
    --bs-navbar-toggler-border-color: rgba(18, 55, 42, .3);
    --bs-navbar-toggler-icon-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%2312372A' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.page-landing .navbar.bg-success.hm-nav-scrolled {
    box-shadow: 0 1px 0 rgba(18, 55, 42, .08), 0 8px 24px -12px rgba(18, 55, 42, .25);
}

/* accessibility.css forces white links on .navbar-dark; ink on cream is 12.6:1 */
.page-landing .navbar-dark .nav-link {
    color: var(--hm-ink) !important;
}

.page-landing .navbar-dark .nav-link:hover,
.page-landing .navbar-dark .nav-link:focus {
    color: var(--hm-green) !important;
    background-color: rgba(18, 55, 42, .06);
}

/* Button-like and card-like links: accessibility.css underlines every link in main */
.page-landing .hm-btn,
.page-landing .hm-audience a {
    text-decoration: none !important;
}

.page-landing .navbar-dark .navbar-toggler {
    border-color: rgba(18, 55, 42, .3);
}

.page-landing .navbar-brand .bi {
    color: var(--hm-green);
}

.page-landing .navbar .btn-light {
    background: var(--hm-green);
    border-color: var(--hm-green);
    color: #fff;
    border-radius: 999px;
    padding-inline: 1.1rem;
}

.page-landing .navbar .btn-light:hover {
    background: var(--ss-green-700);
    border-color: var(--ss-green-700);
    color: #fff;
}

/* ============================================================
   Hero: the art fills the right side; copy sits on the empty paper
   ============================================================ */
.hm-hero {
    position: relative;
    background: var(--hm-paper);
    overflow: hidden;
    isolation: isolate;
}

.hm-hero-stage {
    position: relative;
    min-height: clamp(560px, 52vw, 820px);
}

.hm-hero-media {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    aspect-ratio: 1792 / 1008;
    z-index: 0;
}

.hm-hero-art,
.hm-hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
    display: block;
}

.hm-hero-video {
    z-index: 1;
    opacity: 0;
    transition: opacity .4s ease;
    pointer-events: none;
}

.hm-hero-media.is-playing .hm-hero-video {
    opacity: 1;
}

/* Paper wash behind the copy keeps the text crisp where the art gets busy */
.hm-hero-stage::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(90deg, var(--hm-paper) 0%, var(--hm-paper) 30%, rgba(248, 243, 232, .85) 42%, rgba(248, 243, 232, 0) 56%);
}

.hm-hero-inner {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    min-height: inherit;
    padding-block: clamp(48px, 6vw, 96px);
}

.hm-hero-copy {
    max-width: 36rem;
}

.hm-display {
    font-size: clamp(3rem, 1.6rem + 5.2vw, 6rem);
    line-height: .98;
    margin-bottom: 1.5rem;
}

.hm-display em {
    display: block;
}

.hm-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .85rem;
    margin-top: 2rem;
}

.hm-hero-assure {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem 1.25rem;
    margin: 1.25rem 0 0;
    padding: 0;
    list-style: none;
    font-size: .98rem;
    color: var(--hm-muted);
}

.hm-hero-assure li {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
}

.hm-hero-assure .bi {
    color: var(--hm-green);
}

/* Pause control (WCAG 2.2.2) */
.hm-motion-toggle {
    position: absolute;
    z-index: 3;
    right: clamp(12px, 1.6vw, 24px);
    top: clamp(12px, 1.6vw, 24px); /* top corner: the site's accessibility button owns the bottom-right */
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    border: 1px solid rgba(18, 55, 42, .2);
    background: rgba(255, 253, 248, .9);
    color: var(--hm-ink);
    box-shadow: 0 2px 10px rgba(18, 55, 42, .14);
    cursor: pointer;
}

.hm-motion-toggle[hidden] {
    display: none;
}

.hm-motion-toggle:hover {
    border-color: var(--hm-green);
}

.hm-motion-toggle:focus-visible {
    outline: 3px solid var(--ss-focus);
    outline-offset: 3px;
}

.hm-motion-toggle svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.hm-motion-toggle .i-play,
.hm-motion-toggle[aria-pressed="true"] .i-pause {
    display: none;
}

.hm-motion-toggle[aria-pressed="true"] .i-play {
    display: block;
}

/* Floating "checked in" card on the art */
.hm-checkin-card {
    position: absolute;
    z-index: 2;
    left: 37%;
    top: 9%;
    width: min(300px, 30%);
    min-width: 248px;
    display: flex;
    gap: .9rem;
    align-items: center;
    padding: 1rem 1.1rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, .96);
    border: 1px solid rgba(18, 55, 42, .08);
    box-shadow: 0 2px 4px rgba(18, 55, 42, .05), 0 22px 44px -18px rgba(18, 55, 42, .38);
}

.hm-checkin-card .hm-sample {
    position: absolute;
    top: -10px;
    right: 14px;
    padding: 2px 9px;
    border-radius: 999px;
    background: var(--hm-ink);
    color: #f8f3e8;
    font: 700 .66rem/1.5 var(--ss-font-heading);
    letter-spacing: .12em;
    text-transform: uppercase;
}

.hm-check {
    flex: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--ss-green-100);
}

.hm-check svg {
    width: 26px;
    height: 26px;
}

.hm-check circle {
    fill: none;
    stroke: var(--hm-green);
    stroke-width: 2.5;
}

.hm-check path {
    fill: none;
    stroke: var(--hm-green);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hm-checkin-card strong {
    display: block;
    font-family: var(--ss-font-heading);
    font-size: 1.05rem;
    color: var(--hm-ink);
    line-height: 1.25;
}

.hm-checkin-card small {
    display: block;
    color: var(--hm-muted);
    font-size: .88rem;
    line-height: 1.35;
    margin-top: .15rem;
}

@media (prefers-reduced-motion: no-preference) {
    .hm-anim .hm-checkin-card {
        animation: hm-card-in .7s var(--hm-ease) 1.2s both;
    }
    .hm-anim .hm-check circle {
        stroke-dasharray: 64;
        stroke-dashoffset: 64;
        animation: hm-draw .6s ease-out 1.6s forwards;
    }
    .hm-anim .hm-check path {
        stroke-dasharray: 20;
        stroke-dashoffset: 20;
        animation: hm-draw .35s ease-out 2.05s forwards;
    }
    .hm-anim .hm-hero-copy > * {
        animation: hm-rise .8s var(--hm-ease) both;
    }
    .hm-anim .hm-hero-copy > :nth-child(2) { animation-delay: .08s; }
    .hm-anim .hm-hero-copy > :nth-child(3) { animation-delay: .16s; }
    .hm-anim .hm-hero-copy > :nth-child(4) { animation-delay: .24s; }
    .hm-anim .hm-hero-copy > :nth-child(5) { animation-delay: .32s; }
}

@keyframes hm-card-in {
    from { opacity: 0; transform: translateY(14px) scale(.96); }
    to { opacity: 1; transform: none; }
}

@keyframes hm-draw {
    to { stroke-dashoffset: 0; }
}

@keyframes hm-rise {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: none; }
}

/* Mid-width laptops: the art is nearly as wide as the window, so slide it right
   (losing some window on the far edge), narrow the copy, and pull the pause
   button back on screen by the same amount */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .hm-hero-media {
        right: -17%;
    }
    .hm-motion-toggle {
        right: calc(17vw + 12px);
    }
    .hm-checkin-card {
        left: 45%;
    }
    .hm-hero-copy {
        max-width: 27rem;
    }
    .hm-display {
        font-size: 4.25rem;
    }
}

@media (min-width: 1200px) and (max-width: 1399.98px) {
    .hm-hero-media {
        right: -8%;
    }
    .hm-motion-toggle {
        right: calc(8vw + 12px);
    }
    .hm-checkin-card {
        left: 41%;
    }
    .hm-hero-copy {
        max-width: 31rem;
    }
}

/* Tablet and phone: copy first, then the art as its own panel */
@media (max-width: 991.98px) {
    .hm-hero-stage {
        min-height: 0;
        display: flex;
        flex-direction: column;
    }
    .hm-hero-stage::before {
        display: none;
    }
    .hm-hero-inner {
        order: 1;
        padding-block: 40px 28px;
    }
    .hm-hero-media {
        order: 2;
        position: relative;
        width: 100%;
        height: auto;
        aspect-ratio: 4 / 3;
    }
    .hm-hero-art,
    .hm-hero-video {
        object-position: 82% center;
    }
    .hm-checkin-card {
        left: 16px;
        top: auto;
        bottom: 16px;
        width: auto;
        min-width: 0;
        max-width: calc(100% - 84px);
        padding: .75rem .9rem;
    }
    .hm-check {
        width: 40px;
        height: 40px;
    }
}

@media (min-width: 600px) and (max-width: 991.98px) {
    .hm-hero-media {
        aspect-ratio: 16 / 9;
    }
}

@media (max-width: 575.98px) {
    .hm-hero-actions .hm-btn {
        width: 100%;
    }
    .hm-motion-toggle {
        width: 36px;
        height: 36px;
    }
    .hm-checkin-card strong {
        font-size: .95rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hm-hero-video,
    .hm-motion-toggle {
        display: none !important;
    }
}

/* Same for the site's accessibility widget "Reduce animations" switch */
.a11y-reduce-motion .hm-hero-video,
.a11y-reduce-motion .hm-motion-toggle {
    display: none !important;
}

.a11y-reduce-motion :is(.hm-reveal, .hm-checkin-card, .hm-hero-copy > *, .hm-check circle, .hm-check path, .hm-chip, .hm-call-ring) {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
    stroke-dashoffset: 0 !important;
}

.a11y-reduce-motion .hm-demo-btn::after {
    display: none;
}

/* ---------- Facts strip ---------- */
.hm-facts {
    background: var(--hm-paper);
    border-top: 1px solid var(--hm-line);
    border-bottom: 1px solid var(--hm-line);
}

.hm-facts ul {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin: 0;
    padding: 0;
    list-style: none;
}

.hm-facts li {
    padding: 1.6rem 1.25rem;
    text-align: center;
}

.hm-facts li + li {
    border-left: 1px solid var(--hm-line);
}

.hm-facts strong {
    display: block;
    font-family: var(--hm-serif);
    font-weight: 600;
    font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.5rem);
    line-height: 1.05;
    color: var(--hm-ink);
    letter-spacing: -0.02em;
}

.hm-facts span {
    display: block;
    margin-top: .35rem;
    font-size: .95rem;
    color: var(--hm-muted);
    line-height: 1.4;
}

@media (max-width: 767.98px) {
    .hm-facts ul {
        grid-template-columns: repeat(2, 1fr);
    }
    .hm-facts li:nth-child(3) {
        border-left: 0;
    }
    .hm-facts li:nth-child(n+3) {
        border-top: 1px solid var(--hm-line);
    }
}

/* ---------- How it works: four steps on a drawn line ---------- */
.hm-steps {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(20px, 3vw, 40px);
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: step;
}

.hm-steps::before {
    content: "";
    position: absolute;
    top: 30px;
    left: 12%;
    right: 12%;
    border-top: 2px dashed var(--hm-line);
}

.hm-step {
    position: relative;
    text-align: center;
}

.hm-step-num {
    position: relative;
    width: 60px;
    height: 60px;
    margin: 0 auto 1.25rem;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: #fff;
    border: 2px solid var(--hm-ink);
    font-family: var(--hm-serif);
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--hm-ink);
    box-shadow: 4px 4px 0 var(--hm-sun);
}

.hm-step h3 {
    font-size: 1.25rem;
    margin-bottom: .5rem;
}

.hm-step p {
    color: var(--hm-muted);
    font-size: 1.02rem;
    margin: 0;
}

@media (max-width: 991.98px) {
    .hm-steps {
        grid-template-columns: repeat(2, 1fr);
        row-gap: 40px;
    }
    .hm-steps::before {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .hm-steps {
        grid-template-columns: 1fr;
    }
    .hm-step {
        display: grid;
        grid-template-columns: 56px 1fr;
        gap: 0 1rem;
        text-align: left;
    }
    .hm-step-num {
        grid-row: span 2;
        width: 52px;
        height: 52px;
        margin: 0;
        font-size: 1.35rem;
    }
}

/* ============================================================
   "What happens if you miss a check-in": scroll story with a phone
   ============================================================ */
.hm-story {
    background: var(--hm-ink);
    color: #e7efe9;
    position: relative;
    overflow: clip; /* clip, not hidden: hidden would stop the phone from sticking */
}

/* Two faint sunbeams echo the hero art */
.hm-story::before {
    content: "";
    position: absolute;
    inset: -20% -10% auto auto;
    width: 60%;
    height: 140%;
    background: repeating-linear-gradient(115deg, rgba(233, 162, 59, 0) 0 70px, rgba(233, 162, 59, .07) 70px 110px, rgba(233, 162, 59, 0) 110px 200px);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 45%);
    pointer-events: none;
}

.hm-story .hm-h2 {
    color: #fff;
}

.hm-story .hm-h2 em {
    color: var(--hm-sun);
}

.hm-story .hm-eyebrow {
    color: var(--hm-sun);
}

.hm-story-head {
    max-width: 46rem;
    margin-bottom: clamp(36px, 5vw, 64px);
}

.hm-story-intro {
    color: #c9d8cf;
    font-size: 1.15rem;
    max-width: 38rem;
    margin: 0;
}

.hm-story-intro a {
    color: #fff;
    text-decoration-color: var(--hm-sun);
    text-underline-offset: 3px;
}

.hm-story-grid {
    position: relative;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: clamp(32px, 7vw, 120px);
    align-items: start;
}

.hm-story-sticky {
    position: sticky;
    top: 104px;
}

.hm-phone {
    width: 300px;
    max-width: 100%;
    aspect-ratio: 300 / 560;
    border-radius: 44px;
    padding: 12px;
    background: #0b1f17;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, .08), 0 40px 80px -30px rgba(0, 0, 0, .7);
}

.hm-phone-screen {
    position: relative;
    height: 100%;
    border-radius: 34px;
    overflow: hidden;
    background: linear-gradient(180deg, #f8f3e8 0%, #efe7d6 100%);
    color: var(--hm-ink);
}

.hm-phone-status {
    display: flex;
    justify-content: space-between;
    padding: 14px 22px 0;
    font: 600 .78rem/1 var(--ss-font-heading);
    color: var(--hm-ink);
}

.hm-phone-clock {
    text-align: center;
    margin-top: 26px;
    font-family: var(--hm-serif);
    font-size: 3.4rem;
    font-weight: 500;
    line-height: 1;
    letter-spacing: -0.03em;
}

.hm-phone-date {
    text-align: center;
    font-size: .85rem;
    color: var(--hm-muted);
    margin-top: .3rem;
}

.hm-phone-msg {
    position: absolute;
    left: 12px;
    right: 12px;
    top: 168px;
    padding: .85rem .95rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, .95);
    box-shadow: 0 10px 30px -14px rgba(18, 55, 42, .45);
    font-size: .86rem;
    line-height: 1.4;
    opacity: 0;
    transform: translateY(16px) scale(.97);
    transition: opacity .45s var(--hm-ease), transform .45s var(--hm-ease);
}

.hm-phone-msg.is-active {
    opacity: 1;
    transform: none;
}

.hm-phone-msg header {
    display: flex;
    align-items: center;
    gap: .45rem;
    margin-bottom: .3rem;
    font: 700 .74rem/1 var(--ss-font-heading);
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--hm-muted);
}

.hm-phone-msg header .bi {
    font-size: .9rem;
    color: var(--hm-green);
}

.hm-phone-msg header time {
    margin-left: auto;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
}

.hm-phone-msg--warn header .bi {
    color: var(--hm-sun-text);
}

.hm-phone-msg--alert header .bi {
    color: #b02a37;
}

.hm-phone-call {
    text-align: center;
    padding: 1.1rem .8rem;
}

.hm-phone-call .hm-call-ring {
    width: 64px;
    height: 64px;
    margin: 0 auto .7rem;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--hm-green);
    color: #fff;
    font-size: 1.6rem;
}

@media (prefers-reduced-motion: no-preference) {
    .hm-phone-msg.is-active .hm-call-ring {
        animation: hm-ring 1.6s ease-out infinite;
    }
}

@keyframes hm-ring {
    0% { box-shadow: 0 0 0 0 rgba(21, 115, 71, .5); }
    70%, 100% { box-shadow: 0 0 0 18px rgba(21, 115, 71, 0); }
}

.hm-phone-caption {
    margin-top: 1rem;
    font-size: .85rem;
    color: #a9bfb2;
    max-width: 300px;
}

/* Timeline on the right */
.hm-timeline {
    position: relative;
    margin: 0;
    padding: 0 0 0 56px;
    list-style: none;
}

.hm-timeline::before,
.hm-timeline::after {
    content: "";
    position: absolute;
    left: 19px;
    top: 20px;
    bottom: 20px;
    width: 2px;
    background: rgba(255, 255, 255, .14);
}

/* Progress fill, driven by --hm-progress from home.js */
.hm-timeline::after {
    bottom: auto;
    height: calc((100% - 40px) * var(--hm-progress, 0));
    background: linear-gradient(180deg, var(--hm-sun), #f3c77e);
    transition: height .15s linear;
}

.hm-tl-step {
    position: relative;
    padding: 1.5rem 1.6rem;
    margin-bottom: 1.25rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .08);
    transition: background-color .4s, border-color .4s, transform .4s var(--hm-ease);
}

.hm-tl-step:last-child {
    margin-bottom: 0;
}

.hm-tl-step.is-active {
    background: rgba(255, 255, 255, .08);
    border-color: rgba(233, 162, 59, .45);
}

.hm-tl-dot {
    position: absolute;
    left: -56px;
    top: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: #1d4a39;
    border: 2px solid rgba(255, 255, 255, .2);
    color: #fff;
    transition: background-color .4s, border-color .4s;
}

.hm-tl-step.is-active .hm-tl-dot,
.hm-tl-step.is-past .hm-tl-dot {
    background: var(--hm-sun);
    border-color: var(--hm-sun);
    color: var(--hm-ink);
}

.hm-tl-when {
    display: inline-block;
    margin-bottom: .5rem;
    padding: .2rem .65rem;
    border-radius: 999px;
    background: rgba(233, 162, 59, .16);
    color: #f6d9a8;
    font: 600 .78rem/1.5 var(--ss-font-heading);
    letter-spacing: .04em;
}

/* .page-landing raises specificity above style.css's marketing heading colour */
.page-landing .hm-tl-step h3 {
    color: #fff;
    font-size: 1.3rem;
    margin-bottom: .45rem;
}

.hm-tl-step p {
    color: #c9d8cf;
    margin: 0;
    font-size: 1.02rem;
}

.hm-tl-step strong {
    color: #fff;
}

/* Inline message bubble, shown on phones in place of the sticky phone */
.hm-tl-bubble {
    margin-top: 1rem;
    padding: .8rem .95rem;
    border-radius: 14px;
    background: #f8f3e8;
    color: var(--hm-ink);
    font-size: .9rem;
    line-height: 1.45;
}

.hm-tl-bubble b {
    display: block;
    font: 700 .72rem/1.4 var(--ss-font-heading);
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--hm-muted);
    margin-bottom: .2rem;
}

.hm-story-cta {
    margin-top: 2.5rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 1.5rem;
}

.hm-story-cta p {
    margin: 0;
    color: #c9d8cf;
}

@media (min-width: 992px) {
    .hm-tl-bubble {
        display: none;
    }
}

@media (max-width: 991.98px) {
    .hm-story-grid {
        grid-template-columns: 1fr;
    }
    .hm-story-sticky {
        position: static;
    }
    .hm-phone,
    .hm-phone-caption {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .hm-timeline {
        padding-left: 44px;
    }
    .hm-timeline::before,
    .hm-timeline::after {
        left: 15px;
    }
    .hm-tl-dot {
        left: -44px;
        width: 32px;
        height: 32px;
        font-size: .85rem;
    }
    .hm-tl-step {
        padding: 1.2rem 1.1rem;
    }
}

/* ============================================================
   Features: bento grid
   ============================================================ */
.hm-bento {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
}

.hm-tile {
    position: relative;
    grid-column: span 2;
    padding: 1.75rem;
    border-radius: 24px;
    background: #fff;
    border: 1px solid var(--hm-line);
    overflow: hidden;
    transition: transform .3s var(--hm-ease), box-shadow .3s var(--hm-ease);
}

.hm-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 24px 48px -28px rgba(18, 55, 42, .4);
}

.hm-tile--wide {
    grid-column: span 3;
}

.hm-tile--feature {
    grid-column: span 4;
    grid-row: span 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: center;
    background: linear-gradient(160deg, #fff 0%, var(--hm-paper) 100%);
}

.hm-tile--ink {
    background: var(--hm-ink);
    border-color: var(--hm-ink);
    color: #dbe7e0;
}

.hm-tile--ink h3 {
    color: #fff !important;
}

.hm-tile--ink p {
    color: #c9d8cf !important;
}

.hm-tile-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-size: 1.35rem;
    margin-bottom: 1.1rem;
    background: var(--ss-green-100);
    color: var(--hm-green);
}

.hm-tile-icon--sun {
    background: var(--hm-sun-wash);
    color: var(--hm-sun-text);
}

.hm-tile-icon--rose {
    background: #fbe9eb;
    color: #a52834;
}

.hm-tile-icon--sky {
    background: #e6f1f7;
    color: #0b5a85;
}

.hm-tile--ink .hm-tile-icon {
    background: rgba(233, 162, 59, .16);
    color: var(--hm-sun);
}

.hm-tile h3 {
    font-size: 1.3rem;
    margin-bottom: .5rem;
}

.hm-tile p {
    margin: 0;
    color: var(--hm-muted);
    font-size: 1.02rem;
}

/* Channel chips in the alerts tile */
.hm-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-top: 1.25rem;
}

.hm-chip {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .8rem;
    border-radius: 999px;
    font: 600 .88rem/1.2 var(--ss-font-heading);
    background: rgba(255, 255, 255, .1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .16);
}

@media (prefers-reduced-motion: no-preference) {
    .hm-tile--ink.is-visible .hm-chip {
        animation: hm-chip 2.4s ease-in-out infinite;
    }
    .hm-tile--ink.is-visible .hm-chip:nth-child(2) { animation-delay: .3s; }
    .hm-tile--ink.is-visible .hm-chip:nth-child(3) { animation-delay: .6s; }
}

@keyframes hm-chip {
    0%, 60%, 100% { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .16); }
    20% { background: rgba(233, 162, 59, .25); border-color: var(--hm-sun); }
}

/* Interactive check-in demo in the feature tile */
.hm-demo {
    text-align: center;
    padding: 1.5rem 1rem;
    border-radius: 22px;
    background: #fff;
    border: 1px solid var(--hm-line);
    box-shadow: 0 20px 40px -26px rgba(18, 55, 42, .45);
}

.hm-demo-label {
    font: 600 .78rem/1.4 var(--ss-font-heading);
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--hm-muted);
}

.hm-demo-btn {
    position: relative;
    width: 148px;
    height: 148px;
    margin: 1rem auto;
    border-radius: 50%;
    border: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: .25rem;
    background: radial-gradient(circle at 35% 30%, #1f8c58, var(--hm-green) 60%, var(--ss-green-700));
    color: #fff;
    font: 600 1.05rem/1.2 var(--ss-font-heading);
    cursor: pointer;
    box-shadow: 0 0 0 10px var(--ss-green-100), 0 18px 30px -12px rgba(21, 115, 71, .8);
    transition: transform .2s var(--hm-ease), box-shadow .3s;
}

.hm-demo-btn .bi {
    font-size: 2.2rem;
    line-height: 1;
}

.hm-demo-btn:hover {
    transform: scale(1.03);
}

.hm-demo-btn:active {
    transform: scale(.97);
}

.hm-demo-btn:focus-visible {
    outline: 3px solid var(--ss-focus);
    outline-offset: 14px;
}

.hm-demo-btn.is-done {
    background: radial-gradient(circle at 35% 30%, #f3c77e, var(--hm-sun) 65%, #d98f1f);
    color: var(--hm-ink);
    box-shadow: 0 0 0 10px var(--hm-sun-wash), 0 18px 30px -12px rgba(219, 143, 34, .8);
}

@media (prefers-reduced-motion: no-preference) {
    .hm-demo-btn:not(.is-done)::after {
        content: "";
        position: absolute;
        inset: -10px;
        border-radius: 50%;
        border: 2px solid rgba(21, 115, 71, .35);
        animation: hm-pulse 2.4s ease-out infinite;
    }
}

@keyframes hm-pulse {
    0% { transform: scale(1); opacity: .9; }
    100% { transform: scale(1.22); opacity: 0; }
}

.hm-demo-status {
    min-height: 2.9em;
    margin: 0;
    font-size: .95rem;
    color: var(--hm-muted);
}

.hm-demo-status strong {
    color: var(--hm-ink);
}

/* Plus-list */
.hm-plus {
    margin-top: 20px;
    padding: 1.5rem 1.75rem;
    border-radius: 24px;
    background: var(--hm-paper);
    border: 1px solid var(--hm-line);
}

.hm-plus h3 {
    font-size: 1.05rem;
    margin-bottom: 1rem;
}

.hm-plus ul {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .7rem 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hm-plus li {
    display: flex;
    gap: .55rem;
    align-items: flex-start;
    font-size: 1rem;
}

.hm-plus .bi {
    color: var(--hm-green);
    margin-top: .2rem;
}

@media (max-width: 1199.98px) {
    .hm-tile--feature {
        grid-column: span 6;
        grid-row: auto;
    }
    .hm-tile {
        grid-column: span 3;
    }
}

@media (max-width: 767.98px) {
    .hm-bento {
        grid-template-columns: 1fr;
    }
    .hm-tile,
    .hm-tile--wide,
    .hm-tile--feature {
        grid-column: auto;
    }
    .hm-tile--feature {
        grid-template-columns: 1fr;
    }
    .hm-plus ul {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 768px) and (max-width: 1199.98px) {
    .hm-plus ul {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================================================
   Example scenarios with spot illustrations
   ============================================================ */
.hm-scenes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.hm-scene {
    display: flex;
    flex-direction: column;
    border-radius: 24px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--hm-line);
}

.hm-scene-art {
    aspect-ratio: 4 / 3;
    background: var(--hm-paper);
    overflow: hidden;
}

.hm-scene-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .8s var(--hm-ease);
}

.hm-scene:hover .hm-scene-art img {
    transform: scale(1.04);
}

.hm-scene-body {
    padding: 1.5rem 1.6rem 1.75rem;
}

.hm-scene-tag {
    display: inline-block;
    margin-bottom: .6rem;
    font: 600 .78rem/1.4 var(--ss-font-heading);
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--hm-sun-text);
}

.hm-scene h3 {
    font-size: 1.3rem;
    margin-bottom: .5rem;
}

.hm-scene p {
    margin: 0;
    color: var(--hm-muted);
    font-size: 1rem;
}

.hm-note {
    text-align: center;
    max-width: 44rem;
    margin: 2rem auto 0;
    font-size: .92rem;
    color: var(--hm-muted);
}

@media (max-width: 991.98px) {
    .hm-scenes {
        grid-template-columns: 1fr;
        max-width: 560px;
        margin-inline: auto;
    }
}

/* ============================================================
   Who it's for
   ============================================================ */
.hm-audience {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hm-audience a {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    height: 100%;
    padding: 1.25rem 1.3rem;
    border-radius: 20px;
    background: #fff;
    border: 1px solid var(--hm-line);
    text-decoration: none;
    color: var(--hm-text);
    transition: border-color .25s, transform .25s var(--hm-ease), box-shadow .25s;
}

.hm-audience a:hover {
    border-color: var(--hm-green);
    transform: translateY(-2px);
    box-shadow: 0 18px 36px -24px rgba(18, 55, 42, .45);
}

.hm-audience a:focus-visible {
    outline: 3px solid var(--ss-focus);
    outline-offset: 3px;
}

.hm-audience .bi {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    font-size: 1.25rem;
    background: var(--ss-green-100);
    color: var(--hm-green);
}

.hm-audience strong {
    display: block;
    font-family: var(--ss-font-heading);
    font-size: 1.08rem;
    color: var(--hm-ink);
    line-height: 1.3;
}

.hm-audience span {
    display: block;
    font-size: .95rem;
    color: var(--hm-muted);
    line-height: 1.45;
    margin-top: .15rem;
}

@media (max-width: 1199.98px) {
    .hm-audience {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575.98px) {
    .hm-audience {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   Pricing
   ============================================================ */
.hm-plans {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 400px));
    justify-content: center;
    gap: 24px;
}

.hm-plan {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 2rem;
    border-radius: 28px;
    background: #fff;
    border: 1px solid var(--hm-line);
}

.hm-plan--best {
    border: 2px solid var(--hm-green);
    box-shadow: 0 30px 60px -36px rgba(18, 55, 42, .55);
}

.hm-plan-flag {
    position: absolute;
    top: -14px;
    left: 2rem;
    padding: .25rem .8rem;
    border-radius: 999px;
    background: var(--hm-sun);
    color: var(--hm-ink);
    font: 700 .78rem/1.5 var(--ss-font-heading);
    letter-spacing: .06em;
    text-transform: uppercase;
}

.hm-plan h3 {
    font-size: 1.3rem;
    margin-bottom: .75rem;
}

.hm-price {
    font-family: var(--hm-serif);
    font-size: 3.2rem;
    font-weight: 600;
    line-height: 1;
    color: var(--hm-ink);
    letter-spacing: -0.03em;
}

.hm-price small {
    font-family: var(--ss-font-body);
    font-size: 1rem;
    font-weight: 400;
    color: var(--hm-muted);
    letter-spacing: 0;
}

.hm-plan-sub {
    margin: .5rem 0 1.5rem;
    color: var(--hm-muted);
    font-size: .98rem;
}

.hm-plan ul {
    margin: 0 0 1.75rem;
    padding: 0;
    list-style: none;
    flex-grow: 1;
}

.hm-plan li {
    display: flex;
    gap: .6rem;
    align-items: flex-start;
    padding: .45rem 0;
    border-top: 1px solid var(--hm-paper-deep);
    font-size: 1.02rem;
}

.hm-plan li:first-child {
    border-top: 0;
}

.hm-plan li .bi {
    color: var(--hm-green);
    margin-top: .2rem;
}

.hm-plan .hm-btn {
    width: 100%;
}

.hm-guarantees {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .75rem 2rem;
    margin: 2.5rem 0 0;
    padding: 0;
    list-style: none;
    color: var(--hm-muted);
    font-size: .98rem;
}

.hm-guarantees li {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
}

.hm-guarantees .bi {
    color: var(--hm-green);
    font-size: 1.15rem;
}

.hm-pricing-link {
    text-align: center;
    margin-top: 1.5rem;
}

.hm-pricing-link a {
    color: var(--ss-link);
    font-weight: 600;
    text-underline-offset: 3px;
}

@media (max-width: 767.98px) {
    .hm-plans {
        grid-template-columns: minmax(0, 440px);
    }
}

/* ============================================================
   FAQ (native details/summary)
   ============================================================ */
.hm-faq {
    max-width: 52rem;
    margin: 0 auto;
}

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

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

.hm-faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.35rem .25rem;
    cursor: pointer;
    list-style: none;
    font-family: var(--ss-font-heading);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--hm-ink);
}

.hm-faq summary::-webkit-details-marker {
    display: none;
}

.hm-faq summary::after {
    content: "+";
    flex: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    border: 1.5px solid var(--hm-line);
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--hm-green);
    transition: transform .25s var(--hm-ease), background-color .25s;
}

.hm-faq details[open] summary::after {
    transform: rotate(45deg);
    background: var(--ss-green-100);
}

.hm-faq summary:focus-visible {
    outline: 3px solid var(--ss-focus);
    outline-offset: 2px;
    border-radius: 8px;
}

.hm-faq details > div {
    padding: 0 3.5rem 1.5rem .25rem;
    color: var(--hm-text);
    font-size: 1.05rem;
}

.hm-faq details > div a {
    color: var(--ss-link);
}

@media (max-width: 575.98px) {
    .hm-faq details > div {
        padding-right: .25rem;
    }
    .hm-faq summary {
        font-size: 1.08rem;
    }
}

/* ============================================================
   Closing call to action
   ============================================================ */
.hm-cta {
    position: relative;
    overflow: hidden;
    background: var(--hm-ink);
    color: #dbe7e0;
    text-align: center;
    padding-block: clamp(72px, 9vw, 128px);
}

.hm-cta::before {
    content: "";
    position: absolute;
    top: -30%;
    left: 50%;
    width: 900px;
    height: 900px;
    transform: translateX(-50%);
    background: radial-gradient(closest-side, rgba(233, 162, 59, .22), rgba(233, 162, 59, 0));
    pointer-events: none;
}

.hm-cta > .container {
    position: relative;
}

.hm-cta .hm-h2 {
    color: #fff;
    font-size: clamp(2.25rem, 1.4rem + 3.4vw, 4rem);
}

.hm-cta .hm-h2 em {
    color: var(--hm-sun);
}

.hm-cta p {
    max-width: 36rem;
    margin: 0 auto 2rem;
    font-size: 1.15rem;
    color: #c9d8cf;
}

.hm-cta .hm-fine {
    margin: 1.25rem auto 0;
    font-size: .95rem;
    color: #a9bfb2;
}

/* ---------- Scroll reveal ---------- */
@media (prefers-reduced-motion: no-preference) {
    .hm-js .hm-reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity .7s var(--hm-ease), transform .7s var(--hm-ease);
    }
    .hm-js .hm-reveal.is-visible {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Sticky mobile CTA: appears once the hero buttons scroll away ---------- */
.hm-mobile-cta {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1030;
    display: flex;
    gap: .5rem;
    padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .97);
    border-top: 1px solid var(--hm-line);
    box-shadow: 0 -10px 30px -18px rgba(18, 55, 42, .5);
    transition: transform .35s var(--hm-ease);
}

.hm-js .hm-mobile-cta:not(.is-shown) {
    transform: translateY(110%);
}

.hm-mobile-cta .hm-btn {
    min-height: 48px;
    padding-inline: 1.1rem;
    font-size: 1rem;
}

.hm-mobile-cta .hm-btn--primary {
    flex-grow: 1;
}

@media (max-width: 767.98px) {
    .page-landing #a11y-widget {
        transition: bottom .35s var(--hm-ease);
    }
    .page-landing.hm-cta-up #a11y-widget {
        bottom: calc(88px + env(safe-area-inset-bottom));
    }
}

@media (min-width: 768px) {
    .hm-mobile-cta {
        display: none;
    }
}

/* Two quick routes under the hero buttons: someone who lives alone, and an adult
   child setting StillSafe up for a parent. */
.hm-hero-routes {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem .625rem;
    margin-top: 1.25rem;
}

.hm-hero-routes a {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    min-height: 44px;
    padding: .5rem 1rem;
    border-radius: 999px;
    border: 1px solid var(--hm-line);
    background: rgba(255, 253, 248, .85);
    color: var(--hm-ink);
    font-family: var(--ss-font-heading);
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-decoration: none !important; /* pill links; accessibility.css underlines running-text links */
    transition: border-color .2s var(--hm-ease), background-color .2s var(--hm-ease);
}

.hm-hero-routes a:hover {
    border-color: var(--hm-green);
    background: #fff;
    color: var(--hm-ink);
}

.hm-hero-routes a .bi {
    color: var(--hm-green);
    transition: transform .2s var(--hm-ease);
}

.hm-hero-routes a:hover .bi {
    transform: translateX(3px);
}

/* "Call 911" line under the missed check-in story (dark band) */
.hm-story-cta .hm-911 {
    flex-basis: 100%;
    display: flex;
    gap: .625rem;
    align-items: flex-start;
    padding: .875rem 1rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .16);
    color: #e3ece7;
}

.hm-story-cta .hm-911 .bi {
    color: var(--hm-sun);
    margin-top: .2rem;
}

.hm-story-cta .hm-911 a {
    color: #fff;
    font-weight: 700;
}

/* While the navigation is back on screen (reader scrolled up), the sign-up bar steps
   aside; see the scroll script at the end of index.php. */
@media (max-width: 767.98px) {
    .hm-js .hm-cta-yield .hm-mobile-cta {
        transform: translateY(110%);
    }
}
