/* --- Mörkt Industriellt Tema --- */
:root {
    --bg-deep: #0a0a0a; /* Nästan helt svart */
    --bg-panel: #141414; /* Mörkgrå för paneler */
    --bg-lighter: #1f1f1f; /* För hover-effekter */
    --text-main: #a8a8a8; /* Dämpad ljusgrå för text */
    --text-bright: #ffffff; /* Kritvit för rubriker */
    --steel-blue: #1c5588; /* Dämpad industri/Leksands-blå */
    --steel-blue-hover: #2673b5;
    --border-color: #2a2a2a;
}

/* Global Reset */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-deep);
    color: var(--text-main);
    line-height: 1.6;
    font-weight: 300;
}

h1, h2, h3, h4 {
    font-family: 'Oswald', sans-serif;
    color: var(--text-bright);
    text-transform: uppercase;
    letter-spacing: 1px;
}

a { text-decoration: none; color: inherit; transition: all 0.3s ease; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 2rem; }
.text-center { text-align: center; }

/* Diskret Industri-bakgrund (Perforerad plåt/Mesh) */
.industrial-mesh {
    background-color: var(--bg-deep);
    background-image: radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 14px 14px;
}

/* Diskret Industri-bakgrund (Varningsränder/Durkplåt stil) */
.industrial-stripes {
    background-color: var(--bg-panel);
    background-image: repeating-linear-gradient(
        -45deg,
        rgba(255, 255, 255, 0.01),
        rgba(255, 255, 255, 0.01) 5px,
        transparent 5px,
        transparent 10px
    );
}

/* --- Header --- */
header {
    background-color: rgba(10, 10, 10, 0.95);
    border-bottom: 2px solid var(--steel-blue);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-family: 'Oswald', sans-serif;
    font-weight: 700;
    color: var(--text-bright);
    letter-spacing: 2px;
}
.logo span { color: var(--steel-blue); }

nav ul { display: flex; gap: 2.5rem; }
nav a { 
    font-size: 0.9rem; 
    font-weight: 500; 
    text-transform: uppercase; 
    letter-spacing: 1.5px; 
    color: var(--text-main); 
}
nav a:hover { color: var(--text-bright); }

/* --- Hero-sektion --- */
.hero {
    position: relative;
    padding: 14rem 0 10rem;
    overflow: hidden;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

/* Mörk, sotig bakgrundsbild */
.hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: url('barken334.jpg');
    background-size: cover;
    background-position: center;
    filter: grayscale(80%) brightness(15%) contrast(120%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
    border-left: 4px solid var(--steel-blue);
    padding-left: 2rem;
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text-bright);
}
.hero h1 span {
    color: var(--steel-blue);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 3rem;
    max-width: 600px;
}

.cta-button {
    display: inline-block;
    background-color: var(--steel-blue);
    color: var(--text-bright);
    padding: 1rem 2.5rem;
    font-family: 'Oswald', sans-serif;
    font-size: 1.1rem;
    letter-spacing: 1px;
    border: 1px solid var(--steel-blue-hover);
    transition: all 0.3s ease;
}

.cta-button:hover {
    background-color: transparent;
    color: var(--steel-blue-hover);
    border-color: var(--steel-blue-hover);
    box-shadow: inset 0 0 15px rgba(38, 115, 181, 0.2);
}

/* --- Sektions-titlar --- */
.section { padding: 6rem 0; }
.section-title {
    margin-bottom: 4rem;
}
.section-title h2 {
    font-size: 2.5rem;
    display: inline-block;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
    position: relative;
}
.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: var(--steel-blue);
}

/* --- Tjänster (Paneler) --- */
.services { border-top: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color); }
.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.service-image {
    display: none; /* Dölj bildbehållaren när inga bilder används */
}

.service-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease, filter 0.35s ease;
    filter: brightness(0.95);
}

.service-card:hover .service-image {
    opacity: 1;
    visibility: visible;
}

.service-card:hover .service-image img {
    transform: scale(1.05);
    filter: brightness(1);
}

.service-card {
    background-color: var(--bg-panel);
    padding: 2rem;
    border: 1px solid var(--border-color);
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 220px; /* jämn min-höjd för professionellt utseende */
    max-width: 100%;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.gallery-card {
    overflow: hidden;
    border: 1px solid var(--border-color);
    background-color: var(--bg-panel);
    position: relative;
}

.gallery-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.35s ease, filter 0.35s ease;
    display: block;
    filter: grayscale(30%) contrast(1.05);
}

.gallery-card:hover img {
    transform: scale(1.05);
    filter: grayscale(0%) contrast(1);
}

.gallery-card:after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10,10,10,0) 45%, rgba(10,10,10,0.65) 100%);
    opacity: 0.7;
}

