
html {
    height: 100%;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    margin: 0;
    padding: 0;
    min-height: 100%;
    box-sizing: inherit;
    display: flex;
    flex-direction: column;
    text-align: center;
}

/* Header */
header {
    background: #2a5298; 
    padding: 20px;
    color: white;
    text-align: center;
}

/* Footer */
footer {
    margin-top: auto;
    left: 0;
    bottom: 0;
    right: 0;
    width: 100%;
    background: #4CAF50;
    color: white;
    text-align: center;
    padding: 10px;
}

/* Navigation Bar */
nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    justify-content: center;
    gap: 25px;
}

nav ul li {
    list-style: none;
}

nav ul li a {
    font-size: 18px;
    color: white;
    text-decoration: none;
    padding: 12px 20px;
    border-radius: 5px;
    transition: 0.3s;
    font-weight: 500;
}

/* Navigation Hover Effects */
nav ul li a:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffcc00;
    transform: scale(1.05);
}

/* Hero Section */
.hero {
    background: #f4f4f4;
    padding: 50px 20px;
}

/* Buttons */
.cta-button {
    display: inline-block;
    padding: 12px 20px;
    background: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    margin-right: 15px;
    font-size: 16px;
    transition: 0.3s;
}

.cta-button:last-child {
    margin-right: 0;
}

.cta-button:hover {
    background: #388E3C;
}

/* Main Content Container */
.container {
    width: 60%;
    margin: 50px auto;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    text-align: left;
}

/* Question Section */
.question {
    background: #fff;
    text-align: left;
    padding: 15px;
    margin: 15px 0;
    border-radius: 5px;
    border: 1px solid #ddd;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.1);
}

input[type="radio"] {
    margin-right: 8px;
}

/* Scoreboard Table */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

th, td {
    padding: 12px;
    border: 1px solid #ddd;
    text-align: center;
}

th {
    background-color: #2a5298;
    color: white;
}

td {
    background-color: #f9f9f9;
}

/* Cards (for Modules) */
.card {
    flex: 1;
    background: white;
    padding: 20px;
    margin: 20px auto;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    max-width: 400px;
    text-align: left;
}
.card h2 {
    text-align: center;
}

.card-layout {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

/* Forms */
input[type="text"], input[type="password"], input[type="email"] {
    max-width: 400px;
    width: 93%;
    padding: 10px;
    margin: 8px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
}

input[type="submit"] {
    width: 100%;
    padding: 10px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: 0.3s;
}

input[type="submit"]:hover {
    background-color: #0056b3;
}

/* Error Message Styling */
.error {
    color: red;
    font-size: 14px;
    margin-top: 5px;
}

/* Success Message */
.success {
    color: green;
    font-size: 14px;
    margin-top: 5px;
}

.status-message {
    background-color: #f4f4f4;
    color: #333;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-size: 16px;
}

.scoreboard-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin: 50px auto;
    width: 70%;
    background: #4CAF50; 
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.2);
    color: white; 
}

.scoreboard-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white; 
    border-radius: 8px;
    overflow: hidden;
}

/* Table headers */
.scoreboard-table th {
    background-color: #388E3C; 
    color: white;
    padding: 12px;
    font-size: 16px;
}

/* Table rows */
.scoreboard-table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: center;
    font-size: 14px;
    color: black; 
}

/* Hover effect */
.scoreboard-table tr:hover {
    background-color: #C8E6C9; 
}

.navbar {
    width: 100vw; /* Sikrer at den tar hele bredden av skjermen */
    background-color: #4CAF50; /* Fargen på navbaren */
    padding: 15px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0; /* Fjerner uønskede mellomrom */
    position: fixed; /* Gjør at den alltid er øverst */
    top: 0;
    left: 0;
}

.nav-links {
    display: flex;
    list-style: none;
    padding: 0;
    gap: 20px;
}

.nav-links a {
    text-decoration: none;
    color: white;
    font-size: 18px;
    padding: 10px 20px;
}
.navbar div {
    display: none;
}
.some-class {
    display: none;
}


body {
    margin: 0;
    padding: 0;
}

/* Fullskjerm høyde for å sikre vertikal sentrering */
body, html {
    height: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}


.sortable-list {
    list-style: none;
    padding: 0;
    background: #f8f9fa;
    border: 1px solid #ccc;
    border-radius: 5px;
    padding: 10px;
    min-width: 300px;
}

.sortable-item {
    background: white;
    padding: 10px;
    margin: 5px 0;
    border: 1px solid #ccc;
    border-radius: 4px;
    cursor: grab;
    font-weight: bold;
}

.sortable-item.dragging {
    opacity: 0.5;
}


.container {
    width: 80%;
    margin: 50px auto;
    text-align: center;
}

