/* ===========================================================
   DDO Reports — public styles
   Brand palette: #000, #C8A882, #fff, #F5EDE0 (cream)
   Fonts: Nunito 800 headings, DM Sans body
   =========================================================== */

/* v1.0.1 — iOS Safari tap responsiveness fix. cursor:pointer +
   tap-highlight + touch-action:manipulation resolve the iPhone
   "double-tap to activate" bug. */
.ddo-report-btn,
.ddo-report-close,
.ddo-report-cancel,
.ddo-report-submit,
.ddo-report-select,
.ddo-report-input,
.ddo-report-textarea,
.ddo-report-backdrop {
    cursor: pointer;
    -webkit-tap-highlight-color: rgba(200, 168, 130, 0.25);
    touch-action: manipulation;
}
.ddo-report-select,
.ddo-report-input,
.ddo-report-textarea {
    cursor: text;
}

/* ---- Button ---- */
/* v1.3.1 — Same theme (Hello Elementor) was repainting this button pink and
   adding a border. Force the intended discreet grey + raise specificity so it
   can't. Icon uses fill:currentColor, so forcing colour fixes it too. */
button.ddo-report-btn,
.ddo-report-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent !important;
    border: 0 !important;
    color: #777 !important;
    font-family: 'Nunito', sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.82rem;
    padding: 0.4rem 0.7rem;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none !important;
    text-transform: none !important;
    box-shadow: none !important;
    transition: color 0.15s ease, background 0.15s ease;
}
button.ddo-report-btn:hover,
button.ddo-report-btn:focus,
.ddo-report-btn:hover,
.ddo-report-btn:focus {
    color: #000 !important;
    background: #F5EDE0 !important;
    outline: none;
}
.ddo-report-btn:focus-visible {
    box-shadow: 0 0 0 2px rgba(200, 168, 130, 0.5) !important;
}
button.ddo-report-btn svg,
.ddo-report-btn svg,
.ddo-report-icon {
    fill: currentColor !important;
}
.ddo-report-icon {
    display: inline-block;
    vertical-align: -2px;
    color: #C8A882;
    flex-shrink: 0;
}

/* ---- Modal ---- */
.ddo-report-modal {
    position: fixed;
    inset: 0;
    z-index: 9998;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    font-family: 'DM Sans', system-ui, sans-serif;
}
.ddo-report-modal.is-open {
    display: flex;
}
body.ddo-report-modal-open {
    overflow: hidden;
}
.ddo-report-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    cursor: pointer;
    animation: ddoReportFadeIn 0.18s ease-out;
}
.ddo-report-sheet {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 1.75rem 1.5rem 1.25rem;
    max-width: 480px;
    width: 100%;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    animation: ddoReportSlideUp 0.22s ease-out;
}
@keyframes ddoReportFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes ddoReportSlideUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

.ddo-report-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: transparent !important;
    border: 0 !important;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.7rem;
    line-height: 1;
    color: #777 !important;
    box-shadow: none !important;
    transition: background 0.15s ease, color 0.15s ease;
}
.ddo-report-close:hover,
.ddo-report-close:focus {
    background: #F5EDE0;
    color: #000;
    outline: none;
}

.ddo-report-title {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 1.35rem;
    color: #000;
    margin: 0 0 0.4rem;
    line-height: 1.2;
}
.ddo-report-lede {
    font-size: 0.92rem;
    color: #555;
    margin: 0 0 1.25rem;
    line-height: 1.5;
}

/* ---- Form ---- */
.ddo-report-label {
    display: block;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    color: #000;
    margin: 0.85rem 0 0.35rem;
}
.ddo-report-label:first-of-type {
    margin-top: 0;
}
.ddo-report-select,
.ddo-report-input,
.ddo-report-textarea {
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border: 1.5px solid #e5e5e5;
    border-radius: 10px;
    padding: 0.7rem 0.85rem;
    font-family: inherit;
    font-size: 0.95rem;
    color: #000;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.ddo-report-select:focus,
.ddo-report-input:focus,
.ddo-report-textarea:focus {
    outline: none;
    border-color: #C8A882;
    box-shadow: 0 0 0 3px rgba(200, 168, 130, 0.18);
}
.ddo-report-select.is-invalid,
.ddo-report-input.is-invalid {
    border-color: #c44a4a;
    box-shadow: 0 0 0 3px rgba(196, 74, 74, 0.18);
}
.ddo-report-textarea {
    resize: vertical;
    min-height: 78px;
    font-family: 'DM Sans', system-ui, sans-serif;
}
.ddo-report-count {
    font-size: 0.75rem;
    color: #999;
    text-align: right;
    margin-top: 0.3rem;
}

/* Honeypot — invisible to humans */
.ddo-report-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
}

