/* Team Page Styles */

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    gap: 2rem;
}

.page-title h1 {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    color: var(--text-dark);
}

.page-title p {
    color: var(--text-gray);
    margin: 0;
    font-size: 1.125rem;
}

/* Filter Tabs */
.filter-tabs {
    display: flex;
    gap: 0.5rem;
    background: #f3f4f6;
    padding: 0.25rem;
    border-radius: 0.5rem;
}

.filter-tab {
    background: transparent;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-gray);
}

.filter-tab:hover {
    background: rgba(255, 255, 255, 0.5);
}

.filter-tab.active {
    background: white;
    color: var(--text-dark);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Team Section */
.team-section {
    margin-top: 2rem;
}

.team-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

/* Team Grid */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

/* Team Card */
.team-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
}

.team-card:hover {
    border-color: var(--mint-primary);
    box-shadow: 0 4px 12px rgba(0, 208, 132, 0.1);
    transform: translateY(-2px);
}

.team-card.pending {
    border-color: #f59e0b;
    background: linear-gradient(135deg, #ffffff 0%, rgba(245, 158, 11, 0.02) 100%);
}

.team-card.pending:hover {
    border-color: #d97706;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.1);
}

/* Member Avatar */
.member-avatar {
    position: relative;
    flex-shrink: 0;
}

.avatar.large {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
    font-weight: 700;
}

.avatar.pending {
    background: #f59e0b;
    color: white;
}

/* Status Indicator */
.status-indicator {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 3px solid white;
}

.status-indicator.online {
    background: #10b981;
}

.status-indicator.away {
    background: #f59e0b;
}

.status-indicator.offline {
    background: #6b7280;
}

.status-indicator.pending {
    background: #f59e0b;
    animation: pulse-yellow 2s infinite;
}

@keyframes pulse-yellow {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7);
    }
    
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(245, 158, 11, 0);
    }
    
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
    }
}

/* Member Info */
.member-info {
    flex: 1;
    min-width: 0;
}

.member-info h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
    color: var(--text-dark);
}

.member-email {
    font-size: 0.875rem;
    color: var(--text-gray);
    margin: 0 0 0.75rem 0;
}

.member-role {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.role-badge {
    font-size: 0.625rem;
    font-weight: 600;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    color: white;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.role-badge.owner {
    background: var(--mint-primary);
    color: white;
}

.role-badge.admin {
    background: #2563eb;
    color: white;
}

.role-badge.member {
    background: #7c3aed;
    color: white;
}

.role-badge.pending {
    background: #ea580c;
    color: white;
}

.role-badge.viewer {
    background: #6b7280;
    color: white;
}

.member-joined {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Member Actions */
.member-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.action-btn {
    background: none;
    border: none;
    color: var(--text-gray);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.action-btn:hover {
    background: #f3f4f6;
    color: var(--text-dark);
}

.action-btn.danger:hover {
    background: #fef2f2;
    color: #dc2626;
}

.action-btn svg {
    width: 18px;
    height: 18px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .section-actions {
        flex-direction: column;
        gap: 1rem;
    }
    
    .team-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .team-card {
        padding: 1rem;
    }
    
    .filter-tabs {
        justify-content: center;
    }
    
    .filter-tab {
        flex: 1;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .team-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .member-actions {
        justify-content: center;
    }
    
    .member-role {
        justify-content: center;
    }
}

/* Page Header */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.header-content h1 {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    color: var(--text-dark);
}

.header-content p {
    color: var(--text-gray);
    margin: 0;
    font-size: 1.125rem;
}

.header-stats {
    display: flex;
    gap: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--mint-primary);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-gray);
}

/* Team Section */
.team-section {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.section-title {
    width: 100%;
}

.section-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1rem;
}

.section-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-dark);
}

.section-actions {
    display: flex;
    gap: 0.75rem;
}

/* Members Grid */
.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.member-card {
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1.5rem;
    transition: all 0.2s ease;
    position: relative;
}

.member-card:hover {
    border-color: var(--mint-primary);
    box-shadow: 0 4px 12px rgba(0, 208, 132, 0.1);
}

.member-card.owner {
    border-color: var(--mint-primary);
    background: linear-gradient(135deg, rgba(0, 208, 132, 0.05) 0%, rgba(0, 208, 132, 0.02) 100%);
}

.member-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.member-avatar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.member-avatar .avatar {
    width: 48px;
    height: 48px;
    background: var(--mint-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.125rem;
    flex-shrink: 0;
}



.menu-btn {
    background: none;
    border: none;
    color: var(--text-gray);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
}

.menu-btn:hover {
    background: #f3f4f6;
    color: var(--text-dark);
}

.menu-btn svg {
    width: 20px;
    height: 20px;
}

.member-info h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
    color: var(--text-dark);
}

.member-email {
    color: var(--text-gray);
    font-size: 0.875rem;
    margin: 0 0 0.5rem 0;
}

.member-status {
    font-size: 0.75rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.member-status::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.member-status.online {
    color: #059669;
}

.member-status.online::before {
    background: #059669;
}

.member-status.away {
    color: #d97706;
}

.member-status.away::before {
    background: #d97706;
}

.member-status.offline {
    color: #6b7280;
}

.member-status.offline::before {
    background: #6b7280;
}

.member-stats {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f3f4f6;
}

.stat {
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-gray);
}

/* Invites List */
.invites-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.invite-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    background: #f9fafb;
}

