:root {
    --primary: #1e293b;
    --secondary: #3b82f6;
    --bg-color: #f1f5f9;
    --card-bg: #ffffff;
    --text-main: #334155;
    --text-muted: #64748b;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
}

/* --- HEADER & NAVIGATION --- */
header {
    background: linear-gradient(135deg, var(--primary) 0%, #334155 100%);
    color: white;
    padding: 3rem 1rem 4rem 1rem;
    text-align: center;
    position: relative;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
    letter-spacing: 1px;
}

header p {
    font-size: 1.2rem;
    color: #cbd5e1;
    font-weight: 300;
}

nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    background-color: white;
    padding: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
    padding: 0.5rem 1.5rem;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

nav a:hover, nav a.active {
    color: var(--secondary);
    border-bottom-color: var(--secondary);
}

/* --- MAIN CONTAINER --- */
.container {
    max-width: 1100px;
    margin: 2rem auto 3rem auto;
    padding: 0 1rem;
    position: relative;
    z-index: 10;
}

/* --- CV & PROJEKTER GRID LAYOUT --- */
.cv-grid {
    display: grid;
    grid-template-columns: 1fr 2.5fr;
    gap: 2rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.card {
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.project-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 0;
}

.project-thumbnail {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid #e2e8f0;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.project-thumbnail:hover {
    opacity: 0.9;
}

.project-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

/* --- SIDEPANEL (VENSTRE) --- */
.sidebar {
    text-align: center;
}

.profile-img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid white;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    margin: 0 auto 1.5rem auto;
    background-color: white;
    display: block;
}

.sidebar h3 {
    font-size: 1.2rem;
    color: var(--primary);
    margin: 1.5rem 0 0.5rem 0;
    text-align: left;
    border-bottom: 2px solid var(--bg-color);
    padding-bottom: 0.5rem;
}

.sidebar ul {
    list-style: none;
    text-align: left;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.sidebar ul li {
    margin-bottom: 0.5rem;
}

.sidebar ul li i {
    width: 25px;
    color: var(--secondary);
}

.badge {
    display: inline-block;
    background-color: #e0f2fe;
    color: #0369a1;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.tag-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.tag {
    background-color: var(--bg-color);
    color: var(--text-main);
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.85rem;
}

/* --- HOVEDINDHOLD (HØJRE) --- */
.main-content h2 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.main-content h2 i {
    color: var(--secondary);
}

.timeline {
    border-left: 2px solid #e2e8f0;
    padding-left: 1.5rem;
    margin-left: 1rem;
}

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -1.85rem;
    top: 0.3rem;
    width: 12px;
    height: 12px;
    background-color: var(--secondary);
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 0 0 2px var(--secondary);
}

.timeline-item h4 {
    font-size: 1.1rem;
    color: var(--primary);
}

.timeline-item .company {
    font-weight: 600;
    color: var(--text-main);
}

.timeline-item .date {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: inline-block;
    background-color: var(--bg-color);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
}

.timeline-item p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.course-list {
    list-style: none;
}

.course-list li {
    margin-bottom: 0.8rem;
    padding-left: 1.5rem;
    position: relative;
}

.course-list li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--secondary);
    font-size: 0.9rem;
}

/* --- KONTAKTFORMULAR --- */
.contact-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary);
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
    background-color: #f8fafc;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--secondary);
    background-color: white;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-group textarea {
    resize: vertical;
    height: 150px;
}

button.submit-btn {
    background-color: var(--secondary);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
    font-weight: 600;
    transition: all 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

button.submit-btn:hover {
    background-color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

/* --- BILLED-MODAL (ZOOM OVERLAY) --- */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal.active {
    display: flex; 
}

.modal-content {
    max-width: 85%;
    max-height: 85vh;
    width: auto;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.5);
    object-fit: contain;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    z-index: 10000;
}

.modal-close:hover {
    color: var(--secondary);
}

/* --- RESPONSIVT DESIGN --- */
@media (max-width: 768px) {
    .cv-grid, .projects-grid {
        grid-template-columns: 1fr;
    }
}