/* =========================
   GERAL
========================= */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family:
        Arial,
        Helvetica,
        sans-serif;

    background:
        linear-gradient(
            135deg,
            #071321,
            #0b1e32
        );

    color: white;

    min-height: 100vh;
}


/* =========================
   ESTRUTURA PRINCIPAL
========================= */

.app {
    min-height: 100vh;

    display: grid;

    grid-template-columns:
        240px 1fr;
}


/* =========================
   MENU LATERAL
========================= */

.sidebar {
    min-height: 100vh;

    padding: 25px 16px;

    background:
        rgba(
            5,
            16,
            29,
            0.92
        );

    border-right:
        1px solid
        rgba(
            255,
            255,
            255,
            0.07
        );

    display: flex;

    flex-direction: column;
}


/* =========================
   LOGO
========================= */

.logo {
    display: flex;

    align-items: center;

    gap: 12px;

    padding:
        0 8px 25px;

    border-bottom:
        1px solid
        rgba(
            255,
            255,
            255,
            0.07
        );
}


.logo-icon {
    width: 42px;
    height: 42px;

    border-radius: 12px;

    display: flex;

    align-items: center;

    justify-content: center;

    background:
        linear-gradient(
            135deg,
            #168cd8,
            #35b8ff
        );

    font-size: 20px;

    font-weight: bold;

    box-shadow:
        0 5px 20px
        rgba(
            27,
            153,
            230,
            0.18
        );
}


.logo-text {
    display: flex;

    flex-direction: column;

    gap: 3px;
}


.logo-text strong {
    font-size: 16px;
}


.logo-text span {
    color: #73879d;

    font-size: 11px;
}


/* =========================
   MENU
========================= */

.menu {
    margin-top: 25px;

    display: flex;

    flex-direction: column;

    gap: 7px;
}


.menu-item {
    min-height: 48px;

    padding:
        0 14px;

    border-radius: 11px;

    display: flex;

    align-items: center;

    gap: 13px;

    color: #91a5b9;

    text-decoration: none;

    font-size: 14px;

    font-weight: 600;

    transition:
        background 0.2s,
        color 0.2s,
        transform 0.2s;
}


.menu-item:hover {
    color: white;

    background:
        rgba(
            255,
            255,
            255,
            0.06
        );

    transform:
        translateX(2px);
}


.menu-item.ativo {
    color: #8ed8ff;

    background:
        rgba(
            39,
            153,
            222,
            0.12
        );

    border:
        1px solid
        rgba(
            75,
            177,
            239,
            0.15
        );
}


.menu-icon {
    width: 24px;

    text-align: center;

    font-size: 18px;
}


/* =========================
   FUNDO DO MENU
========================= */

.sidebar-footer {
    margin-top: auto;

    padding:
        18px 10px 5px;

    color: #71859a;

    font-size: 11px;

    display: flex;

    align-items: center;

    gap: 8px;
}


.status-dot {
    width: 8px;
    height: 8px;

    border-radius: 50%;

    background: #2ecc71;

    box-shadow:
        0 0 10px
        rgba(
            46,
            204,
            113,
            0.6
        );
}


/* =========================
   CONTEÚDO PRINCIPAL
========================= */

.conteudo {
    min-width: 0;

    padding:
        35px 45px 60px;
}


/* =========================
   CABEÇALHO DO PAINEL
========================= */

.topbar {
    max-width: 1200px;

    margin:
        0 auto 35px;

    display: flex;

    justify-content: space-between;

    align-items: center;
}


.pagina-label {
    color: #559bc7;

    font-size: 10px;

    font-weight: bold;

    letter-spacing: 1.8px;
}


.topbar h1 {
    margin:
        5px 0 0;

    font-size: 32px;
}


.relogio {
    padding:
        11px 16px;

    border-radius: 10px;

    background:
        rgba(
            255,
            255,
            255,
            0.05
        );

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            0.07
        );

    color: #a9bdd0;

    font-size: 13px;

    font-variant-numeric:
        tabular-nums;
}


/* =========================
   CONTEÚDO METEOROLOGIA
========================= */

.weather-container {
    max-width: 1200px;

    margin: auto;
}


/* =========================
   LOCALIZAÇÃO / SINES
========================= */

.localizacao-tempo {
    display: flex;

    justify-content: space-between;

    align-items: center;

    margin-bottom: 30px;
}


.localizacao-tempo h2 {
    margin: 0;

    font-size: 42px;
}


.localizacao-tempo p {
    color: #9caec2;

    margin-top: 5px;

    margin-bottom: 0;
}


/* =========================
   ESTADO GERAL
========================= */

.estado {
    padding: 12px 20px;

    border-radius: 12px;

    font-weight: bold;

    font-size: 14px;

    transition: 0.2s;
}


.estado.bom {
    background: #1e8c5a;
}


.estado.medio {
    background: #b48a17;
}


.estado.mau {
    background: #ad3d3d;
}


