/* ==========================================================================
   RuneCake — illustrated guide pages
   Artwork: original SVGs generated by tools/generate-art.js.
   Loaded on /guide and /crypto-guide only.
   ========================================================================== */

/* ---------- Illustrated hero banners ---------- */
.hero.hero-art {
    position: relative;
    overflow: hidden;
    min-height: clamp(230px, 34vw, 320px);
    text-align: left;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1.75rem, 5vw, 3.25rem) clamp(1.5rem, 6vw, 3.75rem);
    background:
        linear-gradient(90deg,
            rgba(12, 8, 5, 0.96) 0%,
            rgba(14, 9, 6, 0.90) 34%,
            rgba(14, 9, 6, 0.55) 62%,
            rgba(14, 9, 6, 0.16) 100%),
        url('/assets/art/guide-hero.svg') center / cover no-repeat;
}

.hero.hero-art.hero-crypto {
    background:
        linear-gradient(90deg,
            rgba(12, 8, 5, 0.96) 0%,
            rgba(14, 9, 6, 0.90) 34%,
            rgba(14, 9, 6, 0.55) 62%,
            rgba(14, 9, 6, 0.16) 100%),
        url('/assets/art/crypto-hero.svg') center / cover no-repeat;
}

.hero-art > * {
    position: relative;
    z-index: 2;
    max-width: 660px;
}

.hero-art .badge {
    align-self: flex-start;
    margin-bottom: 0.9rem;
}

.hero-art h1 {
    font-size: clamp(1.9rem, 5.4vw, 3.1rem);
    line-height: 1.14;
    text-wrap: balance;
}

.hero-art p {
    font-size: clamp(0.92rem, 2.1vw, 1.05rem);
    max-width: 58ch;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.85);
}

/* A soft vignette keeps long headlines legible over the illustration. */
.hero-art::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(ellipse at 22% 50%, rgba(0, 0, 0, 0.5), transparent 62%);
}

@media (max-width: 700px) {
    .hero.hero-art,
    .hero.hero-art.hero-crypto {
        background:
            linear-gradient(90deg, rgba(12, 8, 5, 0.94), rgba(12, 8, 5, 0.72)),
            url('/assets/art/guide-hero.svg') 72% / cover no-repeat;
    }

    .hero.hero-art.hero-crypto {
        background:
            linear-gradient(90deg, rgba(12, 8, 5, 0.94), rgba(12, 8, 5, 0.72)),
            url('/assets/art/crypto-hero.svg') 72% / cover no-repeat;
    }

    .hero-art > * { max-width: none; }
}

/* ---------- Section flourish ---------- */
.guide-flourish {
    display: block;
    width: min(340px, 72%);
    height: 20px;
    margin: 1.5rem auto 0.4rem;
    opacity: 0.85;
}

.guide-section-title {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin: 2rem 0 0.85rem;
    font-family: 'MedievalSharp', cursive;
    color: var(--gold);
    font-size: clamp(1.3rem, 3.4vw, 1.65rem);
}

.guide-section-title::before,
.guide-section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.65));
}

.guide-section-title::after {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.65), transparent);
}

/* ---------- Money-making method cards with illustrations ---------- */
.guide-art-grid {
    gap: 1.05rem;
}

.guide-art-grid .method {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr);
    column-gap: 1.15rem;
    align-items: start;
    padding: 1.2rem 1.3rem;
}

.guide-art-grid .method > :not(.method-art) {
    grid-column: 2;
}

.guide-art-grid .method-art {
    grid-column: 1;
    grid-row: 1 / -1;
    width: 78px;
    height: 78px;
    align-self: start;
    margin-top: 0.05rem;
    filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.62));
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.4s;
}

@media (hover: hover) and (pointer: fine) {
    .guide-art-grid .method:hover .method-art {
        transform: translateY(-4px) rotate(-4deg) scale(1.05);
        filter: drop-shadow(0 12px 20px rgba(0, 0, 0, 0.75))
                drop-shadow(0 0 14px rgba(212, 175, 55, 0.45));
    }
}

