/* Volkstuin Complex (template-parts/shows/volkstuin-complex.php).
   Colours from the flyer and the stage: lawn and hedge green, the night-blue
   and red light of the second half, the bunting. Rubik Dirt stands in for the
   flyer's distressed title letter. Photos are a large print running to the
   edge of the screen and smaller prints with a chalk border on top of it. */

.vc {
    --lawn: #3e7418;
    --hedge: #173d12;
    --night: #0d1a33;
    --blood: #7a0d12;
    --blood-deep: #2a0406;
    --splash: #c4121c;
    --chalk: #f4f1e8;

    /* The fixed block takes the blood red as its accent. */
    --show-accent: var(--splash);
    --show-accent-ink: var(--paper);
    --show-accent-text: #a3101a;

    /* Outline buttons fill with chalk on hover, not the house gold. */
    --ghost-hover: var(--chalk);
    --ghost-hover-ink: var(--blood-deep);

    background-color: var(--blood-deep);
    color: var(--chalk);
}

/* ---------- Hero: the bunting photo, the flyer's title ---------- */

.vc-hero {
    position: relative;
    background-color: var(--lawn);
}

.vc-hero-photo {
    position: relative;
    height: 62svh;
    overflow: hidden;
}

.vc-hero-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 35% 20%;
}

/* Dark at the top for the header, lawn at the bottom where the title sits. */
.vc-hero-photo::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgb(0 0 0 / 0.55), transparent 25%),
        linear-gradient(to top, var(--lawn) 0%, rgb(62 116 24 / 0.6) 20%, transparent 45%);
}

.vc-hero-text {
    position: relative;
    z-index: 1;
    margin-top: -4.5rem;
    padding-bottom: 6rem;
}

.vc-title {
    display: flex;
    flex-direction: column;
    font-family: 'Rubik Dirt', var(--font-sans);
    font-size: clamp(3.5rem, 13vw, 9.5rem);
    font-weight: 400;
    line-height: 0.85;
    letter-spacing: -0.01em;
    text-transform: uppercase;
    color: var(--chalk);
    text-shadow: 0 0.04em 0.12em rgb(0 0 0 / 0.35);
}

/* The flyer's blood splash on PLEX. */
.vc-blood {
    background: radial-gradient(ellipse 38% 46% at 34% 58%, var(--splash) 0 60%, transparent 62%),
        radial-gradient(circle at 70% 40%, var(--splash) 0 9%, transparent 10%),
        radial-gradient(circle at 82% 72%, var(--splash) 0 5%, transparent 6%),
        var(--chalk);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    text-shadow: none;
}

.vc-hero-meta {
    max-width: 34em;
    margin-top: var(--space-md);
    font-size: var(--text-sm);
    font-weight: 500;
    line-height: 1.5;
}

/* The bunting hangs over the seam between hero and garden: short garlands,
   flags at a fixed size, cut to the width of the screen. */
.vc-bunting {
    position: absolute;
    left: 0;
    bottom: calc(-1 * var(--space-xl));
    z-index: 2;
    width: 100%;
    height: 7.5rem;
    filter: drop-shadow(0 0.4rem 0.4rem rgb(0 0 0 / 0.25));
}

@media (min-width: 640px) {
    .vc-hero {
        display: flex;
        align-items: flex-end;
        min-height: 100svh;
    }

    .vc-hero-photo {
        position: absolute;
        inset: 0;
        height: auto;
    }

    .vc-hero-photo img {
        object-position: 50% 10%; /* The faces stay above the title. */
    }

    .vc-hero-photo::after {
        background:
            linear-gradient(to bottom, rgb(0 0 0 / 0.55), transparent 25%),
            linear-gradient(to top, var(--lawn) 2%, rgb(23 61 18 / 0.75) 30%, transparent 65%);
    }

    .vc-hero-text {
        margin-top: 0;
        padding-bottom: var(--space-4xl);
    }

    .vc-hero-meta {
        margin-top: var(--space-lg);
        font-size: var(--text-base);
    }
}

/* ---------- The garden: lawn, night, blood ---------- */

.vc-garden {
    position: relative;
    padding-top: var(--space-3xl);
    background: linear-gradient(to bottom,
            var(--lawn) 0%,
            var(--hedge) 28%,
            var(--night) 52%,
            #1a0b24 66%,
            var(--blood) 84%,
            var(--blood-deep) 100%);
}

