/* ===== Team Punishments Styles ===== */

/* Container */
.team-punishments-container {
    padding: var(--team-space-xl);
}

/* Stats Grid */
.team-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--team-space-lg);
    margin-bottom: var(--team-space-xl);
}

.team-stat-card {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.8), rgba(22, 33, 62, 0.8));
    border: 1px solid var(--team-dark-border);
    border-radius: var(--team-radius-lg);
    padding: var(--team-space-lg);
    display: flex;
    align-items: center;
    gap: var(--team-space-md);
    transition: var(--team-transition);
    position: relative;
    overflow: hidden;
}

.team-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--team-gradient-primary);
    opacity: 0;
    transition: var(--team-transition);
}

.team-stat-card:hover::before {
    opacity: 1;
}

.team-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--team-shadow-lg), var(--team-shadow-glow);
}

.team-stat-card.team-stat-primary::before {
    background: linear-gradient(90deg, #a855f7, #06b6d4);
}

.team-stat-card.team-stat-warning::before {
    background: linear-gradient(90deg, #f59e0b, #ef4444);
}

.team-stat-card.team-stat-success::before {
    background: linear-gradient(90deg, #10b981, #06b6d4);
}

.team-stat-card.team-stat-info::before {
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
}

.team-stat-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: var(--team-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.team-stat-card.team-stat-primary .team-stat-icon {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(6, 182, 212, 0.2));
    border: 1px solid rgba(168, 85, 247, 0.3);
    color: #a855f7;
}

.team-stat-card.team-stat-warning .team-stat-icon {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(239, 68, 68, 0.2));
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.team-stat-card.team-stat-success .team-stat-icon {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(6, 182, 212, 0.2));
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.team-stat-card.team-stat-info .team-stat-icon {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(139, 92, 246, 0.2));
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.team-stat-content {
    flex: 1;
}

.team-stat-value {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--team-gray-100);
    line-height: 1;
    margin-bottom: var(--team-space-xs);
}

.team-stat-label {
    font-size: 0.875rem;
    color: var(--team-gray-400);
}

/* Filters */
.team-filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--team-space-md);
}

.team-filter-group {
    display: flex;
    flex-direction: column;
    gap: var(--team-space-xs);
}

.team-filter-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--team-gray-300);
}

.team-input,
.team-select,
.team-textarea {
    width: 100%;
    padding: var(--team-space-sm) var(--team-space-md);
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: var(--team-radius);
    color: var(--team-gray-100);
    font-size: 0.875rem;
    transition: var(--team-transition);
}

.team-input:focus,
.team-select:focus,
.team-textarea:focus {
    outline: none;
    border-color: var(--team-primary);
    box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.1);
    background: rgba(26, 26, 46, 0.8);
}

.team-input::placeholder {
    color: var(--team-gray-500);
}

.team-textarea {
    resize: vertical;
    min-height: 100px;
}

/* Table */
.team-table-container {
    overflow-x: auto;
    border-radius: var(--team-radius-lg);
    border: 1px solid var(--team-dark-border);
}

.team-table {
    width: 100%;
    border-collapse: collapse;
}

.team-table thead {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95), rgba(22, 33, 62, 0.95));
}

.team-table th {
    padding: var(--team-space-md);
    text-align: left;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--team-primary-light);
    border-bottom: 2px solid var(--team-primary);
}

.team-table tbody tr {
    border-bottom: 1px solid var(--team-dark-border);
    transition: var(--team-transition);
}

.team-table tbody tr:hover {
    background: rgba(168, 85, 247, 0.05);
}

.team-table td {
    padding: var(--team-space-md);
    font-size: 0.875rem;
    color: var(--team-gray-300);
}

.team-table-empty {
    text-align: center;
    padding: var(--team-space-xl) !important;
    color: var(--team-gray-500);
}

