.fddm-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.fddm-popup-overlay.is-visible {
    opacity: 1 !important;
    visibility: visible !important;
}

.fddm-popup-container {
    background: #fff;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    position: relative;
    padding: 30px;
    animation: fddmPopupSlideIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes fddmPopupSlideIn {
    from {
        transform: translateY(50px) scale(0.9);
        opacity: 0;
    }

    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.fddm-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
    color: #333;
    /* Dark color for visibility on white background */
    transition: color 0.2s;
    z-index: 10;
}

.fddm-popup-close:hover {
    color: #000;
}

.fddm-popup-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 20px;
    color: #222;
}

.fddm-popup-body {
    font-size: 16px;
    line-height: 1.6;
    color: #444;
}

.fddm-popup-body img {
    max-width: 100%;
    height: auto;
}

/* ======================================
   PUBLIC NOTICES — Premium Cards Banner
   ====================================== */

/* Banner Container */
.fddm-pn-banner {
    width: 100%;
    padding: 24px 20px;
    box-sizing: border-box;
}

.fddm-pn {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

/* Empty State */
.fddm-pn-empty {
    text-align: center;
    padding: 32px 20px;
    color: #6b7280;
}

.fddm-pn-empty-actions {
    margin-top: 14px;
    display: flex;
    justify-content: center;
}

.fddm-pn-empty-icon {
    color: #d1d5db;
    margin-bottom: 12px;
}

.fddm-pn-empty-text {
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
    color: #6b7280;
}

/* Card Grid — two columns on desktop, one on mobile (see @media below) */
.fddm-pn-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.fddm-pn-cards-grid--stacked {
    grid-template-columns: repeat(2, 1fr);
    max-width: 760px;
}

/* Individual Card */
.fddm-pn-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    position: relative;
}

.fddm-pn-card-inner {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 14px;
    padding: 16px 18px 16px;
}

.fddm-pn-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08), 0 4px 10px rgba(0, 0, 0, 0.05);
}

