/*------------------------------------------------------------------*\
    5. Pages - Contact
    Page 49 "Contactos" — design rb_contacts.png
    Mobile-first. Colours/typography driven by theme tokens
    (vars.css). No styling lives on the Elementor widgets.
\*------------------------------------------------------------------*/

/* Local mapping of the mockup colour bands onto the neutral scale.
   Kept page-scoped: these two flat bands are specific to this page. */
.c-contact-intro {
    --contact-band-light: #EDEDED;
    --contact-band-form: #C9C9C9;
}
.c-contact-form-section {
    --contact-band-form: #C9C9C9;
}

/* ==========================================================================
   SECTION 1 — CONTACT INFO (light band)
   ========================================================================== */

.c-contact-intro {
    background-color: var(--contact-band-light);
}

.c-contact-intro__inner {
    width: 100%;
}

.elementor-kit-6 .c-contact-intro__title .elementor-heading-title {
    color: var(--color-title);
    margin: 0;
}

.elementor-kit-6 .c-contact-intro__lead {
    max-width: 46ch;
}

.elementor-kit-6 .c-contact-intro__lead p {
    color: var(--color-title);
    margin: 0;
}

/* ── Contact cards ── */

.c-contact-cards {
    margin-top: 2.5rem;
    /* mobile-first: stack; switch to a row on tablet+.
       Override Elementor's flex custom props, not the raw property. */
    --flex-direction: column;
    --gap: 1.75rem;
    --row-gap: 1.75rem;
    --column-gap: 1.75rem;
}

.c-contact-card {
    flex: 1 1 0;
}

.c-contact-card__icon {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    padding: 0;
    --padding-block-start: 0px;
    --padding-block-end: 0px;
    --padding-inline-start: 0px;
    --padding-inline-end: 0px;
    background-color: var(--neutral-800);   /* #1c1c1c */
    border-radius: 10px;
}

.c-contact-card__icon .elementor-icon,
.c-contact-card__icon i,
.c-contact-card__icon svg {
    color: var(--neutral-0);
    fill: var(--neutral-0);
    font-size: 17px;
    width: 17px;
    height: 17px;
}

.elementor-kit-6 .c-contact-card__label .elementor-heading-title {
    color: var(--color-title);
    font-size: var(--fluid-label) !important;
    font-weight: var(--font-bold) !important;
    line-height: 1.3 !important;
    margin: 0;
}

.elementor-kit-6 .c-contact-card__value p {
    color: var(--neutral-500);
    font-size: var(--fluid-label) !important;
    line-height: 1.4 !important;
    margin: 0;
}

@media screen and (min-width: 768px) {
    .c-contact-cards {
        --flex-direction: row;
        --gap: 3rem;
        --row-gap: 3rem;
        --column-gap: 3rem;
        margin-top: 3rem;
    }
}

/* ==========================================================================
   SECTION 2 — MESSAGE FORM (grey band)
   ========================================================================== */

.c-contact-form-section {
    background-color: var(--contact-band-form);
}

.c-contact-form-section__inner {
    width: 100%;
}

.elementor-kit-6 .c-contact-form-section__title .elementor-heading-title,
.elementor-kit-6 .c-contact-form-section__title h4.elementor-heading-title {
    color: var(--neutral-900);          /* #0E0E0E — mais escuro, conforme o design */
    font-weight: var(--font-bold) !important;
    margin: 0;
}

/* ── Form layout ── */

#form_contacto .elementor-field-group .elementor-field-label {
    color: var(--color-title);
    font-size: var(--fluid-label) !important;
    font-weight: var(--font-medium);
    margin-bottom: 8px;
    padding: 0;
}

/* Inputs, select, textarea — clean fields inside the glass panel */
#form_contacto .elementor-field-group input:not([type="submit"]),
#form_contacto .elementor-field-group textarea,
#form_contacto .elementor-field-group select {
    width: 100%;
    background-color: #2C3D310D;
    border: 1px solid rgba(44, 61, 49, 0.12);
    border-radius: var(--input-radius);
    padding: 16px 16px;
    font-family: var(--font-primary);
    font-size: var(--fluid-label) !important;
    line-height: 1.4;
    box-shadow: none;
}

