/* Ajkai Oriasok Team Colors */
:root {
    --team-blue: #3d6fe5;
    --team-dark-blue: #01216b;
    --team-yellow: #FFD700;
    --team-yellow-light: #FFED4E;
    --team-yellow-dark: #FFC700;
    --text-dark: #121212;
    --bg-light: #f8f9fa;
}

/* General Body Styling */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--bg-light);
}

/* Navbar Custom Styling */
.navbar {
    background: linear-gradient(135deg, var(--team-yellow) 0%, var(--team-yellow-dark) 100%) !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 0.75rem 1rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: bold;
    color: var(--team-dark-blue) !important;
    font-size: 1.25rem;
}

.navbar-brand img {
    height: 50px;
    width: auto;
    margin-right: 10px;
}

.navbar-light .navbar-nav .nav-link {
    color: var(--team-dark-blue) !important;
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link:focus {
    color: var(--team-blue) !important;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
}

.navbar-light .navbar-nav .dropdown-menu {
    background-color: white;
    border: 1px solid var(--team-yellow);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.navbar-light .navbar-nav .dropdown-item:hover {
    background-color: var(--team-yellow-light);
    color: var(--team-dark-blue);
}

.navbar-toggler {
    border-color: var(--team-dark-blue);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%2301216b' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Main Container */
.container {
    max-width: 1200px;
    padding: 0 15px;
}

/* Headers */
h1 {
    color: var(--team-dark-blue);
    font-weight: bold;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid var(--team-yellow);
    font-size: 1.75rem;
}

h2 {
    color: var(--team-blue);
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

/* Table Styling */
.table {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.table thead {
    background: linear-gradient(135deg, var(--team-yellow) 0%, var(--team-yellow-dark) 100%);
    color: var(--team-dark-blue);
}

.table thead th {
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    padding: 1rem 0.75rem;
    letter-spacing: 0.5px;
}

.table tbody tr {
    transition: background-color 0.2s ease;
}

.table tbody tr:hover {
    background-color: rgba(61, 111, 229, 0.05);
}

.table-success {
    background-color: rgba(40, 167, 69, 0.1) !important;
    font-weight: 600;
}

.table-success:hover {
    background-color: rgba(40, 167, 69, 0.2) !important;
}

/* Result color indicators */
.table-success td {
    background-color: rgba(40, 167, 69, 0.15);
}

.table-danger td {
    background-color: rgba(220, 53, 69, 0.15);
}

.table-warning td {
    background-color: rgba(255, 193, 7, 0.15);
}

.table-light td {
    background-color: rgba(248, 249, 250, 0.5);
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--team-dark-blue) 0%, var(--team-blue) 100%);
    color: white;
    padding: 2rem 1rem;
    margin-top: 3rem;
}

footer a {
    color: var(--team-yellow);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--team-yellow-light);
}

/* Responsive Design for Mobile */
@media (max-width: 768px) {
    /* Navbar adjustments */
    .navbar-brand img {
        height: 40px;
    }

    .navbar-brand {
        font-size: 1rem;
    }

    .navbar-collapse {
        background-color: var(--team-yellow-light);
        padding: 1rem;
        border-radius: 8px;
        margin-top: 0.5rem;
    }

    /* Headers */
    h1 {
        font-size: 1.4rem;
    }

    h2 {
        font-size: 1.2rem;
        margin-top: 1.5rem;
    }

    /* Table wrapper for horizontal scroll */
    .table-responsive {
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    }

    /* Compact table styling */
    .table thead th,
    .table tbody td {
        padding: 0.5rem 0.4rem;
        font-size: 0.85rem;
    }

    /* Stack table cells on very small screens */
    .table.table-mobile-stacked thead {
        display: none;
    }

    .table.table-mobile-stacked tbody tr {
        display: block;
        margin-bottom: 1rem;
        border: 2px solid var(--team-yellow);
        border-radius: 8px;
        padding: 0.5rem;
    }

    .table.table-mobile-stacked tbody td {
        display: block;
        text-align: right;
        padding: 0.4rem;
        border: none;
    }

    .table.table-mobile-stacked tbody td::before {
        content: attr(data-label);
        float: left;
        font-weight: bold;
        color: var(--team-dark-blue);
    }

    /* Container padding */
    .container {
        padding: 0 10px;
    }

    /* Footer */
    footer {
        padding: 1.5rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    /* Extra small screens */
    .navbar-brand img {
        height: 35px;
    }

    h1 {
        font-size: 1.2rem;
    }

    h2 {
        font-size: 1.1rem;
    }

    .table thead th,
    .table tbody td {
        font-size: 0.75rem;
        padding: 0.4rem 0.3rem;
    }
}

/* Utility classes */
.text-team-blue {
    color: var(--team-blue) !important;
}

.text-team-yellow {
    color: var(--team-yellow-dark) !important;
}

.bg-team-blue {
    background-color: var(--team-blue) !important;
}

.bg-team-yellow {
    background-color: var(--team-yellow) !important;
}

/* Loading states and animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.table {
    animation: fadeIn 0.5s ease-in-out;
}

/* Navigation phase status indicators */
.nav-link.active-phase {
    font-weight: 700;
    position: relative;
}

.nav-link.active-phase::after {
    content: " ●";
    color: #28a745;
    font-size: 0.8em;
}

.dropdown-item.active-phase {
    font-weight: 600;
    background-color: rgba(40, 167, 69, 0.1);
}

.dropdown-item.active-phase::after {
    content: " ●";
    color: #28a745;
    font-size: 0.8em;
    margin-left: 5px;
}

.dropdown-item.inactive-phase {
    color: #6c757d;
    font-style: italic;
}

.dropdown-item.inactive-phase:hover {
    background-color: rgba(108, 117, 125, 0.1);
}

/* Button styling */
.btn-primary {
    background: linear-gradient(135deg, var(--team-blue) 0%, var(--team-dark-blue) 100%);
    border: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(61, 111, 229, 0.3);
    background: linear-gradient(135deg, var(--team-dark-blue) 0%, var(--team-blue) 100%);
}

/* Age group section styling */
.age-group-section {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-left: 5px solid var(--team-yellow);
}

.lead {
    font-size: 1.1rem;
}

/* Print styles */
@media print {
    .navbar,
    footer,
    .btn {
        display: none;
    }

    .table {
        box-shadow: none;
    }
}