/* Red Accent Bar */
.fddm-pn-card-accent {
    height: 4px;
    background: linear-gradient(90deg, #b91c1c, #dc2626);
    flex-shrink: 0;
}

/* Mobile Toggle (hidden on desktop) */
.fddm-pn-card-mobile-toggle {
    display: none;
}

/* Card Body */
.fddm-pn-card-body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* Card Header */
.fddm-pn-card-header {
    padding: 0;
}

.fddm-pn-card-topline {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.fddm-pn-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #0f172a;
    background: #e2e8f0;
    white-space: nowrap;
}

.fddm-pn-card-title {
    margin: 0 0 6px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f2937;
    line-height: 1.35;
    letter-spacing: -0.01em;
}

.fddm-pn-card-dates {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    text-align: right;
    min-width: 0;
}

.fddm-pn-card-date {
    display: block;
    font-size: 0.78rem;
    color: #9ca3af;
    font-weight: 500;
    letter-spacing: 0.02em;
    line-height: 1.35;
}

.fddm-pn-card-date--archive {
    color: #94a3b8;
}

/* Card Content */
.fddm-pn-card-content {
    padding: 0;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.fddm-pn-actions {
    display: flex;
    align-items: stretch;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: auto;
}

.fddm-pn-actions > a.fddm-pn-view-btn,
.fddm-pn-actions > button.fddm-pn-view-btn {
    appearance: none;
    -webkit-appearance: none;
    box-sizing: border-box;
    align-self: stretch;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    min-height: 38px;
    height: auto;
    padding: 8px 18px;
    border: 0;
    border-radius: 6px;
    line-height: 1.2;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    vertical-align: middle;
}

.fddm-pn-card-text {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #4b5563;
    margin-bottom: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.fddm-pn-card-doc-label {
    font-size: 0.88rem;
    color: #6b7280;
    margin: 0 0 14px;
    font-style: italic;
}

/* View Button */
.fddm-pn-view-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: linear-gradient(135deg, #b91c1c, #991b1b);
    color: #ffffff !important;
    border: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    margin-top: auto;
    align-self: flex-start;
}

.fddm-pn-view-btn--secondary {
    background: #1e3a8a;
}

.fddm-pn-view-btn--secondary:hover {
    background: #1e40af;
    box-shadow: 0 2px 8px rgba(30, 58, 138, 0.25);
}

.fddm-pn-view-btn:hover {
    background: linear-gradient(135deg, #991b1b, #7f1d1d);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(185, 28, 28, 0.3);
}

.fddm-pn-view-btn:active {
    transform: translateY(0);
}

.fddm-pn-view-btn svg {
    flex-shrink: 0;
}

/* Date block (screenshot-like) */
.fddm-pn-date-block {
    width: 84px;
    flex: 0 0 84px;
    border-radius: 10px;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    padding: 10px 10px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.fddm-pn-date-md {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
}

.fddm-pn-date-month {
    font-size: 0.8rem;
    font-weight: 800;
    color: #64748b;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.fddm-pn-date-day {
    font-size: 1.7rem;
    font-weight: 900;
    color: #0f172a;
}

.fddm-pn-date-year {
    margin-top: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #64748b;
}

.fddm-pn-date-archived {
    margin-top: 8px;
    font-size: 0.62rem;
    font-weight: 600;
    color: #94a3b8;
    line-height: 1.25;
}

/* Banner Footer */
.fddm-pn-banner-footer {
    text-align: center;
    margin-top: 16px;
}

.fddm-pn-archive-link {
    font-size: 0.88rem;
    font-weight: 600;
    color: #b91c1c;
    text-decoration: none;
    transition: color 0.2s;
}

.fddm-pn-archive-link:hover {
    color: #7f1d1d;
    text-decoration: underline;
}

/* ======================================
   PUBLIC NOTICES — Full Notice Modal
   ====================================== */
.fddm-pn-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(2px);
}

.fddm-pn-modal {
    background: #fff;
    border-radius: 12px;
    max-width: 680px;
    width: 100%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.fddm-pn-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
    background: #e60000;
    border-bottom: none;
    position: relative;
}

.fddm-pn-modal-title {
    margin: 0;
    padding: 20px 24px 6px;
    font-size: 1.15rem;
    font-weight: 700;
    color: #ffffff;
    text-transform: none;
    letter-spacing: normal;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

.fddm-pn-modal-date {
    display: block;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    padding: 0 24px 16px;
    line-height: 1.4;
}

.fddm-pn-modal-close {
    background: none;
    border: none;
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.fddm-pn-modal-close:hover {
    color: #ffffff;
    transform: scale(1.1);
}

.fddm-pn-modal-body {
    padding: 24px;
    overflow-y: auto;
    font-size: 0.95rem;
    line-height: 1.7;
    color: #374151;
}

.fddm-pn-empty-text {
    margin: 0;
    font-size: 1rem;
    font-weight: 500;
}

.fddm-pn-widget-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #e60000;
    color: #ffffff;
    margin-bottom: 24px;
    padding: 12px 20px;
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 4px 4px 0 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.fddm-pn-header-archive-link {
    color: #ffffff !important;
    text-decoration: none;
    font-size: 0.75rem;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 10px;
    border-radius: 4px;
    transition: background 0.2s;
    text-transform: none;
    letter-spacing: normal;
}

.fddm-pn-header-archive-link:hover {
    background: rgba(255, 255, 255, 0.25);
    text-decoration: none;
}

.fddm-pn-widget-heading span {
    position: relative;
    padding-left: 0;
}

.fddm-pn-widget-heading span::before {
    display: none;
}

/* ======================================
   CARD GRID LAYOUT
   ====================================== */
/* ======================================
   MOBILE RESPONSIVE
   ====================================== */
@media (max-width: 768px) {
    .fddm-pn-cards-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    /* Mobile: Show toggle button, hide card body by default */
    .fddm-pn-card-mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 14px 16px;
        background: none;
        border: none;
        cursor: pointer;
        text-align: left;
        font-size: 0;
    }

    .fddm-pn-card-mobile-title {
        font-size: 0.95rem;
        font-weight: 700;
        color: #1f2937;
    }

    .fddm-pn-chevron {
        color: #9ca3af;
        transition: transform 0.25s ease;
        flex-shrink: 0;
    }

    .fddm-pn-card-mobile-toggle[aria-expanded="true"] .fddm-pn-chevron {
        transform: rotate(180deg);
    }

    .fddm-pn-card-body {
        display: none;
        border-top: 1px solid #f3f4f6;
    }

    .fddm-pn-card-body.fddm-pn-mobile-open {
        display: flex;
    }

    .fddm-pn-card:hover {
        transform: none;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    }

    .fddm-pn-modal {
        max-height: 90vh;
        border-radius: 8px;
    }

    .fddm-pn-modal-body {
        padding: 16px;
    }

    .fddm-pn-card-inner {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 14px 14px 16px;
    }

    .fddm-pn-date-block {
        width: 100%;
        flex: none;
        flex-direction: row;
        justify-content: flex-start;
        gap: 12px;
        padding: 10px 12px;
        text-align: left;
    }

    .fddm-pn-date-md {
        flex-direction: row;
        gap: 10px;
        align-items: baseline;
    }

    .fddm-pn-date-day {
        font-size: 1.35rem;
    }

    .fddm-pn--archive .fddm-pn-date-block {
        flex-wrap: wrap;
    }

    .fddm-pn--archive .fddm-pn-date-archived {
        flex-basis: 100%;
        margin-top: 4px;
        text-align: left;
    }
}

/* Compact vs large modifiers */
.fddm-pn--small .fddm-pn-cards-grid {
    gap: 12px;
}

.fddm-pn--small .fddm-pn-card-inner {
    padding: 14px 14px 14px;
}

.fddm-pn--small .fddm-pn-date-block {
    width: 72px;
    flex-basis: 72px;
}

.fddm-pn--small .fddm-pn-card-title {
    font-size: 1rem;
}

.fddm-pn--small .fddm-pn-card-text {
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.fddm-pn--small .fddm-pn-card-topline {
    flex-wrap: wrap;
    align-items: flex-start;
}

.fddm-pn--small .fddm-pn-card-dates {
    align-items: flex-start;
    text-align: left;
    width: 100%;
}

.fddm-pn--small .fddm-pn-card-date {
    font-size: 0.72rem;
}

.fddm-pn--large .fddm-pn-card-inner {
    padding: 18px 20px 18px;
}

.fddm-pn--large .fddm-pn-date-block {
    width: 92px;
    flex-basis: 92px;
}

.fddm-pn--archive.fddm-pn--large .fddm-pn-date-block {
    width: 96px;
    flex-basis: 96px;
}

.fddm-pn--large .fddm-pn-card-title {
    font-size: 1.12rem;
}

/* Archive sections */
.fddm-pn-archive-topbar {
    display: flex;
    justify-content: flex-end;
    margin: 0 0 14px;
}

.fddm-pn-archive-year {
    margin: 18px 0 28px;
}

.fddm-pn-archive-year-title {
    margin: 0 0 12px;
    font-size: 1.4rem;
    font-weight: 800;
    color: #111827;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 10px;
}

.fddm-pn-archive-month {
    margin: 16px 0 26px;
}

.fddm-pn-archive-month-title {
    margin: 0 0 10px;
    font-size: 1.05rem;
    font-weight: 800;
    color: #374151;
}

.fddm-pn--archive .fddm-pn-card-accent {
    background: linear-gradient(90deg, #334155, #64748b);
}

/* Accessibility Utilities */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.fddm-notice-content-wrapper {
    max-height: 150px;
    /* Approx 6 lines */
    overflow: hidden;
    position: relative;
    transition: max-height 0.5s ease;
    margin-bottom: 10px;
}

.fddm-notice-content-wrapper.expanded {
    max-height: 2000px;
    /* Arbitrary large height for transition */
}

.fddm-notice-content-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(transparent, #fff);
    pointer-events: none;
    transition: opacity 0.3s;
}

.fddm-notice-content-wrapper.expanded::after {
    opacity: 0;
}

.fddm-notice-expand {
    text-align: center;
    margin-top: auto;
}

.fddm-expand-btn {
    background: none;
    border: none;
    color: #007cba;
    cursor: pointer;
    font-size: 0.9em;
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
}

.fddm-expand-btn:hover {
    text-decoration: underline;
}

.fddm-expand-btn .dashicons {
    margin-left: 5px;
    transition: transform 0.3s;
}

.fddm-expand-btn.expanded .dashicons {
    transform: rotate(180deg);
}

/* Public Notices - Archive */
.fddm-notice-archive {
    margin-top: 20px;
}

.fddm-archive-year h2 {
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.fddm-archive-month {
    margin-left: 20px;
    margin-bottom: 30px;
}

.fddm-archive-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fddm-archive-item {
    border-bottom: 1px solid #eee;
    padding: 10px 0;
}

.fddm-archive-header {
    display: flex;
    align-items: center;
    gap: 15px;
}

.fddm-archive-date {
    color: #777;
    font-size: 0.9em;
    min-width: 60px;
}

.fddm-archive-title {
    font-weight: 500;
    flex-grow: 1;
}

.fddm-archive-toggle {
    background: #f0f0f1;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 4px 10px;
    cursor: pointer;
    font-size: 0.8em;
}

.fddm-archive-toggle:hover {
    background: #e5e5e5;
}

.fddm-archive-content {
    padding: 15px;
    background: #f9f9f9;
    margin-top: 10px;
    border-radius: 4px;
}

/* Header Modals */
.fddm-header-modal-content {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fddm-header-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(2px);
}

.fddm-header-modal-body {
    background: #fff;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 0;
    padding: 0;
    position: relative;
    z-index: 100001;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    border: 3px solid #e60000;
}

.fddm-header-modal-body h3 {
    margin: 0;
    padding: 20px 24px;
    background: #e60000;
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: normal;
    border-bottom: none;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

.fddm-header-modal-body .fddm-notice-text {
    padding: 32px 28px;
    font-size: 16px;
    line-height: 1.6;
    color: #1f2937;
    font-family: Georgia, "Times New Roman", serif;
}

.fddm-header-modal-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: none;
    border: none;
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
    z-index: 10;
}

.fddm-header-modal-close:hover {
    color: #ffffff;
    transform: scale(1.1);
}


/* Global Search Styles */
.fddm-global-search {
    margin-bottom: 20px;
}

.fddm-search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.fddm-search-box input {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.fddm-search-result-item {
    display: flex;
    align-items: center;
    background: #fff;
    border: 1px solid #eee;
    padding: 10px;
    margin-bottom: 5px;
    border-radius: 4px;
}

.fddm-result-icon {
    font-size: 24px;
    color: #cc0000;
    margin-right: 15px;
}

.fddm-result-details {
    flex: 1;
}

.fddm-result-title {
    font-weight: bold;
    text-decoration: none;
    color: #333;
}

.fddm-result-meta {
    font-size: 0.85em;
    color: #777;
    margin-top: 3px;
}

.fddm-result-action .button {
    font-size: 0.85em;
}

/* Filter Styles */
.fddm-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    background: #f9f9f9;
    padding: 15px;
    border-radius: 4px;
    align-items: center;
}

.fddm-filter-group {
    flex: 1;
    min-width: 200px;
}

.fddm-filters select {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    width: 100%;
}

.fddm-filter-subscribe {
    display: flex;
    align-items: center;
}

.fddm-subscribe-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #b08d57;
    font-weight: 500;
    white-space: nowrap;
    line-height: 1;
}

.fddm-subscribe-link:hover {
    text-decoration: underline;
}

.fddm-subscribe-link .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
    margin: 0;
    line-height: 1;
}

@media screen and (max-width: 768px) {
    .fddm-filter-subscribe {
        margin-left: 0 !important;
        width: 100%;
        text-align: center;
        justify-content: center;
    }
}

/* Proof of Publication Styles */
.fddm-proof-link-wrap {
    margin-top: 5px;
    font-size: 0.9em;
}

.fddm-proof-link {
    color: #444;
    text-decoration: underline;
}

.fddm-proof-link:hover {
    color: #000;
}

/* PDF Viewer Enhancements */
.fddm-viewer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.fddm-viewer-header .fddm-proof-btn {
    display: inline-block;
    padding: 6px 12px;
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    transition: background 0.2s;
}

.fddm-viewer-header .fddm-proof-btn:hover {
    background: #005a87;
    color: #fff;
}

/* PDF Modal Styles */
.fddm-pdf-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999999 !important;
    /* Extremely high to override WordPress admin bar */
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.fddm-pdf-modal.is-visible {
    opacity: 1;
    visibility: visible;
}

.fddm-pdf-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(2px);
    z-index: 9999999 !important;
    /* Match parent to ensure overlay appears correctly */
}

.fddm-pdf-modal-container {
    background: #fff;
    width: 85vw;
    max-width: 85vw;
    height: 90vh;
    display: flex;
    flex-direction: column;
    border-radius: 0;
    border: 3px solid #cc0000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    z-index: 10000000 !important;
    /* Above overlay to ensure proper stacking */
    position: relative;
}

.fddm-pdf-modal-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
    border-bottom: none;
    background: #e60000;
}

.fddm-pdf-modal-title {
    margin: 0;
    padding: 20px 24px;
    background: transparent;
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: normal;
    border-bottom: none;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
    display: block;
    text-align: left;
}

.fddm-pdf-modal-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: none;
    border: none;
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
    z-index: 10;
}

.fddm-pdf-modal-close:hover {
    color: #ffffff;
    transform: scale(1.1);
}

.fddm-pdf-modal-content {
    flex: 1;
    position: relative;
    background: #eee;
}

.fddm-split-layout {
    display: flex;
    flex-direction: row;
    height: 100%;
    width: 100%;
    overflow: hidden;
}

.fddm-pdf-pane {
    flex: 1;
    height: 100%;
    position: relative;
    background: #eee;
    min-height: 0; /* Add min-height constraint for flexbox */
}

.fddm-proof-pane {
    flex: 0 0 min(42vw, 520px);
    width: min(42vw, 520px);
    min-width: 260px;
    max-width: 50vw;
    height: 100%;
    background: #fdfdfd;
    border-left: 1px solid #ccc;
    padding: 16px 14px;
    box-sizing: border-box;
    overflow-y: auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

.fddm-proof-meta {
    margin: 0 0 10px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.fddm-proof-id-label {
    display: inline-block;
    margin-right: 6px;
    color: #444;
}

.fddm-proof-hint {
    margin: 0 0 10px;
    font-size: 0.8rem;
    color: #555;
}

.fddm-proof-image-container {
    margin-bottom: 10px;
}

.fddm-proof-thumb-btn {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
    cursor: zoom-in;
    border-radius: 2px;
    line-height: 0;
}

.fddm-proof-thumb-btn:focus-visible {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

.fddm-proof-thumb {
    width: 100%;
    height: auto;
    display: block;
    border: 1px solid #ccc;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.fddm-proof-external-wrap {
    margin: 0;
    font-size: 0.85rem;
}

.fddm-proof-newtab {
    color: #0073aa;
    text-decoration: underline;
}

.fddm-proof-newtab:hover {
    color: #005a87;
}

.fddm-proof-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 10000005;
    align-items: center;
    justify-content: center;
    padding: 2vh 2vw;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.9);
}

.fddm-proof-lightbox.is-visible {
    display: flex;
}

.fddm-proof-lightbox-img {
    max-width: 96vw;
    max-height: 92vh;
    width: auto;
    height: auto;
    object-fit: contain;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.45);
}

.fddm-proof-lightbox-close {
    position: absolute;
    top: 16px;
    right: 20px;
    z-index: 2;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 4px;
    font-size: 1.75rem;
    line-height: 1;
    padding: 6px 14px;
    cursor: pointer;
    color: #222;
}

.fddm-proof-lightbox-close:hover {
    background: #fff;
}

/* Mobile: proof prompt after PDF opens in new tab */
.fddm-mobile-proof-interstitial {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999998;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;
}

.fddm-mobile-proof-interstitial.is-visible {
    display: flex;
}

.fddm-mobile-proof-interstitial-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}

.fddm-mobile-proof-interstitial-panel {
    position: relative;
    z-index: 1;
    max-width: 420px;
    width: 100%;
    background: #fff;
    padding: 20px 22px;
    border-radius: 6px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.28);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

.fddm-mobile-proof-interstitial-docname {
    margin: 0 0 12px;
    font-size: 1.05rem;
    line-height: 1.35;
    color: #1a1a1a;
}

.fddm-mobile-proof-interstitial-text {
    margin: 0 0 16px;
    font-size: 0.95rem;
    line-height: 1.45;
    color: #333;
}

.fddm-mobile-proof-interstitial-actions {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.fddm-pdf-modal-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    border: none;
}

@media screen and (max-width: 768px) {
    .fddm-split-layout {
        flex-direction: column;
    }
    .fddm-pdf-pane {
        height: 65vh;
        flex: none;
    }
    .fddm-proof-pane {
        width: 100%;
        max-width: 100%;
        flex: 1 1 auto;
        height: auto;
        border-left: none;
        border-top: 1px solid #ccc;
    }
}

/* Action Icons */
.fddm-action-icons {
    white-space: nowrap;
    min-width: 100px;
}

.fddm-action-btn {
    display: inline-block;
    color: #666;
    margin-right: 8px;
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    font-size: 16px;
    /* Dashicon size base */
    line-height: 1;
    transition: color 0.2s;
}

.fddm-action-btn:hover {
    color: #0073aa;
}

.fddm-action-btn .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* Modal Link Trigger */
.fddm-pdf-modal-trigger {
    cursor: pointer;
}

/* Subscribe Modal Extensions */
#fddm-modal-title {
    margin: 0;
    padding: 20px 24px;
    background: #e60000;
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 3px solid #e60000;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
    display: block;
    text-align: left;
}

#fddm-subscribe-modal-body {
    padding: 32px 28px;
    font-size: 16px;
    line-height: 1.6;
    color: #1f2937;
    font-family: Georgia, "Times New Roman", serif;
    max-height: 70vh;
    overflow-y: auto;
}
/* Small Signup (Footer) Styles */
.fddm-smallsignup-wrapper {
    background: #f8f8f8;
    padding: 20px 20px;
    font-family: inherit;
    border-top: 1px solid #eee;
}