#form_contacto .elementor-field-group textarea {
    min-height: 150px;
    resize: vertical;
}

#form_contacto .elementor-field-group input::placeholder,
#form_contacto .elementor-field-group textarea::placeholder {
    color: var(--neutral-400);
    opacity: 1;
}

/* Select — custom chevron, hide native arrow */
#form_contacto .elementor-field-type-select .elementor-select-wrapper select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23303030' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 14px;
    padding-right: 40px;
}

#form_contacto .elementor-select-wrapper .select-caret-down-wrapper {
    display: none;
}

/* Focus state */
#form_contacto .elementor-field-group input:not([type="submit"]):focus,
#form_contacto .elementor-field-group textarea:focus,
#form_contacto .elementor-field-group select:focus {
    outline: none;
    border-color: var(--color-title);
    box-shadow: 0 0 0 1px var(--color-title);
}

/* ── Submit button — full-width dark bar ── */

#form_contacto .elementor-field-type-submit {
    padding: 0 15px;
    margin-top: 6px;
}

#form_contacto .elementor-button {
    width: 100%;
    justify-content: center;
    background-color: var(--neutral-800);   /* #1c1c1c */
    color: var(--neutral-0);
    border: none;
    border-radius: var(--input-radius);
    padding: 18px 24px;
    font-family: var(--font-primary);
    font-size: var(--fluid-label);
    font-weight: var(--font-semibold);
    letter-spacing: 0.01em;
    transition: var(--transition-base);
}

#form_contacto .elementor-button:hover,
#form_contacto .elementor-button:focus {
    background-color: var(--neutral-950);   /* #000 */
}

/* ── Validation / system messages ── */

#form_contacto .elementor-message {
    font-family: var(--font-primary);
    font-size: var(--fluid-label);
    margin-top: 16px;
}

/* ==========================================================================
   DARK MODE — Contact form (modern, project-aligned)
   Reference: shadcn/ui dark form pattern. No pure black:
     • Section becomes a soft dark "card" (#1A1A1A), not pitch black.
     • Inputs are translucent white (rgba 0.06) with a subtle 1px border
       (rgba 0.10) — light, refined, no heaviness.
     • Title white; labels muted; submit inverts to a light pill with
       dark label (per the "no green / invert #303030" rule).
   ========================================================================== */

[data-theme="dark"] .c-contact-form-section,
[data-theme="dark"] .c-contact-form-section.e-con,
[data-theme="dark"] .c-contact-form-section .e-con,
[data-theme="dark"] .c-contact-form-section .e-con-inner {
    background-color: #303030 !important;   /* Figma dark bg */
    color: inherit !important;
}

[data-theme="dark"] .c-contact-form-section__title .elementor-heading-title,
[data-theme="dark"] .c-contact-form-section__title h4.elementor-heading-title {
    color: #ffffff !important;
}

[data-theme="dark"] #form_contacto .elementor-field-group .elementor-field-label {
    color: rgba(255, 255, 255, 0.62) !important;
    font-weight: var(--font-medium) !important;
}

/* ── Light, modern inputs: translucent surface + subtle rim ── */
[data-theme="dark"] #form_contacto .elementor-field-group input:not([type="submit"]),
[data-theme="dark"] #form_contacto .elementor-field-group textarea,
[data-theme="dark"] #form_contacto .elementor-field-group select {
    background-color: rgba(255, 255, 255, 0.06) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.10) !important;
    border-radius: 10px !important;
    padding: 14px 16px !important;
    box-shadow: none !important;
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
[data-theme="dark"] #form_contacto .elementor-field-group input::placeholder,
[data-theme="dark"] #form_contacto .elementor-field-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.38) !important;
}

/* Hover — barely-there lift on the surface. */
[data-theme="dark"] #form_contacto .elementor-field-group input:not([type="submit"]):hover,
[data-theme="dark"] #form_contacto .elementor-field-group textarea:hover,
[data-theme="dark"] #form_contacto .elementor-field-group select:hover {
    background-color: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.16) !important;
}