.team-user-cell {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.team-user-jid {
    font-weight: 500;
    color: var(--team-gray-200);
}

.team-char-name {
    font-weight: 500;
    color: var(--team-primary-light);
}

/* Badges */
.team-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: var(--team-radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid;
}

.team-badge-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.team-badge-warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.team-badge-info {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.team-badge-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.team-badge-secondary {
    background: rgba(107, 114, 128, 0.1);
    border-color: rgba(107, 114, 128, 0.3);
    color: #6b7280;
}

/* Actions */
.team-actions {
    display: flex;
    gap: var(--team-space-xs);
}

.team-btn-icon {
    width: 2rem;
    height: 2rem;
    border-radius: var(--team-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid;
    background: transparent;
    cursor: pointer;
    transition: var(--team-transition);
}

.team-btn-icon.team-btn-info {
    border-color: rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.team-btn-icon.team-btn-info:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
}

.team-btn-icon.team-btn-warning {
    border-color: rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.team-btn-icon.team-btn-warning:hover {
    background: rgba(245, 158, 11, 0.1);
    border-color: #f59e0b;
}

.team-btn-icon.team-btn-danger {
    border-color: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.team-btn-icon.team-btn-danger:hover {
    background: rgba(239, 68, 68, 0.1);
    border-color: #ef4444;
}

/* Modal Overlay */
.team-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: var(--team-space-lg);
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Modal */
.team-modal {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.98), rgba(22, 33, 62, 0.98));
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: var(--team-radius-xl);
    box-shadow: var(--team-shadow-xl), 0 0 60px rgba(168, 85, 247, 0.3);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.team-modal.team-modal-sm {
    max-width: 450px;
}

.team-modal.team-modal-lg {
    max-width: 900px;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Modal Header */
.team-modal-header {
    padding: var(--team-space-xl);
    border-bottom: 1px solid rgba(168, 85, 247, 0.2);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.1), rgba(6, 182, 212, 0.05));
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.team-modal-header.team-modal-header-danger {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(220, 38, 38, 0.05));
}

.team-modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--team-gray-100);
    margin: 0;
    display: flex;
    align-items: center;
    gap: var(--team-space-sm);
}

.team-modal-close {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--team-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    cursor: pointer;
    transition: var(--team-transition);
}

.team-modal-close:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: rotate(90deg);
}

/* Modal Body */
.team-modal-body {
    padding: var(--team-space-xl);
}

/* Form */
.team-form {
    display: flex;
    flex-direction: column;
    gap: var(--team-space-lg);
}

.team-form-group {
    display: flex;
    flex-direction: column;
    gap: var(--team-space-xs);
}

.team-form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--team-space-md);
}

.team-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--team-gray-200);
    display: flex;
    align-items: center;
    gap: var(--team-space-xs);
}

.team-label.required::after {
    content: '*';
    color: #ef4444;
    margin-left: 4px;
}

.team-error {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.team-error::before {
    content: '⚠';
}

/* Radio Cards */
.team-radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--team-space-md);
}

.team-radio-card {
    position: relative;
    cursor: pointer;
}

.team-radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.team-radio-content {
    padding: var(--team-space-lg);
    background: rgba(26, 26, 46, 0.6);
    border: 2px solid rgba(168, 85, 247, 0.2);
    border-radius: var(--team-radius-lg);
    transition: var(--team-transition);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--team-space-sm);
    min-height: 140px;
}

.team-radio-content svg {
    width: 2rem;
    height: 2rem;
    color: var(--team-primary-light);
    transition: var(--team-transition);
}

.team-radio-content span {
    font-weight: 600;
    color: var(--team-gray-200);
    font-size: 0.875rem;
}

.team-radio-content p {
    font-size: 0.75rem;
    color: var(--team-gray-400);
    margin: 0;
}

.team-radio-card input[type="radio"]:checked + .team-radio-content {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(6, 182, 212, 0.1));
    border-color: var(--team-primary);
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.3);
}

.team-radio-card input[type="radio"]:checked + .team-radio-content svg {
    color: var(--team-primary);
    transform: scale(1.1);
}

.team-radio-card:hover .team-radio-content {
    border-color: rgba(168, 85, 247, 0.4);
    transform: translateY(-2px);
}

/* Info Card */
.team-info-card {
    background: rgba(168, 85, 247, 0.05);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: var(--team-radius-lg);
    padding: var(--team-space-lg);
    margin-bottom: var(--team-space-lg);
}

.team-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--team-space-sm) 0;
    border-bottom: 1px solid rgba(168, 85, 247, 0.1);
}

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

.team-info-label {
    font-size: 0.875rem;
    color: var(--team-gray-400);
    font-weight: 500;
}

.team-info-value {
    font-size: 0.875rem;
    color: var(--team-gray-100);
    font-weight: 600;
}

/* Alert */
.team-alert {
    display: flex;
    gap: var(--team-space-md);
    padding: var(--team-space-lg);
    border-radius: var(--team-radius-lg);
    border: 1px solid;
    margin-bottom: var(--team-space-lg);
}

