.home {
    padding-bottom: 40px;
}

.home h2 {
    font-size: 34px;
    line-height: 1.15;
}

.home h3 {
    font-size: 20px;
    line-height: 1.2;
}

.home-head {
    max-width: 640px;
    margin-bottom: 26px;
}

.home-head p {
    margin-top: 8px;
    color: var(--bone-dim);
    font-size: 17px;
}

.home section + section {
    margin-top: 96px;
}

.home-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.home-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border: 1px solid var(--stone-hover);
    border-radius: var(--radius-md);
    color: var(--bone);
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: border-color 0.2s, background 0.2s, transform 0.2s, box-shadow 0.2s;
}

.home-btn:hover { transform: translateY(-2px); }

.home-btn.is-main:hover { box-shadow: 0 0 32px rgba(207, 90, 62, .5); }

.home-btn:hover {
    border-color: var(--bone-dim);
    background: var(--basalt-800);
}

.home-btn.is-main {
    background: linear-gradient(180deg, #a83c29, #8a3022);
    border-color: var(--ember);
    color: #f6ece2;
    box-shadow: 0 0 24px rgba(207, 90, 62, .3);
}

.home-btn.is-main:hover {
    background: linear-gradient(180deg, #bd4630, #9b3525);
}

.home-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    overflow: hidden;
    isolation: isolate;
    border-bottom: 1px solid var(--stone-line);
}

.home-hero-bg {
    position: absolute;
    inset: -30px;
    z-index: -3;
    background: var(--basalt-900) center 40% / cover no-repeat;
    filter: brightness(.42) saturate(.85) sepia(.25);
    transform: scale(1.06);
    animation: heroDrift 40s ease-in-out infinite alternate;
}

@keyframes heroDrift { to { transform: scale(1.12) translate(-1.5%, -1%); } }

.home-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -2;
    background:
        linear-gradient(90deg, rgba(22, 17, 16, .96) 30%, rgba(22, 17, 16, .55) 65%, rgba(22, 17, 16, .85)),
        linear-gradient(0deg, var(--basalt-900), transparent 40%);
}

.home-embers {
    position: absolute;
    inset: 0;
    z-index: -1;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.home-hero-in {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 48px;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 80px 2rem 64px;
}

.home-eyebrow {
    margin-bottom: 14px;
    color: var(--ember-text);
    font-size: 13px;
    letter-spacing: .24em;
    text-transform: uppercase;
}

.home-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 18px 34px;
    margin-top: 38px;
    padding-top: 22px;
    border-top: 1px solid rgba(241, 232, 219, .08);
}

.home-facts b {
    display: block;
    color: var(--bone);
    font-family: var(--font-display);
    font-size: 30px;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.home-facts span {
    color: var(--bone-dim);
    font-size: 14px;
}

.home-hero h1 {
    max-width: 14ch;
    font-size: clamp(40px, 5.2vw, 68px);
    line-height: 1.02;
    letter-spacing: 0.01em;
}

.home-lead {
    max-width: 560px;
    margin: 22px 0 30px;
    color: var(--bone-2);
    font-size: 19px;
    line-height: 1.55;
}

.home-die-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}

.home-die {
    position: relative;
    width: min(300px, 70vw);
    padding: 0;
    background: none;
    border: none;
    border-radius: 50%;
    cursor: pointer;
}

.home-die::before {
    content: '';
    position: absolute;
    inset: -18%;
    z-index: -1;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(184, 68, 47, 0.28), transparent 65%);
    transition: opacity 0.3s;
}

.home-die svg {
    display: block;
    width: 100%;
    overflow: visible;
    transition: transform 0.25s ease;
}

.home-die:hover svg {
    transform: rotate(-6deg) scale(1.03);
}

.home-die.is-rolling svg {
    animation: dieRoll 0.66s cubic-bezier(0.3, 0.7, 0.4, 1);
}

@keyframes dieRoll {
    0%   { transform: rotate(0) scale(1); }
    40%  { transform: rotate(200deg) scale(0.86); }
    100% { transform: rotate(360deg) scale(1); }
}

