
:root {
    --primary-color: #0056b3; /* Modern Blue */
    --secondary-color: #1a472a;
    --background-color: #f7f9fc; /* Light Grayish Blue */
    --text-color: #333333;
    --header-bg: #ffffff;
    --header-text: #ffffff; /* Changed to white for contrast */
    --container-bg: #ffffff;
    --card-bg: #ffffff;
    --border-color: #e0e0e0;
    --error-color: #d32f2f;
    --reward-color: #2e7d32;
    --risk-color: #c62828;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --ad-bg-color: #f0f4f8;
}

body {
    font-family: var(--font-primary);
    margin: 0;
    background-color: var(--background-color);
    color: var(--text-color);
    background-image: radial-gradient(circle, rgba(0,0,0,0.02) 1px, transparent 1px);
    background-size: 3px 3px;
}

header {
    background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://lh3.googleusercontent.com/gg-dl/AOI_d_997oFGI7lBtdRFLJb_25jyzR8JxRDo0XZfMkcAAnp3voOvWm2gJkKQYQVflHprbc9WUkrt20UbeKZdP7dZm25C7G5HQi3x788g_vYYjvLbdJ7hnKK0uI_QfnO_PRYxqc03oU2EIBOB2QiLvWc462tYmoNIFcF6pVK8wQciJesBSe6jdQ=s1024-rj');
    background-size: cover;
    background-position: center;
    color: var(--header-text);
    padding: 4rem 2rem;
    text-align: center;
    box-shadow: 0 2px 4px var(--shadow-color);
    border-bottom: 3px solid var(--primary-color);
    position: relative;
}

header h1 {
    margin: 0;
    font-size: 3.5rem;
    font-weight: 700;
}

header h2 {
    margin: 0.25rem 0 0;
    font-weight: 400;
    font-size: 1.2rem;
    color: #f0f0f0;
}

.main-layout {
    width: 95%;
    max-width: 1400px;
    margin: 2.5rem auto;
}

.tab-container {
    width: 100%;
}

.tab-nav {
    display: flex;
    justify-content: center;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.tab-link {
    background: none;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    color: #777;
    border-bottom: 4px solid transparent;
    margin-bottom: -2px;
    transition: color 0.3s, border-color 0.3s;
}

.tab-link:hover {
    color: var(--primary-color);
}

.tab-link.active {
    border-bottom-color: var(--primary-color);
    color: var(--primary-color);
    font-weight: 700;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.container {
    background-color: var(--container-bg);
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.05);
    margin-bottom: 2rem;
}

.results-container {
    background-color: transparent;
    padding: 0;
    border-radius: 6px;
    margin-top: 2rem;
    text-align: center;
}

.form-grid, .form-group-inline {
    display: grid;
    gap: 1.75rem;
}

.form-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.form-group-inline {
    grid-template-columns: 1fr 1fr;
}

.form-group label {
    display: block;
    margin-bottom: .6rem;
    font-weight: 500;
    color: #555;
    text-align: left;
}

.form-group input, .form-group select, input[type="file"] {
    width: 100%;
    padding: .8rem 1rem;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-group input:focus, .form-group select:focus, input[type="file"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 86, 179, 0.1);
}

button[type="submit"] {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: .8rem 2.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 10px rgba(0, 86, 179, 0.2);
    margin-top: 1rem;
}

button[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 15px rgba(0, 86, 179, 0.3);
}

.player-result-card, .analysis-card, .comparison-card, .dev-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 6px 15px var(--shadow-color);
    transition: transform 0.3s, box-shadow 0.3s;
    margin-bottom: 1.5rem; 
    text-align: left;
}

.player-result-card:hover, .analysis-card:hover, .comparison-card:hover, .dev-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.player-result-card {
    display: flex;
    align-items: center;
}

.player-photo, .player-photo-small {
    object-fit: cover;
    background-color: #e9ecef;
    border: 3px solid white;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}
.player-photo-small { width: 65px; height: 65px; border-radius: 50%; margin-right: 1.5rem; }
.player-photo { width: 110px; height: 110px; border-radius: 50%; margin-right: 2rem; }