/* ---- Actions ---- */
.ddo-report-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 1.25rem;
    flex-wrap: wrap;
}
.ddo-report-cancel,
.ddo-report-submit {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 0.65rem 1.3rem;
    border-radius: 50px;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
button.ddo-report-cancel,
.ddo-report-cancel {
    background: transparent !important;
    color: #555 !important;
    border-color: #e5e5e5 !important;
}
.ddo-report-cancel:hover,
.ddo-report-cancel:focus {
    background: #F5EDE0;
    color: #000;
    border-color: #C8A882;
    outline: none;
}
button.ddo-report-submit,
.ddo-report-submit {
    background: #000 !important;
    color: #C8A882 !important;
    border-color: #000 !important;
}
.ddo-report-submit:hover,
.ddo-report-submit:focus {
    background: #C8A882;
    color: #000;
    border-color: #C8A882;
    outline: none;
}
.ddo-report-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ---- Error ---- */
.ddo-report-error {
    background: #fdecec;
    color: #c44a4a;
    border: 1px solid #f4c4c4;
    border-radius: 10px;
    padding: 0.65rem 0.9rem;
    font-size: 0.85rem;
    margin-top: 1rem;
}

/* ---- Success panel ---- */
.ddo-report-success {
    text-align: center;
    padding: 1rem 0 0.25rem;
}
.ddo-report-success-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #C8A882;
    color: #000;
    font-size: 2rem;
    font-weight: 800;
    line-height: 56px;
    margin: 0 auto 1rem;
    font-family: 'Nunito', sans-serif;
}
.ddo-report-success h3 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 1.2rem;
    color: #000;
    margin: 0 0 0.4rem;
}
.ddo-report-success p {
    color: #555;
    font-size: 0.92rem;
    margin: 0 0 1.25rem;
}
.ddo-report-success .ddo-report-cancel {
    display: inline-block;
}

/* ---- Mobile ---- */
@media (max-width: 520px) {
    .ddo-report-sheet {
        padding: 1.4rem 1.1rem 1rem;
        border-radius: 14px;
    }
    .ddo-report-title { font-size: 1.2rem; }
    .ddo-report-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }
    .ddo-report-cancel,
    .ddo-report-submit {
        width: 100%;
        text-align: center;
    }
}

/* ===========================================================
   v1.1.2 — Standalone /report-a-venue/ form
   Same brand palette as modal: black + #C8A882 + cream + white
   =========================================================== */

.ddo-report-standalone {
    max-width: 640px;
    margin: 0 auto;
    padding: 1rem;
    font-family: 'DM Sans', system-ui, sans-serif;
}

.ddo-report-standalone-inner {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    padding: 2rem 1.8rem 1.8rem;
}

.ddo-report-standalone-title {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 1.5rem;
    color: #000;
    margin: 0 0 0.5rem;
    line-height: 1.2;
}

.ddo-report-standalone-lede {
    color: #555;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0 0 1.5rem;
}

/* Search field */
.ddo-report-standalone-search-wrap {
    position: relative;
}

.ddo-report-standalone-search {
    width: 100%;
}