/* Små "skruvar" i hörnen för panel-look */
.service-card::before, .service-card::after {
    content: ''; position: absolute; width: 6px; height: 6px; background-color: #333; border-radius: 50%;
}
.service-card::before { top: 10px; left: 10px; box-shadow: calc(100% - 26px) 0 #333; }
.service-card::after { bottom: 10px; left: 10px; box-shadow: calc(100% - 26px) 0 #333; }

.service-card:hover {
    background-color: var(--bg-lighter);
    border-color: #444;
    transform: translateY(-5px);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--steel-blue);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
}

.service-card p {
    margin-bottom: 1rem;
    font-size: 0.95rem;
    color: var(--text-main);
    /* Begränsa textmängden visuellt så kortare kort ser mer enhetliga ut */
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.material-tags {
    display: flex; gap: 0.5rem; flex-wrap: wrap;
}
.material-tag {
    background-color: var(--bg-deep);
    border: 1px solid var(--border-color);
    color: #777;
    padding: 0.3rem 0.6rem;
    font-size: 0.75rem;
    font-family: 'Oswald', sans-serif;
    letter-spacing: 1px;
}
.service-card:hover .material-tag {
    color: var(--text-main);
    border-color: #555;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.process-card {
    background-color: var(--bg-panel);
    padding: 2rem;
    border: 1px solid var(--border-color);
    min-height: 200px;
}

.process-card h3 {
    font-size: 1.35rem;
    margin-bottom: 1rem;
    color: var(--steel-blue);
}

.contact-strip {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    align-items: stretch;
}

.contact-callout,
.contact-list {
    background-color: var(--bg-panel);
    border: 1px solid var(--border-color);
    padding: 2.5rem;
}

.contact-callout h3,
.contact-list h3 {
    margin-bottom: 1rem;
}

.contact-list li {
    margin-bottom: 1rem;
    color: var(--text-bright);
}

/* --- Om Oss / Experter --- */
.profile-container {
    display: flex;
    gap: 4rem;
    align-items: center;
    background-color: var(--bg-panel);
    padding: 3rem;
    border: 1px solid var(--border-color);
}

.profile-text { flex: 1; }
.profile-text p { margin-bottom: 1.5rem; font-size: 1.05rem; }

.profile-images {
    display: flex; gap: 2rem;
}

.profile-img-wrapper {
    text-align: center;
}

.profile-img {
    width: 160px; height: 160px;
    object-fit: cover;
    border: 3px solid var(--border-color);
    filter: grayscale(30%) contrast(110%); /* Lite ruffigare bildton */
    transition: filter 0.3s;
}

.profile-img-wrapper:hover .profile-img {
    filter: grayscale(0%) contrast(100%);
}

.expert-title {
    font-family: 'Oswald', sans-serif;
    font-size: 0.85rem;
    color: var(--steel-blue);
    margin-top: 1rem;
    letter-spacing: 1px;
}

.profile-name {
    font-family: 'Oswald', sans-serif;
    color: var(--text-bright);
    font-size: 1.2rem;
}

/* --- Footer --- */
footer {
    background-color: #050505;
    padding: 5rem 0 2rem;
    border-top: 3px solid var(--border-color);
    font-size: 0.9rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.footer-logo {
    font-size: 1.5rem;
    font-family: 'Oswald', sans-serif;
    color: var(--text-bright);
    margin-bottom: 1rem;
    letter-spacing: 2px;
}
.footer-logo span { color: var(--steel-blue); }

.footer-column h4 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: #666;
}

.footer-column ul li { margin-bottom: 0.5rem; }

.contact-link { color: var(--steel-blue); }
.contact-link:hover { color: var(--text-bright); text-decoration: underline; }

.copyright {
    text-align: center;
    color: #444;
    padding-top: 2rem;
    border-top: 1px solid #111;
    font-size: 0.8rem;
}

/* Gallery modal styles */
/* Modal container uses flex so content is centered */
#gallery-modal { display: none; position: fixed; inset: 0; z-index: 2000; align-items: center; justify-content: center; }
#gallery-modal .gm-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.7); }
#gallery-modal .gm-content { position: relative; margin: 0 1rem; max-width: 1100px; width: calc(100% - 2rem); max-height: 90vh; background: var(--bg-deep); padding: 1rem; border: 1px solid var(--border-color); overflow: auto; }
#gallery-modal .gm-close { position: absolute; right: 8px; top: 8px; background: var(--steel-blue); color: var(--text-bright); border: none; padding: 0.5rem 0.75rem; cursor: pointer; }
#gallery-modal .gm-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap: 0.5rem; padding: 1rem; }
#gallery-modal .gm-item { display:flex; align-items:center; justify-content:center; background: transparent; }
#gallery-modal .gm-item img { max-width: 100%; max-height: 70vh; object-fit: contain; display: block; margin: 0 auto; }

/* --- Responsivitet --- */
@media (max-width: 992px) {
    .hero h1 { font-size: 3rem; }
    .profile-container { flex-direction: column; }
    .profile-images { justify-content: center; width: 100%; }
    .contact-strip { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    nav ul { gap: 1rem; display: none; /* Kan byggas ut till hamburgermeny */ }
    .hero { padding: 10rem 0 6rem; }
    .hero h1 { font-size: 2.5rem; }
    .hero-content { border-left: none; padding-left: 0; }
    .section { padding: 4rem 0; }
    .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
    .profile-images { flex-direction: column; align-items: center; }
}