/* The red drips into the foyer. */
.vc-garden::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2.7rem;
    height: 2.75rem;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='44' viewBox='0 0 240 44'%3E%3Cpath d='M0 0 H240 V6 L227 6 C227 16 225 22 222 22 C219 22 217 16 217 6 L201 6 C201 4 199 10 196 10 C193 10 191 4 191 6 L163 6 C163 24 161 30 158 30 C155 30 153 24 153 6 L126 6 C126 10 124 16 121 16 C118 16 116 10 116 6 L92 6 C92 32 90 38 87 38 C84 38 82 32 82 6 L57 6 C57 6 55 12 52 12 C49 12 47 6 47 6 L23 6 C23 20 21 26 18 26 C15 26 13 20 13 6 L0 6 Z' fill='%232a0406'/%3E%3C/svg%3E") repeat-x 0 0 / 15rem 2.75rem;
    pointer-events: none;
}

/* ---------- Scenes: a sentence of the play and its photos ---------- */

.vc-scene {
    display: flex;
    flex-direction: column;
}

.vc-scene + .vc-scene {
    margin-top: var(--space-3xl);
}

/* ---------- The description, in one piece ---------- */

.vc-story {
    position: relative;
    margin-bottom: var(--space-3xl);
}

.vc-story-text {
    max-width: 40rem;
}

.vc-story-text p {
    margin-bottom: var(--space-md);
    line-height: 1.7;
}

.vc-story-text p:first-child {
    font-size: var(--text-xl);
    font-weight: 500;
    line-height: 1.3;
}

/* ---------- Miranda's notebook: notes on ruled paper, taped on ---------- */

.vc-line {
    margin-bottom: var(--space-lg);
}

.vc-line--note {
    position: relative;
    z-index: 2;
    align-self: flex-start;
    max-width: 22rem;
    padding: var(--space-md) var(--space-md) var(--space-md) var(--space-lg);
    background:
        linear-gradient(to right, transparent 1.15rem, rgb(196 18 28 / 0.35) 1.15rem 1.25rem, transparent 1.25rem),
        repeating-linear-gradient(to bottom, transparent 0 1.6rem, rgb(47 111 181 / 0.22) 1.6rem calc(1.6rem + 1px)),
        #f4f1e8;
    color: #1b120c;
    font-family: var(--font-serif);
    font-size: var(--text-lg);
    font-style: italic;
    line-height: 1.6rem;
    box-shadow: 0 0.6rem 1.25rem rgb(0 0 0 / 0.3);
    transform: rotate(-1.5deg);
    transition: transform var(--duration-normal) ease;
}

.vc-line--note:hover {
    transform: rotate(0deg);
}

/* Tape. */
.vc-line--note::before {
    content: '';
    position: absolute;
    top: -0.7rem;
    left: 50%;
    width: 5rem;
    height: 1.4rem;
    margin-left: -2.5rem;
    background: rgb(255 210 63 / 0.75);
    transform: rotate(3deg);
}

.vc-scene--left .vc-line--note {
    transform: rotate(1.5deg);
}

/* The turn of the play, in the flyer's letter. */
.vc-line--turn {
    margin-bottom: var(--space-lg);
    font-family: 'Rubik Dirt', var(--font-sans);
    font-size: clamp(2.25rem, 9vw, 4.75rem);
    font-weight: 400;
    line-height: 0.95;
    letter-spacing: 0;
    text-transform: uppercase;
}

.vc-photo {
    position: relative;
    display: block;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: rgb(0 0 0 / 0.25);
    cursor: zoom-in;
}

.vc-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.vc-photo:hover img {
    transform: scale(1.04);
}

/* The large print runs to the edge of the screen. */
.vc-photo--large {
    aspect-ratio: 4 / 3;
    margin-inline: calc(-1 * var(--gutter));
}

/* Prints: a chalk border and a slight tilt, as if from Miranda's book. */
.vc-photo--print {
    z-index: 1;
    aspect-ratio: 4 / 3;
    border: 0.375rem solid var(--chalk);
    box-shadow: 0 0.75rem 1.5rem rgb(0 0 0 / 0.35);
}

.vc-photo--print-1 {
    width: 62%;
    margin-top: -18%;
    align-self: flex-end;
    transform: rotate(2deg);
}

.vc-photo--print-2 {
    width: 50%;
    margin-top: -8%;
    align-self: flex-start;
    transform: rotate(-2.5deg);
}

.vc-photo--print-3 {
    width: 56%;
    margin-top: -6%;
    align-self: flex-end;
    transform: rotate(1.5deg);
}

.vc-scene--left .vc-photo--print-1 {
    align-self: flex-start;
    transform: rotate(-2deg);
}

.vc-scene--left .vc-photo--print-2 {
    align-self: flex-end;
}

/* The idyll: prints scattered around the sentence. */
.vc-scene--scatter .vc-photo--print-1 {
    margin-top: 0;
    align-self: flex-start;
    transform: rotate(-2deg);
}