.fddm-smallsignup-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
}

.fddm-smallsignup-intro {
    flex: 1;
}

.fddm-smallsignup-title {
    margin: 0 0 5px 0;
    font-size: 28px;
    font-weight: 700;
    color: #2b3a4a;
}

.fddm-smallsignup-subtext {
    margin: 0;
    color: #666;
    font-size: 16px;
}

.fddm-smallsignup-action-area {
    flex: 1.5;
    max-width: 600px;
}

.fddm-smallsignup-input-group {
    display: flex;
    align-items: center;
    border-bottom: 2px solid #2b3a4a;
    margin-bottom: 8px;
    padding-bottom: 2px;
}

.fddm-smallsignup-input {
    flex: 1;
    border: none !important;
    background: transparent !important;
    padding: 4px 0 !important;
    font-size: 18px !important;
    color: #333 !important;
    outline: none !important;
    box-shadow: none !important;
}

.fddm-smallsignup-submit-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #2b3a4a;
    padding: 0 10px;
    display: flex;
    align-items: center;
    transition: transform 0.2s ease;
}

.fddm-smallsignup-submit-btn:hover {
    transform: translateX(5px);
}

.fddm-smallsignup-submit-btn .dashicons {
    font-size: 22px;
    width: 22px;
    height: 22px;
}

