body{
    font-family: Arial, sans-serif;
    margin:0;
    background:#f5f7fb;

}
/* Täcker glipan ovanför det fasta sidhuvudet (och bakom dess rundade hörn) så att innehåll som scrollas inte syns där. */
body::before{
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 40px; /* header top (25px) + hörnradie (15px) */
    background: #f5f7fb;
    z-index: 99; /* under headern (100) */
}
header{
    display: flex;
    background:#1e2a38;
    color:white;
    padding:15px 0;
    clear: both;
    height: 80px;
    width:95%;
    max-width: 1500px;
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
    position: fixed;
    top : 25px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;

}
header h1{
    display:inline-block;
    margin:0;
}
.logo{
    margin-left: 50px;
    float: left;
    width: 200px;
    height: auto;
    align-items: left;
}
/* Navigering */
header nav{
    display: flex;
    width: fit-content ;
    margin-left: auto;
    margin-right: 50px;
}
.menu {
  list-style: none;
  display: flex;
  gap: 20px;
  padding: 0px;
}

.menu li a {
  color: white;
  text-decoration: none;
  padding: 10px;
  display: block;
}

/* Svarshjälp (bokföringsfrågor och kurser): lampan är tänd när hjälpen visas och släckt när den är dold */
.hint-toggle {
  width: fit-content;
  cursor: pointer;
  user-select: none;
  margin: 0 0 8px;
}

.hint-toggle .lamp {
  color: #adb5bd;
  font-size: 18px;
  margin-right: 6px;
}

.hint-toggle.on .lamp {
  color: #ffc107;
}

/* Menyknapp som ser ut som en länk (t.ex. Logga ut, som skickas med POST) */
.menu li form {
  margin: 0;
}

.menu li .menu-button {
  color: white;
  background: none;
  border: 0;
  font: inherit;
  padding: 10px;
  display: block;
  cursor: pointer;
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #1e2a38;
  list-style: none;
  padding: 0px;
  margin: 0;
  width: max-content;
}

.dropdown-content li a {
  padding: 10px;

}

.dropdown-content li a:hover {
  background: #555;
}

.show {
  display: block;
}

/* Användarmenyn ligger längst till höger, så den fälls ut åt vänster */
.user-menu .dropdown-content {
  left: auto;
  right: 0;
}

.dropdown-content li .menu-button {
  width: 100%;
  text-align: left;
}

.dropdown-content li .menu-button:hover {
  background: #555;
}
.dropdown-header {
  color: #aaa;
  font-weight: bold;
  padding: 10px;
  margin-top: 5px;
  border-top: 1px solid #666;
  cursor: default;
}
main {
    width:95%;
    max-width: 1500px;
    margin:auto;
    margin-top: 105px;
    min-height: calc(100vh - 224px); /* Justera baserat på header och footer höjd */
    display: flex;
    flex-direction: column;
    border: 1px solid #000000;
    overflow-y: auto;
    padding: 10px;
}
footer{
    text-align:center;
    padding:10px;
    margin-top:40px;
    background:#1e2a38;
    color:white;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    width: 95%;
    max-width: 1500px;
    margin: auto;
}

.btn{
    display:inline-block;
    margin-top:20px;
    padding:4px 10px;
    background:rgb(64, 26, 235);
    color:#fff;
    text-decoration:none;
    border-radius:5px;
    font-weight:bold;
    width: fit-content;
}
table {
    width: 50%;
    border-collapse: collapse;
    margin-top: 20px;
}
thead {
    background-color: #4CAF50;
    color: white;
}
tbody tr:nth-child(even) {
    background-color: #f2f2f2;
}
tbody tr:hover {
    background-color: #ddd;
}
form tr:hover {
    background-color: none;
}
.hero{
    background:#2d8cff;
    color:white;
    text-align:center;
    padding:50px 10px;
}
.features{
    display:flex;
    gap:20px;
    margin-top:40px;
}
.card{
    background:white;
    padding:25px;
    border-radius:8px;
    box-shadow:0 2px 8px rgba(0,0,0,0.1);
    flex:1;
}
.created {
    font-size: 0.85em;
    color: #777;
}
.content {
    margin-top: 20px;
    line-height: 1.6;
    font-size: 1em;
}
.correct {
    color: #2e7d32;        /* mörkgrön text */
    background: #e8f5e9;   /* ljusgrön bakgrund */
    border: 1px solid #4caf50;
    border-radius: 5px;
    width: fit-content;
    padding: 3px 10px;
    font-weight: bold;
}

