/* Picks Page Styles */
.picks-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0.5rem;
}

.picks-summary {
    background: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.picks-count {
    font-size: 0.9rem;
}

.picks-count span {
    color: #013369;
    font-weight: bold;
    font-size: 1.2rem;
}

.games-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.game-card {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
    transition: all 0.2s ease;
    margin-bottom: 0.75rem;
}

.game-card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);
}

.game-expired {
    opacity: 0.6;
    background: #f8f9fa;
}

.game-time {
    text-align: center;
    font-weight: 600;
    color: #666;
    margin-bottom: 0.4rem;
    font-size: 0.75rem;
}

.badge-expired {
    background: #ffc107;
    color: #000;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-size: 0.65rem;
    margin-left: 0.4rem;
    font-weight: 600;
}

.badge-final {
    background: #6c757d;
    color: white;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-size: 0.65rem;
    margin-left: 0.4rem;
    font-weight: 600;
}

.game-matchup {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 0.5rem;
    align-items: center;
    width: 100%;
}

.vs {
    font-weight: bold;
    color: #999;
    font-size: 0.85rem;
    padding: 0 0.5rem;
    flex-shrink: 0;
}

.team-pick {
    display: flex;
}

.team-label {
    flex: 1;
    cursor: pointer;
    padding: 0.4rem 0.5rem;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    transition: all 0.2s ease;
    background: white;
    display: flex;
    align-items: center;
    position: relative;
}

.team-label:hover:not(.locked):not(.disabled-pick) {
    border-color: #013369;
    background: #f8f9fa;
}

.team-label.selected {
    border-color: #28a745;
    background: #d4edda;
    box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2);
}

.team-label.selected:hover:not(.locked) {
    border-color: #218838;
    background: #c3e6cb;
}

.team-label.locked {
    opacity: 0.6;
    cursor: not-allowed;
    border-color: #e0e0e0;
    background: #f8f9fa;
    pointer-events: none;
}

.team-label.disabled-pick {
    opacity: 0.4;
    cursor: not-allowed;
    border-color: #e0e0e0;
    background: #f8f8f8;
    pointer-events: none;
}

.team-label.disabled-pick:hover {
    border-color: #e0e0e0;
    background: #f8f8f8;
    transform: none;
}

.team-label input[type="checkbox"] {
    display: none;
}