.fddm-smallsignup-categories-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.fddm-smallsignup-categories-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.fddm-smallsignup-category-label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    color: #555;
    cursor: pointer;
    font-weight: 500;
}

.fddm-smallsignup-category-label input[type="checkbox"] {
    margin: 0;
}

.fddm-smallsignup-unsubscribe {
    color: #888;
    text-decoration: underline;
    font-size: 13px;
    font-weight: 500;
}

.fddm-smallsignup-unsubscribe:hover {
    color: #666;
}

.fddm-public-ui-feedback {
    margin: 0 0 16px;
    clear: both;
}

.fddm-public-ui-feedback:empty {
    display: none;
}

.fddm-ui-confirm-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

/* Response messaging */
.fddm-alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 15px;
    border-radius: 4px;
    border-left: 4px solid #4caf50;
    margin-top: 20px;
}

.fddm-alert-error {
    background: #ffebee;
    color: #c62828;
    padding: 15px;
    border-radius: 4px;
    border-left: 4px solid #f44336;
    margin-top: 20px;
}

@media (max-width: 991px) {
    .fddm-smallsignup-container {
        flex-direction: column;
        gap: 30px;
    }
    .fddm-smallsignup-action-area {
        max-width: 100%;
        width: 100%;
    }
}

/* Unified archive (notices + events) */
.fddm-unified-archive .fddm-archive-year {
    margin-bottom: 40px;
}