/* Focus — soft, neutral ring (no green). */
[data-theme="dark"] #form_contacto .elementor-field-group input:not([type="submit"]):focus,
[data-theme="dark"] #form_contacto .elementor-field-group textarea:focus,
[data-theme="dark"] #form_contacto .elementor-field-group select:focus {
    outline: none !important;
    background-color: rgba(255, 255, 255, 0.10) !important;
    border-color: rgba(255, 255, 255, 0.45) !important;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08) !important;
}

/* Select chevron → white. */
[data-theme="dark"] #form_contacto .elementor-field-type-select .elementor-select-wrapper select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
}
/* Native dropdown panel inherits OS dark via color-scheme (vars.css). */

/* ── Submit — inverted pill (light surface, dark label). No green. ── */
[data-theme="dark"] #form_contacto .elementor-button {
    background-color: #EDEDED !important;
    color: #303030 !important;
    border: 0 !important;
    border-radius: 10px !important;
    padding: 18px 24px !important;
    font-weight: var(--font-semibold) !important;
    transition: background-color 0.2s ease, transform 0.2s ease;
}
[data-theme="dark"] #form_contacto .elementor-button:hover {
    background-color: #ffffff !important;
}
[data-theme="dark"] #form_contacto .elementor-button:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.6) !important;
    outline-offset: 3px;
}

/* ==========================================================================
   .rb-contact-hero — section overrides (kept light even in dark mode).
   Scoped under .rb-contact-hero so the rules win over the generic dark
   surfaces (and explicitly cover the inner .e-con / .e-con-inner).
   ========================================================================== */

.rb-contact-hero,
.rb-contact-hero.e-con,
.rb-contact-hero .e-con,
.rb-contact-hero .e-con-inner,
[data-theme="dark"] .rb-contact-hero,
[data-theme="dark"] .rb-contact-hero.e-con,
[data-theme="dark"] .rb-contact-hero .e-con,
[data-theme="dark"] .rb-contact-hero .e-con-inner {
    background-color: #EDEDED !important;
    color: inherit !important;
}

/* Title — strong dark heading on the light band. */
.rb-contact-hero .c-contact-intro__title .elementor-heading-title,
[data-theme="dark"] .rb-contact-hero .c-contact-intro__title .elementor-heading-title {
    color: #303030 !important;
}

/* Lead description — dark on the light band. */
.rb-contact-hero .c-contact-intro__lead p,
[data-theme="dark"] .rb-contact-hero .c-contact-intro__lead p {
    color: #303030 !important;
}

/* Icon-box title + description — dark over light band. */
.rb-contact-hero .elementor-icon-box-title,
.rb-contact-hero .elementor-icon-box-description,
[data-theme="dark"] .rb-contact-hero .elementor-icon-box-title,
[data-theme="dark"] .rb-contact-hero .elementor-icon-box-description {
    color: #303030 !important;
}

/* ==========================================================================
   .rb-header — only on the Contactos page (.page-id-49): logo + menu
   stay dark over the light .rb-contact-hero band, in both themes.
   ========================================================================== */

/* Logo: force solid dark while the header is NOT sticky (over the
   light .rb-contact-hero band). When sticky, fall back to the global
   header rules (dark bg in dark → white logo, etc.). */
body.page-id-49 .she-header.rb-header .rb-logo img {
    filter: brightness(0) !important;
}

/* Sticky on the Contactos page → logo white (both themes). */
body.page-id-49 .rb-header .rb-logo img {
    filter: brightness(0) !important;
}

/* Main nav items dark only in non-sticky state. */
body.page-id-49 .rb-header .elementor-nav-menu--main .elementor-item {
    color: #303030 !important;
}

body.page-id-49 .rb-header .e-off-canvas__main .elementor-nav-menu--main .elementor-item {
    color: #fff !important;
}

body.page-id-49 .rb-header .elementor-icon svg {
    stroke: #303030 !important;
}

body.page-id-49 .rb-header .e-off-canvas__main .elementor-icon svg {
    stroke: var(--neutral-100) !important;
}