.team-alert svg {
    flex-shrink: 0;
    width: 1.5rem;
    height: 1.5rem;
}

.team-alert.team-alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.team-alert h4 {
    font-size: 0.875rem;
    font-weight: 700;
    margin: 0 0 var(--team-space-xs) 0;
    color: inherit;
}

.team-alert p {
    font-size: 0.75rem;
    margin: 0;
    opacity: 0.9;
}

/* Details Grid */
.team-details-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--team-space-lg);
}

.team-details-section {
    background: rgba(26, 26, 46, 0.4);
    border: 1px solid rgba(168, 85, 247, 0.15);
    border-radius: var(--team-radius-lg);
    padding: var(--team-space-lg);
}

.team-details-section.team-details-full {
    grid-column: 1 / -1;
}

.team-details-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--team-primary-light);
    margin: 0 0 var(--team-space-md) 0;
    padding-bottom: var(--team-space-sm);
    border-bottom: 2px solid rgba(168, 85, 247, 0.2);
}

.team-details-list {
    display: flex;
    flex-direction: column;
    gap: var(--team-space-sm);
}

.team-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--team-space-sm);
    background: rgba(168, 85, 247, 0.03);
    border-radius: var(--team-radius);
}

.team-detail-label {
    font-size: 0.875rem;
    color: var(--team-gray-400);
    font-weight: 500;
}

.team-detail-value {
    font-size: 0.875rem;
    color: var(--team-gray-100);
    font-weight: 600;
    text-align: right;
}

.team-text-warning {
    color: #f59e0b !important;
}

.team-description-box {
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: var(--team-radius-lg);
    padding: var(--team-space-md);
    color: var(--team-gray-300);
    font-size: 0.875rem;
    line-height: 1.6;
    white-space: pre-wrap;
    max-height: 200px;
    overflow-y: auto;
}

/* Modal Actions */
.team-modal-actions {
    display: flex;
    gap: var(--team-space-md);
    justify-content: flex-end;
    margin-top: var(--team-space-xl);
    padding-top: var(--team-space-lg);
    border-top: 1px solid rgba(168, 85, 247, 0.2);
}

.team-btn {
    padding: var(--team-space-sm) var(--team-space-lg);
    border-radius: var(--team-radius-lg);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--team-transition);
    border: 1px solid;
    display: inline-flex;
    align-items: center;
    gap: var(--team-space-xs);
}

.team-btn-primary {
    background: linear-gradient(135deg, #a855f7, #06b6d4);
    border-color: transparent;
    color: var(--team-white);
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.3);
}

.team-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(168, 85, 247, 0.4);
}

.team-btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-color: transparent;
    color: var(--team-white);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.team-btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

.team-btn-secondary {
    background: rgba(107, 114, 128, 0.1);
    border-color: rgba(107, 114, 128, 0.3);
    color: var(--team-gray-300);
}

.team-btn-secondary:hover {
    background: rgba(107, 114, 128, 0.2);
    border-color: rgba(107, 114, 128, 0.5);
}

.team-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Pagination */
.team-pagination {
    margin-top: var(--team-space-lg);
    display: flex;
    justify-content: center;
}

/* Enhanced Pagination Styles */
.team-pagination nav {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

/* Show only the pagination links, hide the showing text */
.team-pagination nav > div.hidden {
    display: flex !important;
    justify-content: center;
    align-items: center;
}

.team-pagination nav > div:not(.hidden) {
    display: none !important;
}

.team-pagination .flex {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    justify-content: center;
}

/* Pagination Links Container */
.team-pagination .flex-1 {
    display: flex !important;
    justify-content: center;
    gap: 0.5rem;
}

/* Previous & Next Buttons */
.team-pagination a,
.team-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    transition: all 0.25s ease;
    border: 2px solid;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

/* Active Link (Current Page) */
.team-pagination span[aria-current="page"] {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.4);
    cursor: default;
}

/* Regular Links */
.team-pagination a {
    background: white;
    color: #6b7280;
    border-color: #e5e7eb;
    text-decoration: none;
}

.team-pagination a:hover {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    border-color: #d1d5db;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    color: #374151;
}

/* Previous & Next Buttons Specific Styling */
.team-pagination a[rel="prev"],
.team-pagination a[rel="next"] {
    padding: 0.625rem 1.25rem;
    font-weight: 700;
    gap: 0.5rem;
}

.team-pagination a[rel="prev"]:hover,
.team-pagination a[rel="next"]:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.4);
}

