/* HLS-video ei vaikuta muuhun layoutiin */
#hls-container {
    position: relative;
    width: 100%;
    max-width: 1400px; /* voit säätää bannerin leveyden mukaan */
    margin: 1.5rem auto; /* keskitys */
}

#hls-container video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px; /* jos haluat pyöristetyt kulmat */
}

#hls-container .live-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: red;
    color: white;
    padding: 0.25rem 0.5rem;  /* rem-yksikkö skaalautuu */
    font-size: 0.7rem;
    font-weight: bold;
    border-radius: 4px;
    z-index: 2;
}

#hls-container #timestamp {
    position: absolute;
    bottom: 3px;
    right: 3px;
    padding: 0.25rem 0.5rem;
    background: rgba(0, 91, 187, 0.9);
    color: #FFD700;
    font-size: 0.7rem;
    font-weight: 400;
    border-radius: 4px;
    z-index: 2;
    text-shadow: 
        0 0 2px #FFD700,
        0 0 4px #FFD700,
        0 0 6px #FFD700,
        0 0 10px rgba(255,215,0,0.5);
}

/* Media query pienille näytöille (esim. max 600px) */
@media screen and (max-width: 600px) {
    /* LIVE ja timestamp skaalautuvat */
    #banner #hls-container .live-badge,
    #banner #hls-container #timestamp {
        font-size: 0.5rem !important;
        padding: 0.2rem 0.4rem !important;
    }

    /* Lämpötilalukema pienempi mobiilissa */
    #banner .temp-value {
        font-size: 1.3rem !important;
    }


    #hls-container {
        max-width: 100%;        /* täyttää koko näytön leveydestä */
    }

    .temp-value {
        font-size: 1.3rem;      /* pienempi lämpötilalukema mobiilissa */
    }
}

/* ====== Tekijämerkintä ====== */
/* ====== Tekijämerkintä HTML5 UP pohjassa ====== */
#banner .content p.credits {
    font-size: 8px !important;       /* pysyy aina pienenä */
    line-height: 1.2 !important;     /* tiukka riviväli */
    color: #666 !important;          /* harmaa väri */
    margin-top: 10px !important;
    margin-bottom: 0 !important;
    text-align: left !important;
    opacity: 0.65 !important;        /* himmennys kuten sidebarissa */
}


/* Otsikko */
#main-title {
    margin-top: -1px;
    margin-bottom: -4px;
    font-size: 1.8rem;
}

/* Poistaa tyhjän tilan lämpötila-sivulta */
#banner .content-header {
    margin: 0 !important;
    padding: 0 !important;
}

/* Lämpötilalukema */
.temp-value {
    font-size: 1.8rem;
    font-weight: bold;
    margin: 0 auto 0 auto;  /* ylä- ja alareuna nolla, keskitys vaakasuunnassa */
    display: block;
    text-align: center;       /* keskittää tekstin */
    text-shadow: 0px 3px 6px rgba(0, 0, 0, 0.4);
}



.chart-wrapper {
    position: relative;
    width: 100%;
    max-width: 1400px;
    height: 400px;
    margin: 22px auto;
    border-radius: 10px;
    background: #f0f8ff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    overflow: hidden;
    padding-top: 50px;
    padding-bottom: 35px;
}

/* Kaavion otsikko kaavion sisällä */
.chart-wrapper .chart-title {
    position: absolute;
    top: 20px;
    left: 20px;
    font-weight: bold;
    font-size: 1.2rem;
    color: #333;
    z-index: 10;
    margin: 0;
}

.chart-wrapper canvas {
    width: 100% !important;
    height: 100% !important;
}

.chart-wrapper h3 {
    text-align: left;
    margin-left: 26px;
    margin-top: -26px;
    font-size: 1.2rem; 
    color: #594F4E; 
    font-weight: 700;
    
  }


/* Auringonnousu / -lasku osio */
#sunTimes {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    font-size: 1rem;
    margin-top: -15px;
    margin-bottom: 0;
}

