:root {
    --bg-dark: #121212;
    --surface: #1e1e1e;
    --surface-light: #2d2d2d;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --red-corner: #d32f2f;
    --red-corner-light: rgba(211, 47, 47, 0.2);
    --blue-corner: #1976d2;
    --blue-corner-light: rgba(25, 118, 210, 0.2);
    --accent: #ffb300;
    --border: #333333;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 16px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

header {
    background-color: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
}

nav a {
    color: var(--text-primary);
    text-decoration: none;
    margin-left: 15px;
    font-size: 0.9rem;
}

nav a:hover {
    color: var(--accent);
}

main {
    padding: 40px 20px;
}

section {
    margin-bottom: 50px;
}

h1 {
    font-size: 2.2rem;
    margin-bottom: 15px;
    line-height: 1.2;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--accent);
    border-bottom: 2px solid var(--surface-light);
    padding-bottom: 10px;
}

h3 {
    font-size: 1.3rem;
    margin: 25px 0 10px 0;
    color: var(--text-primary);
}

p {
    margin-bottom: 15px;
    color: var(--text-secondary);
}

ul {
    margin-bottom: 20px;
    padding-left: 20px;
    color: var(--text-secondary);
}

li {
    margin-bottom: 10px;
}

.ad-container {
    background-color: var(--surface);
    border: 1px dashed var(--border);
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 40px;
    text-align: center;
}

/* Interactive Scorecard Styles */
.interactive-scorecard {
    background-color: var(--surface);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.score-setup {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.fighter-input {
    background: var(--surface-light);
    border: 2px solid transparent;
    color: white;
    padding: 12px;
    border-radius: 6px;
    font-size: 1.2rem;
    font-weight: bold;
    width: 40%;
    text-align: center;
}

.red-input {
    border-bottom-color: var(--red-corner);
}
.red-input:focus { border-color: var(--red-corner); outline: none; }

.blue-input {
    border-bottom-color: var(--blue-corner);
}
.blue-input:focus { border-color: var(--blue-corner); outline: none; }

.vs {
    font-weight: bold;
    color: var(--text-secondary);
    font-size: 1.2rem;
    padding: 0 10px;
}

.round-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: var(--surface-light);
    margin-bottom: 15px;
    border-radius: 8px;
    padding: 10px;
}

.round-label {
    font-weight: bold;
    width: 60px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--accent);
}

.score-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    justify-content: center;
}

.score-btn {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.score-btn:hover {
    background: #444;
}

.score-value {
    font-size: 1.5rem;
    font-weight: bold;
    width: 30px;
    text-align: center;
}

.red-side .score-value { color: var(--red-corner); }
.blue-side .score-value { color: var(--blue-corner); }

.totals-display {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.total-box {
    font-size: 3rem;
    font-weight: 900;
    padding: 10px 30px;
    border-radius: 8px;
}

.red-total {
    color: var(--red-corner);
    background-color: var(--red-corner-light);
}

.blue-total {
    color: var(--blue-corner);
    background-color: var(--blue-corner-light);
}

.total-label {
    padding: 0 20px;
    font-weight: bold;
    letter-spacing: 2px;
    color: var(--text-secondary);
    text-align: center;
}

.controls {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    justify-content: center;
}

button {
    background-color: var(--accent);
    color: var(--bg-dark);
    border: none;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: bold;
    border-radius: 6px;
    cursor: pointer;
    transition: opacity 0.2s;
}

button:hover {
    opacity: 0.9;
}

button.secondary {
    background-color: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

footer {
    background-color: var(--surface);
    padding: 30px 0;
    margin-top: 50px;
    border-top: 1px solid var(--border);
    text-align: center;
}

footer p {
    font-size: 0.9rem;
    margin-bottom: 15px;
}

footer nav {
    display: inline-flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

@media (max-width: 600px) {
    .fighter-input {
        width: 100%;
        margin-bottom: 10px;
    }
    .score-setup {
        flex-direction: column;
    }
    .vs {
        margin: 5px 0;
    }
    .totals-display {
        flex-direction: column;
        gap: 10px;
    }
    .total-label {
        order: -1;
    }
    .round-row {
        flex-direction: column;
        gap: 15px;
    }
    .score-controls {
        width: 100%;
        justify-content: space-between;
    }
}


/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
