/* Färger */
:root {
    --color-bg: #d8d3ff;         /* Huvudbakgrund: mjuk lila */

    --color-bg-alt: #cfc8ff;     /* Alt-sektioner: syrénlila */

    --color-card: #c0b6ff;       /* Kort: djupare lila */

    /* Accentfärger */
    --color-primary: #4f8cff;    /* Blå accent */
    --color-accent: #a855f7;     /* Lila accent */

    /* Text */
    --color-text: #1e1e2e;       /* Mörk grafit */
    --color-muted: #565061;      /* Ljus grafit */

    /* UI */
    --shadow-soft: 0 12px 24px rgba(0, 0, 0, 0.14);
    --radius-lg: 18px;
    --radius-full: 999px;

    --max-width: 1080px;
    --font-main: "Inter", system-ui, sans-serif;
}
/* Bas */
*, /*Att använda för alla elementar */
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-main);
    color: var(--color-text);

    /* Mjuk enfärgad pastell-lila bakgrund */
    background: var(--color-bg);

    line-height: 1.6;
}

/* Wrapper så footern trycks ner */
.page-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Sektioner */

.section {
    padding: 4rem 1.5rem;
}

.section-alt {
    background-color: var(--color-bg-alt); /* Pastellsektion */
}

.section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-intro {
    margin-bottom: 1.8rem;
    color: var(--color-muted);
}

/* Header */

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;

    background: rgba(255, 255, 255, 0.25); /* lätt genomskinlig glaslook */
    backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.header-inner {
    max-width: var(--max-width);
    margin: 0 auto;

    padding: 1rem 1.5rem;

    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.logo-mark {
    width: 36px;
    height: 36px;
    border-radius: 50%;

    background: radial-gradient(circle, #7da0ff, #c28dff);
    display: flex;
    align-items: center;
    justify-content: center;

    color: white;
    font-weight: 700;
}

.logo-text {
    font-weight: 600;
}

/* Nav */
.main-nav {
    display: flex;
    gap: 1.2rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--color-muted);
    position: relative;
}

.main-nav a:hover {
    color: var(--color-primary);
}

/* HERO */

.hero {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 2.5rem;
    align-items: center;
    max-width: var(--max-width);
    margin: 0 auto;
}

.hero-tag {
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--color-muted);
}

.hero-title {
    margin: 0.6rem 0 1rem;
    font-size: clamp(2.4rem, 4vw, 3rem);
}

.hero-subtitle {
    color: var(--color-muted);
    margin-bottom: 1.5rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
}

/* Social links */
.hero-social {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    color: var(--color-muted);
}

.hero-social a {
    color: var(--color-primary);
}

/* Hero image */
.hero-photo {
    display: flex;
    justify-content: center;
}

.hero-photo img {
    width: 260px;
    height: 260px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid white;
    box-shadow: var(--shadow-soft);
}

/* Buttons */

.btn {
    padding: 0.8rem 1.5rem;
    border-radius: var(--radius-full);
    font-size: 0.95rem;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    color: white;
    box-shadow: var(--shadow-soft);
}

.btn-outline {
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
}

/* Skills */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.skill-card {
    background: var(--color-card);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
}

/* Projects */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.project-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}

.project-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.project-body {
    padding: 1.3rem;
}
/* Testimonials / Referenser */

.testimonials-grid {
    /* Flexiblt rutnät  */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    align-items: flex-start;
}

.testimonial-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: 1rem;
    box-shadow: var(--shadow-soft);
    text-align: center;
}

/* Gör skärmbild liten och snygg */
.testimonial-card img {
    display: block;
    max-width: 260px;    /* maximal bildbredd */
    max-height: 180px;   /* maximal höjd */
    width: 100%;
    margin: 0 auto 0.7rem;
    object-fit: cover;   /* beskär för att undvika sträckning */
    border-radius: 10px;
}

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




/* Contact*/

.contact-layout {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
}

.weather-widget {
    background: var(--color-card);
    padding: 1.2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
}

.contact-form {
    background: var(--color-card);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);

    display: flex;
    gap: 0.8rem;
    flex-direction: column;
}

.contact-form input,
.contact-form textarea {
    border: 1px solid rgba(60, 60, 60, 0.25);
    padding: 0.7rem;
    border-radius: 10px;
    background: white;
    font: inherit;
}

/* Footer */

.site-footer {
    padding: 1.5rem;
    text-align: center;
    color: var(--color-muted);
    margin-top: auto;
}

/* Mobil */

@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .skills-grid,
    .projects-grid,
    .testimonials-grid,
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .main-nav {
        flex-wrap: wrap;
        justify-content: center;
    }
}