#sunTimes div {
    text-align: center;
    line-height: 1.2;
}

#sunTimes span {
    font-size: 0.95rem;
}

#sunTimes span b {
    font-weight: bold;
}

#sunTimes img {
    display: block;
    margin: 0 auto 3px;
    height: 21px;
}

/* Käännä auringonlasku-gif 180 astetta */
#sunsetDiv img {
    transform: rotate(180deg);
    display: block;
}


/* Tumma teema: h3 otsikot chart-wrapperissa */
body.dark .chart-wrapper h3 {
    color: #555555;  /* vaalea teksti tummalla taustalla */
}

/*=============================
  Tavoitellut huiput – Kortti
===============================*/
.peak-card {
  display: flex;
  gap: 1.5rem;
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 2rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  transition: 0.3s ease;
}

.peak-card:hover {
  transform: translateY(-4px);
}

/* Tuore huiputus */
.peak-card.reached {
  border-left: 6px solid #2ecc71;
  background: linear-gradient(to right, #eef8f1, #ffffff);
}

/* Kuva */
.peak-image {
  background: #f5f5f5; /* jos jää tyhjää tilaa */
}

.peak-image img {
  width: 260px;
  height: 180px;
  object-fit: cover;
  border-radius: 14px 0 0 14px; /* pyöristys vasemmalle */
  display: block;
}

/* Sisältö */
.peak-content {
  flex: 1;
  padding: 1.2rem 1.2rem 1.2rem 0;
}

/* Otsikko */
.peak-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.peak-header h3 {
  margin: 0;
}

/* Korkeusnumero */
.peak-height {
  font-size: 1.8rem;
  font-weight: 700;
  color: #888;
}

/* Meta */
.peak-meta {
  margin: 0.4rem 0 0.8rem;
  color: #666;
  font-size: 0.95rem;
}

.peak-meta span {
  margin-right: 1rem;
}

/* Korkeusmittari */
.height-bar {
  height: 8px;
  background: #e5e5e5;
  border-radius: 6px;
  overflow: hidden;
}

.height-fill {
  height: 100%;
  background: linear-gradient(90deg, #4facfe, #00c6ff);
}

/* Yritykset */
.peak-attempts {
  margin-bottom: 0.8rem;
}

.attempt {
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}

.attempt.reached {
  color: #2ecc71; /* vihreä huiputetuille */
}

.attempt.aborted {
  color: #e74c3c; /* punainen keskeytyksille */
}

/*=============================
  Responsiivisuus (Mobiili)
===============================*/
@media (max-width: 768px) {
  .peak-card {
    flex-direction: column;
  }

  .peak-image img {
    width: 100%;
    height: auto;         /* korkeus automaattinen */
    object-fit: contain;  /* koko kuva näkyviin */
    border-radius: 14px 14px 0 0; /* pyöristetty yläreuna */
  }

  .peak-content {
    padding: 1rem;
  }
}

/* =========================
   Peak Names – Always Dark
========================= */

/* Kaikkien huippujen nimet kortilla pysyvät mustina, vaikka body.dark on päällä */
.peak-card .peak-header h3 {
    color: #888 !important;
}

/* Tuoreimman vuoden huiput */
.peak-card.latest-year {
    background: linear-gradient(to right, #fff2b2, #ffffff); /* tummempi vaalea keltainen */
}

.banner-wrapper {
    display: flex;
    gap: 30px;
    align-items: stretch;
    flex-wrap: wrap;
}







.banner-top {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 20px;
}

/* Teksti saa vähemmän tilaa */
.banner-text {
    flex: 0 0 38%;
}

/* Kartta saa enemmän tilaa */
#peakMap {
    flex: 1;
    height: 610px;
    width: 100%;
    border-radius: 10px;
}
/* mobiili */
@media (max-width: 1000px) {

    .banner-top {
        flex-direction: column;
    }

    .banner-text {
        flex: 1;
    }

    #peakMap {
    flex: 1 1 400px;
    min-width: 0;
        margin-top: 10px;
    }
}



