/* =============================================
   News & Events Pro v2 — uses default WP Posts
   ============================================= */

:root {
    --nep-accent:   #e94560;
    --nep-navy:     #1a1a2e;
    --nep-navy2:    #0f3460;
    --nep-white:    #ffffff;
    --nep-light:    #f8f9ff;
    --nep-text:     #2d2d3a;
    --nep-muted:    #6b7280;
    --nep-border:   #e5e7eb;
    --nep-radius:   14px;
    --nep-shadow:   0 4px 24px rgba(26,26,46,.10);
    --nep-shadow-h: 0 16px 48px rgba(26,26,46,.22);
    --nep-tr:       .35s cubic-bezier(.4,0,.2,1);
}

/* ── Wrapper ── */
.nep-wrapper { width: 100%; box-sizing: border-box; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }

/* ── Grid ── */
.nep-grid { display: grid; gap: 28px; }
.nep-cols-3 { grid-template-columns: repeat(3, 1fr); }
.nep-cols-2 { grid-template-columns: repeat(2, 1fr); }
.nep-cols-1 { grid-template-columns: 1fr; }

@media (max-width: 1024px) { .nep-cols-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .nep-cols-3, .nep-cols-2 { grid-template-columns: 1fr; } .nep-grid { gap: 18px; } }

/* ── Card ── */
.nep-card {
    background: var(--nep-white);
    border-radius: var(--nep-radius);
    overflow: hidden;
    box-shadow: var(--nep-shadow);
    transition: transform var(--nep-tr), box-shadow var(--nep-tr);
    display: flex;
    flex-direction: column;
    animation: nepFadeUp .5s ease both;
}
.nep-card:hover { transform: translateY(-6px); box-shadow: var(--nep-shadow-h); }
.nep-card-inner { display: flex; flex-direction: column; height: 100%; }

.nep-card:nth-child(1) { animation-delay: .05s; }
.nep-card:nth-child(2) { animation-delay: .12s; }
.nep-card:nth-child(3) { animation-delay: .19s; }
.nep-card:nth-child(4) { animation-delay: .26s; }
.nep-card:nth-child(5) { animation-delay: .33s; }
.nep-card:nth-child(6) { animation-delay: .40s; }

@keyframes nepFadeUp {
    from { opacity: 0; transform: translateY(26px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Image wrap ── */
.nep-image-link { display: block; text-decoration: none !important; }
.nep-image-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
    background: linear-gradient(135deg, var(--nep-navy), var(--nep-navy2));
}
.nep-image-wrap img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
    transition: transform .55s cubic-bezier(.4,0,.2,1);
}
.nep-card:hover .nep-image-wrap img { transform: scale(1.07); }
.nep-image-wrap::after {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(26,26,46,.52) 100%);
    opacity: 0;
    transition: opacity var(--nep-tr);
}
.nep-card:hover .nep-image-wrap::after { opacity: 1; }

/* ── No-image placeholder ── */
.nep-no-image {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460);
}
.nep-no-image svg { width: 48px; height: 48px; fill: rgba(255,255,255,.2); }

/* ── Type badge ── */
.nep-type-badge {
    position: absolute; top: 14px; left: 14px;
    padding: 4px 12px; border-radius: 20px;
    font-size: 11px; font-weight: 700; letter-spacing: .8px;
    text-transform: uppercase; color: #fff; z-index: 2;
    backdrop-filter: blur(6px);
}
.nep-badge-event { background: rgba(16,185,129,.85); }
.nep-badge-news  { background: rgba(59,130,246,.85); }

/* ── Date badge ── */
.nep-date-badge {
    position: absolute; bottom: 14px; right: 14px;
    background: #fff; border-radius: 10px;
    padding: 6px 12px; text-align: center; min-width: 52px;
    box-shadow: 0 2px 12px rgba(0,0,0,.18); z-index: 2; line-height: 1;
}
.nep-date-badge .nep-day { display: block; font-size: 22px; font-weight: 800; color: var(--nep-accent); letter-spacing: -1px; }
.nep-date-badge .nep-mon { display: block; font-size: 9px; font-weight: 700; color: var(--nep-muted); text-transform: uppercase; letter-spacing: 1px; margin-top: 2px; }
.nep-date-badge .nep-yr  { display: block; font-size: 9px; font-weight: 600; color: var(--nep-muted); letter-spacing: .5px; margin-top: 1px; }

/* ── Card body ── */
.nep-card-body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 9px; flex: 1; }

/* ── Category tag ── */
.nep-cat-tag {
    display: inline-block; font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .9px;
    color: var(--nep-accent) !important;
    border-left: 3px solid var(--nep-accent); padding-left: 8px;
    line-height: 1; text-decoration: none !important;
}