/* Disabled State */
.team-pagination span[aria-disabled="true"] {
    background: #f3f4f6;
    color: #d1d5db;
    border-color: #e5e7eb;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Add Icons to Previous/Next */
.team-pagination a[rel="prev"]::before {
    content: "←";
    font-size: 1rem;
    font-weight: bold;
}

.team-pagination a[rel="next"]::after {
    content: "→";
    font-size: 1rem;
    font-weight: bold;
}

/* Number Links */
.team-pagination a:not([rel]),
.team-pagination span:not([aria-current]):not([aria-disabled]) {
    min-width: 2.5rem;
    padding: 0.5rem 0.75rem;
}

/* Dots Separator */
.team-pagination span:not([aria-current]):not([aria-disabled]) {
    background: transparent;
    border-color: transparent;
    color: #9ca3af;
    cursor: default;
    box-shadow: none;
}

/* Responsive */
@media (max-width: 1024px) {
    .team-details-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .team-punishments-container {
        padding: var(--team-space-md);
    }

    .team-stats-grid {
        grid-template-columns: 1fr;
    }

    .team-filters-grid {
        grid-template-columns: 1fr;
    }

    .team-form-row {
        grid-template-columns: 1fr;
    }

    .team-radio-group {
        grid-template-columns: 1fr;
    }

    .team-modal {
        max-width: 95%;
        margin: var(--team-space-md);
    }

    .team-modal-header,
    .team-modal-body {
        padding: var(--team-space-md);
    }

    .team-table-container {
        overflow-x: scroll;
    }

    .team-modal-actions {
        flex-direction: column-reverse;
    }

    .team-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Scrollbar */
.team-modal::-webkit-scrollbar,
.team-description-box::-webkit-scrollbar {
    width: 8px;
}

.team-modal::-webkit-scrollbar-track,
.team-description-box::-webkit-scrollbar-track {
    background: rgba(26, 26, 46, 0.5);
    border-radius: 4px;
}

.team-modal::-webkit-scrollbar-thumb,
.team-description-box::-webkit-scrollbar-thumb {
    background: rgba(168, 85, 247, 0.5);
    border-radius: 4px;
}

.team-modal::-webkit-scrollbar-thumb:hover,
.team-description-box::-webkit-scrollbar-thumb:hover {
    background: rgba(168, 85, 247, 0.7);
}

/* Character Avatar Cards */
.team-char-avatar-card {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.08), rgba(6, 182, 212, 0.05));
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.team-char-avatar-card:hover {
    transform: translateY(-5px);
    border-color: rgba(168, 85, 247, 0.6);
    box-shadow: 0 10px 30px rgba(168, 85, 247, 0.3);
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.12), rgba(6, 182, 212, 0.08));
}

.team-char-avatar-wrapper {
    width: 80px;
    height: 80px;
    margin: 0 auto 12px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid rgba(168, 85, 247, 0.5);
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(6, 182, 212, 0.2));
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.team-char-avatar-card:hover .team-char-avatar-wrapper {
    border-color: rgba(168, 85, 247, 0.8);
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
}

.team-char-avatar-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-char-name {
    font-weight: 700;
    color: var(--team-primary-light);
    font-size: 0.875rem;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.3s ease;
}

.team-char-avatar-card:hover .team-char-name {
    color: var(--team-primary);
    transform: scale(1.05);
}

.team-char-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

@media (max-width: 768px) {
    .team-char-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 12px;
    }

    .team-char-avatar-wrapper {
        width: 60px;
        height: 60px;
    }
}

/* Character Search Autocomplete Dropdown */
.team-char-autocomplete {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 50;
    margin-top: 0.25rem;
    max-height: 300px;
    overflow-y: auto;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.98), rgba(22, 33, 62, 0.98));
    border: 2px solid rgba(168, 85, 247, 0.3);
    border-radius: 0.75rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2), 0 0 30px rgba(168, 85, 247, 0.3);
    animation: slideDown 0.3s ease-out;
    backdrop-filter: blur(10px);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.team-char-autocomplete::-webkit-scrollbar {
    width: 6px;
}

.team-char-autocomplete::-webkit-scrollbar-track {
    background: rgba(26, 26, 46, 0.5);
    border-radius: 3px;
}

.team-char-autocomplete::-webkit-scrollbar-thumb {
    background: rgba(168, 85, 247, 0.5);
    border-radius: 3px;
}