.invite-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.invite-avatar .avatar {
    width: 40px;
    height: 40px;
    background: #d1d5db;
    color: #6b7280;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
}

.invite-details h4 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
    color: var(--text-dark);
}

.invite-details p {
    color: var(--text-gray);
    font-size: 0.875rem;
    margin: 0 0 0.25rem 0;
}

.invite-role {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.125rem 0.375rem;
    border-radius: 9999px;
    background: #e5e7eb;
    color: #6b7280;
    text-transform: uppercase;
}

.invite-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.invite-date {
    font-size: 0.875rem;
    color: var(--text-gray);
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

/* Buttons */
.btn-sm {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
}

.btn-secondary {
    background: #f3f4f6;
    color: var(--text-dark);
    border: 1px solid #e5e7eb;
}

.btn-secondary:hover {
    background: #e5e7eb;
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 0.75rem;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-dark);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-gray);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f3f4f6;
    color: var(--text-dark);
}

.modal-close svg {
    width: 20px;
    height: 20px;
}

/* Form */
.invite-form {
    padding: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--mint-primary);
    box-shadow: 0 0 0 3px rgba(0, 208, 132, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 2rem;
}

/* Member Dropdown Menu */
.member-dropdown {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    overflow: hidden;
}

.dropdown-header {
    padding: 0.75rem 1rem;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
}

.dropdown-header strong {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-dark);
}

.member-role {
    font-size: 0.75rem;
    color: var(--text-gray);
    text-transform: uppercase;
    font-weight: 500;
}

.dropdown-divider {
    height: 1px;
    background: #e5e7eb;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    width: 100%;
    border: none;
    background: none;
    color: var(--text-dark);
    font-size: 0.875rem;
    cursor: pointer;
    transition: background 0.2s ease;
    text-align: left;
}

.dropdown-item:hover {
    background: #f3f4f6;
}

.dropdown-item.danger {
    color: #ef4444;
}

.dropdown-item.danger:hover {
    background: #fef2f2;
}

.dropdown-item svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* Role Change Modal */
.modal-body {
    padding: 1.5rem;
}

.role-options {
    margin-top: 1rem;
}

.role-option {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.role-option:hover {
    border-color: var(--mint-primary);
    background: #f0fdf4;
}

.role-option input[type="radio"] {
    margin-top: 0.125rem;
}

.role-label {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
    display: block;
}

.role-description {
    font-size: 0.875rem;
    color: var(--text-gray);
    display: block;
}

.modal-footer {
    padding: 1.5rem;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
} 