/* ── Title ── */
.nep-title { margin: 0 !important; font-size: 16px !important; font-weight: 700 !important; line-height: 1.4 !important; }
.nep-title a {
    color: var(--nep-navy) !important;
    text-decoration: none !important;
    background: linear-gradient(var(--nep-accent), var(--nep-accent)) no-repeat 0 100%;
    background-size: 0 2px;
    transition: background-size var(--nep-tr), color var(--nep-tr);
}
.nep-title a:hover { color: var(--nep-accent) !important; background-size: 100% 2px; }

/* ── Meta ── */
.nep-meta { display: flex; flex-wrap: wrap; gap: 10px; }
.nep-meta-item { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--nep-muted); }
.nep-meta-item svg { width: 13px; height: 13px; fill: var(--nep-accent); flex-shrink: 0; }

/* ── Excerpt ── */
.nep-excerpt { font-size: 13px !important; color: var(--nep-muted) !important; line-height: 1.65 !important; margin: 0 !important; flex: 1; }

/* ── Read more ── */
.nep-read-more {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 12.5px; font-weight: 700; color: var(--nep-accent) !important;
    text-decoration: none !important; margin-top: 4px;
    transition: gap var(--nep-tr);
}
.nep-read-more:hover { gap: 8px; }
.nep-read-more svg { width: 15px; height: 15px; fill: var(--nep-accent); }

/* ── Archive link ── */
.nep-archive-link-wrap { text-align: center; margin-top: 38px; }
.nep-archive-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 13px 32px;
    background: linear-gradient(135deg, var(--nep-accent), #c0392b);
    color: #fff !important; font-size: 14px; font-weight: 700;
    border-radius: 50px; text-decoration: none !important;
    box-shadow: 0 6px 22px rgba(233,69,96,.35);
    transition: transform var(--nep-tr), box-shadow var(--nep-tr);
}
.nep-archive-btn:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(233,69,96,.45); }
.nep-archive-btn svg { width: 17px; height: 17px; fill: #fff; }

/* ── Empty ── */
.nep-empty { text-align: center; color: var(--nep-muted); padding: 40px; font-size: 15px; }

/* ───────────────────────────────────────────
   CATEGORY ARCHIVE PAGE
─────────────────────────────────────────── */
.nep-archive-page { max-width: 1180px; margin: 0 auto; padding: 50px 20px 70px; }

.nep-archive-hero {
    text-align: center; padding: 60px 20px 50px;
    background: linear-gradient(135deg, var(--nep-navy), var(--nep-navy2));
    border-radius: 20px; margin-bottom: 44px;
    position: relative; overflow: hidden;
}
.nep-archive-hero::before {
    content: ''; position: absolute;
    top: -50%; left: -30%; width: 80%; height: 200%;
    background: radial-gradient(circle, rgba(233,69,96,.18) 0%, transparent 65%);
    pointer-events: none;
}
.nep-archive-hero h1 { color: #fff !important; font-size: 36px !important; font-weight: 800 !important; margin: 0 0 10px !important; letter-spacing: -1px; }
.nep-archive-hero p  { color: rgba(255,255,255,.7) !important; font-size: 15px; margin: 0 !important; }

/* ── Filter / category nav ── */
.nep-cat-nav { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 38px; }
.nep-cat-nav a {
    padding: 9px 22px; border-radius: 50px; font-size: 13px; font-weight: 600;
    border: 1.5px solid var(--nep-border); background: var(--nep-white);
    color: var(--nep-text) !important; text-decoration: none !important;
    transition: all var(--nep-tr);
}
.nep-cat-nav a:hover,
.nep-cat-nav a.current {
    background: var(--nep-accent); border-color: var(--nep-accent);
    color: #fff !important; transform: translateY(-2px);
    box-shadow: 0 5px 16px rgba(233,69,96,.28);
}

/* ── Pagination ── */
.nep-pagination { display: flex; justify-content: center; gap: 8px; margin-top: 52px; flex-wrap: wrap; }
.nep-pagination .page-numbers {
    display: inline-flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; border-radius: 50%;
    font-size: 14px; font-weight: 600; text-decoration: none !important;
    border: 1.5px solid var(--nep-border);
    color: var(--nep-text) !important; background: var(--nep-white);
    transition: all var(--nep-tr);
}
.nep-pagination .page-numbers.current,
.nep-pagination .page-numbers:hover {
    background: var(--nep-accent); border-color: var(--nep-accent);
    color: #fff !important; box-shadow: 0 4px 14px rgba(233,69,96,.35);
}

/* ── Divi compat ── */
.et_pb_section .nep-wrapper { width: 100%; }
.et_pb_text .nep-wrapper     { width: 100%; }
