/* WPCodeQuill PWA - Ultra Modern Admin UI */
.codequill-pwa-wrap {
    max-width: 850px;
    margin: 30px 20px 0 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* Premium Floating Card Container */
.codequill-pwa-card {
    background: #ffffff;
    border: none;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.03);
    padding: 40px;
    box-sizing: border-box;
}

/* Header Styling */
.codequill-pwa-header {
    border-bottom: 2px solid #f3f4f6;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.codequill-pwa-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    letter-spacing: -0.02em;
}

/* Override WordPress Form Table defaults */
.codequill-pwa-card .form-table {
    margin-top: 0;
}

.codequill-pwa-card .form-table th {
    font-weight: 600;
    color: #374151;
    font-size: 14.5px;
    padding: 20px 20px 20px 0;
    vertical-align: middle;
    width: 220px;
}

.codequill-pwa-card .form-table td {
    padding: 15px 10px;
    vertical-align: middle;
}

/* Thick, Modern Inputs */
.codequill-pwa-card input[type="text"] {
    width: 100%;
    max-width: 480px;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    background-color: #f9fafb;
    color: #111827;
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: none;
}

.codequill-pwa-card input[type="text"]:focus {
    background-color: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
    outline: none;
}

/* Circular, Modern Color Picker */
.codequill-pwa-card input[type="color"] {
    -webkit-appearance: none;
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    padding: 0;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.codequill-pwa-card input[type="color"]:hover {
    transform: scale(1.05);
}

.codequill-pwa-card input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.codequill-pwa-card input[type="color"]::-webkit-color-swatch {
    border: none;
    border-radius: 50%;
}

/* Modern Save Button Area */
.codequill-pwa-footer {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 2px solid #f3f4f6;
}

.codequill-pwa-footer .button-primary {
    background: #2563eb !important;
    border-color: #2563eb !important;
    color: #ffffff !important;
    text-shadow: none !important;
    box-shadow: 0 4px 6px rgba(37, 99, 235, 0.2) !important;
    border-radius: 8px !important;
    padding: 8px 28px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    height: auto !important;
    line-height: normal !important;
    transition: all 0.2s ease !important;
}

.codequill-pwa-footer .button-primary:hover {
    background: #1d4ed8 !important;
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.3) !important;
    transform: translateY(-1px);
}

/* KEEP YOUR EXISTING 4-COLUMN PROMO GRID CSS BELOW THIS LINE */

/* Enhanced Inputs */
.codequill-pwa-card input[type="text"] {
    width: 100%;
    max-width: 400px;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid #8c8f94;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.codequill-pwa-card input[type="text"]:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
    outline: none;
}

.codequill-pwa-card input[type="color"] {
    cursor: pointer;
    border-radius: 4px;
    height: 34px;
    padding: 2px;
}

/* Submit Area */
.codequill-pwa-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-bottom: none;
}

/* WPCodeQuill 4-Column Promo Grid */
.codequill-promo-wrap {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px dashed #dcdcde;
}

.codequill-promo-wrap h2 {
    font-size: 18px;
    color: #1d2327;
    margin-bottom: 20px;
}

.codequill-promo-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* Card Styling */
.codequill-promo-item {
    background: #ffffff;
    border: 1px solid #f0f0f1;
    border-radius: 8px;
    overflow: hidden;
    text-decoration: none !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.codequill-promo-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

/* Image Area */
.codequill-promo-img {
    width: 100%;
    aspect-ratio: 4/3;
    background-color: #f6f7f7;
    position: relative;
    border-bottom: 1px solid #f0f0f1;
}

.codequill-promo-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* "NEW" Badge on Image */
.codequill-promo-new {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #10b981;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}

/* Content Area */
.codequill-promo-content {
    padding: 10px;
}

.codequill-promo-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.codequill-promo-badge {
    background: #e0f2fe;
    color: #0284c7;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
}

.codequill-promo-stars {
    color: #d4e619; /* Yellow stars */
    font-size: 14px;
    letter-spacing: 2px;
}

.codequill-promo-title {
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive for smaller screens */
@media (max-width: 1200px) {
    .codequill-promo-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .codequill-promo-grid { grid-template-columns: 1fr; }
}