/* ==========================================================================
   SOROLA.FI - YHTEINEN UUSI ITSESTÄÄNTOIMIVA TUMMA TYYLI
   ========================================================================== */

body {
    background-color: #0b0d13;
    /* Viittaus uuteen SVG-taustakuvaan */
    background-image: url("bg.svg");
    color: #e2e8f0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 30px 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    box-sizing: border-box;
}

/* Yhteinen pääkontti kaikille sivuille */
.laatikko {
    background: rgba(20, 24, 36, 0.95);
    border: 2px solid #ffaa00;
    border-radius: 16px;
    padding: 35px;
    max-width: 650px; /* Admin-paneelissa tätä voi ylikirjoittaa leveämmäksi tarvittaessa */
    width: 100%;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(255, 170, 0, 0.05);
    backdrop-filter: blur(8px);
}

/* Yleiset otsikot */
.otsikko {
    color: #ffaa00;
    text-align: center;
    margin-top: 0;
    margin-bottom: 35px;
    font-size: 2.2rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 800;
    text-shadow: 0 0 10px rgba(255, 170, 0, 0.2);
}

/* Osiot (kuten adminissa tai lyhentimessä) */
.admin-section, .osion-tausta {
    background: #191f2d;
    border: 1px solid #2d3748;
    border-radius: 12px;
    padding: 22px;
    margin-bottom: 25px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.admin-section h2, .admin-section h3, .osion-tausta h2 {
    margin-top: 0;
    margin-bottom: 18px;
    color: #ffaa00;
    border-bottom: 2px solid #2d3748;
    padding-bottom: 8px;
    font-size: 1.3rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Flex-lomakerakenteet */
.flex-form {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

/* Syötekentät */
.syote {
    flex: 1;
    min-width: 200px;
    background: #0b0d13;
    border: 1px solid #4a5568;
    color: #fff;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.syote:focus {
    border-color: #ffaa00;
    outline: none;
    box-shadow: 0 0 8px rgba(255, 170, 0, 0.3);
    background: #11141d;
}

/* Yleiset painikkeet */
.nappula, .nappula1 {
    display: inline-block;
    text-align: center;
    text-decoration: none;
    background: #ffaa00;
    color: #0b0d13;
    border: none;
    padding: 12px 26px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-sizing: border-box;
}

.nappula:hover, .nappula1:hover {
    background: #ffbb33;
    box-shadow: 0 0 12px rgba(255, 170, 0, 0.4);
    transform: translateY(-1px);
}

/* Alaspäin yhteensopivuus linkkilistojen napeille */
.nappula1 {
    width: 100%;
    margin-bottom: 12px;
}

/* Erikoisvärit */
.nappi-puna { background-color: #ef4444; color: white; }
.nappi-puna:hover { background-color: #dc2626; box-shadow: 0 0 12px rgba(239, 68, 68, 0.4); }

.nappi-oranssi { background-color: #f97316; color: white; }
.nappi-oranssi:hover { background-color: #ea580c; box-shadow: 0 0 12px rgba(249, 115, 22, 0.4); }

.nappi-pieni { padding: 6px 14px; font-size: 0.85rem; border-radius: 6px; width: auto; margin-bottom: 0; }

/* Taulukot (Vieraskirja, linkit jne.) */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

th, td {
    padding: 14px 12px;
    text-align: left;
    border-bottom: 1px solid #2d3748;
}

th {
    color: #a0aec0;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    background: rgba(11, 13, 19, 0.4);
}

tr:hover td { background: rgba(255, 255, 255, 0.02); }
td { color: #e2e8f0; font-size: 0.95rem; }

code {
    background: #0b0d13;
    padding: 5px 10px;
    border-radius: 6px;
    font-family: monospace;
    color: #f6ad55;
    font-weight: bold;
    border: 1px solid #2d3748;
}

/* Linkit */
.linkki-takaisin {
    display: block;
    text-align: center;
    margin-top: 30px;
    color: #a0aec0;
    text-decoration: none;
    transition: color 0.2s;
    font-size: 0.95rem;
}

.linkki-takaisin:hover {
    color: #ffaa00;
}

@media (max-width: 768px) {
    .laatikko { padding: 20px; }
    .flex-form { flex-direction: column; }
    .syote, .nappula { width: 100%; }
}
