/* ============================================
   CANDIDATES ELEMENTOR WIDGET STYLES
   ============================================ */

.cd-candidates-widget {
    width: 100%;
    margin: 0 auto;
}

/* Empty State */
.cd-candidates-empty {
    padding: 60px 20px;
    text-align: center;
    background: #f9fafb;
    border: 2px dashed #e5e7eb;
    border-radius: 12px;
}

.cd-candidates-empty p {
    margin: 0;
    color: #6b7280;
    font-size: 16px;
}

/* Section Title */
.cd-candidates-section-title {
    font-size: 32px;
    font-weight: 700;
    color: #1f2937;
    text-align: center;
    margin: 0 0 48px;
    line-height: 1.2;
}

/* ============================================
   LAYOUT 1: Featured Row + Grid
   ============================================ */

/* Main Candidates Section */
.cd-candidates-main-section {
    margin-bottom: 64px;
}

.cd-candidates-main-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 48px;
    max-width: 900px;
    margin: 0 auto;
}

/* Main Candidate Card */
.cd-candidate-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cd-candidate-main:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.cd-candidate-main-image {
    width: 100%;
    aspect-ratio: 3/4;
    overflow: hidden;
    background: #f3f4f6;
}

.cd-candidate-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cd-candidate-main-content {
    padding: 24px 32px 32px;
    text-align: center;
}

.cd-candidate-main .cd-candidate-name {
    font-size: 28px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 12px;
    line-height: 1.2;
}

.cd-candidate-main-title {
    font-size: 18px;
    font-weight: 600;
    color: #2e94f4;
    margin: 0 0 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.cd-candidate-main-description {
    font-size: 16px;
    line-height: 1.6;
    color: #4b5563;
    margin: 0;
}

.cd-candidate-main-description p {
    margin: 0 0 12px;
}

.cd-candidate-main-description p:last-child {
    margin-bottom: 0;
}

/* Regular Candidates Grid */
.cd-candidates-regular-section {
    margin-top: 64px;
}

.cd-candidates-grid {
    display: grid;
    gap: 32px;
}

.cd-candidates-cols-2 {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.cd-candidates-cols-3 {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.cd-candidates-cols-4 {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

.cd-candidates-cols-5 {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
}

/* Regular Candidate Card */
.cd-candidate-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cd-candidate-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.cd-candidate-image {
    width: 100%;
    aspect-ratio: 3/4;
    overflow: hidden;
    background: #f3f4f6;
    position: relative;
}

.cd-candidate-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cd-candidate-info {
    padding: 12px 16px 16px;
    text-align: center;
}

.cd-candidate-card .cd-candidate-name {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 4px;
    line-height: 1.3;
}

.cd-candidate-profession {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.4;
}

/* ============================================
   LAYOUT 2: Uniform Cards
   ============================================ */

.cd-candidates-uniform-section {
    /* Inherits from regular section */
}

.cd-candidate-uniform {
    /* All cards same size, including main candidates */
}

.cd-candidate-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #2e94f4 0%, #1e73be 100%);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 6px 12px;
    border-radius: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* ============================================
   LAYOUT 3: Simple List
   ============================================ */

.cd-candidates-list-section {
    max-width: 800px;
    margin: 0 auto;
}

.cd-candidate-list-item {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 24px;
    margin-bottom: 16px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cd-candidate-list-item:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.cd-candidate-list-number {
    font-size: 32px;
    font-weight: 700;
    color: #2e94f4;
    line-height: 1;
    min-width: 48px;
    text-align: center;
}

.cd-candidate-list-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    background: #f3f4f6;
    flex-shrink: 0;
}

.cd-candidate-list-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cd-candidate-list-info {
    flex: 1;
}

.cd-candidate-list-item .cd-candidate-name {
    font-size: 20px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 4px;
}

.cd-candidate-list-item .cd-candidate-profession {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .cd-candidates-section-title {
        font-size: 24px;
        margin-bottom: 32px;
    }
    
    .cd-candidates-main-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .cd-candidate-main .cd-candidate-name {
        font-size: 24px;
    }
    
    .cd-candidate-main-title {
        font-size: 16px;
    }
    
    .cd-candidates-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)) !important;
        gap: 20px;
    }
    
    .cd-candidate-card .cd-candidate-name {
        font-size: 16px;
    }
    
    .cd-candidate-profession {
        font-size: 13px;
    }
    
    .cd-candidate-list-item {
        gap: 16px;
        padding: 16px;
    }
    
    .cd-candidate-list-number {
        font-size: 24px;
        min-width: 36px;
    }
    
    .cd-candidate-list-image {
        width: 64px;
        height: 64px;
    }
    
    .cd-candidate-list-item .cd-candidate-name {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .cd-candidates-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)) !important;
    }
    
    .cd-candidate-info {
        padding: 16px;
    }
}

/* ============================================
   CANDIDATE NUMBERING
   ============================================ */

.cd-candidate-number {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2e94f4 0%, #1e73be 100%);
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    z-index: 10;
}

/* Smaller number for regular cards */
.cd-candidate-card .cd-candidate-number {
    width: 32px;
    height: 32px;
    font-size: 16px;
    top: 10px;
    left: 10px;
}

/* Larger number for main candidates */
.cd-candidate-main .cd-candidate-number {
    width: 48px;
    height: 48px;
    font-size: 24px;
    top: 16px;
    left: 16px;
}

@media (max-width: 768px) {
    .cd-candidate-number {
        width: 30px;
        height: 30px;
        font-size: 14px;
        top: 8px;
        left: 8px;
    }
    
    .cd-candidate-main .cd-candidate-number {
        width: 40px;
        height: 40px;
        font-size: 20px;
        top: 12px;
        left: 12px;
    }
}
