/* ── Dokan Vendor Subscription – Frontend Styles ── */

/* ─ Banner ─ */
.dvs-plan-banner {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 1px 4px rgba(0,0,0,.06);
    overflow: hidden;
}
.dvs-plan-banner-inner {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    padding: 14px 18px;
}
.dvs-plan-badge {
    display: inline-block;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .5px;
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
}
.dvs-plan-usage {
    font-size: 14px;
    color: #374151;
}
.dvs-progress-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 160px;
}
.dvs-progress-bar {
    flex: 1;
    height: 8px;
    background: #f3f4f6;
    border-radius: 99px;
    overflow: hidden;
}
.dvs-progress-fill {
    height: 100%;
    border-radius: 99px;
    transition: width .4s ease;
}
.dvs-pct {
    font-size: 12px;
    color: #6b7280;
    min-width: 32px;
}
.dvs-limit-alert {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 6px;
    color: #b91c1c;
    font-size: 13px;
    padding: 6px 12px;
}
.dvs-limit-warn {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 6px;
    color: #92400e;
    font-size: 13px;
    padding: 6px 12px;
}
.dvs-upgrade-btn {
    display: inline-block;
    background: #ef4444;
    color: #fff !important;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    margin-left: 8px;
    transition: background .2s;
}
.dvs-upgrade-btn:hover { background: #dc2626; }
.dvs-view-plans {
    font-size: 13px;
    color: #3b82f6;
    text-decoration: none;
    margin-left: auto;
}
.dvs-view-plans:hover { text-decoration: underline; }

/* ─ Modal ─ */
.dvs-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: dvsOverlayIn .2s ease;
}
/* Hidden state — toggled by JS via class, never touch body overflow */
.dvs-modal-overlay.dvs-modal-hidden {
    display: none !important;
}
@keyframes dvsOverlayIn { from { opacity:0 } to { opacity:1 } }

/* Inner box renamed to .dvs-modal-box so it doesn't clash with overlay class */
.dvs-modal-box {
    background: #fff;
    border-radius: 16px;
    max-width: 780px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: dvsModalIn .25s cubic-bezier(.34,1.56,.64,1);
    box-shadow: 0 24px 60px rgba(0,0,0,.25);
}
@keyframes dvsModalIn { from { opacity:0;transform:scale(.9) } to { opacity:1;transform:scale(1) } }

.dvs-modal-close {
    z-index: 10;
    pointer-events: auto;
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    color: #9ca3af;
    padding: 2px 6px;
    border-radius: 6px;
}
.dvs-modal-close:hover { color: #374151; background:#f3f4f6; }

.dvs-modal-head {
    padding: 28px 32px 16px;
    border-bottom: 1px solid #f3f4f6;
    text-align: center;
}
.dvs-modal-head h2 {
    margin: 0 0 6px;
    font-size: 22px;
    color: #111827;
}
.dvs-modal-head p {
    margin: 0;
    color: #6b7280;
    font-size: 14px;
}

/* ─ Plans grid (modal + page) ─ */
.dvs-plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
    padding: 24px 28px;
}

