/* ==============================
   Platform Page Styles
   크레이지아케이드 스타일
   ============================== */

.platform-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

/* Header */
.platform-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--electric-blue);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px var(--shadow);
}

.header-left .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 24px;
    font-weight: 900;
}

.header-left .logo i {
    color: var(--electric-blue);
    font-size: 28px;
}

.header-right {
    display: flex;
    gap: 12px;
}

.btn-outline-sm,
.btn-primary-sm {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s;
}

.btn-outline-sm {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline-sm:hover {
    border-color: var(--electric-blue);
    color: var(--electric-blue);
    transform: translateY(-2px);
}

.btn-primary-sm {
    background: var(--electric-blue);
    border: none;
    color: white;
}

.btn-primary-sm:hover {
    background: var(--moss-green);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 173, 239, 0.3);
}

/* Search Section */
.search-section {
    padding: 24px;
    background: var(--bg-secondary);
    margin-bottom: 20px;
}

.search-bar {
    position: relative;
    margin-bottom: 16px;
}

.search-bar i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 16px;
}

.search-bar input {
    width: 100%;
    padding: 14px 14px 14px 48px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.3s;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--electric-blue);
    box-shadow: 0 0 0 3px rgba(0, 173, 239, 0.1);
}

/* Filter Bar */
.filter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    overflow-x: auto;
}

.filter-btn {
    padding: 10px 16px;
    border: 2px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}

.filter-btn:hover {
    background: var(--bg-primary);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--electric-blue);
    border-color: var(--electric-blue);
    color: white;
}

.filter-btn i {
    margin-right: 6px;
}

/* Sort Bar */
.sort-bar {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sort-bar label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
}

.sort-bar select {
    padding: 8px 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    background: var(--bg-secondary);
    cursor: pointer;
}

/* Stats Banner */
.stats-banner {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 0 24px 24px;
}

.stats-banner .stat-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: linear-gradient(135deg, var(--moss-green), var(--electric-blue));
    border-radius: 12px;
    color: white;
    box-shadow: 0 4px 12px var(--shadow);
}

.stat-icon {
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    backdrop-filter: blur(10px);
}

.stat-info {
    flex: 1;
}

.stat-value {
    font-size: 28px;
    font-weight: 900;
    margin-bottom: 2px;
}

.stat-label {
    font-size: 12px;
    opacity: 0.9;
}

/* Rooms Grid */
.rooms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 0 24px 40px;
}

/* Room Card */
.room-card {
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.room-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--moss-green), var(--electric-blue));
}

.room-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px var(--shadow);
    border-color: var(--electric-blue);
}

.room-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.room-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.room-code {
    font-size: 12px;
    color: var(--text-secondary);
    font-family: 'Courier New', monospace;
    font-weight: 600;
}

.room-badge {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.room-badge.public {
    background: var(--success);
    color: white;
}

.room-badge.full {
    background: var(--danger);
    color: white;
}

.room-badge.hot {
    background: var(--warning);
    color: white;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Room Stats */
.room-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 16px;
}

.room-stat {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background: var(--bg-primary);
    border-radius: 8px;
}

.room-stat i {
    color: var(--electric-blue);
    font-size: 16px;
}

.room-stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    display: block;
}

.room-stat-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
}

/* Progress Bar */
.room-progress {
    margin-bottom: 16px;
}

.room-progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.room-progress-bar {
    height: 8px;
    background: var(--bg-primary);
    border-radius: 4px;
    overflow: hidden;
}

.room-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--moss-green), var(--success));
    transition: width 0.5s;
}

/* Room Footer */
.room-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.room-members-count {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-secondary);
}

.room-members-count i {
    color: var(--electric-blue);
}

.room-action-btn {
    padding: 8px 16px;
    background: var(--electric-blue);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.room-action-btn:hover {
    background: var(--moss-green);
    transform: scale(1.05);
}

.room-action-btn:disabled {
    background: var(--border-color);
    color: var(--text-secondary);
    cursor: not-allowed;
    transform: none;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-secondary);
}

.empty-state i {
    color: var(--border-color);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
    margin-bottom: 24px;
}

/* Modal Detail */
.modal-lg {
    max-width: 600px;
}

.room-detail-info {
    background: var(--bg-primary);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row .label {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-row .label i {
    margin-right: 8px;
    color: var(--electric-blue);
}

.detail-row .value {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.room-description {
    margin-bottom: 20px;
}

.room-description h4,
.room-members-preview h4 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.room-description h4 i,
.room-members-preview h4 i {
    color: var(--electric-blue);
}

.room-description p {
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-secondary);
    padding: 12px;
    background: var(--bg-primary);
    border-radius: 8px;
}

.members-avatars {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.member-avatar {
    width: 40px;
    height: 40px;
    background: var(--electric-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 768px) {
    .stats-banner {
        grid-template-columns: 1fr;
    }
    
    .rooms-grid {
        grid-template-columns: 1fr;
    }
    
    .platform-header {
        flex-direction: column;
        gap: 16px;
    }
    
    .filter-bar {
        flex-wrap: nowrap;
        overflow-x: auto;
    }
}

@media (max-width: 480px) {
    .room-stats {
        grid-template-columns: 1fr;
    }
}