.player-result-info h4 { margin: 0 0 0.25rem; font-size: 1.3rem; color: var(--primary-color); }
.player-result-info p { margin: 0; color: #666; }

.analysis-card .analysis-header, .dev-card .dev-header { display: flex; align-items: center; margin-bottom: 2rem; }

.risk-reward-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-item { padding: 1.5rem; border-radius: 10px; text-align: center; color: white; }
.summary-item.risk { background: var(--risk-color); }
.summary-item.reward { background: var(--reward-color); }
.summary-label { display: block; font-size: 1rem; margin-bottom: 0.5rem; opacity: 0.9; }
.summary-value { font-size: 2.8rem; font-weight: 700; }

.positional-summary { line-height: 1.7; font-size: 1.1rem; }

.comparison-card { padding: 2.5rem; }
.comparison-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.player-column { border-right: 1px solid var(--border-color); padding: 0 1.5rem; }
.player-column:last-child { border-right: none; padding-left: 1.5rem; }
.comparison-header { text-align: center; margin-bottom: 2rem; }
.comparison-header .player-photo-small { margin: 0 auto 1rem; display: block; }
.comparison-header h4 { font-size: 1.4rem; margin: 0.5rem 0; color: var(--primary-color); border: none; }
.comparison-header p { margin: 0; color: #777; }

.stats-grid { display: grid; gap: 1rem; }
.stat-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 0.8rem 1rem;
    background-color: #f7f9fc;
    border-radius: 6px;
    transition: background-color 0.2s;
}
.stat-row:hover { background-color: #eff3f7; }
.stat-row .stat-label { font-weight: 500; color: #444; }
.stat-row .stat-value { font-weight: 700; font-size: 1.1rem; color: var(--primary-color); }

.dev-card .player-info h3 { margin: 0; font-size: 2rem; border: none; color: var(--text-color); }
.dev-card h4 { font-size: 1.3rem; color: var(--primary-color); margin: 2rem 0 1rem; }

.chart-container {
    margin-top: 2.5rem;
    height: 400px;
}

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

.stat-item { text-align: center; background-color: #f7f9fc; padding: 1rem; border-radius: 8px; }
.stat-label { font-size: 0.9rem; color: #666; margin-bottom: 0.75rem; }
.stat-value { font-size: 1.8rem; font-weight: 700; margin: 0; }
.stat-value.current { color: var(--primary-color); }
.stat-value.last { color: #aaa; font-size: 1.1rem; }

.legend {
    display: flex; justify-content: center; gap: 1.5rem;
    font-size: 0.9rem; margin-top: 1rem;
}
.legend-item::before { content: ''; display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 0.5rem; vertical-align: middle; }
.legend-item.current::before { background-color: var(--primary-color); }
.legend-item.last::before { background-color: #aaa; }

.error-message { color: var(--error-color); font-size: 0.9rem; margin-top: 0.5rem; min-height: 1.2em; text-align: left;}

/* Sponsored Content */
.sponsored-section {
    display: none; /* Initially hidden */
    padding: 2rem 0;
    margin-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.sponsored-widget {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.sponsored-widget h4 {
    grid-column: 1 / -1; 
    text-align: center;
    font-size: 1.5rem;
    color: #999;
    margin: 0 0 1rem 0;
}

.ad-placeholder {
    background-color: var(--ad-bg-color);
    border-radius: 8px;
    padding: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #444;
    text-align: center;
    border: 1px dashed var(--border-color);
}

.ad-placeholder p { margin: 0; }

.ad-placeholder.inline-ad {
    display: none; /* Initially hidden */
    margin-top: 0;
    text-align: center;
}


/* Video Analysis & Loader */
.video-analysis-card h4 { font-size: 1.4rem; color: var(--primary-color); margin-bottom: 1rem; }

.loader {
    border: 5px solid #f3f3f3; 
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

footer {
    text-align: center;
    padding: 3rem 1rem;
    margin-top: 2rem;
    color: #888;
}
