/* -------------------- */
/* Reset & base         */
/* -------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg: #cfcfcf;             /* cinza de fundo */
    --text-main: #ffffff;
    --orange: #f29b1d;
    --orange-dark: #d8820f;
    --blue: #37a9e3;
    --blue-dark: #2586b7;
    --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.18);
    --radius-pill: 999px;
    --transition-fast: 0.25s ease-out;
    --transition-medium: 0.4s ease-out;
    --font-main: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
                 Roboto, sans-serif;
}

html,
body {
    height: 100%;
}

body {
    font-family: var(--font-main);
    background: var(--bg);
    color: var(--text-main);
    overflow-x: hidden; /* evita scroll horizontal no mobile */
}

/* -------------------- */
/* Layout principal     */
/* -------------------- */

/* contentor com margem à volta no desktop */
.page {
    min-height: calc(100vh - 80px);
    max-width: 1200px;          /* limita a largura em ecrãs grandes */
    margin: 40px auto;          /* margem à volta */
    padding: 32px;
    display: flex;
    align-items: stretch;
    justify-content: center;
    border-radius: 24px;
}

/* duas colunas lado a lado */
.panel {
    flex: 1;
    padding: 32px 32px 48px;
    display: flex;
    flex-direction: column;
    position: relative;
}

/* linha vertical subtil ao centro para separar os lados em desktop */
.panel-right {
    border-left: 1px solid rgba(255, 255, 255, 0.35);
}

/* header com logo no topo */
.panel-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

/* alinhamento e tamanho dos logos */
.logo {
    max-width: 180px;
    height: auto;
}

.logo-right {
    margin-left: auto;
}

/* conteúdo central */
.panel-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 28px;
}

/* título principal */
.headline {
    font-weight: 500;
    letter-spacing: 0.18em;
    font-size: 18px;
    line-height: 1.4;
    text-transform: uppercase;
    color: var(--text-main); /* valor base (fallback) */
}

/* cores dos headlines por secção */
.panel-left .headline {
    color: var(--orange);
}

.panel-right .headline {
    color: var(--blue);
}

/* wrapper para controlar tamanho/posicionamento do blob */
.blob-wrapper {
    max-width: 300px;
    width: 100%;
}

/* link à volta do blob */
.blob-link {
    display: block;
    text-decoration: none;
}

/* imagem central com animação */
.blob {
    display: block;
    width: 100%;
    height: auto;
    animation: blobFloatTilt 10s ease-in-out infinite;
    transform-origin: center center;
    filter: drop-shadow(0 18px 35px rgba(0, 0, 0, 0.35));
    transition: transform var(--transition-medium),
                filter var(--transition-medium);
}

/* variações de timing entre os lados */
.blob-research {
    animation-delay: 0s;
}

.blob-distribution {
    animation-delay: 1.4s;
}

/* ligeiro zoom e rotação extra ao hover */
.blob:hover {
    transform: translateY(-8px) scale(1.05) rotate(2deg);
    filter: drop-shadow(0 24px 45px rgba(0, 0, 0, 0.55));
}

/* call-to-action */
.cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 40px;
    border-radius: var(--radius-pill);
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    color: #ffffff;
    box-shadow: var(--shadow-soft);
    transition:
        transform var(--transition-fast),
        box-shadow var(--transition-fast),
        background-color var(--transition-fast);
}

/* botão laranja */
.cta-research {
    background: var(--orange);
}

/* botão azul */
.cta-distribution {
    background: var(--blue);
}

.cta-research:hover {
    background: var(--orange-dark);
    transform: translateY(-3px);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.28);
}

.cta-distribution:hover {
    background: var(--blue-dark);
    transform: translateY(-3px);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.28);
}

/* pequeno “tap” no click */
.cta:active {
    transform: translateY(0);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
}

/* -------------------- */
/* Animações            */
/* -------------------- */

@keyframes blobFloatTilt {
    0% {
        transform: translateY(0) scale(1) rotate(0deg);
    }
    20% {
        transform: translateY(-8px) scale(1.015) rotate(-3deg);
    }
    50% {
        transform: translateY(0) scale(1.03) rotate(0deg);
    }
    80% {
        transform: translateY(6px) scale(1.015) rotate(3deg);
    }
    100% {
        transform: translateY(0) scale(1) rotate(0deg);
    }
}

/* -------------------- */
/* Responsivo           */
/* -------------------- */

@media (max-width: 960px) {

    .page {
        flex-direction: column;
        max-width: 100%;
        min-height: auto;
        margin: 12px auto;
        padding: 12px;
        border-radius: 14px;
    }

    /* em mobile mantemos a ordem natural:
       RS (panel-left) em cima, Dist (panel-right) em baixo
    */

    /* linha só no painel de cima (RS) */
    .panel {
        border-left: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.35);
        padding: 18px 12px 26px;
    }

    .panel-right {
        border-bottom: none;  /* o painel de baixo sem linha */
    }

    .panel-content {
        gap: 20px;
    }

    .headline {
        font-size: 14px;
        letter-spacing: 0.12em;
    }

    .logo {
        max-width: 130px;
    }

    /* no mobile o logo azul deixa de ir para a direita */
    .logo-right {
        margin-left: 0;
    }

    .blob-wrapper {
        max-width: 150px;
    }

    .cta {
        width: 100%;
        max-width: 260px;
        padding: 10px 20px;
        font-size: 14px;
    }
}

@media (max-width: 600px) {

    .page {
        margin: 8px auto;
        padding: 8px;
        border-radius: 10px;
    }

    .panel {
        padding: 16px 10px 22px;
    }

    .panel-content {
        gap: 16px;
    }

    .headline {
        font-size: 13px;
        letter-spacing: 0.08em;
    }

    .blob-wrapper {
        max-width: 150px;     /* aqui fica compacto */
    }

    .logo {
        max-width: 120px;
    }

    .cta {
        max-width: 230px;
        font-size: 13px;
        padding: 9px 18px;
    }
}
