/* =====================================================
   Meteopego V5
   Style Sheet
===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

:root{

    --primary:#0d6efd;
    --secondary:#6c757d;
    --success:#198754;
    --warning:#ffc107;
    --danger:#dc3545;

    --background:#eef5fb;
    --card:#ffffff;
    --text:#212529;

}

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{

    font-family:'Poppins',sans-serif;
    background:linear-gradient(180deg,#d9ecff 0%,#eef5fb 100%);
    color:var(--text);

}

/* ===========================
   Hero
=========================== */

.hero{

    text-align:center;
    margin-bottom:40px;

}

.hero h1{

    font-size:3rem;
    font-weight:700;
    color:var(--primary);

}

.hero p{

    color:#555;
    font-size:1.1rem;

}

/* ===========================
   Dashboard
=========================== */

.dashboard{

    margin-top:30px;

}

/* ===========================
   Cards
=========================== */

.card{

    border:none !important;
    border-radius:18px;
    overflow:hidden;
    background:var(--card);

    transition:.25s;

}

.card:hover{

    transform:translateY(-5px);

    box-shadow:0 15px 35px rgba(0,0,0,.12);

}

.card-body{

    padding:30px;

}

.card h2{

    font-size:2.4rem;

}

.card-title{

    margin-top:10px;

    font-weight:600;

}

.display-5{

    margin-top:15px;

    font-weight:700;

    color:var(--primary);

}

/* ===========================
   Grafici
=========================== */

.card-header{

    font-weight:600;

    font-size:1.1rem;

}

/* ===========================
   Footer
=========================== */

footer{

    margin-top:60px;

    padding:25px;

    text-align:center;

    color:#777;

    font-size:.9rem;

}

/* ===========================
   Navbar
=========================== */

.navbar{

    box-shadow:0 3px 15px rgba(0,0,0,.08);

}

.navbar-brand{

    font-weight:700;

}

/* ===========================
   Responsive
=========================== */

@media(max-width:768px){

.hero h1{

    font-size:2.2rem;

}

.display-5{

    font-size:2rem;

}

.card-body{

    padding:20px;

}

}

/* ==========================
Grafici
========================== */

.chart-container {

    position: relative;

    width: 100%;

    height: 420px;

}

/* ==========================
   Bussola vento
========================== */

.wind-direction-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
}

.wind-compass {
    position: relative;
    width: 150px;
    height: 150px;
    border: 3px solid var(--primary);
    border-radius: 50%;
    background: #f8fbff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, .10);
}

.wind-direction-label {
    position: absolute;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--primary);
}

.wind-direction-label.north {
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
}

.wind-direction-label.east {
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.wind-direction-label.south {
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
}

.wind-direction-label.west {
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.wind-arrow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 65px;
    transform-origin: 50% 100%;
    transform: translate(-50%, -100%) rotate(0deg);
    background: var(--primary);
    border-radius: 5px;
    transition: transform .5s ease;
    font-size: 0;
}

.wind-arrow::after {
    content: "";
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 16px solid var(--primary);
}

#wind-direction {
    font-size: 1.1rem;
}
/* --------------------------------------------------------------------------
   Grafici Home - ultime 24 ore
   -------------------------------------------------------------------------- */

.home-charts-section .card-header {
    font-weight: 600;
}

.home-chart-card {
    padding: 16px;
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: 12px;
    background: #fff;
}

.home-chart-card h5 {
    font-weight: 600;
}

.home-chart-container {
    position: relative;
    width: 100%;
    height: 260px;
}

.home-chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

@media (max-width: 576px) {

    .home-chart-card {
        padding: 12px;
    }

    .home-chart-container {
        height: 220px;
    }

    .home-chart-card .d-flex {
        align-items: flex-start !important;
        flex-direction: column;
        gap: 4px;
    }

}

/* --------------------------------------------------------------------------
   Webcam - placeholder
   -------------------------------------------------------------------------- */

.webcam-placeholder {
    min-height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;

    padding: 50px 30px;

    border: 2px dashed rgba(13, 110, 253, .25);
    border-radius: 18px;

    background:
        linear-gradient(
            135deg,
            rgba(13, 110, 253, .04),
            rgba(255, 255, 255, .95)
        );

    box-shadow: 0 8px 30px rgba(0, 0, 0, .06);
}

.webcam-placeholder-icon {
    width: 100px;
    height: 100px;

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

    margin-bottom: 25px;

    border-radius: 50%;

    background: rgba(13, 110, 253, .1);

    color: #0d6efd;

    font-size: 48px;
}

.webcam-placeholder h2 {
    font-weight: 600;
    margin-bottom: 15px;
}

.webcam-placeholder p {
    max-width: 600px;
    margin-bottom: 12px;
    color: #6c757d;
}

@media (max-width: 576px) {

    .webcam-placeholder {
        min-height: 400px;
        padding: 35px 20px;
    }

    .webcam-placeholder-icon {
        width: 80px;
        height: 80px;
        font-size: 38px;
    }

    .webcam-placeholder h2 {
        font-size: 1.6rem;
    }

}

/* --------------------------------------------------------------------------
   Webcam - placeholder
   -------------------------------------------------------------------------- */

.webcam-placeholder {
    min-height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 50px 30px;
    border: 2px dashed rgba(13, 110, 253, .25);
    border-radius: 18px;
    background: linear-gradient(
        135deg,
        rgba(13, 110, 253, .04),
        rgba(255, 255, 255, .95)
    );
    box-shadow: 0 8px 30px rgba(0, 0, 0, .06);
}

.webcam-placeholder-icon {
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    border-radius: 50%;
    background: rgba(13, 110, 253, .1);
    color: #0d6efd;
    font-size: 48px;
}

.webcam-placeholder h2 {
    font-weight: 600;
    margin-bottom: 15px;
}

.webcam-placeholder p {
    max-width: 600px;
    margin-bottom: 12px;
    color: #6c757d;
}

@media (max-width: 576px) {

    .webcam-placeholder {
        min-height: 400px;
        padding: 35px 20px;
    }

    .webcam-placeholder-icon {
        width: 80px;
        height: 80px;
        font-size: 38px;
    }

    .webcam-placeholder h2 {
        font-size: 1.6rem;
    }

}
