﻿html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    height: 100%;
}

a, .btn-link {
    color: #006bb7;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

/* Mobile-first responsive styles */
.container-fluid {
    padding-left: 15px;
    padding-right: 15px;
}

/* Card styles for mobile */
.card {
    margin-bottom: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.card-header {
    background-color: #f8f9fa;
    font-weight: 600;
    padding: 0.75rem 1rem;
}

.card-body {
    padding: 1rem;
}

/* Responsive table wrapper */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1rem;
}

/* Mobile-friendly table */
.table-mobile {
    width: 100%;
    margin-bottom: 1rem;
}

.table-mobile thead {
    display: none;
}

.table-mobile tbody tr {
    display: block;
    margin-bottom: 1rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    background: white;
    padding: 0.75rem;
}

.table-mobile tbody td {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.table-mobile tbody td:last-child {
    border-bottom: none;
}

.table-mobile tbody td::before {
    content: attr(data-label);
    font-weight: 600;
    margin-right: 1rem;
    color: #495057;
}

/* Desktop table view */
@media (min-width: 768px) {
    .table-mobile thead {
        display: table-header-group;
    }

    .table-mobile tbody tr {
        display: table-row;
        border: none;
        padding: 0;
    }

    .table-mobile tbody td {
        display: table-cell;
        padding: 0.75rem;
        border-bottom: 1px solid #dee2e6;
    }

    .table-mobile tbody td::before {
        content: none;
    }
}

/* Tournament card for mobile */
.tournament-card {
    border-left: 4px solid #1b6ec2;
    transition: transform 0.2s, box-shadow 0.2s;
}

.tournament-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    cursor: pointer;
}

.tournament-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1b6ec2;
    margin-bottom: 0.5rem;
}

.tournament-meta {
    font-size: 0.9rem;
    color: #6c757d;
}

.tournament-date {
    display: inline-block;
    background: #e7f3ff;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85rem;
    margin-right: 0.5rem;
}

.tournament-status {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
}

.status-active {
    background: #d4edda;
    color: #155724;
}

.status-upcoming {
    background: #fff3cd;
    color: #856404;
}

.status-completed {
    background: #f8d7da;
    color: #721c24;
}

/* Search and filter styles */
.search-box {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.search-box:focus {
    outline: none;
    border-color: #1b6ec2;
    box-shadow: 0 0 0 0.2rem rgba(27, 110, 194, 0.25);
}

/* Player info card */
.player-card {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    border-bottom: 1px solid #e9ecef;
}

.player-card:last-child {
    border-bottom: none;
}

.player-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.2rem;
    margin-right: 1rem;
    flex-shrink: 0;
}

.player-info {
    flex-grow: 1;
}

.player-name {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.player-details {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Loading spinner */
.loading-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3rem;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
    border: 0.3em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}

@keyframes spinner-border {
    to { transform: rotate(360deg); }
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #6c757d;
}

.empty-state-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Utility classes */
.mb-3 { margin-bottom: 1rem; }
.mt-3 { margin-top: 1rem; }
.text-muted { color: #6c757d; }
.text-center { text-align: center; }
.fw-bold { font-weight: 600; }

/* Detail page styles */
.info-item {
    margin-bottom: 0.5rem;
}

.info-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #6c757d;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.info-value {
    font-size: 1rem;
    color: #212529;
    font-weight: 500;
}

/* Large avatar for detail pages */
.player-avatar-large {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 2rem;
    flex-shrink: 0;
}

/* Stat cards */
.stat-card {
    border: none;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: #1b6ec2;
}

.stat-label {
    font-size: 0.9rem;
    color: #6c757d;
    text-transform: uppercase;
    font-weight: 600;
}

/* Participant/Stage items */
.participant-item,
.stage-item,
.tournament-history-item {
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s;
}

.participant-item:hover,
.tournament-history-item:hover {
    background-color: #f8f9fa;
    cursor: pointer;
}

.participant-item:last-child,
.stage-item:last-child,
.tournament-history-item:last-child {
    border-bottom: none;
}

.participant-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

/* Placement badges */
.placement-badge {
    background: #ffd700;
    color: #000;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
}

.placement-badge-large {
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    color: #000;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Gender badge */
.bg-pink {
    background-color: #e91e63 !important;
    color: white;
}

/* Stage item specific */
.stage-item {
    padding: 1rem;
}

/* Score highlighting */
.text-success {
    color: #28a745 !important;
}

.text-primary {
    color: #007bff !important;
}

/* Responsive adjustments for detail pages */
@media (max-width: 767px) {
    .player-avatar-large {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .stat-icon {
        font-size: 2rem;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }
}

/* Bootstrap Icons alignment */
.bi {
    display: inline-block;
    vertical-align: middle;
    line-height: 1;
}

/* Icon alignment in buttons */
.btn .bi {
    vertical-align: text-top;
    margin-right: 0.25rem;
}

/* Icon alignment in headings */
h1 .bi, h2 .bi, h3 .bi, h4 .bi, h5 .bi, h6 .bi {
    vertical-align: middle;
    margin-right: 0.5rem;
}

/* Icon alignment in badges */
.badge .bi {
    vertical-align: text-top;
    margin-right: 0.25rem;
}

/* Icon alignment in regular text */
p .bi, span .bi, small .bi {
    vertical-align: middle;
}

/* Icon sizing helpers */
.bi-sm {
    font-size: 0.875rem;
}

.bi-lg {
    font-size: 1.5rem;
}

.bi-xl {
    font-size: 2rem;
}

.bi-xxl {
    font-size: 2.5rem;
}

/* Icon in stat cards */
.stat-icon .bi {
    font-size: 2.5rem;
    vertical-align: middle;
}

/* Icon in empty state */
.empty-state-icon .bi {
    font-size: 3rem;
    vertical-align: middle;
}



