/**
 * Profile page styles
 *
 * @package Kildare_Membership
 */

/* ===== Profile Container ===== */
.kc-profile-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 30px 20px;
}

/* ===== Profile Header ===== */
.kc-profile-header {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 30px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 12px;
    margin-bottom: 24px;
}

.kc-profile-avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.kc-profile-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #00d9ff;
    background: #333;
    display: flex;
    align-items: center;
    justify-content: center;
}

.kc-profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kc-avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #666;
}

.kc-avatar-placeholder .dashicons {
    font-size: 40px;
    width: 40px;
    height: 40px;
}

.kc-profile-info {
    flex: 1;
}

.kc-profile-username {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
}

.kc-profile-email {
    color: #999;
    font-size: 0.95rem;
    margin: 0 0 4px;
}

.kc-profile-meta {
    color: #666;
    font-size: 0.85rem;
    margin: 0;
}

/* ===== Profile Sections ===== */
.kc-profile-sections {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.kc-profile-section {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 24px;
}

.kc-section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #333;
}

.kc-profile-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Reuse form input styles from auth.css */
.kc-profile-form .kc-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.kc-profile-form label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #ccc;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.kc-profile-actions {
    display: flex;
    justify-content: flex-start;
}

/* ===== Avatar Modal ===== */
.kc-avatar-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.kc-avatar-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.kc-avatar-modal-content {
    position: relative;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    background: #1a1a1a;
    border: 1px solid #444;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.kc-avatar-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #333;
}

.kc-avatar-modal-header h3 {
    margin: 0;
    color: #fff;
    font-size: 1.1rem;
}

.kc-avatar-modal-close {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px;
    display: flex;
}

.kc-avatar-modal-close:hover {
    color: #fff;
}

/* Avatar Grid */
.kc-avatar-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    padding: 20px;
    overflow-y: auto;
    max-height: 50vh;
}

.kc-avatar-option {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid transparent;
    cursor: pointer;
    background: #333;
    padding: 0;
    transition: all 0.2s;
}

.kc-avatar-option:hover {
    border-color: #666;
    transform: scale(1.05);
}

.kc-avatar-option.kc-avatar-selected {
    border-color: #00d9ff;
    box-shadow: 0 0 12px rgba(0, 217, 255, 0.3);
}

.kc-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.kc-avatar-check {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 22px;
    height: 22px;
    background: #00d9ff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.kc-avatar-check .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    color: #0d0d0d;
}

.kc-no-avatars {
    grid-column: 1 / -1;
    text-align: center;
    color: #666;
}

.kc-avatar-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid #333;
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
    .kc-profile-header {
        flex-direction: column;
        text-align: center;
        padding: 24px 20px;
    }

    .kc-profile-section {
        padding: 20px 16px;
    }

    .kc-avatar-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        padding: 16px;
    }
}