.dvs-plan-card {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow .2s, transform .2s;
}
.dvs-plan-card:hover {
    box-shadow: 0 8px 28px rgba(0,0,0,.12);
    transform: translateY(-2px);
}
.dvs-plan-card.dvs-plan-current {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

.dvs-plan-card-top {
    padding: 20px 16px;
    text-align: center;
    color: #fff;
}
.dvs-plan-card-top h3 {
    margin: 0 0 8px;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
}
.dvs-price { line-height: 1.2; }
.dvs-amount { font-size: 26px; font-weight: 800; }
.dvs-period { font-size: 12px; opacity: .85; display: block; }

.dvs-plan-card-body {
    padding: 18px 16px;
}
.dvs-plan-card-body ul {
    margin: 0 0 16px;
    padding: 0;
    list-style: none;
}
.dvs-plan-card-body ul li {
    font-size: 13px;
    color: #374151;
    padding: 4px 0;
}

.dvs-plan-btn {
    display: block;
    text-align: center;
    background: #3b82f6;
    color: #fff !important;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    padding: 9px 16px;
    border-radius: 8px;
    transition: background .2s;
}
.dvs-plan-btn:hover { background: #2563eb; }

.dvs-current-badge {
    display: block;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: #3b82f6;
    padding: 8px;
    background: #eff6ff;
    border-radius: 8px;
}
.dvs-free-badge {
    display: block;
    text-align: center;
    font-size: 13px;
    color: #6b7280;
    padding: 8px;
    background: #f9fafb;
    border-radius: 8px;
}

/* ─ Plans page header ─ */
.dvs-plans-page { max-width: 900px; margin: 0 auto; padding: 20px 0; }
.dvs-plans-header { text-align: center; margin-bottom: 32px; }
.dvs-plans-header h2 { font-size: 28px; margin-bottom: 8px; }
.dvs-plans-header p  { color: #6b7280; }
.dvs-plans-page .dvs-plans-grid { padding: 0; }

/* ── Full Plans Page (vendor-plans-full.php) ── */
.dvs-full-plans-wrap {
    max-width: 960px;
    margin: 0 auto;
    padding: 10px 0 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Status card */
.dvs-status-card {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 28px;
    box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.dvs-status-left  { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 200px; }
.dvs-status-right { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 180px; }
.dvs-status-text  { font-size: 14px; color: #374151; }
.dvs-pct-text     { font-size: 12px; color: #6b7280; white-space: nowrap; }

/* Header */
.dvs-plans-header { text-align: center; margin-bottom: 32px; }
.dvs-plans-header h2 { font-size: 28px; font-weight: 800; color: #111827; margin: 0 0 8px; }
.dvs-plans-header p  { font-size: 15px; color: #6b7280; margin: 0; }

/* Plans grid */
.dvs-plans-grid-full {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

/* Plan card */
.dvs-plan-card-full {
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
    background: #fff;
    position: relative;
    transition: box-shadow .25s, transform .25s, border-color .25s;
}
.dvs-plan-card-full:hover {
    box-shadow: 0 10px 32px rgba(0,0,0,.12);
    transform: translateY(-3px);
}
.dvs-plan-card-full.dvs-plan-active {
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59,130,246,.12);
}

/* Current ribbon */
.dvs-current-ribbon {
    position: absolute;
    top: 12px;
    right: -28px;
    background: #fff;
    color: #3b82f6;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 36px;
    transform: rotate(35deg);
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
    letter-spacing: .4px;
}

/* Card header */
.dvs-plan-card-header {
    padding: 24px 20px 20px;
    text-align: center;
    color: #fff;
}
.dvs-plan-card-header h3 {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    letter-spacing: .3px;
}
.dvs-price-main { font-size: 30px; font-weight: 800; display: block; }
.dvs-price-sub  { font-size: 12px; opacity: .8; margin-top: 2px; display: block; }

/* Card body */
.dvs-plan-card-body-full { padding: 20px 20px 22px; }

/* Features list */
.dvs-plan-features {
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}
.dvs-plan-features li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #374151;
    padding: 5px 0;
    border-bottom: 1px solid #f9fafb;
}
.dvs-plan-features li:last-child { border-bottom: none; }
.dvs-feat-icon { font-size: 14px; flex-shrink: 0; }

/* Usage bar inside card */
.dvs-plan-usage-bar { margin-bottom: 16px; }
.dvs-usage-label {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #6b7280;
    margin-bottom: 4px;
}

/* CTA buttons */
.dvs-plan-cta { margin-top: 6px; }
.dvs-btn-upgrade {
    display: block;
    text-align: center;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff !important;
    text-decoration: none !important;
    font-size: 14px;
    font-weight: 700;
    padding: 11px 18px;
    border-radius: 10px;
    transition: opacity .2s, transform .15s;
    letter-spacing: .2px;
}
.dvs-btn-upgrade:hover { opacity: .92; transform: scale(1.02); }
.dvs-btn-current {
    display: block;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #3b82f6;
    padding: 11px 18px;
    background: #eff6ff;
    border-radius: 10px;
}
.dvs-btn-free, .dvs-btn-na {
    display: block;
    text-align: center;
    font-size: 13px;
    color: #9ca3af;
    padding: 10px 18px;
    background: #f9fafb;
    border-radius: 10px;
}

/* Payment note */
.dvs-payment-note {
    text-align: center;
    font-size: 13px;
    color: #6b7280;
    border-top: 1px solid #f3f4f6;
    padding-top: 18px;
}
.dvs-payment-note p { margin: 0; }

/* Responsive */
@media (max-width: 640px) {
    .dvs-plans-grid-full { grid-template-columns: 1fr; }
    .dvs-plans-header h2 { font-size: 22px; }
    .dvs-status-card { flex-direction: column; }
    .dvs-plan-banner-inner { flex-direction: column; align-items: flex-start; }
}

/* ═══════════════════════════════════════
   DVS Store Badge — Public vendor store page
   ═══════════════════════════════════════ */

.dvs-store-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--dvs-badge-color, #8b5cf6);
    color: #fff;
    padding: 5px 12px 5px 8px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0,0,0,.18);
    margin: 6px 0 4px 0;
    width: fit-content;
    letter-spacing: .01em;
}

.dvs-store-badge-icon {
    font-size: 15px;
    line-height: 1;
}

.dvs-store-badge-label {
    font-size: 13px;
    font-weight: 700;
}

.dvs-store-badge-tick {
    font-size: 11px;
    font-weight: 500;
    opacity: .88;
    border-left: 1px solid rgba(255,255,255,.4);
    padding-left: 7px;
    margin-left: 2px;
}

/* Shine animation on badge */
.dvs-store-badge::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,.18) 50%, transparent 60%);
    pointer-events: none;
}
.dvs-store-badge {
    position: relative;
    overflow: hidden;
}
