/*
Theme Name: Fret & Vice Coming Soon — Exact
Theme URI: https://fretandvice.com/
Author: Fret & Vice
Description: Exact Fret & Vice coming-soon landing page with a functional contact form.
Version: 2.2.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.0
Text Domain: fret-vice-exact
*/

:root {
    --fv-ink: #f1e9dc;
    --fv-accent: #a52e28;
}

* { box-sizing: border-box; }

html,
body {
    margin: 0;
    width: 100%;
    min-height: 100%;
    background: #090909;
}

body {
    min-height: 100vh;
    overflow: hidden;
    color: var(--fv-ink);
    font-family: Arial, Helvetica, sans-serif;
}

.fv-page {
    position: fixed;
    inset: 0;
    overflow: hidden;
    background: #090909;
}

/*
 * The approved artwork is 1568 x 886 (1.7697517:1), essentially 16:9.
 * The stage uses the same aspect ratio and covers the viewport. All interactive
 * form coordinates are percentage-based against this same stage, so the live
 * controls remain registered to the artwork.
 */
.fv-stage {
    position: absolute;
    left: 50%;
    top: 50%;
    width: max(100vw, calc(100vh * 1.769751693));
    height: max(100vh, calc(100vw / 1.769751693));
    transform: translate(-50%, -50%);
}

.fv-artwork {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    user-select: none;
    pointer-events: none;
}

.fv-form {
    position: absolute;
    pointer-events: auto;
    left: 69.48%;
    top: 50.78%;
    width: 26.22%;
    height: 37.70%;
    z-index: 4;
}

.fv-field,
.fv-message,
.fv-submit {
    position: absolute;
    left: 7.05%;
    width: 85.8%;
    border: 0;
    outline: 0;
    margin: 0;
    border-radius: 2px;
    font: 500 clamp(10px, .76vw, 15px)/1.35 Arial, Helvetica, sans-serif;
}

.fv-field,
.fv-message {
    color: #f1e9dc;
    background: rgba(13, 13, 12, 0.06);
    caret-color: #f1e9dc;
    padding: 0 1.15%;
    transition: background-color .15s ease, box-shadow .15s ease;
}

.fv-field:focus,
.fv-message:focus {
    background: rgba(15, 15, 14, .48);
    box-shadow: inset 0 0 0 1px rgba(241, 233, 220, .28);
}

.fv-field::placeholder,
.fv-message::placeholder { color: transparent; }

.fv-name {
    top: 12.23%;
    height: 10.64%;
}

.fv-email {
    top: 32.18%;
    height: 10.37%;
}

.fv-message {
    top: 52.39%;
    height: 22.61%;
    resize: none;
    padding-top: 1.6%;
}

.fv-submit {
    top: 79.26%;
    height: 12.77%;
    z-index: 20;
    cursor: pointer !important;
    pointer-events: auto !important;
    touch-action: manipulation;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    color: transparent;
    text-indent: -9999px;
    overflow: hidden;
}

.fv-submit:focus-visible {
    outline: 2px solid rgba(241,233,220,.85);
    outline-offset: 2px;
}

.fv-submit:hover {
    box-shadow: inset 0 0 0 999px rgba(255,255,255,.035);
}

.fv-form-meta {
    position: absolute;
    left: 7.05%;
    top: 101.8%;
    width: 85.8%;
    text-align: center;
    pointer-events: none;
}

.fv-status {
    position: static;
    width: 100%;
    margin: 0 0 7px;
    text-align: center;
    font: 700 clamp(8px, .62vw, 12px)/1.4 Arial, Helvetica, sans-serif;
    letter-spacing: .11em;
    text-transform: uppercase;
    color: #f1e9dc;
    text-shadow: 0 1px 2px #000;
}

.fv-copyright {
    /* IMPORTANT: this element sits OUTSIDE .fv-stage. That keeps position:fixed
       tied to the visible browser viewport rather than the transformed/cropped
       16:9 artwork stage. 8.42% is the measured left edge of the F in the
       approved desktop artwork. */
    --fv-stage-w: max(100vw, calc(100vh * 1.769751693));
    position: fixed;
    left: calc(((100vw - var(--fv-stage-w)) / 2) + (var(--fv-stage-w) * 0.0842));
    bottom: 14px;
    z-index: 20;
    width: auto;
    margin: 0;
    color: rgba(241, 233, 220, .82);
    font: 700 clamp(7px, .50vw, 9px)/1.35 Arial, Helvetica, sans-serif;
    letter-spacing: .13em;
    text-transform: uppercase;
    text-align: left;
    text-shadow: 0 1px 3px rgba(0,0,0,.95);
    white-space: nowrap;
    pointer-events: none;
}

.fv-hp,
.fv-sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/*
 * Responsive presentation
 * -----------------------
 * The approved 1568×886 composition remains pixel-registered on desktop.
 * Tablets and phones deliberately stop trying to squeeze that landscape canvas
 * into a portrait viewport. Instead the left 1080px of the approved artwork is
 * used as a branded hero and the same live form is presented beneath it.
 */
