body {
    background-image: url('./SG.webp');
    background-size: cover;
    background-attachment: scroll;
    background-repeat: no-repeat;
    background-position: center center;
    color: #fff;
    margin: 0;
    padding: 0 0 60px;
}

h1, h2, h3, label {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
}

.form-container {
    background: rgba(0,0,0,0.7);
    padding: 20px;
    border-radius: 8px;
    max-width: 400px;
    margin: 20px auto;
    position: relative;
}

input[type="text"], input[type="date"], input[type="password"],
input[type="number"], input[type="file"], textarea, select {
    width: 100%;
    box-sizing: border-box;
    padding: 8px;
    margin-bottom: 10px;
    border: none;
    border-radius: 4px;
    background: rgba(255,255,255,0.9);
    color: #000;
}

textarea { resize: vertical; }

button {
    background-color: #4CAF50;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-right: 8px;
    margin-bottom: 6px;
}
button:hover { background-color: #45a049; }
button:disabled { background-color: #888; cursor: default; }

.btn-back  { background-color: #555; }
.btn-back:hover { background-color: #333; }
.btn-blue  { background-color: #2196F3; }
.btn-blue:hover { background-color: #1976D2; }
.btn-red   { background-color: #c0392b; }
.btn-red:hover { background-color: #a93226; }

.autocomplete-suggestions {
    position: absolute;
    z-index: 1000;
    background: rgba(0,0,0,0.85);
    border-radius: 4px;
    max-height: 150px;
    overflow-y: auto;
    width: calc(100% - 40px);
}
.autocomplete-suggestion {
    padding: 10px;
    cursor: pointer;
    color: #fff;
}
.autocomplete-suggestion:hover { background: rgba(255,255,255,0.2); }

table { border-collapse: separate; border-spacing: 20px 0; width: 100%; }
th { text-align: left; padding: 6px; }
td { padding: 6px; }

.status-ok  { color: #90EE90; font-size: 0.9em; }
.status-err { color: #FF6B6B; font-size: 0.9em; }

footer {
    position: fixed;
    bottom: 0; right: 0;
    font-size: 12px;
    color: #ccc;
    background-color: rgba(0,0,0,0.4);
    padding: 6px 12px;
    border-top-left-radius: 6px;
    z-index: 1000;
}

nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }

.rulebook-indicator {
    display: inline-block;
    font-size: 0.8em;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 8px;
    vertical-align: middle;
}
.has-rulebook { background: #2e7d32; }
.no-rulebook  { background: #7f3333; }

#answer-box {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    padding: 16px;
    margin-top: 16px;
    line-height: 1.6;
    display: none;
}

@media (max-width: 480px) {
    .form-container { margin: 10px; padding: 15px; }
}