.vc-scene--scatter .vc-photo--print-2 {
    align-self: flex-end;
    margin-top: -10%;
    transform: rotate(2.5deg);
}

/* Heads over the hedge, with the line written on the hedge. */
.vc-scene--hedge {
    position: relative;
}

.vc-scene--hedge .vc-photo--large {
    aspect-ratio: 4 / 3;
}

.vc-scene--hedge .vc-photo--large img {
    object-position: 50% 70%;
}

.vc-scene--hedge .vc-line {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 8%;
    z-index: 1;
    margin: 0;
    padding: 0 var(--gutter);
    z-index: 3;
    font-size: clamp(1.75rem, 6vw, 5rem);
    text-align: center;
    text-shadow: 0 0.05em 0.3em rgb(0 0 0 / 0.7);
    pointer-events: none;
}

.vc-scene--hedge .vc-photo--large {
    z-index: 1;
}

/* ---------- Props from the flyer and the stage: small, in corners ---------- */

.vc-prop {
    position: absolute;
    z-index: 3; /* Over the corner of a photo. */
    display: block;
    pointer-events: none;
}

/* The brooding gnome sits on the top corner of the note, as on the flyer. */
.vc-prop--brood {
    top: -3.6rem;
    right: 0.75rem;
    width: 3.25rem;
}

/* The hatchet, planted in the corner of the last note. */
.vc-prop--axe {
    bottom: -1.5rem;
    right: -1.5rem;
    width: 3.75rem;
    transform: rotate(6deg);
}

/* In the dark, a gnome peeks from the edge of the screen. */
.vc-scene:has(.vc-prop--peek) {
    position: relative;
}

.vc-prop--peek {
    /* Half his face past the edge of the screen. */
    bottom: 1rem;
    left: calc(-1 * var(--gutter) - 1.1rem);
    width: 3.25rem;
    transform: rotate(28deg);
}

/* The hedge, where the idyll turns; eyes in it. */
/* Sprigs of the hedge creep into a corner of a scene. */
.vc-scene:has(.vc-prop--leaves, .vc-prop--leaves-eyes) {
    position: relative;
}

.vc-prop--leaves {
    top: -2.5rem;
    right: calc(-1 * var(--gutter));
    width: 6rem;
    transform: scaleX(-1) rotate(-10deg);
    opacity: 0.85;
}

.vc-prop--leaves-eyes {
    bottom: -2rem;
    left: calc(-1 * var(--gutter));
    width: 6.5rem;
}

/* Muddy boot prints, across the dark between night and blood. */
.vc-prop--tracks {
    position: relative;
    z-index: 0;
    width: 100%;
    height: 6rem;
    margin: var(--space-xl) 0 calc(-1 * var(--space-xl));
    overflow: visible;
    opacity: 0.3;
}

/* ---------- About the play, credits as on the flyer ---------- */

.vc-about {
    display: grid;
    gap: var(--space-xl);
    margin-top: var(--space-3xl);
}

.vc-about-text {
    max-width: 36rem;
    margin: 0;
    line-height: 1.7;
}

.vc-credits div {
    margin-bottom: var(--space-2xs);
}

.vc-credits dt,
.vc-credits dd {
    display: inline;
}

.vc-credits dt {
    color: rgb(244 241 232 / 0.75);
}