.team-char-autocomplete::-webkit-scrollbar-thumb:hover {
    background: rgba(168, 85, 247, 0.7);
}

.team-char-autocomplete-item {
    width: 100%;
    padding: 0.875rem 1rem;
    text-align: left;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(168, 85, 247, 0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.team-char-autocomplete-item:last-child {
    border-bottom: none;
}

.team-char-autocomplete-item:hover {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(6, 182, 212, 0.08));
    transform: translateX(4px);
}

.team-char-autocomplete-item:active {
    transform: translateX(2px) scale(0.98);
}

.team-char-autocomplete-avatar {
    width: 40px;
    height: 40px;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 2px solid rgba(168, 85, 247, 0.3);
    flex-shrink: 0;
    background: rgba(168, 85, 247, 0.1);
    transition: all 0.2s ease;
}

.team-char-autocomplete-item:hover .team-char-autocomplete-avatar {
    border-color: rgba(168, 85, 247, 0.6);
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.4);
}

.team-char-autocomplete-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-char-autocomplete-info {
    flex: 1;
    min-width: 0;
}

.team-char-autocomplete-name {
    font-weight: 600;
    color: var(--team-gray-100);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
    transition: color 0.2s ease;
}

.team-char-autocomplete-item:hover .team-char-autocomplete-name {
    color: var(--team-primary-light);
}

.team-char-autocomplete-level {
    padding: 0.125rem 0.5rem;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.3), rgba(118, 75, 162, 0.3));
    color: white;
    border-radius: 0.375rem;
    font-size: 0.7rem;
    font-weight: 600;
    border: 1px solid rgba(168, 85, 247, 0.4);
}

.team-char-autocomplete-id {
    font-size: 0.75rem;
    color: var(--team-gray-500);
    font-family: var(--team-font-mono);
}

.team-char-autocomplete-arrow {
    flex-shrink: 0;
    color: var(--team-gray-600);
    transition: all 0.2s ease;
}

.team-char-autocomplete-item:hover .team-char-autocomplete-arrow {
    color: var(--team-primary-light);
    transform: translateX(4px);
}

/* Loading Spinner */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.team-loading-spinner {
    animation: spin 1s linear infinite;
}

/* Character Details Card */
.team-char-details-card {
    margin-top: 1rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(96, 165, 250, 0.05));
    border: 2px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.75rem;
    animation: fadeIn 0.3s ease-in;
}

.team-char-details-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

.team-char-details-header svg {
    color: #3b82f6;
}

.team-char-details-header h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e40af;
}

.team-char-details-content {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.team-char-details-avatar {
    width: 80px;
    height: 80px;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 3px solid #3b82f6;
    flex-shrink: 0;
    background: white;
}

.team-char-details-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-char-details-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.team-char-details-item {
    display: flex;
    flex-direction: column;
}

.team-char-details-label {
    font-size: 0.75rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.team-char-details-value {
    font-weight: 600;
    color: #1f2937;
    font-size: 0.875rem;
}

.team-char-details-item.full-width {
    grid-column: span 2;
}

/* Device Info Card */
.team-device-info-card {
    margin-top: 1rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(253, 224, 71, 0.05));
    border: 2px solid rgba(245, 158, 11, 0.3);
    border-radius: 0.75rem;
}

.team-device-info-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(245, 158, 11, 0.2);
}

.team-device-info-header svg {
    color: #f59e0b;
}

.team-device-info-header h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #92400e;
}

.team-device-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.team-device-info-item {
    display: flex;
    flex-direction: column;
}

.team-device-info-label {
    font-size: 0.75rem;
    color: #78350f;
    margin-bottom: 0.25rem;
}

.team-device-info-value {
    font-weight: 600;
    color: #92400e;
    font-family: var(--team-font-mono);
    word-break: break-all;
    font-size: 0.875rem;
}

/* Validation Error */
.team-validation-error {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

.team-validation-error svg {
    color: #ef4444;
    flex-shrink: 0;
}

.team-validation-error span {
    font-size: 0.875rem;
    color: #991b1b;
    font-weight: 500;
}

/* Responsive for autocomplete */
@media (max-width: 768px) {
    .team-char-autocomplete {
        max-height: 250px;
    }

    .team-char-details-content {
        flex-direction: column;
    }

    .team-char-details-grid {
        grid-template-columns: 1fr;
    }

    .team-char-details-item.full-width {
        grid-column: span 1;
    }

    .team-device-info-grid {
        grid-template-columns: 1fr;
    }
}
