/*
 * Filnavn: admin_style.css
 * Mappe: /controlpanel/css/
 * Beskrivelse: Felles stilark for alle sider i kontrollpanelet.
*/

body { 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    margin: 0; 
    background-color: #f9f9f9; 
    color: #333;
}

.cp-header { 
    background-color: #003300; 
    color: #cebf69; 
    padding: 1rem 2rem; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.cp-header h1 { 
    margin: 0; 
    font-size: 1.5rem; 
}

.cp-header a { 
    color: #cebf69; 
    text-decoration: none; 
}
.cp-header a:hover {
    text-decoration: underline;
}

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

.cp-container h2 { 
    border-bottom: 2px solid #eee; 
    padding-bottom: 0.5rem; 
    font-size: 1.4rem;
    color: #003300;
}

.cp-welcome { 
    font-size: 1.2rem; 
}

/* Meny på hovedsiden i CP */
.cp-menu ul { 
    list-style: none; 
    padding: 0; 
}
.cp-menu li { 
    margin: 0.8rem 0; 
}
.cp-menu a { 
    text-decoration: none; 
    color: #003300; 
    font-size: 1rem; 
}
.cp-menu a:hover { 
    text-decoration: underline; 
}


/* Tabeller (for lister) */
.content-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin-top: 1.5rem;
}

.content-table th, 
.content-table td { 
    border: 1px solid #ddd; 
    padding: 0.8rem; 
    text-align: left; 
    font-size: 0.9rem;
}

.content-table th { 
    background-color: #f2f2f2; 
}

.content-table tr:nth-child(even) { 
    background-color: #f9f9f9; 
}

.content-table a { 
    color: #003300; 
    font-weight: bold; 
    text-decoration: none;
}
.content-table a:hover {
    text-decoration: underline;
}

/* Knapper */
.add-new-btn,
.submit-btn { 
    display: inline-block; 
    background-color: #003300; 
    color: #cebf69; 
    padding: 0.8rem 2rem; 
    border: none;
    text-decoration: none; 
    border-radius: 3px; 
    cursor: pointer; 
    font-size: 1rem; 
    transition: opacity 0.2s;
}
.add-new-btn {
    padding: 0.7rem 1.5rem; 
    margin-bottom: 1.5rem; 
}

.add-new-btn:hover,
.submit-btn:hover {
    opacity: 0.9;
}

/* Skjemaer (Forms) */
.form-group { 
    margin-bottom: 1.5rem; 
}

label { 
    display: block; 
    font-weight: bold; 
    margin-bottom: 0.5rem; 
}

input[type="text"],
input[type="file"], 
textarea { 
    width: 100%; 
    padding: 0.8rem; 
    border: 1px solid #ccc; 
    border-radius: 3px; 
    font-size: 0.9rem; 
    box-sizing: border-box; 
}

textarea { 
    min-height: 150px; 
    resize: vertical; 
}

.form-row { 
    display: flex; 
    gap: 1rem; 
}

.form-row .form-group { 
    flex: 1; 
}

.error { 
    background-color: #ffebee; 
    color: #c62828; 
    border: 1px solid #c62828; 
    padding: 1rem; 
    border-radius: 3px; 
    margin-bottom: 1.5rem; 
}