/* Create Ad Specific Styles */
.create-ad-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.create-ad-form-section, .create-ad-preview-section {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.create-ad-form-section .card, .create-ad-preview-section .card {
    padding: 1.5rem;
    margin-bottom: 0;
    height: auto;
}

.create-ad-form-section h2, .create-ad-preview-section h2 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #334155;
    margin-top: 0;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-row .form-group {
    flex: 1;
}

/* Wallet Summary */
.wallet-summary-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.wallet-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    flex: 1;
}

.wallet-stat {
    display: flex;
    flex-direction: column;
}

.wallet-stat .stat-label {
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.wallet-stat .stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
}

/* Scheduling */
.day-presets {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.days-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
}

.days-grid label {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    cursor: pointer;
    background-color: #f8fafc;
}

.days-grid input[type="checkbox"] {
    margin-right: 5px;
}

/* Quality Indicator */
.quality-progress-container {
    width: 100%;
    height: 8px;
    background-color: #e2e8f0;
    border-radius: 4px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.quality-progress-bar {
    height: 100%;
    background-color: #4f46e5;
    transition: width 0.3s ease;
}

.quality-checks-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.quality-check-item {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: #64748b;
}

.quality-check-item i {
    margin-right: 0.5rem;
    width: 16px;
}

.quality-check-item.complete {
    color: #10b981;
}

.quality-check-item.incomplete {
    color: #94a3b8;
}

/* Preview Card */
.preview-card-sticky {
    position: sticky;
    top: 20px;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.preview-header h2 {
    margin: 0;
    border: none;
    padding: 0;
}

.preview-modes button {
    margin-left: 0.5rem;
}

.ad-preview-container {
    border: 1px solid #e2e8f0;
    background-color: #f8fafc;
    border-radius: 0.5rem;
    padding: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    transition: all 0.3s ease;
}

.mobile-preview {
    width: 320px;
    margin: 0 auto;
}

/* The Advertisement Itself */
.ad-card {
    width: 100%;
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.text-only-ad .ad-media {
    display: none;
}

.ad-header {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.ad-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 0.75rem;
    background-color: #e2e8f0;
}

.ad-logo-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 0.75rem;
    background-color: #4f46e5;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.25rem;
}

.ad-brand-info {
    display: flex;
    flex-direction: column;
}

.advertiser-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: #1e293b;
}

.sponsored-tag {
    font-size: 0.75rem;
    color: #64748b;
}

.ad-media {
    width: 100%;
    aspect-ratio: 16/9;
    background-color: #e2e8f0;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ad-media img, .ad-media video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.media-placeholder {
    color: #94a3b8;
    font-size: 0.875rem;
}

.ad-content {
    padding: 1rem;
}

.ad-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.5rem 0;
}

.ad-description {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0 0 1rem 0;
    line-height: 1.4;
}

.ad-cta {
    display: block;
    width: 100%;
    padding: 0.75rem;
    background-color: #4f46e5;
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    margin-bottom: 0.5rem;
}

.ad-domain {
    font-size: 0.75rem;
    color: #94a3b8;
    display: block;
    text-align: center;
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem 0;
}

#save-draft-btn {
    background-color: #e2e8f0;
    color: #334155;
}

#create-campaign-btn {
    background-color: #4f46e5;
    color: white;
    padding: 0.75rem 2rem;
}

#create-campaign-btn:disabled, #save-draft-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Responsive */
@media (max-width: 900px) {
    .create-ad-container {
        grid-template-columns: 1fr;
    }
    .preview-card-sticky {
        position: static;
    }
}

@media (max-width: 480px) {
    .form-row {
        flex-direction: column;
    }
    .days-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .wallet-summary-card {
        flex-direction: column;
        align-items: flex-start;
    }
    .wallet-info-grid {
        width: 100%;
    }
}