.vc-credits dd {
    margin-left: 0.35em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.vc-all {
    margin: 0;
}

.vc-all .btn--ghost {
    color: var(--chalk);
}

.vc-all .btn--ghost:hover {
    color: var(--ghost-hover-ink);
}

/* ---------- The fixed block, rising into the foyer ---------- */

.vc-info {
    position: relative;
    z-index: 1;
    margin-top: var(--space-2xl);
    margin-bottom: calc(-1 * var(--space-2xl));
}

.vc-info .show-info {
    box-shadow: 0 1.5rem 3rem rgb(0 0 0 / 0.35);
    border-top: 4px solid var(--splash);
}

/* The foyer leaves room for the block's overlap. */
.show-design + .foyer {
    padding-top: calc(var(--space-2xl) + var(--space-lg));
}

/* ---------- Desktop: the scenes as mosaics on the grid ---------- */

@media (min-width: 1024px) {
    .vc-garden {
        padding-top: var(--space-4xl);
    }

    .vc-scene {
        display: grid;
        grid-template-columns: repeat(12, 1fr);
        grid-auto-rows: 2rem;
        column-gap: var(--space-md);
        align-items: start;
    }

    .vc-scene + .vc-scene {
        margin-top: var(--space-4xl);
    }

    .vc-line,
    .vc-line--turn {
        margin: 0;
    }

    .vc-line--note {
        font-size: var(--text-xl);
        line-height: 1.9rem;
        max-width: none;
        padding: var(--space-lg) var(--space-lg) var(--space-lg) var(--space-xl);
        background:
            linear-gradient(to right, transparent 1.5rem, rgb(196 18 28 / 0.35) 1.5rem 1.6rem, transparent 1.6rem),
            repeating-linear-gradient(to bottom, transparent 0 1.9rem, rgb(47 111 181 / 0.22) 1.9rem calc(1.9rem + 1px)),
            #f4f1e8;
    }


    .vc-story-text {
        grid-column: 1 / 8;
    }

    .vc-story-text p:first-child {
        font-size: var(--text-2xl);
    }

    .vc-scene .vc-line--note {
        align-self: center;
    }

    .vc-prop--brood {
        top: -4.6rem;
        width: 4.25rem;
    }

    .vc-prop--axe {
        width: 4.75rem;
    }

    .vc-prop--peek {
        left: calc(-1 * var(--bleed) - 1.4rem);
        bottom: 2rem;
        width: 4.25rem;
    }

    .vc-prop--leaves {
        right: calc(-1 * var(--bleed) - 1rem);
        width: 9rem;
    }

    .vc-prop--leaves-eyes {
        left: calc(-1 * var(--bleed) - 1rem);
        width: 9.5rem;
    }

    .vc-prop--tracks {
        height: 9rem;
        margin: var(--space-2xl) 0 calc(-1 * var(--space-2xl));
    }

    .vc-line--turn {
        font-size: clamp(2.5rem, 3.6vw, 3.75rem);
    }

    /* The turn sits high beside the photo; its print hangs below it, never over it. */
    .vc-scene--left .vc-line--turn {
        grid-row: 2 / 12;
        align-self: start;
    }

    .vc-scene--left:has(.vc-line--turn) .vc-photo--print-1 {
        grid-column: 8 / 12;
        grid-row: 13 / 21;
    }

    .vc-photo--print,
    .vc-photo--print-1,
    .vc-photo--print-2,
    .vc-photo--print-3 {
        width: auto;
        margin: 0;
        aspect-ratio: auto;
        border-width: 0.625rem;
    }

    .vc-photo--large {
        aspect-ratio: auto;
        margin: 0;
    }

    /* Large photo right: the sentence on the left, prints over the photo's corners. */
    .vc-scene--right .vc-line {
        grid-column: 1 / 5;
        grid-row: 3 / 12;
        align-self: center;
    }

    .vc-scene--right .vc-photo--large {
        grid-column: 6 / 13;
        grid-row: 1 / 14;
        margin-right: calc(-1 * var(--bleed));
    }

    .vc-scene--right .vc-photo--print-1 {
        grid-column: 4 / 8;
        grid-row: 11 / 19;
    }

    .vc-scene--right .vc-photo--print-2 {
        grid-column: 10 / 13;
        grid-row: 12 / 19;
    }

    /* Large photo left: the mirror image. */
    .vc-scene--left .vc-line {
        grid-column: 9 / 13;
        grid-row: 3 / 12;
        align-self: center;
    }

    .vc-scene--left .vc-photo--large {
        grid-column: 1 / 8;
        grid-row: 1 / 14;
        margin-left: calc(-1 * var(--bleed));
    }

    .vc-scene--left .vc-photo--print-1 {
        grid-column: 6 / 10;
        grid-row: 11 / 19;
    }

    .vc-scene--left .vc-photo--print-2 {
        grid-column: 1 / 4;
        grid-row: 12 / 19;
    }

    /* The idyll: three prints around a centred sentence. */
    .vc-scene--scatter .vc-line {
        grid-column: 5 / 9;
        grid-row: 9 / 15;
        align-self: center;
    }

    .vc-scene--scatter .vc-photo--print-1 {
        grid-column: 1 / 5;
        grid-row: 1 / 9;
    }

    .vc-scene--scatter .vc-photo--print-2 {
        grid-column: 9 / 13;
        grid-row: 2 / 9;
    }

    .vc-scene--scatter .vc-photo--print-3 {
        grid-column: 5 / 9;
        grid-row: 14 / 22;
    }

    /* The hedge: the full frame. */
    .vc-scene--hedge {
        display: block;
    }

    .vc-scene--hedge .vc-photo--large {
        aspect-ratio: 21 / 9;
        margin-inline: calc(-1 * var(--bleed));
    }

    .vc-about {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }

    .vc-credits {
        text-align: right;
    }

    .vc-all {
        grid-column: 1 / -1;
    }

    .vc-hero-meta {
        font-size: var(--text-lg);
    }
}