.wrong {
    color: #c62828;
    background: #ffebee;
    border: 1px solid #f44336;
    border-radius: 5px;
    width: fit-content;
    padding: 3px 10px;
    font-weight: bold;
}

.neutral {
    color: #37474f;
    background: #eceff1;
    border: 1px solid #90a4ae;
    border-radius: 5px;
    width: fit-content;
    padding: 3px 10px;
    font-weight: bold;
}
main input, main select {
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
}
.btn-group {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.btn-group button {
    margin: 0;
}

table tbody tr td {
    padding: 0.5rem;
    vertical-align: middle;
}

th {
    color: #0000 !important; 
}
table tbody tr td select,
table tbody tr td input {
    width: 100%;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

#progressBadge {
    margin-left: 0.5rem;
}

.level-card {
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.level-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1) !important;
}

.progress-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto;
}
.text-end {
    color: #000000 !important;
}
.text-white {
    color: #ffffff !important;
}
th, thead {
    color: #fff !important;
}
a.disabled {
  pointer-events: none;
  opacity: 0.65;
  color: var(--bs-secondary-color, #6c757d) !important;
}
/* ===== Sidor från sidhanteringen (admin.ledgerlab.se → Innehåll → Sidor), app/module/pages/show.php =====
   Egna ll-klasser så att de globala reglerna ovan (.btn, .card, table, th) inte påverkar sidorna. */
.ll-page {
    color: #1e2a38;
    line-height: 1.6;
}
.ll-page h1, .ll-page h2, .ll-page h3 { color: #1e2a38; }
.ll-page a:not(.ll-btn) { color: #2d5f9a; }

.ll-hero {
    background: linear-gradient(135deg, #1e2a38 0%, #2f4a68 100%);
    color: #fff;
    border-radius: 12px;
    padding: 64px 40px;
    margin-bottom: 40px;
}
.ll-hero-inner { max-width: 760px; }
.ll-hero h1 { color: #fff; font-size: clamp(1.9rem, 4vw, 2.9rem); font-weight: 700; margin: 8px 0 16px; }
.ll-hero .ll-lead { font-size: 1.2rem; color: #d7e1ec; margin-bottom: 28px; }
.ll-eyebrow { display: inline-block; font-size: .85rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #ffc107; }
.ll-hero-points { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 8px 24px; color: #d7e1ec; }
.ll-hero-points i { color: #ffc107; margin-right: 6px; }

.ll-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.ll-btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    border: 2px solid transparent;
    transition: transform .15s ease, box-shadow .15s ease;
}
.ll-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0, 0, 0, .18); }
.ll-btn-accent { background: #ffc107; color: #1e2a38; }
.ll-btn-ghost { border-color: rgba(255, 255, 255, .7); color: #fff; }
.ll-btn-dark { background: #1e2a38; color: #fff; }

.ll-section { padding: 16px 8px 40px; }
.ll-section-alt { background: #f5f7fb; border-radius: 12px; padding: 40px 24px; margin-bottom: 40px; }
.ll-section-title { text-align: center; font-weight: 700; margin-bottom: 8px; }
.ll-section-intro { text-align: center; color: #5b6b7d; max-width: 640px; margin: 0 auto 28px; }

.ll-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 24px; }
.ll-feature {
    background: #fff;
    border: 1px solid #e3e8ef;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(30, 42, 56, .05);
}
.ll-feature > i { font-size: 1.8rem; color: #2d5f9a; display: block; margin-bottom: 12px; }
.ll-feature h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.ll-feature p { margin: 0; color: #5b6b7d; }

.ll-steps { list-style: none; counter-reset: ll-step; padding: 0; display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 24px; }
.ll-steps li { counter-increment: ll-step; position: relative; padding: 24px 24px 24px 72px; background: #fff; border: 1px solid #e3e8ef; border-radius: 12px; }
.ll-steps li::before {
    content: counter(ll-step);
    position: absolute; left: 20px; top: 22px;
    width: 36px; height: 36px; border-radius: 50%;
    background: #1e2a38; color: #ffc107; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
}
.ll-steps h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 4px; }
.ll-steps p { margin: 0; color: #5b6b7d; }

.ll-cta { text-align: center; background: #1e2a38; color: #fff; border-radius: 12px; padding: 48px 24px; margin: 8px 0 24px; }
.ll-cta h2 { color: #fff; font-weight: 700; }
.ll-cta p { color: #d7e1ec; max-width: 560px; margin: 8px auto 24px; }

/* Textsidor (Om, Integritetspolicy, Cookies, Villkor) */
.ll-doc { max-width: 820px; margin: 16px auto 32px; }
.ll-doc h1 { font-weight: 700; margin-bottom: 4px; }
.ll-doc h2 { font-size: 1.3rem; font-weight: 700; margin-top: 28px; }
.ll-doc .ll-updated { color: #5b6b7d; font-size: .9rem; }

@media (max-width: 576px) {
    .ll-hero { padding: 40px 20px; }
    .ll-section-alt { padding: 28px 16px; }
}

/* ===== Frågor, kurser och prov ===== */
/* Knapparna under en fråga: centrerade och nära varandra; föregående/nästa är bara ikoner (samma i övningar och kurser). */
/* Kontakt och intresseanmälan: fältet som bara robotar fyller i (app/module/contact/common.php). */
.message-form-extra { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.question-actions { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.question-actions .btn { margin-top: 0; width: auto; border-radius: 8px; font-weight: 700; transition: transform .15s ease, box-shadow .15s ease; }
.question-actions .btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(30, 42, 56, .25); }
/* Föregående/nästa: mörkblå med vita pilar (systemets färger) */
.question-actions .btn-icon { width: 48px; height: 42px; padding: 0; background-color: #1e2a38; border-color: #1e2a38; color: #fff; font-size: 1.15rem; }
.question-actions .btn-icon:hover:not(:disabled) { background-color: #2f4a68; border-color: #2f4a68; color: #fff; }
.question-actions .btn-icon:disabled { background-color: #c5ccd6; border-color: #c5ccd6; color: #fff; opacity: 1; }
/* Huvudknappen (Rätta, Svara, Avsluta prov): gul accent med mörkblå text */
.question-actions .btn-main { min-width: 160px; height: 42px; background-color: #ffc107; border-color: #ffc107; color: #1e2a38; }
.question-actions .btn-main:hover:not(:disabled) { background-color: #ffcd38; border-color: #ffcd38; color: #1e2a38; }
.question-actions .btn-main:disabled { background-color: #ffe08a; border-color: #ffe08a; color: #6b7785; }

/* Frågelistan i kurser och prov: bara så bred som texten och ett litet mellanrum */
.course-question-list { flex: 0 0 auto; width: auto; min-width: 9rem; }
.course-question-list .list-group-item { padding: .45rem .75rem; gap: 12px; }

/* Provets resultatsida */
.exam-result-row.table-danger td, .exam-result-row.table-success td { vertical-align: top; }
.exam-answer-table { width: 100%; margin: 0; }
.exam-answer-table td { padding: 2px 6px; font-size: .875rem; }

/* Konteringstabellen: rubrikerna ska synas (den globala th-regeln ovan gör dem vita) */
.answer-table thead th { color: #1e2a38 !important; }
/* Info-rutan: ingen extra marginal från den globala .card-regeln */
.card.question-info { padding: 0; }