.module-selection {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.module-card {
    background: #4CAF50; /* Keep the same green theme */
    color: white;
    text-decoration: none;
    padding: 20px;
    width: 250px;
    text-align: center;
    border-radius: 8px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.module-card:hover {
    transform: scale(1.05);
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
}




.search-users-container {
    max-width: 900px;
    margin: 50px auto;
    background: #ffffff;
    padding: 30px 40px;
    border-radius: 8px;
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.1);
}

.search-users-container h2,
.search-users-container h3 {
    color: #333;
    text-align: center;
}

.search-users-container form {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.search-users-container input[type="text"] {
    height: 44px;
    padding: 0 15px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 6px 0 0 6px;
    outline: none;
    transition: border 0.3s ease;
}

.search-users-container button[type="submit"] {
    height: 44px;
    padding: 0 20px;
    font-size: 16px;
    background-color: #4CAF50;
    color: #fff;
    border: none;
    border-radius: 0 6px 6px 0;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.search-users-container form {
    align-items: center;
}

.search-users-container button[type="submit"]:hover {
    background-color: #388e3c;
}

.search-users-container ul {
    list-style: none;
    padding: 0;
}

.search-users-container li {
    background-color: #f9f9f9;
    margin-bottom: 12px;
    padding: 20px 30px;
    border-radius: 6px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #e0e0e0;
}

.search-users-container li form {
    margin: 0;
}

.search-users-container li button {
    padding: 8px 14px;
    font-size: 14px;
    background-color: #2196F3;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.search-users-container li button:hover {
    background-color: #1976D2;
}

/* Quiz results */
.green {
    color: green;
    font-weight: bold;
}

.red {
    color: red;
    font-weight: bold;
}

.correct {
    background-color: #d4edda;
    padding: 10px;
    border-left: 5px solid green;
    margin-bottom: 10px;
}

.wrong {
    background-color: #f8d7da;
    padding: 10px;
    border-left: 5px solid red;
    margin-bottom: 10px;
}

.success-message {
    background-color: #e8f5e9;
    color: #2e7d32;
    padding: 12px;
    margin: 15px 0;
    border: 1px solid #c8e6c9;
    border-radius: 6px;
    text-align: center;
    font-weight: 500;
}

/* Hover & button enhancement */
.search-users-container button:hover {
    filter: brightness(1.1);
    transform: scale(1.03);
    transition: 0.2s ease-in-out;
}

.search-users-container li {
    transition: background-color 0.2s ease;
}

.search-users-container li:hover {
    background-color: #eef7ee;
}

.remove-button {
    background-color: #e53935;
    color: white;
    border: none;
    padding: 6px 12px;
    margin-left: 10px;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.2s ease-in-out;
}

.remove-button:hover {
    background-color: #c62828;
}
.wrapper {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 20px;
}
.left-sidebar {
    width: 250px; /* Adjust the width as needed */
    background-color: #f4f4f4;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    height: 100vh; /* Make the sidebar stick to the page */
    overflow-y: auto; /* Allows scrolling if there are too many friends */
}


/* Acheivment badge */
.badge-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* Midtstill badgene horisontalt */
    gap: 12px;
    margin: 20px auto;
}

.badge {
    background-color: #c8facc; /* Lys grønn */
    color: #206020; /* Mørkere grønn tekst for kontrast */
    padding: 10px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 15px;
    display: inline-block;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.2s ease-in-out;
}

.badge:hover {
    transform: scale(1.05);
    cursor: default;
}

/* === Learning Material Page === */

.container {
    max-width: 800px;
    margin: 50px auto;
    padding: 30px;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0px 4px 12px rgba(0,0,0,0.1);
    text-align: left;
    line-height: 1.6;
}

.container h2 {
    color: #2c3e50;
    font-size: 28px;
    margin-bottom: 15px;
}



.container ul {
    padding-left: 20px;
    margin-top: 10px;
}

.container ul li {
    margin-bottom: 8px;
    list-style-type: disc;
}

pre {
    background-color: #f5f5f5;
    padding: 12px;
    border-radius: 5px;
    border-left: 4px solid #4CAF50;
    overflow-x: auto;
    font-size: 16px;
    font-family: Consolas, Monaco, monospace;
}

iframe {
    display: block;
    margin-top: 20px;
    max-width: 100%;
    border-radius: 8px;
}

/* === MODULES PAGE: Python Basics === */

.hero {
    padding: 40px 20px;
    text-align: center;
    background-color: #f8fff8;
}

.hero h2 {
    font-size: 2.2em;
    color: #4CAF50;
    margin-bottom: 10px;
    text-align: center;
}

.hero p {
    color: #444;
    margin-bottom: 30px;
    font-size: 1.1em;
}

.module-block {
    background-color: #ffffff;
    border: 2px solid #4CAF50;
    border-radius: 12px;
    padding: 25px;
    margin: 20px auto;
    max-width: 600px;
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.05);
}

.module-block h3 {
    margin-bottom: 15px;
    font-size: 1.4em;
    color: #388E3C;
}

/* Reuse CTA buttons but align them */
.module-block .cta-button {
    display: inline-block;
    margin: 10px 8px;
    padding: 10px 18px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    transition: 0.3s;
    font-weight: 600;
}

.module-block .cta-button:hover {
    background-color: #388E3C;
}

/* === MODULES PAGE: Web Development === */

.hero {
    padding: 40px 20px;
    text-align: center;
    background-color: #f4f4f4;
}



.hero p {
    color: #444;
    margin-bottom: 30px;
    font-size: 1.1em;
    text-align: center;
}

.module-selection {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.module-card {
    background-color: #ffffff;
    border: 2px solid #0a9313;
    border-radius: 12px;
    padding: 25px;
    width: 90%;
    max-width: 600px;
    text-align: left;
    text-decoration: none;
    color: #333;
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.module-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.module-card h3 {
    margin-bottom: 10px;
    font-size: 1.3em;
    color: #5ed249;
}

.module-card p {
    font-size: 1em;
    color: #666;
}
/* Felles stil for begge knapper */
.search-users-container a.edit-button,
.search-users-container .remove-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    padding: 0 16px;
    font-size: 16px;
    font-weight: 500;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    text-decoration: none;
}

/* Grønn knapp */
.search-users-container a.edit-button {
    background-color: #4CAF50;
    color: white;
}

/* Rød knapp */
.search-users-container .remove-button {
    background-color: #ff4d4d;
    color: white;
}

/* Hover-effekter hvis du vil */
.search-users-container a.edit-button:hover {
    background-color: #45a049;
}

.search-users-container .remove-button:hover {
    background-color: #e53935;
}