/* =========================
   CARTÕES
========================= */

.cards {
    display: grid;

    grid-template-columns:
        repeat(
            4,
            minmax(0, 1fr)
        );

    gap: 16px;
}


.card {
    background:
        rgba(
            255,
            255,
            255,
            0.08
        );

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            0.1
        );

    border-radius: 18px;

    padding: 22px;

    display: flex;

    gap: 18px;

    min-width: 0;

    backdrop-filter:
        blur(10px);
}


.icon {
    font-size: 34px;
}


.titulo {
    color: #9caec2;

    font-size: 14px;
}


.valor {
    font-size: 30px;

    font-weight: bold;

    margin-top: 4px;
}


.detalhe {
    margin-top: 5px;

    color: #c3d0dc;

    font-size: 14px;
}


.direcao {
    margin-top: 12px;

    font-size: 17px;

    color: #8ed8ff;
}


/* =========================
   PREVISÃO
========================= */

.previsao {
    margin-top: 35px;

    background:
        rgba(
            255,
            255,
            255,
            0.06
        );

    padding: 25px;

    border-radius: 18px;

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            0.04
        );
}


/* =========================
   NAVEGAÇÃO DOS DIAS
========================= */

.previsao-header {
    display: grid;

    grid-template-columns:
        50px 1fr 50px;

    align-items: center;

    margin-bottom: 20px;
}


.titulo-dia {
    text-align: center;
}


.titulo-dia h2 {
    margin: 0;

    font-size: 22px;
}


.titulo-dia span {
    display: block;

    margin-top: 4px;

    color: #9caec2;

    font-size: 13px;
}


.seta-dia {
    width: 44px;

    height: 44px;

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            0.12
        );

    border-radius: 12px;

    background:
        rgba(
            255,
            255,
            255,
            0.06
        );

    color: white;

    font-size: 32px;

    line-height: 1;

    cursor: pointer;

    transition: 0.2s;
}


.seta-dia:hover:not(:disabled) {
    background:
        rgba(
            78,
            174,
            255,
            0.18
        );

    border-color:
        rgba(
            142,
            216,
            255,
            0.35
        );
}


.seta-dia:active:not(:disabled) {
    transform:
        scale(0.94);
}


.seta-dia:disabled {
    opacity: 0.18;

    cursor: default;
}


/* =========================
   HORAS
========================= */

.horas {
    display: grid;

    grid-template-columns:
        repeat(
            6,
            minmax(0, 1fr)
        );

    gap: 10px;
}


.hora {
    text-align: center;

    padding: 15px 8px;

    border-radius: 12px;

    background:
        rgba(
            255,
            255,
            255,
            0.05
        );

    min-width: 0;

    transition: 0.2s;
}


.hora:hover {
    background:
        rgba(
            255,
            255,
            255,
            0.09
        );
}


.hora-passada {
    opacity: 0.48;
}


.hora-atual {
    opacity: 1;

    background:
        rgba(
            78,
            174,
            255,
            0.12
        );

    border:
        1px solid
        rgba(
            142,
            216,
            255,
            0.35
        );

    box-shadow:
        0 0 18px
        rgba(
            78,
            174,
            255,
            0.08
        );
}


.hora-titulo {
    display: block;

    color: #aab8c5;

    font-weight: bold;

    font-size: 15px;
}


.tempo-icon {
    display: block;

    font-size: 30px;

    margin: 12px 0;
}


.temperatura {
    font-size: 22px;

    font-weight: bold;

    margin-bottom: 14px;
}


.vento-label {
    font-size: 12px;

    color: #9caec2;

    margin-bottom: 4px;
}


.vento-valor {
    font-size: 15px;

    font-weight: bold;
}


.rajada {
    color: #9caec2;

    font-size: 11px;

    margin-top: 3px;
}


.indicador {
    width: 12px;

    height: 12px;

    border-radius: 50%;

    margin: 12px auto 0;
}


.verde {
    background: #2ecc71;
}


.amarelo {
    background: #f1c40f;
}


.vermelho {
    background: #e74c3c;
}


/* =========================
   MAR E MARÉS
========================= */

.mares {
    margin-top: 20px;

    background:
        rgba(
            255,
            255,
            255,
            0.06
        );

    padding: 25px;

    border-radius: 18px;

    border:
        1px solid
        rgba(
            255,
            255,
            255,
            0.04
        );
}


.mares-header {
    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 20px;

    margin-bottom: 22px;
}


.mares-header h2 {
    margin: 0;
}


.mares-header p {
    color: #9caec2;

    margin: 5px 0 0;

    font-size: 14px;
}


.mare-estado {
    padding: 10px 16px;

    border-radius: 10px;

    background:
        rgba(
            78,
            174,
            255,
            0.15
        );

    color: #8ed8ff;

    font-size: 13px;

    font-weight: bold;
}


/* =========================
   INFO MAR
========================= */