.d-face {
    stroke: var(--brass);
    stroke-width: 2.5;
    stroke-linejoin: round;
}

.d-out {
    fill: #2a1d19;
}

.d-mid {
    fill: #3a2620;
}

.d-edge {
    fill: none;
    stroke: rgba(176, 146, 92, 0.55);
    stroke-width: 1.6;
}

.d-num {
    fill: var(--bone);
    font-family: var(--font-display);
    font-size: 46px;
    font-weight: 700;
    text-anchor: middle;
    dominant-baseline: middle;
}

.home-die.is-crit .d-out { fill: #3a1a14; }
.home-die.is-crit .d-num { fill: #f0c27a; }
.home-die.is-fail .d-num { fill: var(--ember-text); }

.home-die-note {
    max-width: 320px;
    min-height: 3em;
    color: var(--bone-dim);
    font-size: 16px;
    text-align: center;
}

.shot {
    position: relative;
    margin: 0;
    overflow: hidden;
    background: var(--basalt-800);
    border: 1px solid var(--stone-line);
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
    aspect-ratio: 16 / 10;
}

.shot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: var(--basalt-900);
    cursor: zoom-in;
}

.shot img:focus-visible {
    outline: 2px solid var(--ember-text);
    outline-offset: -4px;
}

.shot-natural {
    aspect-ratio: auto;
}

.shot-natural img {
    height: auto;
}

.shot-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    position: absolute;
    inset: 10px;
    padding: 20px;
    border: 1px dashed var(--stone-hover);
    border-radius: var(--radius-md);
    color: var(--ash);
    text-align: center;
}

.shot-empty b {
    color: var(--bone-2);
    font-family: var(--font-display);
    font-size: 22px;
}

.shot-empty span {
    font-size: 14px;
}

.shot-empty small {
    font-size: 12.5px;
}

.tour-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 18px;
    overflow-x: auto;
    border-bottom: 1px solid var(--stone-line);
    scrollbar-width: none;
}

.tour-tabs::-webkit-scrollbar {
    display: none;
}

.tour-tab {
    flex: none;
    padding: 10px 16px;
    background: none;
    border: none;
    color: var(--bone-dim);
    font-size: 16px;
    cursor: pointer;
    box-shadow: inset 0 -2px 0 transparent;
    transition: color 0.2s, box-shadow 0.2s;
}

.tour-tab:hover {
    color: var(--bone);
}

.tour-tab.is-active {
    color: var(--bone);
    box-shadow: inset 0 -2px 0 var(--ember);
}

.tour-stage {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    gap: 14px;
    align-items: center;
}

.tour-arrow {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    background: var(--basalt-800);
    border: 1px solid var(--stone-line);
    border-radius: 50%;
    color: var(--bone-dim);
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.tour-arrow:hover {
    color: var(--bone);
    border-color: var(--stone-hover);
}

.tour-arrow svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.tour-slide {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr);
    gap: 32px;
    align-items: center;
}

.tour-slide[hidden] {
    display: none;
}

.tour-slide.is-active {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(14px); }
    to   { opacity: 1; transform: none; }
}

.tour-copy p {
    margin: 10px 0 16px;
    color: var(--bone-2);
    font-size: 17px;
}

.tour-copy ul {
    display: flex;
    flex-direction: column;
    gap: 9px;
    list-style: none;
}

.tour-copy li {
    position: relative;
    padding-left: 22px;
    color: var(--bone-dim);
    font-size: 15.5px;
}

.tour-copy li::before {
    content: '';
    position: absolute;
    left: 2px;
    top: 0.55em;
    width: 8px;
    height: 8px;
    border: 1.5px solid var(--brass);
    transform: rotate(45deg);
}

.tour-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.tour-dots span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--stone-line);
    transition: background 0.2s, transform 0.2s;
}

.tour-dots span.is-active {
    background: var(--ember);
    transform: scale(1.3);
}

.path {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px;
    list-style: none;
    counter-reset: none;
}

.path li {
    position: relative;
}

.path li:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 22px;
    left: 58px;
    right: -18px;
    height: 1px;
    background: linear-gradient(90deg, var(--ember-text), var(--stone-line));
}