.fddm-unified-archive .fddm-archive-year-title {
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    margin: 0 0 20px;
    font-size: 1.5rem;
    color: #1f2937;
}

.fddm-unified-archive .fddm-archive-month {
    margin-left: 12px;
    margin-bottom: 28px;
}

.fddm-unified-archive .fddm-archive-month-title {
    font-size: 1.15rem;
    color: #555;
    margin: 0 0 12px;
}

.fddm-unified-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fddm-unified-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f1;
}

.fddm-unified-item-main {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1 1 220px;
    min-width: 0;
}

.fddm-unified-item .fddm-pn-card-dates {
    align-items: flex-end;
    text-align: right;
    flex: 0 1 auto;
}

.fddm-item-badge {
    font-size: 0.72rem;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 4px;
    font-weight: 700;
    letter-spacing: 0.04em;
    white-space: nowrap;
    flex-shrink: 0;
}

.fddm-item-badge.notice {
    background: #fff3cd;
    color: #856404;
}

.fddm-item-badge.event {
    background: #d1ecf1;
    color: #0c5460;
}

.fddm-item-title {
    font-weight: 500;
    color: #1f2937;
}

.fddm-item-title-link {
    font-weight: 500;
    text-decoration: none;
    color: inherit;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    text-align: left;
    font-size: inherit;
    font-family: inherit;
}

