/* Banner ads — 970×250 max */
.pad-ad--banner {
    text-align: center;
    margin: 16px auto;
    max-width: 970px;
}

.pad-ad--banner a {
    display: inline-block;
    max-width: 100%;
}

.pad-ad--banner img {
    max-width: 100%;
    width: 970px;
    height: auto;
    border-radius: 8px;
}

/* Video ads — 970×250 fixed */
.pad-ad--video {
    text-align: center;
    margin: 16px auto;
    max-width: 970px;
}

.pad-ad__video-wrap {
    position: relative;
    width: 100%;
    max-width: 970px;
    height: 250px;
    overflow: hidden;
    border-radius: 8px;
    margin: 0 auto;
    background: #000;
}

.pad-ad__video-wrap video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.pad-ad__video-embed {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.pad-ad__video-embed iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* Clickable overlay covering entire video area */
.pad-ad__video-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    cursor: pointer;
}

/* Mute/unmute toggle */
.pad-ad__mute-btn {
    position: absolute;
    bottom: 12px;
    right: 12px;
    z-index: 2;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    padding: 0;
}

.pad-ad__mute-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* HTML ads — 970×250 max */
.pad-ad--html {
    text-align: center;
    margin: 16px auto;
    max-width: 970px;
    max-height: 250px;
    overflow: hidden;
}

/* Ad zone wrapper in frontpage */
.pulmad-ad-zone {
    max-width: 100%;
    overflow: hidden;
}

/* Responsive */
@media (max-width: 768px) {
    .pad-ad--banner {
        margin: 12px 0;
    }

    .pad-ad--banner img {
        border-radius: 4px;
    }
}

/* ---- Vendor Ad Form ---- */
.pad-vendor__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.pad-vendor__header .pulmad-account__panel-title {
    margin: 0;
}

.pad-vendor__form {
    max-width: 640px;
}

.pad-vendor__field {
    margin-bottom: 20px;
}

.pad-vendor__label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 14px;
    color: #1e293b;
}

.pad-vendor__input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.pad-vendor__input:focus {
    outline: none;
    border-color: #276FAB;
    box-shadow: 0 0 0 3px rgba(39, 111, 171, 0.1);
}

.pad-vendor__checkboxes {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #f8fafc;
}

.pad-vendor__checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    cursor: pointer;
}

.pad-vendor__image-upload {
    margin-top: 4px;
}

.pad-vendor__image-preview {
    position: relative;
    display: inline-block;
    max-width: 400px;
    margin-bottom: 8px;
}

.pad-vendor__image-preview img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.pad-vendor__image-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pad-vendor__image-remove:hover {
    background: rgba(239, 68, 68, 0.9);
}

.pad-vendor__file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
}

.pad-vendor__help {
    margin-top: 6px;
    font-size: 12px;
    color: #64748b;
}

.pad-vendor__actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.pad-vendor__note {
    margin-top: 16px;
    font-size: 13px;
    color: #64748b;
    font-style: italic;
}

.pad-vendor__message {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 14px;
}

.pad-vendor__message--success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.pad-vendor__message--error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.pad-vendor__action-link {
    font-size: 13px;
    color: #276FAB;
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.pad-vendor__action-link:hover {
    text-decoration: underline;
}

.pad-vendor__action-link--delete {
    color: #ef4444;
    margin-left: 8px;
}

/* ---- Duration Selector ---- */
.pad-vendor__duration-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pad-vendor__duration-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s, background-color 0.2s;
    background: #fff;
}

.pad-vendor__duration-card:hover {
    border-color: #94a3b8;
}

.pad-vendor__duration-card:has(input:checked) {
    border-color: #276FAB;
    background: #f0f7ff;
}

.pad-vendor__duration-card--free:has(input:checked) {
    border-color: #22c55e;
    background: #f0fdf4;
}

.pad-vendor__duration-card input[type="radio"] {
    margin-top: 3px;
    flex-shrink: 0;
    accent-color: #276FAB;
}

.pad-vendor__duration-card--free input[type="radio"] {
    accent-color: #22c55e;
}

.pad-vendor__duration-card-inner {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pad-vendor__duration-card-inner strong {
    font-size: 14px;
    color: #1e293b;
}

.pad-vendor__duration-card-inner small {
    font-size: 12px;
    color: #64748b;
}

/* ---- Ad Status Card ---- */
.pad-vendor__status-card {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    background: #f8fafc;
}

.pad-vendor__status-preview {
    max-width: 100%;
    overflow: hidden;
}

.pad-vendor__status-preview img {
    width: 100%;
    height: auto;
    display: block;
}

.pad-vendor__status-details {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pad-vendor__status-row {
    display: flex;
    gap: 8px;
    font-size: 14px;
}

.pad-vendor__status-row strong {
    color: #475569;
    min-width: 80px;
    flex-shrink: 0;
}

.pad-vendor__status-stats {
    display: flex;
    gap: 16px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #e2e8f0;
    font-size: 13px;
    color: #64748b;
}

@media (max-width: 640px) {
    .pad-vendor__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .pad-vendor__actions {
        flex-direction: column;
    }

    .pad-vendor__status-stats {
        flex-direction: column;
        gap: 4px;
    }
}
