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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f5f5f0;
    color: #2c2c2c;
    line-height: 1.6;
}

.container {
    max-width: 680px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

header {
    text-align: center;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #1a1a1a;
}

.subtitle {
    color: #666;
    font-size: 1.1rem;
    margin-top: 0.25rem;
}

h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

/* Info card */
.info-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem 1rem;
}

dt {
    font-weight: 600;
    white-space: nowrap;
}

dd {
    color: #444;
}

/* Registration */
.registration {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.spots {
    text-align: center;
    padding: 0.75rem;
    background: #f0f7f0;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    font-size: 1rem;
    color: #2d6a2e;
}

.spots-number {
    font-weight: 700;
    font-size: 1.3rem;
}

.spots-full {
    font-weight: 700;
    color: #b91c1c;
}

.spots.spots-zero {
    background: #fef2f2;
    color: #b91c1c;
}

.field {
    margin-bottom: 1rem;
}

label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.3rem;
    font-size: 0.9rem;
}

input[type="text"] {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

input[type="text"].input-error {
    border: 2px solid #b91c1c;
    background: #fef2f2;
}

input[type="text"].input-error:focus {
    border-color: #b91c1c;
    box-shadow: 0 0 0 2px rgba(185, 28, 28, 0.2);
}

input[type="text"]:focus {
    outline: none;
    border-color: #4a7c4b;
    box-shadow: 0 0 0 2px rgba(74, 124, 75, 0.15);
}

button[type="submit"] {
    width: 100%;
    padding: 0.7rem;
    background: #3a6e3b;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

button[type="submit"]:hover {
    background: #2d572e;
}

button[type="submit"]:disabled {
    background: #999;
    cursor: not-allowed;
}

/* Message */
.message {
    margin-top: 1rem;
    padding: 0.75rem;
    border-radius: 6px;
    text-align: center;
    font-weight: 500;
}

.message.success {
    background: #f0f7f0;
    color: #2d6a2e;
}

.message.error {
    background: #fef2f2;
    color: #b91c1c;
}

/* Teams table */
.teams {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    text-align: left;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid #eee;
}

th {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #888;
    font-weight: 600;
}

td:first-child, th:first-child {
    width: 2.5rem;
    color: #aaa;
}

tr:last-child td {
    border-bottom: none;
}

.empty {
    text-align: center;
    color: #888;
    padding: 1rem 0;
}

footer a {
    color: #3a6e3b;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

footer {
    text-align: center;
    color: #888;
    font-size: 0.9rem;
}

@media (max-width: 500px) {
    .container { padding: 1rem; }
    header h1 { font-size: 1.5rem; }
    dl { grid-template-columns: 1fr; }
    dt { margin-top: 0.5rem; }
}