.fddm-item-title-link:hover {
    text-decoration: underline;
    color: #0073aa;
}

@media (max-width: 640px) {
    .fddm-unified-item .fddm-pn-card-dates {
        align-items: flex-start;
        text-align: left;
        width: 100%;
        padding-left: 0;
    }

    .fddm-unified-archive .fddm-archive-month {
        margin-left: 0;
    }
}

/* Public forms ([fddm_form]) */
.fddm-form-app-wrapper {
    max-width: 760px;
    margin: 0 auto 2rem;
    background: #fff;
    padding: 28px 32px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.04);
    color: #1f2937;
}

.fddm-form-app-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.fddm-form-app-org {
    margin: 0 0 0.35rem;
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #6b7280;
}

.fddm-form-app-title {
    margin: 0 0 0.5rem;
    font-size: 1.5rem;
    line-height: 1.25;
    color: #111827;
}

.fddm-form-app-lede {
    margin: 0;
    color: #4b5563;
    font-size: 0.95rem;
    line-height: 1.5;
}

.fddm-form-section {
    margin: 1.75rem 0;
}

.fddm-form-section h3 {
    margin: 0 0 1rem;
    font-size: 1.1rem;
    color: #111827;
    border-bottom: 2px solid #b91c1c;
    padding-bottom: 0.4rem;
}

