:root {
    --sports-blue: #0093FA;
    --sports-blue-hover: #0080e6;
    --sports-gray: #F4F5F7;
    --sports-light-blue: rgba(0, 147, 250, 0.05);
    
    /* Light theme colors */
    --bg-color: #F4F5F7;
    --calculator-bg: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #6B7683;
    --input-bg: #F4F5F7;
    --input-hover-bg: #E5E9F2;
    --input-focus-bg: #ffffff;
    --border-color: #E5E9F2;
    --result-bg: rgba(0, 147, 250, 0.05);
    --result-hover-bg: rgba(0, 147, 250, 0.08);
    --shadow-color: rgba(0, 147, 250, 0.1);
    
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

/* Dark theme colors */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #1a1a1a;
        --calculator-bg: #2d2d2d;
        --text-primary: #ffffff;
        --text-secondary: #b0b0b0;
        --input-bg: #3a3a3a;
        --input-hover-bg: #4a4a4a;
        --input-focus-bg: #2d2d2d;
        --border-color: #4a4a4a;
        --result-bg: rgba(0, 147, 250, 0.15);
        --result-hover-bg: rgba(0, 147, 250, 0.2);
        --shadow-color: rgba(0, 0, 0, 0.3);
    }
}

/* Manual dark theme class */
.dark-theme {
    --bg-color: #1a1a1a;
    --calculator-bg: #2d2d2d;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --input-bg: #3a3a3a;
    --input-hover-bg: #4a4a4a;
    --input-focus-bg: #2d2d2d;
    --border-color: #4a4a4a;
    --result-bg: rgba(0, 147, 250, 0.15);
    --result-hover-bg: rgba(0, 147, 250, 0.2);
    --shadow-color: rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Neoris', 'TT Neoris', 'Roboto', sans-serif;
    line-height: 1.4;
    color: var(--text-primary);
    background: transparent;
    margin: 0;
    padding: 0;
    min-height: 200px;
    max-height: 200px;
    overflow: hidden;
}

.container {
    width: 100%;
    margin: 0;
    padding: 0;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ligue1-predictor-container {
    background: var(--calculator-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 2px 8px var(--shadow-color);
    padding: 0.75rem;
    border: 2px solid var(--sports-blue);
    position: relative;
    overflow: hidden;
    margin: 0;
    width: 730px;
    max-width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
}

.ligue1-predictor-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    pointer-events: none;
}

.conference-section {
    background: #ffffff;
    border-radius: 0;
    padding: 0;
    border: none;
    max-width: 100%;
    margin: 0;
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.conference-title {
    font-size: 1.125rem;
    font-weight: 500;
    margin: 0;
    color: #000000;
    text-align: center;
    letter-spacing: -0.01em;
    position: relative;
    z-index: 1;
    border: none;
    padding: 0;
    font-family: 'Neoris', 'TT Neoris', 'Roboto', sans-serif;
    flex-shrink: 0;
}

.conference-spacer {
    height: 1px;
    flex-shrink: 0;
}

.teams-list {
    padding: 0;
    margin: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    position: relative;
    z-index: 1;
    flex: 1;
    justify-content: center;
}

.team-item {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: var(--transition);
    cursor: pointer;
    user-select: none;
    min-height: 40px;
    position: relative;
    touch-action: none;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.team-item:hover {
    background: var(--input-hover-bg);
    border-color: var(--sports-blue);
}

.team-item:focus {
    background: var(--input-focus-bg);
    border-color: var(--sports-blue);
    outline: none;
}

.team-item.dragging {
    opacity: 0.5;
    transform: rotate(2deg);
    z-index: 1000;
    cursor: grabbing;
}

.team-item.drag-over {
    background: var(--result-bg);
    border-color: var(--sports-blue);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow-color);
}

.team-item.touch-dragging {
    opacity: 0.8;
    transform: rotate(3deg);
    box-shadow: 0 8px 24px var(--shadow-color);
    border: 2px solid var(--sports-blue);
    background: var(--result-bg);
}

.team-item.touch-active {
    background: var(--result-bg);
    transform: scale(1.02);
    transition: all 0.1s ease;
}

/* Кнопка коэффициента справа от названия команды */
.odds-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 28px;
    padding: 0;
    border-radius: 6px;
    background: var(--sports-blue);
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    margin-left: auto;
    flex-shrink: 0;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid var(--sports-blue);
    font-family: 'Neoris', 'TT Neoris', 'Roboto', sans-serif;
}

.odds-button:hover {
    background: var(--sports-blue-hover);
    transform: scale(1.05);
}

.team-logo {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    object-fit: contain;
    margin-right: 0.5rem;
    flex-shrink: 0;
    background: white;
    border: 1px solid var(--border-color);
}

.team-name {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.2;
    flex: 1;
    min-width: 0;
    font-family: 'Neoris', 'TT Neoris', 'Roboto', sans-serif;
}



/* Mobile responsiveness */
@media (max-width: 768px) {
    body {
        min-height: auto;
        max-height: none;
        overflow: visible;
    }
    
    .container {
        height: auto;
        min-height: 200px;
    }
    
    .ligue1-predictor-container {
        width: 100%;
        height: auto;
        min-height: 200px;
        padding: 0.75rem;
    }
    
    .conference-title {
        font-size: 1.1rem;
        margin: 0;
    }
    
    .team-item {
        padding: 0.5rem;
        min-height: 42px;
    }
    
    .team-logo {
        width: 26px;
        height: 26px;
        margin-right: 0.5rem;
    }
    
    .team-name {
        font-size: 0.95rem;
    }
    
    .odds-button {
        width: 52px;
        height: 26px;
        font-size: 0.85rem;
    }
    
    .teams-list {
        gap: 0.375rem;
    }
}

@media (max-width: 480px) {
    .ligue1-predictor-container {
        padding: 0.75rem;
    }
    
    .team-item {
        padding: 0.5rem;
        min-height: 40px;
    }
    
    .team-logo {
        width: 24px;
        height: 24px;
        margin-right: 0.5rem;
    }
    
    .team-name {
        font-size: 0.9rem;
    }
    
    .odds-button {
        width: 48px;
        height: 24px;
        font-size: 0.8rem;
    }
    
    .conference-title {
        font-size: 1rem;
        margin: 0;
    }
    
    .teams-list {
        gap: 0.25rem;
    }
}