.mar-info {
    display: grid;

    grid-template-columns:
        repeat(
            4,
            minmax(0, 1fr)
        );

    gap: 10px;
}


.mar-item {
    background:
        rgba(
            255,
            255,
            255,
            0.05
        );

    border-radius: 12px;

    padding: 18px;

    min-width: 0;

    transition: 0.2s;
}


.mar-item:hover {
    background:
        rgba(
            255,
            255,
            255,
            0.09
        );
}


.mar-label {
    display: block;

    color: #9caec2;

    font-size: 12px;

    margin-bottom: 9px;
}


.mar-valor {
    font-size: 20px;

    font-weight: bold;
}


.mar-detalhe {
    color: #9caec2;

    font-size: 12px;

    margin-top: 7px;
}


/* =========================
   MARÉS DO DIA
========================= */

.proximas-mares {
    margin-top: 25px;

    border-top:
        1px solid
        rgba(
            255,
            255,
            255,
            0.08
        );

    padding-top: 20px;
}


.proximas-mares h3 {
    margin:
        0 0 15px;

    font-size: 16px;
}


.mare-timeline {
    display: grid;

    grid-template-columns:
        repeat(
            4,
            minmax(0, 1fr)
        );

    gap: 10px;
}


.mare-evento {
    text-align: center;

    padding: 15px 10px;

    background:
        rgba(
            255,
            255,
            255,
            0.04
        );

    border-radius: 12px;

    transition: 0.2s;
}


.mare-evento:hover {
    background:
        rgba(
            255,
            255,
            255,
            0.08
        );
}


.mare-evento.destaque {
    background:
        rgba(
            78,
            174,
            255,
            0.10
        );

    border:
        1px solid
        rgba(
            142,
            216,
            255,
            0.25
        );
}


.mare-icon {
    font-size: 21px;

    margin-bottom: 6px;
}


.mare-hora {
    font-size: 19px;

    font-weight: bold;
}


.mare-tipo {
    color: #9caec2;

    font-size: 12px;

    margin-top: 4px;
}


.mare-altura {
    color: #8ed8ff;

    font-size: 14px;

    font-weight: bold;

    margin-top: 6px;
}


/* =========================
   TABLET
========================= */

@media (max-width: 1100px) {

    .conteudo {
        padding:
            30px 25px 50px;
    }


    .cards {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .horas {
        grid-template-columns:
            repeat(
                4,
                minmax(0, 1fr)
            );
    }

}


/* =========================
   MENU COMPACTO
========================= */

@media (max-width: 800px) {

    .app {
        grid-template-columns:
            72px 1fr;
    }


    .sidebar {
        padding:
            20px 10px;
    }


    .logo {
        justify-content: center;

        padding:
            0 0 20px;
    }


    .logo-text,
    .menu-text,
    .sidebar-footer span {
        display: none;
    }


    .menu-item {
        padding: 0;

        justify-content: center;
    }


    .menu-icon {
        width: auto;
    }


    .sidebar-footer {
        justify-content: center;
    }


    .conteudo {
        padding:
            25px 18px 40px;
    }


    .topbar {
        margin-bottom: 30px;
    }


    .topbar h1 {
        font-size: 28px;
    }


    .localizacao-tempo h2 {
        font-size: 34px;
    }


    .horas {
        grid-template-columns:
            repeat(
                3,
                minmax(0, 1fr)
            );
    }


    .mar-info {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .mare-timeline {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }

}


/* =========================
   TELEMÓVEL
========================= */

@media (max-width: 600px) {

    .conteudo {
        padding:
            20px 12px 35px;
    }


    .topbar {
        align-items: center;
    }


    .topbar h1 {
        font-size: 25px;
    }


    .pagina-label {
        font-size: 9px;
    }


    .relogio {
        padding:
            9px 10px;

        font-size: 11px;
    }


    .localizacao-tempo {
        align-items: flex-start;

        flex-direction: column;

        gap: 15px;
    }


    .localizacao-tempo h2 {
        font-size: 32px;
    }


    .estado {
        padding:
            10px 14px;

        font-size: 12px;
    }


    .cards {
        grid-template-columns:
            1fr;
    }


    .previsao {
        padding: 18px;
    }


    .horas {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .mares {
        padding: 18px;
    }


    .mares-header {
        align-items: flex-start;

        flex-direction: column;
    }


    .mar-info {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .mare-timeline {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }

}


/* =========================
   ECRÃ MUITO PEQUENO
========================= */

@media (max-width: 400px) {

    .app {
        grid-template-columns:
            62px 1fr;
    }


    .sidebar {
        padding:
            15px 7px;
    }


    .logo-icon {
        width: 38px;

        height: 38px;
    }


    .conteudo {
        padding:
            18px 10px 30px;
    }


    .relogio {
        font-size: 10px;

        padding:
            8px;
    }


    .horas {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .mar-info {
        grid-template-columns:
            1fr;
    }


    .mare-timeline {
        grid-template-columns:
            1fr;
    }

}

.logo-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}