.fddm-form-help {
    margin: -0.25rem 0 1rem;
    color: #6b7280;
    font-size: 0.9rem;
}

.fddm-form-grid {
    display: grid;
    gap: 0 1rem;
}

.fddm-form-grid-2 {
    grid-template-columns: 1fr 1fr;
}

.fddm-form-grid-3 {
    grid-template-columns: 2fr 1fr 1fr;
}

.fddm-form-mirror {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    margin: 0.35rem 0 0.65rem;
}

.fddm-form-mirror-option {
    display: inline-flex !important;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500 !important;
    margin: 0 !important;
    cursor: pointer;
}

.fddm-form-registration input.fddm-form-mirrored,
.fddm-form-registration textarea.fddm-form-mirrored {
    background: #f3f4f6;
    color: #374151;
    cursor: not-allowed;
}

.fddm-form-registration .fddm-form-row {
    margin-bottom: 1rem;
}

.fddm-form-registration .fddm-form-row label,
.fddm-form-registration .fddm-form-radios legend {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 600;
    color: #374151;
}

.fddm-form-registration input[type="text"],
.fddm-form-registration input[type="email"],
.fddm-form-registration input[type="tel"],
.fddm-form-registration input[type="date"],
.fddm-form-registration textarea {
    width: 100%;
    max-width: 100%;
    padding: 0.55rem 0.7rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 1rem;
    box-sizing: border-box;
}