.path-num {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    margin-bottom: 16px;
    border: 1.5px solid var(--ember);
    border-radius: 50%;
    color: var(--bone);
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 700;
}

.path p {
    margin-top: 6px;
    color: var(--bone-dim);
    font-size: 15.5px;
}

.home-hero-guide {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 48px;
    align-items: center;
}

.guide-copy > p {
    max-width: 560px;
    margin: 12px 0 22px;
    color: var(--bone-2);
    font-size: 17px;
}

.guide-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 28px;
}

.guide-list div {
    padding-left: 16px;
    border-left: 2px solid var(--brass);
}

.guide-list dt {
    color: var(--bone);
    font-family: var(--font-display);
    font-size: 18px;
}

.guide-list dd {
    margin: 2px 0 0;
    color: var(--bone-dim);
    font-size: 15.5px;
}

.home-phone {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr);
    gap: 48px;
    align-items: center;
}

.phone-copy > p {
    max-width: 520px;
    margin: 12px 0 22px;
    color: var(--bone-2);
    font-size: 17px;
}

.phone-points {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 26px;
    list-style: none;
}

.phone-points li {
    padding-left: 16px;
    border-left: 2px solid var(--brass);
    color: var(--bone-dim);
    font-size: 15.5px;
}

.phone-points b {
    color: var(--bone);
    font-weight: 700;
}

.phone-copy .home-actions[hidden] { display: none; }

.phone-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    align-items: end;
}

.phone-row.is-1 { grid-template-columns: minmax(0, 300px); justify-content: center; }
.phone-row.is-2 { grid-template-columns: repeat(2, minmax(0, 280px)); justify-content: center; }

.phone {
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.phone-frame {
    position: relative;
    aspect-ratio: 9 / 19.5;
    padding: 8px;
    background: #0d0908;
    border: 1px solid #3a2e2a;
    border-radius: 30px;
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45), inset 0 0 0 2px #1d1513;
    overflow: hidden;
}

.phone.is-front .phone-frame {
    transform: translateY(-22px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55), 0 0 40px rgba(207, 90, 62, 0.18), inset 0 0 0 2px #1d1513;
}

.phone-notch {
    position: absolute;
    top: 14px;
    left: 50%;
    z-index: 1;
    width: 30%;
    height: 14px;
    transform: translateX(-50%);
    border-radius: 999px;
    background: #0d0908;
}

.phone-frame img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    border-radius: 23px;
    background: var(--basalt-900);
    cursor: zoom-in;
}

.phone-frame .shot-empty { inset: 8px; border-radius: 23px; }
.phone-frame .shot-empty b { font-size: 17px; }
.phone-frame .shot-empty span { font-size: 11px; overflow-wrap: anywhere; }

.phone figcaption {
    color: var(--bone-dim);
    font-size: 13.5px;
    line-height: 1.45;
}

.phone figcaption b {
    display: block;
    margin-bottom: 2px;
    color: var(--bone);
    font-family: var(--font-display);
    font-size: 16px;
}

@media (max-width: 1100px) {
    .home-phone { grid-template-columns: 1fr; gap: 28px; }
}

@media (max-width: 560px) {

    .phone-row {
        display: flex;
        gap: 14px;
        margin: 0 -1rem;
        padding: 26px 1rem 4px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
    }
    .phone-row::-webkit-scrollbar { display: none; }
    .phone { flex: 0 0 62%; scroll-snap-align: center; }
    .phone.is-front .phone-frame { transform: none; }
}

.master-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 48px;
}

.master-grid > div {
    padding: 22px 0;
    border-top: 1px solid var(--stone-line);
}

.master-grid p {
    max-width: 560px;
    margin-top: 8px;
    color: var(--bone-dim);
    font-size: 16px;
}

