/**
 * Perwillowen Studio — Component & Plugin Overrides
 */

/* --------------------------------------------------
   Hero (explicit CSS — does not rely on Tailwind
   utilities that may be missing from the build)
-------------------------------------------------- */
.perwillowen-hero {
    position: relative;
    isolation: isolate;
    /* Fill viewport below the sticky nav (~4.5–5rem) */
    min-height: calc(100vh - 5rem);
    min-height: calc(100dvh - 5rem);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.perwillowen-hero__media {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    pointer-events: none;
}

.perwillowen-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: rgba(0, 0, 0, 0.4);
}

.perwillowen-hero__inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
    text-align: center;
    color: #fff;
}

/* --------------------------------------------------
   Hero fallback gradient (used when hero image is
   not yet uploaded)
-------------------------------------------------- */
.hero-fallback {
    background: linear-gradient(135deg, #2C2C2C 0%, #1A1A1A 100%);
}

.hero-fallback .perwillowen-hero__media {
    display: none;
}

/* --------------------------------------------------
   Contact Form 7 — match site styling
-------------------------------------------------- */
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea {
    width: 100%;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background-color: var(--input);
    color: var(--foreground);
    font-family: inherit;
    font-size: 1rem;
    line-height: 1.5;
    transition: box-shadow 150ms, border-color 150ms;
}

.wpcf7 input[type="text"]:focus,
.wpcf7 input[type="email"]:focus,
.wpcf7 input[type="tel"]:focus,
.wpcf7 textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 30%, transparent);
}

.wpcf7 input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.5rem 1rem;
    background-color: var(--primary);
    color: var(--primary-foreground);
    font-weight: 500;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    font-size: 0.875rem;
    transition: background-color 150ms;
}

.wpcf7 input[type="submit"]:hover {
    background-color: color-mix(in oklab, var(--primary) 90%, transparent);
}

.wpcf7-not-valid-tip {
    color: var(--destructive);
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.wpcf7-response-output {
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    margin-top: 1rem;
    font-size: 0.875rem;
}

.wpcf7-mail-sent-ok {
    border-color: hsl(145, 92%, 87%);
    background-color: hsl(143, 85%, 96%);
    color: hsl(140, 100%, 27%);
}

.wpcf7-mail-sent-ng,
.wpcf7-aborted {
    border-color: hsl(359, 100%, 94%);
    background-color: hsl(359, 100%, 97%);
    color: hsl(360, 100%, 45%);
}

/* --------------------------------------------------
   Smooth-scroll offset for sticky nav
-------------------------------------------------- */
:target {
    scroll-margin-top: 80px;
}

/* --------------------------------------------------
   WordPress Page content (block editor output)
-------------------------------------------------- */
.perwillowen-page-content {
    font-size: 1.125rem;
    line-height: 1.625;
    color: var(--foreground);
}

.perwillowen-page-content p {
    margin-bottom: 1rem;
}

.perwillowen-page-content h2,
.perwillowen-page-content h3 {
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--foreground);
}

.perwillowen-page-content h2 {
    font-size: 1.875rem;
}

.perwillowen-page-content h3 {
    font-size: 1.5rem;
}

.perwillowen-page-content ul,
.perwillowen-page-content ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.perwillowen-page-content ul {
    list-style: disc;
}

.perwillowen-page-content ol {
    list-style: decimal;
}

.perwillowen-page-content a {
    color: var(--primary);
    text-decoration: underline;
}

.perwillowen-page-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1.5rem 0;
}

/* --------------------------------------------------
   WordPress nav menus
-------------------------------------------------- */
.perwillowen-nav-desktop {
    align-items: center;
}

.perwillowen-menu {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.perwillowen-menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.perwillowen-menu a,
.perwillowen-nav-link {
    color: inherit;
    text-decoration: none;
    transition: color 150ms;
}

.perwillowen-menu a:hover,
.perwillowen-nav-link:hover {
    color: var(--primary);
}

.perwillowen-menu--mobile {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
}

.perwillowen-menu--mobile a {
    display: block;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}