.fddm-form-registration input:focus,
.fddm-form-registration textarea:focus {
    outline: none;
    border-color: #b91c1c;
    box-shadow: 0 0 0 2px rgba(185, 28, 28, 0.15);
}

.fddm-form-radios label {
    display: inline-flex !important;
    align-items: center;
    gap: 0.4rem;
    margin-right: 1.25rem;
    margin-bottom: 0.5rem !important;
    font-weight: 500 !important;
}

.fddm-form-checkbox label {
    display: flex !important;
    align-items: flex-start;
    gap: 0.55rem;
    font-weight: 500 !important;
}

.fddm-form-checkbox input {
    margin-top: 0.2rem;
}

.fddm-form-actions {
    margin-top: 1.5rem;
}

.fddm-form-registration .fddm-btn-primary {
    background: #b91c1c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.7rem 1.4rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
}

.fddm-form-registration .fddm-btn-primary:hover {
    background: #991b1b;
}

.fddm-form-registration .fddm-btn-primary:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.fddm-form-response {
    margin-top: 1rem;
    padding: 0.9rem 1rem;
    border-radius: 4px;
}

.fddm-form-response.fddm-alert-success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.fddm-form-response.fddm-alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

@media (max-width: 640px) {
    .fddm-form-app-wrapper {
        padding: 20px 16px;
    }

    .fddm-form-grid-2,
    .fddm-form-grid-3 {
        grid-template-columns: 1fr;
    }
}
