/* ==========================================
   FONT
========================================== */
@font-face {
    font-family: 'CCJoeKubert';
    src: local('CCJoeKubert'),
         url('../fonts/CCJoeKubert.woff2') format('woff2'),
         url('../fonts/CCJoeKubert.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}


/* ==========================================
   BASE
========================================== */
html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'CCJoeKubert', system-ui, sans-serif;
    background: #f2f2f2;
    color: #222;
    overflow-x: hidden;
}

body {
    display: flex;
    flex-direction: column;
}

/* Låt main scrolla om innehållet är för stort */
main {
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 75px; /* gör plats för fixed footer */
    gap: 20px;
    box-sizing: border-box;
    overflow-y: visible;
}

/* ==========================================
   LINKS
========================================== */
a {
    color: inherit;
    text-decoration: underline;
}

/* ==========================================
   HEADER
========================================== */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-bottom: 1px solid #eee;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding: 10px 20px;
}

.header-inner {
    display: flex;
    align-items: center;
    gap: clamp(4px, 4vw, 25px);
    max-width: 1200px;
    width: 100%;
    justify-content: center;
}

header img {
    height: auto;
    max-height: 60px;
    height: 60px;
    width: auto;
    flex-shrink: 0;
}

/* mobil: visa bara den lilla loggan */
.logo-horizontal {
  display: none;
}

.logo-small {
  display: inline-block;
}


/* ==========================================
   TITLE IMAGE
========================================== */
.title-image {
    display: block;
    width: 100%;
    max-width: 500px;
    height: auto;
    margin: 0 auto 20px auto;
}

/* ==========================================
   TEXT
========================================== */
.text {
    text-align: center;
    padding-right: 10px;
    max-width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
}

.text p {
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    line-height: 1.5;
    margin-bottom: 0.9em;
}

/* ==========================================
   MOCKUP (3D)
========================================== */
.mockup-wrapper {
    flex: 0 0 auto;
    width: 40%;
    max-width: 600px;
    /* min-width: 350px; */
    min-width: 280px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.mockup {
    display: flex;
    align-items: center;
    justify-content: center;
    perspective: 1200px;
}

.mockup-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 6px;
    transform-origin: left center;
    transform: rotateY(-18deg) rotateX(4deg);
    box-shadow: 0 18px 35px rgba(0,0,0,0.25);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    will-change: transform;
    max-width: none;
}

.mockup-img:hover {
    transform: rotateY(-10deg) rotateX(3deg) translateZ(25px);
    box-shadow: 0 25px 55px rgba(0,0,0,0.35);
}

.mockup-img:active {
    transform: rotateY(-8deg) rotateX(2deg) translateZ(15px);
}

/* ==========================================
   FOOTER
========================================== */
footer {
    position: fixed;
    bottom: 0;
    width: 100%;
    z-index: 1000;
    background: #dadada;
    border-top: 1px solid #ddd;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.05);
    height: 45px;
    font-size: clamp(0.75rem, 1.2vw, 0.9rem);
    line-height: 1.3;
}

footer .footer-inner {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 0 10px; /* lite utrymme mot kanterna på mobil */
    box-sizing: border-box;
}

footer .footer-content {
    text-align: center;
    white-space: nowrap; /* hindrar wrap */
}

footer .footer-content a {
    text-decoration: underline;
    color: inherit;
}

.footer a {
    display: inline-flex;
    align-items: center;
    gap: 6px;             /* avstånd mellan ikon och text */
    line-height: 1;       /* hindrar att ikonen ändrar radens höjd */
}

.footer a svg {
    position: relative;
    top: 2px;
}

.mail-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    line-height: 1;
    vertical-align: middle;
}

.mail-icon {
    width: 18px;
    height: 18px;
    position: relative;
    top: 2px; /* perfekt visuell centrering */
    flex-shrink: 0;
}


/* ==========================================
   DESKTOP (≥900px)
========================================== */
@media (min-width: 900px) {
    /* Main layout */
    main {
        display: flex;
        flex-direction: row;
        align-items: flex-start;
        gap: 10px; /* mellan text och mockup */
        justify-content: center;
        max-width: 1200px;
        margin: 0 auto;
        padding: 0 40px; /* <-- extra padding på sidorna */
        box-sizing: border-box;
    }

    /* Header */
    .header-inner {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: clamp(10px, 4vw, 25px);
        max-width: 1200px;
        margin: 0 auto;
        padding-left: 40px; /* matchar main */
        padding-right: 40px;
        box-sizing: border-box;
    }

    .logo-horizontal {
        display: flex;
        align-items: center;
        gap: 0px;
        border: 2px solid black;
        padding: 5px 5px 5px 19px;
    }
    .logo-small {
        display: none;
    }

    /* justera storlek på de uppdelade delarna */
    .logo.text-part-one {
        height: 50px; /* texten större på breda skärmar */
    }
    .logo.text-part-two {
        height: 41px; /* texten större på breda skärmar */
        position: relative;
        left: -8px;
    }

    .logo.unicorn {
        height: 50px;
    }

    header img:not(.logo) {
        height: auto;
        max-height: 60px;
        width: auto;
    }

    /* Text & mockup */
    .text, .mockup-wrapper {
        flex: 0 0 50%;
        max-width: 50%;
        box-sizing: border-box;
    }

    .text {
        text-align: left;
        padding-left: 0;
        padding-right: 10px;
        padding-top: clamp(25px, 5vw, 50px);
        padding-bottom: 0;
    }

    .mockup-wrapper {
        display: flex;
        justify-content: center;
        align-items: center;
        max-width: 600px;
        padding-top: clamp(25px, 5vw, 50px);
        padding-bottom: clamp(25px, 5vw, 50px);
        padding-left: 10px;
        padding-right: 0;
    }

    .mockup-img {
        width: 100%;
        height: auto;
    }
}

/* ==========================================
   LARGE SCREENS (≥1200px)
========================================== */
@media (min-width: 1200px) {
    .mockup-wrapper {
        width: 35%;
    }
}

/* ==========================================
   TABLET / PORTRAIT HIGH-RES (900–1200px, portrait)
========================================== */
@media (min-width: 900px) and (max-width: 1200px) and (orientation: portrait) {
    main {
        padding-left: 40px;   /* mer luft på sidorna */
        padding-right: 40px;
    }

    .header-inner {
        padding-left: 40px;
        padding-right: 40px;
    }
}

/* ==========================================
   MOBILE / SMALL SCREENS (<900px)
========================================== */
@media (max-width: 899px) {
    main {
        flex-direction: column;
        align-items: center;
        gap: 5px;
        padding: 20px; /* generellt padding runt allt */
        padding-bottom: 85px; /* extra plats för footer */
    }

    .mockup-wrapper {
        width: 90%;
        max-width: none;
        justify-content: center;
        align-items: center;
        padding-left: 10px;
        padding-right: 10px;
    }

    .text {
        max-width: 90%;
        text-align: center;
        padding: 0 10px;
    }

    .title-image {
        max-width: 350px;
    }

    .header-inner {
        justify-content: center;
        gap: clamp(10px, 4vw, 25px);
        padding: 10px 20px;
    }

    header img {
        height: auto;
        max-height: 50px;
    }

    header {
        min-height: 60px;
        height: auto;
        padding: 10px 0;
    }
}


/* Fix sticky på Android-tablets */
@supports (-webkit-touch-callout: none) {
    html, body {
        overflow-x: hidden;
        overflow-y: auto;
        height: auto;
    }
}
