/* Homepage (desktop and tablet): the line, a sample of notes, the app, then artists.
   Paper and charcoal; colour comes from the records. Phones get home_landing.* instead. */
body.r-home {
    --rh-home-width: min(calc(100% - 2 * var(--rh-gutter)), calc(1280px - 2 * var(--rh-gutter)));
    --rh-home-ground: #1b1a18;
    --rh-home-on-ground: #f1efe9;
    --rh-home-gold: #9a8460;
    --rh-home-cover: 510px;
}

.r-home main { width: 100%; max-width: none; margin: 0; padding: 0; }
.r-home main *, .r-home main *::before, .r-home main *::after { box-sizing: border-box; }
.r-home main a { color: inherit; text-decoration: none; }
.r-home main button, .r-home main input { font: inherit; }
.r-home main button, .r-home main a, .r-home main summary { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.r-home main [hidden] { display: none !important; }
.rh-desktop { color: var(--rh-ink); font-family: var(--rh-sans); -webkit-font-smoothing: antialiased; }
.rh-desktop :is(h1, h2, h3, p, ul, li, figure) { margin: 0; padding: 0; color: inherit; font-family: inherit; }
.rh-desktop > section:not(.rh-artists), .rh-artists-inner { width: var(--rh-home-width); margin-inline: auto; }

/* Shared pieces. */
.rh-desktop .rh-store {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-height: 50px;
    padding: 0 1.35rem 0 1.15rem;
    border-radius: 8px;
    background: var(--rh-ink);
    color: var(--rh-paper);
    font: 500 16px/1 var(--rh-sans);
    letter-spacing: -0.035em;
    white-space: nowrap;
    transition: background-color 160ms ease;
}
.rh-desktop .rh-store:hover { background: color-mix(in srgb, var(--rh-ink) 86%, var(--rh-paper)); }
.rh-store svg { flex: none; width: 17px; height: 19px; margin-top: -2px; }
.rh-desktop .rh-store--paper { background: var(--rh-home-on-ground); color: var(--rh-home-ground); }
.rh-desktop .rh-store--paper:hover { background: #fff; }
.rh-get { display: flex; align-items: center; gap: 1.5rem; }
.rh-qr { display: flex; align-items: center; gap: 0.85rem; }
.rh-qr-code { display: block; width: 58px; height: 58px; color: var(--rh-ink); }
.rh-qr span { max-width: 7ch; font-size: 0.8rem; line-height: 1.35; color: var(--rh-muted); }
.rh-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 2.6rem; }
.rh-section-heading h2 { font-size: 0.9rem; font-weight: 500; line-height: 1.4; letter-spacing: -0.025em; }
.rh-desktop .rh-section-heading a { display: inline-flex; align-items: center; min-height: 44px; font-size: 0.7rem; color: var(--rh-muted); }
.rh-desktop .rh-section-heading a:hover { color: var(--rh-ink); }
[data-home-image] { background: var(--rh-skeleton-base); }
[data-home-image] img { display: block; width: 100%; height: 100%; object-fit: cover; transition: opacity 400ms ease; }
[data-home-image].is-loading img, [data-home-image].is-error img { opacity: 0; }

/* Opening. */
.rh-hero {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-content: center;
    align-items: center;
    gap: clamp(2rem, 4vw, 4rem);
    min-height: min(calc(100svh - 72px), 820px);
    padding: 1.5rem 0 4.5rem;
}
.rh-hero h1 {
    margin-left: -0.05em;
    font-size: clamp(3.5rem, 6.1vw, 6rem);
    font-weight: 500;
    line-height: 0.9;
    letter-spacing: -0.062em;
}
/* Instagram sits on the specimen caption's row, out of flow so the opening stays centred. */
.rh-hero-copy { position: relative; align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
.rh-desktop .rh-insta { position: absolute; left: 0; bottom: 0; display: flex; align-items: center; gap: 0.45rem; min-height: 3.4rem; font-size: 0.95rem; letter-spacing: -0.025em; transition: opacity 160ms ease; }
.rh-insta svg { flex: none; width: 22px; height: 22px; margin-left: -3px; }
@media (hover: hover) and (pointer: fine) { .rh-desktop .rh-insta:hover { opacity: 0.6; } }
.rh-desktop .rh-lede { max-width: 19ch; margin: 1.5rem 0 2.4rem; font-size: clamp(1.2rem, 1.55vw, 1.45rem); line-height: 1.3; letter-spacing: -0.03em; color: var(--rh-muted); }

/* A record with two track notes, in the entry page's card style. */
.rh-specimen { position: relative; }
.rh-specimen-record { position: relative; display: grid; justify-items: end; }
.rh-specimen.is-switched .rh-specimen-record { animation: rh-home-enter 260ms ease both; }
.rh-specimen-cover { width: min(100%, var(--rh-home-cover)); aspect-ratio: 1; overflow: hidden; }
.rh-specimen-cards {
    position: absolute;
    left: 0;
    bottom: calc(3.4rem + 3.1rem);
    display: grid;
    gap: 0.7rem;
    width: min(370px, 58%);
}
.rh-note {
    padding: 1.2rem 1.4rem 1.3rem;
    border-radius: 4px;
    background: var(--rh-note-paper);
    box-shadow: 0 1px 2px rgba(25, 21, 16, 0.05), 0 14px 34px rgba(25, 21, 16, 0.12);
}
.rh-note:nth-child(2) { margin-left: 2.25rem; }
.rh-note-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.rh-note h3 { min-width: 0; font-size: 1.05rem; font-weight: 500; line-height: 1.3; letter-spacing: -0.03em; }
.rh-note-heading span { flex: none; font-size: 0.7rem; color: var(--rh-muted); }
.rh-note p { margin-top: 0.5rem; font-size: 0.93rem; line-height: 1.6; letter-spacing: -0.012em; }
.rh-desktop .rh-specimen-caption { display: grid; align-content: center; gap: 0.1rem; width: min(100%, var(--rh-home-cover)); min-height: 3.4rem; margin-top: 0.9rem; padding-right: 9.5rem; line-height: 1.35; }
.rh-specimen-caption span:first-child { font-size: 0.95rem; letter-spacing: -0.025em; }
.rh-specimen-caption span:last-child { font-size: 0.73rem; color: var(--rh-muted); }
.rh-specimen-switch { position: absolute; right: 0; bottom: 0; display: flex; align-items: center; gap: 0.5rem; min-height: 3.4rem; }
.rh-specimen-switch button { width: 40px; height: 40px; padding: 0; border: 0; border-radius: 0; background: var(--rh-skeleton-base); cursor: pointer; opacity: 0.4; transition: opacity 160ms ease; }
.rh-specimen-switch button:hover { opacity: 0.75; }
.rh-specimen-switch button[aria-pressed="true"] { opacity: 1; }
.rh-specimen-switch img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* The app: real screens, one line each. Phone proportions follow the App Store studio. */
.rh-app { padding: 1.2rem 0 5.5rem; border-top: 0.5px solid var(--rh-line); }
.rh-phones { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1.25rem, 3.5vw, 3.5rem); }
.rh-phone-item { display: grid; justify-items: center; align-content: start; gap: 1.6rem; }
.rh-phone-item .rh-phone { width: min(100%, 238px); }
.rh-phone-item figcaption { max-width: 15ch; font-size: 1.15rem; font-weight: 500; line-height: 1.2; letter-spacing: -0.035em; text-align: center; text-wrap: balance; }
.rh-phone {
    position: relative;
    container-type: inline-size;
    aspect-ratio: 954 / 2019;
    border-radius: 14.47% / 6.84%;
    background: #0e0e0f;
    box-shadow: inset 0 0 0 1.5px #2b2b2e, 0 28px 60px -28px rgba(25, 21, 16, 0.4);
}
.rh-screen { position: absolute; inset: 2.2cqi; overflow: hidden; border-radius: 12.26cqi; }
.rh-screen img { object-position: top; }
.rh-island { position: absolute; top: 4.6cqi; left: 50%; width: 28cqi; height: 8.2cqi; border-radius: 4.1cqi; background: #000; translate: -50% 0; }

/* Artists: the one change of ground on the page. */
.rh-artists { overflow: hidden; background: var(--rh-home-ground); color: var(--rh-home-on-ground); }
.rh-artists-inner { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 5vw, 5rem); }
.rh-artists-copy { padding: 6.5rem 0; }
.rh-artists-label { display: flex; align-items: center; gap: 0.55rem; font-size: 0.9rem; font-weight: 500; letter-spacing: -0.02em; }
.rh-seal { width: 22px; height: 22px; color: var(--rh-home-gold); }
.rh-artists h2 {
    max-width: 11ch;
    margin: 1.6rem 0 2rem;
    font-size: clamp(2.9rem, 5vw, 4.9rem);
    font-weight: 500;
    line-height: 0.93;
    letter-spacing: -0.06em;
}
.rh-artists h2 em { font-style: normal; color: var(--rh-home-gold); }
.rh-artists-lines { display: grid; gap: 0.55rem; max-width: 34rem; list-style: none; text-wrap: pretty; }
.rh-artists-lines li { font-size: 1.2rem; line-height: 1.35; letter-spacing: -0.03em; color: color-mix(in srgb, var(--rh-home-on-ground) 70%, transparent); }
.rh-artists-actions { display: grid; justify-items: start; gap: 1rem; margin-top: 2.6rem; }
.rh-claim { width: min(100%, 380px); }
.rh-claim summary { display: inline-flex; align-items: center; gap: 0.55rem; min-height: 44px; font-size: 1rem; font-weight: 500; letter-spacing: -0.03em; list-style: none; cursor: pointer; }
.rh-claim summary::-webkit-details-marker { display: none; }
.rh-claim summary::after { content: "+"; font-size: 1.25rem; font-weight: 300; line-height: 1; transition: transform 180ms ease; }
.rh-claim[open] summary::after { transform: rotate(45deg); }
.rh-claim[open] form { animation: rh-home-enter 220ms ease; }
.rh-claim form { padding-top: 0.5rem; }
.rh-claim label { display: block; margin-bottom: 0.4rem; font-size: 0.72rem; color: color-mix(in srgb, var(--rh-home-on-ground) 60%, transparent); }
.rh-claim-field { display: flex; align-items: center; gap: 0.45rem; min-height: 46px; border-bottom: 1px solid color-mix(in srgb, var(--rh-home-on-ground) 35%, transparent); }
.rh-claim-field:focus-within { border-bottom-color: var(--rh-home-on-ground); }
.rh-desktop .rh-claim-field input { flex: 1; min-width: 0; padding: 0.5rem 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; color: inherit; font: inherit; font-size: 16px; }
.rh-desktop .rh-claim-field input:focus { outline: none; box-shadow: none; }
.rh-desktop .rh-claim-field button { flex: none; min-height: 44px; padding: 0 0.1rem 0 0.6rem; border: 0; background: transparent; color: inherit; font: inherit; font-size: 0.78rem; cursor: pointer; }
.rh-desktop .rh-claim-field button:disabled { opacity: 0.5; cursor: wait; }
.rh-invite-trap { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.rh-desktop .rh-claim-status { margin-top: 0.75rem; font-size: 0.8rem; line-height: 1.5; }
.rh-claim-status.is-error { color: #e3a08a; }
.rh-claim-status a { text-decoration: underline; text-underline-offset: 3px; }
.rh-artists-visual { position: relative; min-height: 420px; }
.rh-artists-visual .rh-phone { position: absolute; top: 5.5rem; left: 50%; width: min(100%, 330px); translate: -50% 0; box-shadow: inset 0 0 0 1.5px #2b2b2e, 0 0 0 1px rgba(241, 239, 233, 0.08); }

/* Editors' Picks: the one live section, kept small. */
.rh-picks { padding: 1.2rem 0 5rem; }
.rh-picks-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.25rem, 3vw, 2.5rem); }
.rh-pick { display: grid; grid-template-columns: 88px minmax(0, 1fr); align-items: center; gap: 1.1rem; }
.rh-pick-image { width: 88px; height: 88px; overflow: hidden; }
.rh-pick-text { min-width: 0; }
.rh-pick-name { display: block; font-size: 1.7rem; line-height: 1; overflow-wrap: anywhere; }
.rh-pick-meta { display: block; margin-top: 0.4rem; font-size: 0.72rem; color: var(--rh-muted); }
.rh-pick:hover .rh-pick-name { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }

/* Close. */
.rh-close { display: grid; justify-items: center; padding: 5rem 0 6rem; border-top: 0.5px solid var(--rh-line); text-align: center; }
.rh-close-icon { width: 84px; height: 84px; border-radius: 22.5%; }
.rh-close h2 { margin: 1.4rem 0 0.35rem; font-size: 2.6rem; font-weight: 500; line-height: 1; letter-spacing: -0.055em; }
.rh-close p { margin-bottom: 2rem; font-size: 1.05rem; letter-spacing: -0.02em; color: var(--rh-muted); }

/* QR codes stay dark-on-light for cameras. */
body.dark-mode .rh-qr-code { padding: 4px; border-radius: 2px; background: #f1efe9; color: #171615; }

@keyframes rh-home-enter { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 1000px) {
    .rh-hero { grid-template-columns: 1fr; min-height: 0; padding-top: 2.5rem; }
    .rh-desktop .rh-insta { left: auto; right: 0; }
    .rh-specimen-record { justify-items: center; }
    .rh-specimen-cards { left: calc(50% - min(var(--rh-home-cover), 100%) / 2 - 2.5rem); }
    .rh-specimen-switch { right: calc(50% - min(var(--rh-home-cover), 100%) / 2); }
    .rh-phones { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 3.5rem; }
    .rh-artists-inner { grid-template-columns: 1fr; }
    .rh-artists-copy { padding-bottom: 0; }
    .rh-artists-visual { min-height: 380px; }
    .rh-picks-row { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .rh-desktop *, .rh-desktop *::before, .rh-desktop *::after { animation: none !important; transition: none !important; }
}