/* Search results dropdown */
.ddo-report-standalone-results {
    margin-top: 6px;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    background: #fff;
    max-height: 320px;
    overflow-y: auto;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.ddo-rs-result {
    display: flex;
    flex-direction: column;
    width: 100%;
    text-align: left;
    background: transparent;
    border: 0;
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.12s ease;
    font-family: inherit;
}

.ddo-rs-result:last-child { border-bottom: 0; }

.ddo-rs-result:hover,
.ddo-rs-result:focus {
    background: #F5EDE0;
    outline: none;
}

.ddo-rs-result-name {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 0.95rem;
    color: #000;
    line-height: 1.3;
}

.ddo-rs-result-meta {
    font-size: 0.8rem;
    color: #777;
    margin-top: 2px;
    text-transform: capitalize;
}

.ddo-rs-noresults {
    padding: 14px 16px;
    color: #777;
    font-size: 0.9rem;
    font-style: italic;
}

/* Selected venue chip */
.ddo-report-standalone-selected {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #F5EDE0;
    border: 1px solid #C8A882;
    border-radius: 12px;
    padding: 12px 14px;
    margin-bottom: 12px;
}

.ddo-report-standalone-selected-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.ddo-rs-selected-name {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: #000;
    font-size: 0.95rem;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ddo-rs-selected-meta {
    color: #555;
    font-size: 0.82rem;
    text-transform: capitalize;
}

.ddo-report-standalone-change {
    background: transparent;
    border: 1px solid #000;
    color: #000;
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 0.8rem;
    padding: 6px 14px;
    border-radius: 999px;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease, color 0.15s ease;
}

.ddo-report-standalone-change:hover {
    background: #000;
    color: #C8A882;
}

/* Not-listed entry button */
.ddo-report-standalone-notlisted {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: 0;
    color: #555;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.85rem;
    padding: 12px 0 0;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color 0.15s ease;
}

.ddo-report-standalone-notlisted:hover {
    color: #000;
}

.ddo-report-standalone-notlisted svg {
    color: #C8A882;
}

/* Success state */
.ddo-report-standalone-success {
    text-align: center;
    padding: 1rem 0;
}

.ddo-report-standalone-success .ddo-report-success-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 1rem;
    background: #C8A882;
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 800;
}

.ddo-report-standalone-success h3 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: #000;
    font-size: 1.2rem;
    margin: 0 0 0.5rem;
}

.ddo-report-standalone-success p {
    color: #555;
    font-size: 0.95rem;
    margin: 0 0 1.2rem;
    line-height: 1.5;
}

.ddo-rs-reset {
    width: auto !important;
}

/* Mobile */
@media (max-width: 520px) {
    .ddo-report-standalone {
        padding: 0.5rem;
    }
    .ddo-report-standalone-inner {
        padding: 1.4rem 1.2rem 1.2rem;
        border-radius: 12px;
    }
    .ddo-report-standalone-title {
        font-size: 1.25rem;
    }
    .ddo-report-standalone-selected {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    .ddo-report-standalone-change {
        width: 100%;
    }
}

/* ===========================================================
   v1.3.0 — Site-wide feedback tab
   The modal itself reuses the .ddo-report-modal / .ddo-report-sheet
   styles above; only the pinned launcher is new.
   =========================================================== */
/* v1.3.1 — Colours forced with !important + raised specificity because the
   active theme (Hello Elementor) was repainting the tab pink. Layout props
   stay non-important so the mobile overrides below still apply. */
button.ddo-feedback-tab,
.ddo-feedback-tab {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 9990;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: #000 !important;
    color: #C8A882 !important;
    border: 0 !important;
    border-radius: 12px 0 0 12px;
    cursor: pointer;
    font-family: 'Nunito', sans-serif !important;
    font-weight: 800 !important;
    font-size: 0.82rem;
    line-height: 1.1;
    letter-spacing: 0.02em;
    text-decoration: none !important;
    text-transform: none !important;
    padding: 0.7rem 0.85rem;
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.28);
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transition: background 0.15s ease, color 0.15s ease, padding 0.15s ease;
    -webkit-tap-highlight-color: rgba(200, 168, 130, 0.25);
    touch-action: manipulation;
}
button.ddo-feedback-tab svg,
.ddo-feedback-tab svg {
    transform: rotate(0deg);
    flex-shrink: 0;
    fill: currentColor !important;
}
button.ddo-feedback-tab:hover,
button.ddo-feedback-tab:focus,
.ddo-feedback-tab:hover,
.ddo-feedback-tab:focus {
    background: #C8A882 !important;
    color: #000 !important;
    padding-right: 1.1rem;
    outline: none;
}
.ddo-feedback-tab:focus-visible {
    box-shadow: 0 0 0 3px rgba(200, 168, 130, 0.5);
}
.ddo-feedback-tab-label { line-height: 1; }