.fv-art-frame {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.fv-mobile-contact-title { display: none; }

@media (max-width: 1200px), (max-aspect-ratio: 3/2) {
    html,
    body {
        min-height: 100%;
        overflow-x: hidden;
        overflow-y: auto;
        background: #090909;
    }

    body { min-height: 100dvh; }

    .fv-page {
        position: relative;
        inset: auto;
        width: 100%;
        min-height: 100dvh;
        overflow: visible;
        background:
            radial-gradient(circle at 55% 8%, rgba(74, 65, 55, .10), transparent 38%),
            #090909;
    }

    .fv-stage {
        position: relative;
        left: auto;
        top: auto;
        width: 100%;
        height: auto;
        transform: none;
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }

    /* Crop away the desktop form while preserving the exact approved hero art. */
    .fv-art-frame {
        position: relative;
        inset: auto;
        width: 100%;
        aspect-ratio: 1080 / 886;
        overflow: hidden;
        flex: 0 0 auto;
        background: #090909;
    }

    .fv-artwork {
        position: absolute;
        left: 0;
        top: 0;
        width: 145.185185%; /* 1568 / 1080 */
        height: 100%;
        max-width: none;
        object-fit: fill;
    }


    .fv-form {
        position: relative;
        left: auto;
        top: auto;
        width: calc(100% - 48px);
        max-width: 620px;
        height: auto;
        z-index: 4;
        margin: clamp(24px, 5vw, 48px) auto 0;
        padding: clamp(24px, 5vw, 38px);
        border: 1px solid rgba(241, 233, 220, .17);
        border-radius: 5px;
        background:
            linear-gradient(rgba(22, 21, 19, .94), rgba(13, 13, 12, .96)),
            #111;
        box-shadow: 0 20px 55px rgba(0,0,0,.28);
    }

    .fv-mobile-contact-title {
        display: block;
        margin: 0 0 28px;
        color: var(--fv-ink);
        font: 700 13px/1 Arial, Helvetica, sans-serif;
        letter-spacing: .38em;
        text-transform: uppercase;
    }

    .fv-mobile-contact-title::after {
        content: "";
        display: block;
        width: 70px;
        height: 2px;
        margin-top: 13px;
        background: var(--fv-accent);
    }

    .fv-form label.fv-sr-only {
        position: static !important;
        display: block;
        width: auto !important;
        height: auto !important;
        margin: 0 0 9px !important;
        padding: 0 !important;
        overflow: visible !important;
        clip: auto !important;
        white-space: normal !important;
        color: var(--fv-ink);
        font: 700 11px/1.2 Arial, Helvetica, sans-serif;
        letter-spacing: .32em;
        text-transform: uppercase;
    }

    .fv-field,
    .fv-message,
    .fv-submit {
        position: relative;
        left: auto;
        top: auto;
        width: 100%;
        border-radius: 3px;
    }

    .fv-field,
    .fv-message {
        display: block;
        color: var(--fv-ink);
        background: rgba(11, 11, 10, .62);
        border: 1px solid rgba(241, 233, 220, .24);
        font: 500 16px/1.35 Arial, Helvetica, sans-serif;
        padding: 12px 14px;
        margin: 0 0 22px;
        -webkit-appearance: none;
        appearance: none;
    }

    .fv-field { height: 48px; }

    .fv-message {
        height: 124px;
        resize: vertical;
        min-height: 110px;
        max-height: 260px;
    }

    .fv-field:focus,
    .fv-message:focus {
        background: rgba(15, 15, 14, .88);
        border-color: rgba(241, 233, 220, .50);
        box-shadow: 0 0 0 1px rgba(241, 233, 220, .12);
    }

    .fv-submit {
        display: block;
        height: 52px;
        margin: 3px 0 0;
        border: 0;
        background: #9f2e29;
        color: #f8efe3;
        text-indent: 0;
        overflow: visible;
        font: 700 13px/1 Arial, Helvetica, sans-serif;
        letter-spacing: .33em;
        text-transform: uppercase;
        box-shadow: inset 0 0 0 1px rgba(255,255,255,.03);
    }

    .fv-submit:hover,
    .fv-submit:focus-visible {
        background: #ad342e;
        box-shadow: inset 0 0 0 1px rgba(255,255,255,.10);
    }

    .fv-form-meta {
        position: static;
        left: auto;
        top: auto;
        width: 100%;
        margin: 16px 0 0;
        text-align: center;
    }

    .fv-status {
        position: static;
        width: 100%;
        margin: 0 0 10px;
        font-size: 11px;
    }

    .fv-copyright {
        position: static;
        left: auto;
        bottom: auto;
        width: calc(100% - 48px);
        max-width: 620px;
        margin: 12px auto clamp(38px, 8vw, 72px);
        color: rgba(241, 233, 220, .62);
        font-size: 8px;
        letter-spacing: .13em;
        white-space: normal;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .fv-art-frame {
        /* A slightly tighter crop keeps the identity larger on a phone. */
        aspect-ratio: 1010 / 886;
    }

    .fv-artwork {
        width: 155.247525%; /* 1568 / 1010 */
    }

    .fv-form {
        width: calc(100% - 28px);
        margin-top: 18px;
        padding: 24px 20px 22px;
    }

    .fv-copyright { width: calc(100% - 28px); }

    .fv-mobile-contact-title { margin-bottom: 24px; }
    .fv-field, .fv-message { margin-bottom: 19px; }

}

@media (max-width: 390px) {
    .fv-form,
    .fv-copyright { width: calc(100% - 20px); }
}

/* Explicitly keep the live submit control interactive even if a plugin or WordPress global style targets buttons. */
.fv-form button.fv-submit,
.fv-form button.fv-submit:hover,
.fv-form button.fv-submit:focus,
.fv-form button.fv-submit:active {
    cursor: pointer !important;
    pointer-events: auto !important;
}
.fv-form button.fv-submit:disabled {
    cursor: pointer !important;
    opacity: 1 !important;
}
