/**
 * Plötner Dev — Custom Styles
 * Hover effects, transitions, and details beyond theme.json.
 */

/* --- Global refinements --- */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: var(--wp--preset--color--accent);
    color: var(--wp--preset--color--base);
}

/* --- Card hover effects --- */
.ploetner-card {
    transition: border-color 0.3s ease, transform 0.2s ease;
}

.ploetner-card:hover {
    border-color: var(--wp--preset--color--border-hover) !important;
    transform: translateY(-2px);
}

/* --- Community card description (block-editor content rendered in a card) --- */
.ploetner-card-desc,
.ploetner-card-desc p {
    color: var(--wp--preset--color--text-muted);
    font-size: var(--wp--preset--font-size--small);
    font-weight: 300;
    line-height: 1.6;
}

.ploetner-card-desc > :last-child {
    margin-bottom: 0;
}

/* --- Expertise grid: seamless 1px gap look --- */
.ploetner-expertise-grid {
    background: var(--wp--preset--color--border);
    gap: 1px !important;
    overflow: hidden;
    border-radius: 3px;
}

.ploetner-expertise-grid > .wp-block-column {
    transition: background 0.3s ease;
}

.ploetner-expertise-grid > .wp-block-column:hover {
    background: var(--wp--preset--color--base-elevated) !important;
}

/* --- Speaking rows: hover highlight --- */
/*
 * The hover tint bleeds 0.75rem past the content on each side via a pseudo-element
 * rather than negative horizontal margins. Negative margins would override the
 * block layout's `margin-inline: auto`, breaking the row's centering (it would be
 * pulled left and no longer line up with the section heading).
 */
.ploetner-speaking-row {
    position: relative;
    transition: background 0.2s ease;
    border-radius: 2px;
}

.ploetner-speaking-row::before {
    content: "";
    position: absolute;
    inset: 0 -0.75rem;
    border-radius: 2px;
    background: transparent;
    transition: background 0.2s ease;
    pointer-events: none;
    z-index: 0;
}

.ploetner-speaking-row > * {
    position: relative;
    z-index: 1;
}

.ploetner-speaking-row:hover::before {
    background: rgba(200, 255, 0, 0.05);
}

/* --- CTA Button hover --- */
.wp-block-button__link.has-accent-background-color {
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.wp-block-button__link.has-accent-background-color:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* --- Nav CTA button --- */
.ploetner-nav-cta .wp-block-button__link {
    font-family: var(--wp--preset--font-family--mono);
    font-size: var(--wp--preset--font-size--tiny) !important;
    padding: 0.4rem 1rem !important;
    border: 1px solid var(--wp--preset--color--accent);
    background: transparent !important;
    color: var(--wp--preset--color--accent) !important;
    transition: background 0.2s ease, color 0.2s ease;
}

.ploetner-nav-cta .wp-block-button__link:hover {
    background: var(--wp--preset--color--accent) !important;
    color: var(--wp--preset--color--base) !important;
}

/* --- Separator opacity fix --- */
.wp-block-separator {
    opacity: 1 !important;
}

/* --- Smooth scroll --- */
html {
    scroll-behavior: smooth;
}

/* --- Section label style (reusable) --- */
.ploetner-section-label {
    font-family: var(--wp--preset--font-family--mono);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

/* --- Accent mark (inline highlight) --- */
mark.has-inline-color.has-accent-color {
    background: transparent;
}

/* --- Footer links --- */
.ploetner-footer a {
    font-family: var(--wp--preset--font-family--mono);
    transition: color 0.2s ease;
}

.ploetner-footer a:hover {
    color: var(--wp--preset--color--accent) !important;
}

/* --- Mobile hamburger / overlay menu --- */
.ploetner-header .wp-block-navigation__responsive-container-open,
.ploetner-header .wp-block-navigation__responsive-container-close {
    color: var(--wp--preset--color--accent);
}

/* --- Responsive --- */
@media (max-width: 782px) {
    .ploetner-speaking-row .wp-block-columns {
        flex-direction: column !important;
        gap: 0.25rem !important;
    }
}