/* v1.3.4 — On phones, switch to a round, icon-only chat bubble docked
   bottom-right so it never overlaps venue cards. Selectors match the main
   rule's specificity (button.x) and use !important so they win — the earlier
   .x-only mobile rule was being out-specified by button.ddo-feedback-tab. */
@media (max-width: 600px) {
    button.ddo-feedback-tab,
    .ddo-feedback-tab {
        top: auto !important;
        bottom: 18px !important;
        right: 16px !important;
        left: auto !important;
        transform: none !important;
        writing-mode: horizontal-tb !important;
        text-orientation: mixed !important;
        width: 52px !important;
        height: 52px !important;
        min-width: 0 !important;
        padding: 0 !important;
        gap: 0 !important;
        border-radius: 50% !important;
        justify-content: center !important;
        align-items: center !important;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.32) !important;
    }
    /* Icon only — hide the word on mobile. */
    button.ddo-feedback-tab .ddo-feedback-tab-label,
    .ddo-feedback-tab .ddo-feedback-tab-label {
        display: none !important;
    }
    button.ddo-feedback-tab svg,
    .ddo-feedback-tab svg {
        width: 22px !important;
        height: 22px !important;
    }
    /* Keep it a perfect circle on tap/focus (don't let the desktop hover
       padding-shift deform it); just lift the icon to gold-on-black. */
    button.ddo-feedback-tab:hover,
    button.ddo-feedback-tab:focus,
    .ddo-feedback-tab:hover,
    .ddo-feedback-tab:focus {
        padding: 0 !important;
        background: #000 !important;
        color: #C8A882 !important;
    }
}

/* Respect users who don't want the tab following them — the inline
   [ddo_feedback_button] shortcode still works. */
@media print {
    button.ddo-feedback-tab,
    .ddo-feedback-tab { display: none !important; }
}

/* ===========================================================
   v1.3.5 — Bottom-of-page feedback link
   Renders in the footer (not fixed). Discreet, centred, brand
   colours forced so the theme can't repaint it.
   =========================================================== */
.ddo-feedback-footer {
    width: 100%;
    text-align: center;
    padding: 1.4rem 1rem 1.8rem;
    box-sizing: border-box;
}
button.ddo-feedback-footer-link,
.ddo-feedback-footer-link {
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
    background: transparent !important;
    border: 1.5px solid #C8A882 !important;
    color: #000 !important;
    font-family: 'Nunito', sans-serif !important;
    font-weight: 700 !important;
    font-size: 0.9rem;
    line-height: 1.2;
    letter-spacing: 0.01em;
    text-decoration: none !important;
    text-transform: none !important;
    padding: 0.6rem 1.25rem !important;
    border-radius: 50px !important;
    cursor: pointer;
    box-shadow: none !important;
    transition: background 0.15s ease, color 0.15s ease;
}
button.ddo-feedback-footer-link svg,
.ddo-feedback-footer-link svg {
    fill: #C8A882 !important;
    flex-shrink: 0;
    transition: fill 0.15s ease;
}
button.ddo-feedback-footer-link:hover,
button.ddo-feedback-footer-link:focus,
.ddo-feedback-footer-link:hover,
.ddo-feedback-footer-link:focus {
    background: #000 !important;
    color: #C8A882 !important;
    outline: none;
}
.ddo-feedback-footer-link:hover svg,
.ddo-feedback-footer-link:focus svg {
    fill: #C8A882 !important;
}
.ddo-feedback-footer-link:focus-visible {
    box-shadow: 0 0 0 3px rgba(200, 168, 130, 0.5) !important;
}
@media print {
    .ddo-feedback-footer { display: none !important; }
}

/* ===========================================================
   v1.3.7 — The Woody day-planner panel uses very high z-indexes
   (up to 999999). The feedback modal can be opened from inside
   Woody (the in-chat bubble), so it must sit ABOVE the panel —
   otherwise it opens behind the chat and looks like nothing
   happened. The per-venue report modal is unaffected (it never
   opens over Woody).
   =========================================================== */
.ddo-feedback-modal,
#ddo-feedback-modal.ddo-report-modal {
    z-index: 1000001 !important;
}