.team-info-pick {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.team-logo-wrapper {
    position: relative;
    flex-shrink: 0;
}

.team-logo-pick {
    width: 28px;
    height: 28px;
    object-fit: contain;
    display: block;
}

.selected-checkmark {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    background: #28a745;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    animation: checkmarkPop 0.2s ease;
}

@keyframes checkmarkPop {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.team-details {
    flex: 1;
    min-width: 0;
}

.team-name-with-spread {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.team-name {
    font-weight: 600;
    font-size: 0.85rem;
    color: #013369;
    line-height: 1.2;
}

.team-label.selected .team-name {
    color: #155724;
}

.team-spread-inline {
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.2;
    display: inline-flex;
    align-items: center;
}

.pick-indicator {
    margin-left: auto;
    flex-shrink: 0;
    padding-left: 0.5rem;
}

.pick-label {
    background: #28a745;
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
    display: inline-block;
}

.team-spread {
    font-size: 0.7rem;
    color: #666;
    line-height: 1.2;
}

.game-score {
    text-align: center;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid #eee;
    font-weight: 600;
    font-size: 0.75rem;
    color: #28a745;
}

.picks-submit {
    text-align: center;
    margin-top: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.picks-container:has(#picks-dock) {
    padding-bottom: 6.5rem;
}

.picks-dock {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    background: #013369;
    color: #fff;
    box-shadow: 0 -6px 20px rgba(1, 51, 105, 0.22);
    padding: 0.7rem 1rem calc(0.7rem + env(safe-area-inset-bottom));
}

.picks-dock-inner {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.picks-dock-status {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.picks-dock-dots {
    display: flex;
    gap: 0.35rem;
}

.picks-dock-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.picks-dock-dot.filled {
    background: #ffc107;
    border-color: #ffc107;
}

.picks-dock.is-complete .picks-dock-dot.filled {
    background: #28a745;
    border-color: #28a745;
}

.picks-dock-count {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.picks-dock-count .js-pick-count {
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffc107;
}

.picks-dock.is-complete .picks-dock-count .js-pick-count {
    color: #8ee5a8;
}

.picks-dock .btn-primary {
    background: #ffc107;
    color: #013369;
    border: none;
    font-weight: 700;
}

.picks-dock .btn-primary:hover {
    background: #ffca2c;
    color: #013369;
}

.btn-large {
    font-size: 1rem;
    padding: 0.75rem 2rem;
}

.picks-note {
    margin-top: 0.5rem;
    color: #666;
    font-size: 0.8rem;
}

.no-games {
    text-align: center;
    padding: 3rem;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Groups Page Styles */
.groups-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.current-group,
.no-group,
.available-groups,
.create-group {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.current-group h3,
.no-group h3,
.available-groups h3,
.create-group h3 {
    color: #013369;
    margin-bottom: 1rem;
}

.groups-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.group-card {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border: 2px solid #ddd;
    transition: border-color 0.3s;
}

.group-card:hover {
    border-color: #013369;
}

.group-card h4 {
    color: #013369;
    margin-bottom: 0.5rem;
}

.group-privacy {
    color: #666;
    font-size: 0.9rem;
    margin: 0.5rem 0;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
}

/* Group Details */
.group-details {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.group-info h4 {
    color: #013369;
    margin-bottom: 0.5rem;
}

.admin-badge {
    color: #ffc107;
    font-weight: 600;
    margin-top: 0.5rem;
}

.group-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-self: flex-start;
}

.group-members {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.25rem;
}

.group-member-chip {
    background: #f4f6f8;
    color: #013369;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    font-size: 0.9rem;
}

.group-member-chip.is-you {
    background: #013369;
    color: white;
    font-weight: 600;
}

.group-card-actions {
    margin-top: 1rem;
}

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-weight: 600;
}

.badge-success {
    background: #d4edda;
    color: #155724;
}

.badge-locked {
    background: #fff3cd;
    color: #856404;
}

.group-admin-nav {
    max-width: 1100px;
    margin: 0 auto 1rem;
}

.group-admin-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.group-admin-section {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.group-admin-section h3 {
    color: #013369;
    margin-bottom: 0.5rem;
}

.group-admin-section p {
    color: #666;
    margin-bottom: 1rem;
}

.group-admin-add {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.group-admin-add input[type="email"] {
    flex: 1;
    min-width: 220px;
    padding: 0.6rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.dues-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1rem;
    margin: 0 0 1rem;
}

.dues-toolbar p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
    max-width: 40rem;
}

.dues-table-wrap {
    overflow-x: auto;
}

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

.dues-table th,
.dues-table td {
    padding: 0.65rem 0.5rem;
    text-align: left;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.dues-table th {
    color: #013369;
    font-size: 0.85rem;
}

.dues-table select,
.dues-table input[type="text"] {
    width: 100%;
    min-width: 140px;
    padding: 0.4rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.dues-table small {
    display: block;
    color: #888;
    font-size: 0.75rem;
    margin-top: 0.2rem;
}

.dues-notes {
    margin-top: 1.25rem;
}

.dues-notes label {
    display: block;
    color: #013369;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.dues-notes p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.dues-notes textarea {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-family: inherit;
    font-size: 0.95rem;
    line-height: 1.5;
    resize: vertical;
}

.create-group-cta {
    background: linear-gradient(135deg, #013369 0%, #0056b3 100%);
    color: white;
    padding: 3rem;
    border-radius: 10px;
    text-align: center;
}

.create-group-cta h3 {
    color: white;
    margin-bottom: 1rem;
}

.create-group-cta p {
    margin-bottom: 1.5rem;
}

/* Form Styles */
.form-container {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.group-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: #495057;
}

.form-input {
    padding: 0.75rem;
    border: 2px solid #dee2e6;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-input:focus {
    outline: none;
    border-color: #013369;
}

.form-group small {
    color: #6c757d;
    font-size: 0.875rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-weight: normal;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.form-info {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 5px;
    border-left: 4px solid #013369;
}

.form-info h4 {
    color: #013369;
    margin-bottom: 1rem;
}

.form-info ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.form-info li {
    padding: 0.5rem 0;
    color: #495057;
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.private-group-notice {
    background: #fff3cd;
    border: 1px solid #ffc107;
    padding: 1.5rem;
    border-radius: 5px;
    margin-bottom: 2rem;
}

.private-group-notice h3 {
    color: #856404;
    margin-bottom: 0.5rem;
}

.private-group-notice p {
    color: #856404;
    margin: 0;
}

/* Leaderboard Page Styles */
.leaderboard-container {
    max-width: 1200px;
    margin: 0 auto;
}

.leaderboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    text-align: center;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #013369;
    margin-bottom: 0.25rem;
}

.stat-label {
    color: #666;
    font-size: 0.9rem;
}

.leaderboard-table-container {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow-x: auto;
    margin-bottom: 2rem;
}

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

.leaderboard-table thead {
    background: #013369;
    color: white;
}

.leaderboard-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    white-space: nowrap;
}

.leaderboard-table tbody tr {
    border-bottom: 1px solid #eee;
    transition: background 0.2s;
}

.leaderboard-table tbody tr:hover {
    background: #f8f9fa;
}

.leaderboard-table.you-ghost-table {
    margin-bottom: 0.65rem;
}

.leaderboard-table tbody tr.you-ghost {
    background: #f3f7fb !important;
    outline: 1px dashed #013369;
    outline-offset: -1px;
}

.leaderboard-table tbody tr.current-user {
    background: #fff3cd !important;
}

.leaderboard-table tbody tr.perfect-week {
    background: #d4edda !important;
}

.leaderboard-table td {
    padding: 0.5rem 1rem;
}

.position {
    text-align: center;
}

.position-number {
    font-size: 1.1rem;
    font-weight: bold;
    color: #013369;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.player-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
}

.player-name {
    font-weight: 500;
}

.player-name-link {
    color: #013369;
    text-decoration: none;
    transition: color 0.2s;
}

.player-name-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

.dues-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
    color: white;
    line-height: 1;
    flex-shrink: 0;
}

.dues-status.paid {
    background: #28a745;
}

.dues-status.unpaid {
    background: #dc3545;
}

.dues-summary-paid {
    color: #28a745;
    font-weight: 600;
}

.dues-summary-unpaid {
    color: #dc3545;
    font-weight: 600;
}

.winners-payout {
    color: #013369 !important;
    font-weight: 600;
}

.winners-table .is-late td,
.winner-picks .is-late td {
    color: #dc3545;
    font-weight: 600;
}

.winner-picks {
    width: 100%;
    border-collapse: collapse;
    margin: 0.35rem 0 1rem;
    font-size: 0.9rem;
}

.winner-picks th,
.winner-picks td {
    padding: 0.4rem 0.5rem;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.winner-picks th {
    color: #013369;
    font-size: 0.8rem;
}

.winners-table .winner-pay-method {
    display: inline-block;
    margin-right: 0.4rem;
    font-weight: 600;
    color: #013369;
}

.winners-table .winner-handle {
    color: #333;
}

.pot-form {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.6rem 0.75rem;
}

.pot-form label {
    color: #013369;
    font-weight: 600;
}

.pot-form select,
.pot-form input[type="text"] {
    padding: 0.5rem 0.65rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.pot-form input[type="text"] {
    width: 120px;
}

.pot-history {
    margin-top: 0.85rem;
    margin-bottom: 0 !important;
    font-size: 0.9rem;
}

.lb-pot {
    display: inline-flex;
    align-items: baseline;
    gap: 0.4rem;
    padding: 0.22rem 0.7rem 0.26rem;
    background: linear-gradient(135deg, #0b3d2e 0%, #14532d 55%, #1f7a3a 100%);
    border: 1px solid #c9a227;
    border-radius: 999px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
    white-space: nowrap;
}

.lb-pot-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #ffd76a;
}

.lb-pot-value {
    font-size: 0.95rem;
    font-weight: 800;
    color: #fff8dc;
}

@media (max-width: 768px) {
    .lb-pot-label {
        font-size: 0.6rem;
    }

    .lb-pot-value {
        font-size: 0.85rem;
    }
}

.lb-meta {
    color: #666;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.45rem;
}

.picks-short {
    display: inline-flex;
    align-items: center;
    padding: 0.12rem 0.5rem;
    border-radius: 999px;
    background: #fff3cd;
    color: #856404;
    border: 1px solid #e0a800;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    flex-shrink: 0;
}

.picks-short.complete {
    background: #e8f5e9;
    color: #1e7e34;
    border-color: #28a745;
}

.badge-you {
    background: #ffc107;
    color: #000;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    margin-left: 0.5rem;
}

.score {
    font-size: 1rem;
    color: #013369;
}

.picks-display {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.pick-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
}

.pick-badge.correct {
    background: #28a745;
    color: white;
}

.pick-badge.incorrect {
    background: #dc3545;
    color: white;
}

.pick-badge.pending {
    background: #ffc107;
    color: #000;
}

.pick-badge.upcoming {
    background: #e9ecef;
    color: #495057;
}

/* Logo-based pick badges */
.pick-badge-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.15rem;
    border-radius: 4px;
    border: 2px solid transparent;
    background: white;
    transition: all 0.2s;
}

.pick-badge-logo.correct {
    border-color: #28a745;
    background: #d4edda;
}

.pick-badge-logo.incorrect {
    border-color: #dc3545;
    background: #f8d7da;
}

.pick-badge-logo.pending {
    border-color: #ffc107;
    background: #fff3cd;
}

.pick-badge-logo.upcoming {
    border-color: #dee2e6;
    background: #f8f9fa;
}

.pick-badge-logo.hidden-pick {
    border-color: #adb5bd;
    background: #e9ecef;
    cursor: help;
    /* Don't override width/height - let it match other pick-badge-logo boxes */
}

.hidden-pick-icon {
    width: 28px;
    height: 28px;
    color: #6c757d;
    display: block;
}

.pick-team-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
    display: block;
}

.no-picks-yet {
    color: #999;
    font-style: italic;
}

.week-score {
    font-size: 1.1rem;
    text-align: center;
}

.leaderboard-legend {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.leaderboard-legend h4 {
    color: #013369;
    margin-bottom: 1rem;
}

.legend-items {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.update-frequency-info {
    margin-top: 0.75rem;
    padding: 0.75rem;
    border-top: 2px solid #e9ecef;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 6px;
    font-size: 0.75rem;
    line-height: 1.4;
}

.update-frequency-header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #dee2e6;
}

.update-icon {
    font-size: 1rem;
    filter: grayscale(0.2);
}

.update-title {
    font-weight: 600;
    color: #013369;
    font-size: 0.8rem;
    letter-spacing: 0.2px;
    text-transform: uppercase;
}

.update-details {
    display: flex;
    flex-direction: row;
    gap: 1rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.update-item {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    padding: 0.15rem 0;
    flex: 1;
    min-width: 200px;
}

.update-label {
    font-weight: 600;
    color: #495057;
    flex-shrink: 0;
    font-size: 0.75rem;
}

.update-value {
    color: #6c757d;
    font-size: 0.75rem;
}

.next-refresh-section {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px dashed #dee2e6;
}

.next-refresh-heading {
    margin: 0 0 0.5rem 0;
    font-size: 0.8rem;
    font-weight: 600;
    color: #495057;
    text-align: center;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.next-update-time {
    display: flex;
    flex-direction: row !important;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: nowrap;
}

.next-update-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.6rem;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 16px;
    border: 1px solid #e9ecef;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.next-update-item:hover {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transform: translateY(-1px);
}

.next-update-icon {
    font-size: 0.8rem;
    opacity: 0.7;
}

.next-update-text {
    font-size: 0.7rem;
    color: #495057;
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    letter-spacing: 0.1px;
    white-space: nowrap;
}

.next-update-divider {
    color: #adb5bd;
    font-size: 1rem;
    font-weight: 300;
    opacity: 0.5;
}

.admin-refresh-section {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px dashed #dee2e6;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.admin-refresh-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.9rem;
    background: linear-gradient(135deg, #013369 0%, #0056b3 100%);
    color: white;
    border: none;
    border-radius: 18px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(1, 51, 105, 0.2);
    white-space: nowrap;
}

.admin-refresh-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #0056b3 0%, #013369 100%);
    box-shadow: 0 3px 6px rgba(1, 51, 105, 0.3);
    transform: translateY(-1px);
}

.admin-refresh-btn:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(1, 51, 105, 0.2);
}

.admin-refresh-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.admin-refresh-btn.loading .refresh-icon {
    animation: spin 1s linear infinite;
}

.refresh-icon {
    font-size: 0.85rem;
}

.refresh-text {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    letter-spacing: 0.2px;
}

.refresh-status {
    font-size: 0.7rem;
    font-weight: 500;
    min-height: 1.2rem;
    display: inline-flex;
    align-items: center;
}

.refresh-status.refreshing {
    color: #ffc107;
}

.refresh-status.success {
    color: #28a745;
}

.refresh-status.error {
    color: #dc3545;
}

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

@media (max-width: 768px) {
    .admin-refresh-section {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .admin-refresh-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .update-frequency-info {
        padding: 0.6rem;
        font-size: 0.7rem;
    }
    
    .update-title {
        font-size: 0.75rem;
    }
    
    .update-details {
        flex-direction: column;
        gap: 0.35rem;
    }
    
    .update-item {
        flex-direction: row;
        gap: 0.4rem;
        min-width: auto;
    }
    
    .update-label {
        min-width: 110px;
    }
    
    .next-update-time {
        flex-direction: row;
        gap: 0.5rem;
        flex-wrap: wrap;
    }
    
    .next-update-item {
        flex: 1;
        min-width: 140px;
    }
    
    .next-update-divider {
        display: none;
    }
    
    .next-update-item {
        width: 100%;
        justify-content: center;
        padding: 0.25rem 0.5rem;
    }
}

/* Default: Show desktop table, hide mobile cards and toggle */
.leaderboard-desktop {
    display: block;
}

.leaderboard-cards-mobile {
    display: none;
}

.leaderboard-mobile-toggle-container {
    display: none;
}

@media (max-width: 768px) {
    /* Keep teams side-by-side on mobile */
    .game-matchup {
        grid-template-columns: 1fr auto 1fr;
        gap: 0.4rem;
    }
    
    .vs {
        font-size: 0.75rem;
        padding: 0 0.25rem;
    }
    
    .picks-summary {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }

    .picks-dock-inner {
        gap: 0.75rem;
    }

    .picks-dock .btn-large {
        font-size: 0.9rem;
        padding: 0.65rem 1.1rem;
        white-space: nowrap;
    }
    
    .team-label {
        padding: 0.4rem 0.5rem;
    }
    
    .team-logo-pick {
        width: 28px;
        height: 28px;
    }
    
    .team-name {
        font-size: 0.8rem;
    }
    
    .team-spread-inline {
        font-size: 0.8rem;
    }
    
    .selected-checkmark {
        width: 18px;
        height: 18px;
        font-size: 11px;
        top: -3px;
        right: -3px;
    }
    
    .pick-indicator {
        padding-left: 0.4rem;
    }
    
    .pick-label {
        font-size: 0.65rem;
        padding: 0.15rem 0.4rem;
    }
    
    .game-card {
        padding: 0.75rem;
    }
    
    .picks-container {
        padding: 0.5rem;
    }
    
    /* Ensure teams stay on one line */
    .team-name-with-spread {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    /* Hide desktop table, show mobile cards and toggle */
    .leaderboard-desktop {
        display: none;
    }
    
    .leaderboard-cards-mobile {
        display: block;
    }
    
    /* Mobile Toggle Button */
    .leaderboard-mobile-toggle-container {
        display: block;
        margin-bottom: 0.75rem;
        text-align: center;
    }
    
    .leaderboard-mobile-toggle {
        background: #013369;
        color: white;
        border: none;
        border-radius: 6px;
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
        font-weight: 600;
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        transition: background 0.2s;
    }
    
    .leaderboard-mobile-toggle:active {
        background: #002244;
    }
    
    .leaderboard-mobile-toggle .toggle-icon {
        font-size: 0.7rem;
        transition: transform 0.2s;
    }
    
    /* Mobile Headers */
    .leaderboard-mobile-header {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.75rem;
        background: #013369;
        color: white;
        border-radius: 6px 6px 0 0;
        font-size: 0.75rem;
        font-weight: 600;
        margin-bottom: 0.5rem;
    }
    
    .leaderboard-mobile-header-position {
        min-width: 30px;
        text-align: center;
    }
    
    .leaderboard-mobile-header-player {
        flex: 1;
        min-width: 0;
    }
    
    .leaderboard-mobile-header-scores {
        min-width: 35px;
        text-align: right;
    }
    
    .leaderboard-mobile-header-scores.mobile-scores-hidden {
        display: none;
    }
    
    .leaderboard-mobile-header-week {
        min-width: 45px;
        text-align: right;
    }
    
    .leaderboard-mobile-header-week.mobile-scores-hidden {
        display: none;
    }
    
    .leaderboard-mobile-header-picks {
        flex-shrink: 0;
        min-width: 0;
    }
    
    .leaderboard-mobile-header-picks.mobile-picks-hidden {
        display: none;
    }
    
    .sortable-mobile {
        cursor: pointer;
        user-select: none;
        transition: opacity 0.2s;
        display: flex;
        align-items: center;
        gap: 0.25rem;
    }
    
    .sortable-mobile:active {
        opacity: 0.7;
    }
    
    .sort-arrow-mobile {
        font-size: 0.7rem;
        color: rgba(255, 255, 255, 0.7);
    }
    
    /* Mobile Leaderboard Cards - Compact Single Line */
    .leaderboard-card {
        background: white;
        border-radius: 6px;
        padding: 0.5rem 0.75rem;
        margin-bottom: 0.5rem;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
        display: flex;
        align-items: center;
        gap: 0.5rem;
        min-height: 50px;
    }
    
    .leaderboard-card:active {
        transform: scale(0.98);
    }
    
    .leaderboard-card.you-ghost {
        background: #f3f7fb;
        outline: 1px dashed #013369;
        margin-bottom: 0.65rem;
    }

    .leaderboard-card.current-user {
        background: #fff3cd !important;
        border-left: 3px solid #ffc107;
    }
    
    .leaderboard-card.perfect-week {
        background: #d4edda !important;
        border-left: 3px solid #28a745;
    }
    
    .leaderboard-card-position {
        min-width: 30px;
        text-align: center;
    }
    
    .leaderboard-card-position .position-number {
        font-size: 0.9rem;
        font-weight: bold;
        color: #013369;
    }
    
    .leaderboard-card-player {
        flex: 1;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        min-width: 0; /* Allow shrinking */
    }
    
    .leaderboard-card-player .player-avatar {
        width: 28px;
        height: 28px;
        flex-shrink: 0;
    }
    
    .leaderboard-card-player .player-name {
        font-size: 0.85rem;
        font-weight: 600;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .leaderboard-card-player .badge-you {
        font-size: 0.65rem;
        padding: 0.15rem 0.35rem;
        flex-shrink: 0;
    }

    .leaderboard-card-player .picks-short {
        font-size: 0.62rem;
        padding: 0.1rem 0.32rem;
    }
    
    /* Scores container - hidden by default on mobile */
    .leaderboard-card-scores {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        flex-shrink: 0;
    }
    
    .leaderboard-card-scores.mobile-scores-hidden {
        display: none;
    }
    
    /* Picks container - shown by default, hidden when scores shown */
    .leaderboard-card-picks.mobile-picks-hidden {
        display: none;
    }
    
    .leaderboard-card-season-score {
        min-width: 35px;
        text-align: right;
    }
    
    .leaderboard-card-season-score .score-value {
        font-size: 0.9rem;
        font-weight: bold;
        color: #013369;
    }
    
    .leaderboard-card-week-score {
        min-width: 45px;
        text-align: right;
        font-size: 0.8rem;
        color: #666;
    }
    
    .leaderboard-card-week-score strong {
        font-size: 0.9rem;
        color: #013369;
    }
    
    .leaderboard-card-picks {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        flex-shrink: 0;
        min-width: 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
    }
    
    .leaderboard-card-picks::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }
    
    .leaderboard-card-picks .picks-display {
        display: flex;
        gap: 0.25rem;
        flex-wrap: nowrap;
    }
    
    .leaderboard-card-picks .pick-badge-logo {
        flex-shrink: 0;
    }
    
    .leaderboard-card-picks .pick-team-logo,
    .leaderboard-card-picks .hidden-pick-icon {
        width: 24px;
        height: 24px;
    }
    
    .leaderboard-card-picks .hidden-pick {
        width: auto;
        height: auto;
        padding: 0.15rem;
    }
    
    .leaderboard-card-picks .no-picks-yet {
        font-size: 0.7rem;
        color: #999;
        white-space: nowrap;
    }
    
    /* Hide labels on mobile for compactness */
    .picks-label,
    .score-label {
        display: none;
    }
    
    /* ATS section mobile improvements */
    .ats-performance-section {
        padding: 1rem !important;
    }
    
    .ats-game-card {
        grid-template-columns: 1fr !important;
        gap: 0.5rem !important;
    }
    
    .ats-team {
        flex-direction: column;
        text-align: center;
        padding: 0.75rem;
    }
    
    .ats-score {
        order: 2;
        padding: 0.5rem 0;
    }
    
    .ats-team:first-child {
        order: 1;
    }
    
    .ats-team:last-child {
        order: 3;
    }
    
    .ats-legend {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
}

/* Perfect Week Banner */
.perfect-week-banner {
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 50%, #ffd700 100%);
    border-bottom: 2px solid #ff6b35;
    box-shadow: 0 2px 10px rgba(255, 107, 53, 0.25);
    margin: 0 0 1rem 0;
    padding: 0.75rem 1rem;
    animation: slideDownBanner 0.6s ease-out, pulseBanner 2s ease-in-out infinite 0.6s;
    position: relative;
    overflow: hidden;
    border-radius: 0 0 8px 8px;
}

.perfect-week-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 3s infinite;
}

@keyframes slideDownBanner {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes pulseBanner {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
    }
    50% {
        box-shadow: 0 6px 25px rgba(255, 107, 53, 0.5);
    }
}

@keyframes shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

.perfect-banner-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.perfect-banner-icon {
    font-size: 2rem;
    animation: bounce 1s ease-in-out infinite;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    flex-shrink: 0;
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.perfect-banner-text {
    flex: 1;
    text-align: center;
}

.perfect-banner-title {
    font-size: 1.3rem;
    font-weight: 900;
    color: #ff6b35;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 0.2rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    animation: glow 2s ease-in-out infinite;
    line-height: 1.2;
}

@keyframes glow {
    0%, 100% {
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1), 0 0 10px rgba(255, 107, 53, 0.3);
    }
    50% {
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1), 0 0 20px rgba(255, 107, 53, 0.6);
    }
}

.perfect-banner-subtitle {
    font-size: 0.95rem;
    color: #333;
    font-weight: 600;
    line-height: 1.3;
}

.perfect-banner-subtitle strong {
    color: #ff6b35;
    font-weight: 800;
}

.perfect-banner-close {
    position: absolute;
    top: 0.4rem;
    right: 0.75rem;
    font-size: 1.5rem;
    color: #666;
    cursor: pointer;
    width: 1.75rem;
    height: 1.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    background: rgba(255, 255, 255, 0.5);
    flex-shrink: 0;
}

.perfect-banner-close:hover {
    background: rgba(255, 255, 255, 0.8);
    color: #ff6b35;
    transform: rotate(90deg);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .perfect-week-banner {
        margin: 0 0 1rem 0;
        padding: 0.6rem 0.75rem;
    }
    
    .perfect-banner-content {
        flex-direction: row;
        gap: 0.5rem;
        align-items: center;
    }
    
    .perfect-banner-icon {
        font-size: 1.5rem;
    }
    
    .perfect-banner-title {
        font-size: 1.1rem;
        letter-spacing: 1px;
        margin-bottom: 0.15rem;
    }
    
    .perfect-banner-subtitle {
        font-size: 0.85rem;
    }
    
    .perfect-banner-close {
        top: 0.3rem;
        right: 0.5rem;
        font-size: 1.25rem;
        width: 1.5rem;
        height: 1.5rem;
    }
}