.library {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.library a {
    display: block;
    padding: 22px 20px 24px;
    background: var(--basalt-800);
    border: 1px solid var(--stone-line);
    border-radius: var(--radius-lg);
    color: inherit;
    text-decoration: none;
    transition: border-color 0.2s, background 0.2s;
}

.library a:hover {
    border-color: var(--ember);
    background: #241b19;
}

.library h3 {
    color: var(--bone);
}

.library p {
    margin-top: 6px;
    color: var(--bone-dim);
    font-size: 15px;
}

.library a.has-img {
    position: relative;
    display: flex;
    align-items: flex-end;
    aspect-ratio: 4 / 5;
    padding: 18px;
    overflow: hidden;
    isolation: isolate;
    background: var(--basalt-950);
    transition: border-color 0.2s, transform 0.25s;
}

.library a.has-img img {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(.55);
    transition: filter 0.3s, transform 0.5s;
}

.library a.has-img::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(0deg, rgba(10, 7, 6, .95), transparent 60%);
}

.library a.has-img:hover { transform: translateY(-4px); background: var(--basalt-950); }
.library a.has-img:hover img { filter: brightness(.8); transform: scale(1.05); }
.library a.has-img p { color: var(--bone-2); }

.home-final {
    padding: 56px 24px;
    text-align: center;
    background: radial-gradient(500px 200px at 50% 0%, rgba(184, 68, 47, 0.16), transparent 70%);
    border-top: 1px solid var(--stone-line);
}

.home-final h2 {
    max-width: 18ch;
    margin: 0 auto 26px;
    font-size: clamp(30px, 3.6vw, 44px);
}

.home-final .home-actions {
    justify-content: center;
}

@media (max-width: 1100px) {
    .tour-slide {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .path {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .path li::after {
        display: none;
    }

    .library {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .home section + section {
        margin-top: 64px;
    }

    .home h2 {
        font-size: 28px;
    }

    .home-hero-in {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 40px 1rem 44px;
    }

    .home-die-wrap { order: -1; }

    .home-die {
        width: min(220px, 60vw);
    }

    .home-hero-guide {
        grid-template-columns: 1fr;
    }

    .master-grid {
        grid-template-columns: 1fr;
    }

    .tour-stage {
        grid-template-columns: minmax(0, 1fr);
    }

    .tour-arrow {
        display: none;
    }
}

@media (max-width: 560px) {
    .path,
    .library {
        grid-template-columns: 1fr;
    }

    .home-lead {
        font-size: 17px;
    }

    .home-btn {
        width: 100%;
    }

    .home-hero h1 {
        font-size: 34px;
    }

    .home-hero-in {
        padding: 28px 1rem 36px;
        gap: 20px;
    }

    .home-facts {
        gap: 14px 24px;
        margin-top: 26px;
    }

    .home-facts b {
        font-size: 24px;
    }

    .home section + section {
        margin-top: 48px;
    }

    .home-head p {
        font-size: 15.5px;
    }

    .library a.has-img {
        aspect-ratio: 16 / 10;
    }

    .home-final {
        padding: 40px 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-hero-bg,
    .home-die.is-rolling svg,
    .tour-slide.is-active {
        animation: none;
    }
}

.zoom {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    background: rgba(10, 7, 6, 0.92);
    cursor: zoom-out;
}

.zoom[hidden] {
    display: none;
}

.zoom img {
    max-width: 100%;
    max-height: 100%;
    border: 1px solid var(--stone-line);
    border-radius: var(--radius-md);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}

.zoom-close {
    position: absolute;
    top: 16px;
    right: 20px;
    width: 42px;
    height: 42px;
    background: var(--basalt-800);
    border: 1px solid var(--stone-line);
    border-radius: 50%;
    color: var(--bone);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

@media (max-width: 600px) {
    .zoom {
        padding: 12px;
    }
}

.party-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: 48px;
    align-items: start;
}

.party-roles {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 28px 32px;
    align-content: start;
}

.party-roles > .home-btn {
    grid-column: 1 / -1;
    justify-self: start;
}

.party-role h3 {
    margin: 0 0 14px;
    color: var(--ember-text);
    font-family: var(--font-display);
    font-size: 21px;
}

.party-role .guide-list {
    margin-bottom: 0;
}

.party-shots {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.party-thumbs {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
}

@media (max-width: 1100px) {
    .party-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .party-roles,
    .party-thumbs {
        grid-template-columns: 1fr;
    }
}