* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background: #fff;
}

body {
    position: relative;
    overflow: hidden;
    color: #222;
    font-family: Arial, Helvetica, sans-serif;
}


/* =========================================================
   BRAND
   ========================================================= */

.brand {
    position: fixed;
    top: 12px;
    left: 28px;

    display: flex;
    align-items: center;
    gap: 18px;

    z-index: 1000;
}

.brand a {
    color: #222;
    text-decoration: none;

    font-size: 21px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.qr-logo {
    display: block;

    width: 42px;
    height: 42px;

    object-fit: contain;
}


/* =========================================================
   S / I / M NAVIGATION
   ========================================================= */

.top-nav {
    position: fixed;
    top: 19px;
    right: 76px;

    display: flex;
    align-items: center;
    gap: 25px;

    z-index: 2000;
}

.top-nav a {
    position: relative;

    color: #444;
    text-decoration: none;

    font-size: 12px;
    font-weight: 400;

    z-index: 2001;
}

.top-nav a:hover,
.top-nav a.active {
    color: #000;
    font-weight: 600;
}


/* =========================================================
   STAGE
   ========================================================= */

.stage {
    position: relative;

    width: 100vw;
    height: 100vh;

    overflow: hidden;
    background: #fff;
}


/* =========================================================
   COMMON IMAGE BUTTON
   ========================================================= */

.child {
    position: absolute;

    margin: 0;
    padding: 0;

    border: 0;
    outline: 0;

    background: transparent;

    appearance: none;
    -webkit-appearance: none;
}

.child img {
    display: block;

    user-select: none;
    -webkit-user-drag: none;

    pointer-events: none;
}


/* =========================================================
   S - SAGA
   Full height, top-left.
   ========================================================= */

.child-left {
    top: 0;
    left: 0;

    height: 100vh;
    width: auto;
}

.child-left img {
    width: auto;
    height: 100vh;

    max-width: none;
    max-height: none;

    object-fit: contain;
    object-position: left top;
}


/* =========================================================
   I - ISLA
   Full height on landscape.
   Top aligned on portrait.
   ========================================================= */

.child-center {
    top: 0;
    left: 50%;

    height: 100vh;
    width: auto;

    transform: translateX(-50%);
}

.child-center img {
    width: auto;
    height: 100vh;

    max-width: 100vw;
    max-height: 100vh;

    object-fit: contain;
    object-position: center top;
}


/* =========================================================
   M - MEA
   Full height on landscape.
   Top aligned also on portrait.
   ========================================================= */

.child-right {
    top: 0;
    right: 0;

    height: 100vh;
    width: auto;
}

.child-right img {
    display: block;

    width: auto;
    height: 100vh;

    max-width: 100vw;
    max-height: 100vh;

    object-fit: contain;
    object-position: right top;
}


/* =========================================================
   AUDIO CLICK AREA

   The BUTTON itself contains the complete image, but we do
   NOT let the complete button receive pointer events.

   Only the ::after face area receives clicks.
   ========================================================= */

.audio-face {
    pointer-events: none;
    cursor: default;
}

.audio-face::after {
    content: "";

    position: absolute;

    z-index: 50;

    pointer-events: auto;
    cursor: pointer;

    background: transparent;
}


/* Saga face: upper-left part of image */

.child-left.audio-face::after {
    left: 17%;
    top: 21%;

    width: 32%;
    height: 25%;
}


/* Isla face: center */

.child-center.audio-face::after {
    left: 35%;
    top: 21%;

    width: 30%;
    height: 24%;
}


/* Mea face: center/right */

.child-right.audio-face::after {
    left: 34%;
    top: 20%;

    width: 32%;
    height: 25%;
}


/* =========================================================
   PORTRAIT

   Isla and Mea fit to screen WIDTH and start at top.
   Any unused vertical area remains white.
   ========================================================= */

@media (orientation: portrait) {

    .child-center {
        top: 0;
        left: 50%;

        width: 100vw;
        height: auto;

        transform: translateX(-50%);
    }

    .child-center img {
        width: 100vw;
        height: auto;

        max-width: 100vw;
        max-height: none;

        object-fit: contain;
        object-position: center top;
    }


    .child-right {
        top: 0;
        right: 0;

        width: 100vw;
        height: auto;
    }

    .child-right img {
        width: 100vw;
        height: auto;

        max-width: 100vw;
        max-height: none;

        object-fit: contain;
        object-position: right top;
    }
}


/* =========================================================
   MOBILE HEADER
   ========================================================= */

@media (max-width: 768px) {

    .brand {
        top: 10px;
        left: 14px;

        gap: 12px;
    }

    .brand a {
        font-size: 18px;
    }

    .qr-logo {
        width: 40px;
        height: 40px;
    }

    .top-nav {
        top: 12px;
        right: 12px;

        gap: 8px;

        z-index: 2000;
    }

    /*
       Letters remain visually small, but each link gets a
       much larger invisible touch target.
    */

    .top-nav a {
        display: flex;

        width: 36px;
        height: 36px;

        align-items: center;
        justify-content: center;

        font-size: 12px;
    }
}


/* =========================================================
   VERY SMALL PHONES
   ========================================================= */

@media (max-width: 420px) {

    .brand {
        left: 10px;
    }

    .brand a {
        font-size: 17px;
    }

    .qr-logo {
        width: 38px;
        height: 38px;
    }

    .top-nav {
        top: 10px;
        right: 6px;

        gap: 2px;
    }

    .top-nav a {
        width: 34px;
        height: 38px;
    }
}
