/* ============================================================================
   DESIGN SYSTEM - Paquete C (dashboards + social)
   Componentes: glinder, raffle, dashboards user/organizer
   ============================================================================ */

/* ============================================================================
   1. DASHBOARD - layout, sidebars, stat cards mejorados
   ============================================================================ */
.rp-dash-page {
    background: var(--rp-bg-2);
    min-height: 100vh;
    padding: 30px 0;
}

.rp-dash-header {
    background: white;
    border: 1px solid var(--rp-border);
    border-radius: var(--rp-radius-lg);
    padding: 28px 32px;
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}
.rp-dash-header h1 { font-size: 1.75rem !important; margin-bottom: 4px; }
.rp-dash-header .subtitle { color: var(--rp-text-2); font-size: 14px; }

.rp-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.rp-stat-card {
    background: white;
    border: 1px solid var(--rp-border);
    border-radius: var(--rp-radius);
    padding: 24px;
    transition: transform 0.2s, box-shadow 0.2s;
}
.rp-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--rp-shadow);
}
.rp-stat-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--rp-accent-l);
    color: var(--rp-accent-d);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}
.rp-stat-card-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--rp-text-3);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 6px;
}
.rp-stat-card-value {
    font-size: 1.875rem;
    font-weight: 800;
    color: var(--rp-text);
    letter-spacing: -0.02em;
    line-height: 1;
}
.rp-stat-card-meta {
    font-size: 12px;
    color: var(--rp-text-3);
    margin-top: 8px;
}
.rp-stat-card-meta-up { color: var(--rp-success); }
.rp-stat-card-meta-down { color: var(--rp-danger); }

.rp-dash-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}
@media (max-width: 992px) {
    .rp-dash-grid { grid-template-columns: 1fr; }
}

.rp-panel {
    background: white;
    border: 1px solid var(--rp-border);
    border-radius: var(--rp-radius-lg);
    overflow: hidden;
}
.rp-panel-header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--rp-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.rp-panel-header h3 { font-size: 1rem !important; margin: 0 !important; }
.rp-panel-body { padding: 0; }

.rp-list-item {
    padding: 16px 24px;
    border-bottom: 1px solid var(--rp-border);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: background 0.2s;
}
.rp-list-item:last-child { border-bottom: none; }
.rp-list-item:hover { background: var(--rp-bg-2); }
.rp-list-item-content { flex: 1; min-width: 0; }
.rp-list-item-title {
    font-weight: 600;
    color: var(--rp-text);
    font-size: 14px;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.rp-list-item-sub {
    font-size: 12px;
    color: var(--rp-text-3);
}
.rp-list-item-meta {
    text-align: right;
    flex-shrink: 0;
}

/* ============================================================================
   2. GLINDER (swipe-style buscar pareja)
   ============================================================================ */
.rp-glinder-stage {
    max-width: 420px;
    margin: 0 auto;
    position: relative;
    height: 580px;
}

.rp-swipe-card {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    border: 1px solid var(--rp-border);
    border-radius: 24px;
    box-shadow: var(--rp-shadow-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, opacity 0.3s ease;
}
.rp-swipe-card-stack-2 { transform: scale(0.95) translateY(12px); opacity: 0.7; z-index: 1; }
.rp-swipe-card-stack-3 { transform: scale(0.9)  translateY(24px); opacity: 0.4; z-index: 0; }
.rp-swipe-card-active  { z-index: 2; }

.rp-swipe-card-photo {
    height: 60%;
    background-size: cover;
    background-position: center;
    background-color: var(--rp-bg-3);
    position: relative;
    display: flex;
    align-items: flex-end;
    padding: 20px;
    color: white;
}
.rp-swipe-card-photo::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,0.7) 100%);
}
.rp-swipe-card-photo-content {
    position: relative;
    z-index: 2;
}
.rp-swipe-card-photo-content h3 {
    color: white !important;
    font-size: 1.5rem !important;
    margin-bottom: 4px !important;
}
.rp-swipe-card-photo-content p {
    color: rgba(255,255,255,0.9);
    margin: 0;
    font-size: 14px;
}

.rp-swipe-card-body {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.rp-swipe-card-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.rp-swipe-card-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 24px;
}
.rp-swipe-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px solid var(--rp-border);
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 24px;
    transition: all 0.2s;
}
.rp-swipe-btn:hover { transform: scale(1.1); box-shadow: var(--rp-shadow); }
.rp-swipe-btn-no    { color: var(--rp-danger);  border-color: var(--rp-danger); }
.rp-swipe-btn-yes   { color: var(--rp-success); border-color: var(--rp-success); }
.rp-swipe-btn-super { color: var(--rp-info);    border-color: var(--rp-info); }

/* ============================================================================
   3. RAFFLE (sorteo con boletos)
   ============================================================================ */
.rp-raffle-tickets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin: 24px 0;
}
.rp-ticket {
    aspect-ratio: 1.6 / 1;
    background: white;
    border: 2px dashed var(--rp-border-2);
    border-radius: var(--rp-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 14px;
    transition: all 0.2s;
    position: relative;
}
.rp-ticket-num {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--rp-text);
    letter-spacing: -0.02em;
    line-height: 1;
}
.rp-ticket-name {
    font-size: 11px;
    color: var(--rp-text-3);
    text-align: center;
    margin-top: 4px;
}

.rp-ticket-winner {
    border: 2px solid var(--rp-accent);
    background: linear-gradient(135deg, rgba(22,163,74,0.1), rgba(22,163,74,0.05));
    box-shadow: 0 0 0 4px rgba(22,163,74,0.15);
    transform: scale(1.05);
    z-index: 2;
}
.rp-ticket-winner::before {
    content: '🏆';
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--rp-accent);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.rp-raffle-spinner {
    background: var(--rp-primary);
    color: white;
    padding: 32px;
    border-radius: var(--rp-radius-lg);
    text-align: center;
    margin-bottom: 24px;
}
.rp-raffle-spinner-num {
    font-size: 4rem;
    font-weight: 900;
    color: var(--rp-accent);
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 16px 0;
}
