/**
 * Captain's Tips - Root Level Global Stylesheet
 * Shared styles for main website and dashboard
 */

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ===== NAVIGATION BAR ===== */
.navbar {
    background: white;
    border-radius: 12px;
    padding: 15px 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.navbar-brand {
    font-size: 1.3em;
    font-weight: 700;
    color: #1e3a8a;
    cursor: pointer;
    text-decoration: none;
}

.navbar-menu {
    display: flex;
    gap: 20px;
    align-items: center;
}

.navbar-link {
    color: #4b5563;
    text-decoration: none;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.2s;
}

.navbar-link:hover {
    background: #f3f4f6;
    color: #1e3a8a;
}

.navbar-link.active {
    background: #1e3a8a;
    color: white;
}

.navbar-auth {
    display: flex;
    gap: 12px;
    align-items: center;
}

.navbar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: #f3f4f6;
    border-radius: 8px;
    color: #374151;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.navbar-user:hover {
    background: #e5e7eb;
    transform: translateY(-1px);
}

.navbar-user-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 0.9em;
}

.navbar-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.navbar-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: #1e3a8a;
    margin: 5px 0;
    transition: all 0.3s;
    border-radius: 3px;
}

.navbar-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.navbar-toggle.active span:nth-child(2) {
    opacity: 0;
}

.navbar-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* ===== BUTTONS ===== */
.btn {
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
    display: inline-block;
    cursor: pointer;
    border: none;
    font-size: 1em;
}

.btn-primary {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(30, 58, 138, 0.3);
}

.btn-secondary {
    background: white;
    color: #1e3a8a;
    border: 2px solid #1e3a8a;
}

.btn-secondary:hover {
    background: #1e3a8a;
    color: white;
}

.btn-logout {
    background: #ef4444;
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-logout:hover {
    background: #dc2626;
}

/* ===== TABULAR NUMBERS ===== */
/* Ensures numbers align perfectly in columns */
.stat-value,
.stat-card .stat-value,
.odds,
.odds-table .odds,
.price-amount,
.score,
.confidence-score,
.betting-amount,
.profit-loss,
[data-type="number"],
table td:last-child {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .navbar {
        padding: 15px 20px;
        flex-direction: column;
        align-items: stretch;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-menu {
        display: none;
        flex-direction: column;
        gap: 0;
        width: 100%;
        margin-top: 15px;
        padding-top: 15px;
        border-top: 1px solid #e5e7eb;
    }

    .navbar-menu.active {
        display: flex;
    }

    .navbar-link {
        width: 100%;
        padding: 12px 16px;
        text-align: left;
    }

    .navbar-auth {
        display: none;
        flex-direction: column;
        gap: 10px;
        width: 100%;
        margin-top: 10px;
    }

    .navbar-auth.active {
        display: flex;
    }

    .btn {
        width: 100%;
        text-align: center;
        padding: 12px 20px;
    }

    .navbar-user {
        width: 100%;
        justify-content: flex-start;
    }
}