/* Category colour-coding makes scanning the list effortless. */
.guide-art-grid .method[data-tone='beginner'] { border-left-color: #8fd07a; }
.guide-art-grid .method[data-tone='mid'] { border-left-color: #82b7ff; }
.guide-art-grid .method[data-tone='high'] { border-left-color: #ff9b73; }
.guide-art-grid .method[data-tone='afk'] { border-left-color: #c39bff; }

.guide-art-grid .method-top { align-items: baseline; }
.guide-art-grid .method h3 { letter-spacing: 0.01em; }

.guide-art-grid .method-note {
    font-size: 0.76rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--gold-dark, #b8941f);
    margin-top: 0.15rem;
}

@media (max-width: 620px) {
    .guide-art-grid .method {
        grid-template-columns: 60px minmax(0, 1fr);
        column-gap: 0.85rem;
        padding: 1rem;
    }

    .guide-art-grid .method-art {
        width: 56px;
        height: 56px;
    }
}

/* ---------- Quick-jump navigation ---------- */
.guide-toc {
    border: 1px solid rgba(212, 175, 55, 0.45);
    background: linear-gradient(180deg, rgba(74, 44, 32, 0.72), rgba(20, 12, 8, 0.86));
    padding: 0.9rem 1.1rem;
    margin: 1.25rem 0;
}

.guide-toc-title {
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold-dark, #b8941f);
    margin-bottom: 0.65rem;
}

.guide-toc-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.guide-toc-links a {
    display: inline-block;
    padding: 0.38rem 0.72rem;
    border: 1px solid rgba(212, 175, 55, 0.45);
    color: var(--parchment, #f0e68c);
    font-size: 0.78rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}

.guide-toc-links a:hover,
.guide-toc-links a:focus-visible {
    background: var(--gold);
    color: #2d1810;
    transform: translateY(-1px);
}

/* ---------- Shared accordion styling (also used by the guide FAQ) ---------- */
.cg-faq details {
    border-bottom: 1px solid rgba(139, 115, 85, 0.55);
    padding: 0.7rem 0;
}

.cg-faq summary {
    cursor: pointer;
    color: var(--gold, #d4af37);
    font-weight: 600;
}

.cg-faq p {
    margin-top: 0.5rem;
    line-height: 1.7;
}

/* ---------- Crypto guide illustrated steps ---------- */
.cg-steps.cg-illustrated .cg-step {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    column-gap: 1.1rem;
    align-items: start;
    padding-left: 1.1rem;
}

/* Keep the step number, but move it out of the illustration column. */
.cg-steps.cg-illustrated .cg-step::before {
    left: auto;
    right: 0.9rem;
    top: 0.9rem;
    width: 1.9rem;
    height: 1.9rem;
    font-size: 1rem;
    opacity: 0.85;
}

.cg-steps.cg-illustrated .cg-step h3 { padding-right: 2.4rem; }

.cg-steps.cg-illustrated .cg-step > :not(.cg-step-art) {
    grid-column: 2;
}

.cg-step-art {
    grid-column: 1;
    grid-row: 1 / -1;
    width: 72px;
    height: 72px;
    filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.6));
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@media (hover: hover) and (pointer: fine) {
    .cg-steps.cg-illustrated .cg-step:hover .cg-step-art {
        transform: translateY(-3px) scale(1.05);
    }
}

@media (max-width: 620px) {
    .cg-steps.cg-illustrated .cg-step {
        grid-template-columns: 56px minmax(0, 1fr);
        column-gap: 0.85rem;
    }

    .cg-step-art { width: 54px; height: 54px; }
}

/* ---------- Fact strip ---------- */
.guide-facts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.guide-fact {
    text-align: center;
    border: 1px solid rgba(212, 175, 55, 0.4);
    background: rgba(212, 175, 55, 0.06);
    padding: 0.9rem 0.6rem;
}

.guide-fact b {
    display: block;
    font-family: 'MedievalSharp', cursive;
    font-size: 1.25rem;
    color: var(--gold);
    line-height: 1.2;
}

.guide-fact span {
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted, #b8941f);
}

@media (prefers-reduced-motion: reduce) {
    .guide-art-grid .method-art,
    .cg-step-art,
    .guide-toc-links a { transition: none; }
}
