/* ------------------------------
   Base / scroll / background
------------------------------ */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  width: 100%;
  min-height: 100%;
  height: auto;
  overflow-x: hidden;
  overflow-y: auto;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  background: transparent;
}

body {
  width: 100%;
  min-width: 0;
  min-height: 100vh;
  height: auto;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-x: none;
  overscroll-behavior-y: auto;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  background: transparent;
  position: relative;
  z-index: 0;
  font-family: "Open Sans", Arial, sans-serif;
}

/* ------------------------------
   Reduced motion
------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms;
    animation-iteration-count: 1;
    transition-duration: 0.001ms;
  }
}

/* =========================================================
   HikinPedia Greece - extraCSS5 clean
   Ενιαίο CSS χωρίς override layers.
   Κρατάει τα υπάρχοντα IDs/classes/JS hooks.
   ========================================================= */

/* ------------------------------
   Design tokens
------------------------------ */
:root {
  --hp-green: #015c4b;
  --hp-green-2: #0d7660;
  --hp-blue: #006fa8;
  --hp-text: #18332d;
  --hp-muted: rgba(24, 51, 45, 0.62);
  --hp-panel: rgba(255, 255, 255, 0.95);
  --hp-panel-strong: rgba(255, 255, 255, 0.98);
  --hp-line: rgba(1, 92, 75, 0.12);
  --hp-soft: rgba(1, 92, 75, 0.08);
  --hp-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
  --hp-shadow-soft: 0 4px 14px rgba(0, 0, 0, 0.14);
  --hp-shadow-strong: 0 14px 34px rgba(0, 0, 0, 0.22);
  --hp-radius: 14px;
  --hp-radius-pill: 999px;
}


.fixed-bg {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  min-height: 100vh;
  pointer-events: none;
  background-image: url("IMG_20200823_095102_12.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  transform: translateZ(0);
  backface-visibility: hidden;
  contain: paint;
  min-height: 100dvh;
  z-index: -10;
  pointer-events: none;

  
}



h1 {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    font-size: 25px;
    color: white;
    text-align: center;
    font-family: Georgia, "Times New Roman", serif;
    text-shadow: 1px 1px 0 #000;
}


#blink-btn{
    background:#015c4b;
    border-radius:50%;
    padding:10px;
    border:none;
    cursor:pointer;
    color:white;
    width:40px;
    height:40px;
    display:flex;
    align-items:center;
    justify-content:center;
}

@media (max-width:768px){

    .fixed-bg {
         background-image: url("IMG_20200823_095102_1-min.jpg");
    height: 100svh;
    min-height: 100dvh;
    }



}



.fixed-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.08),
    rgba(0, 0, 0, 0.03) 42%,
    rgba(0, 0, 0, 0.12)
  );
}



button,
a {
  -webkit-tap-highlight-color: rgba(1, 92, 75, 0.18);
}

button {
  cursor: pointer;
}

.mobile-break {
  display: none;
}



/* ------------------------------
   Shared inputs
------------------------------ */

input[type="text"],
#searchInput,
#address,
.quicksearch-input {
  width: 300px;
  max-width: 93vw;
  min-width: 0;
  padding: 10px 42px 10px 14px;
  border-radius: var(--hp-radius-pill);
  border: 1px solid rgba(1, 92, 75, 0.14);
  outline: none;
  background: rgba(255, 255, 255, 0.95);
  color: var(--hp-text);
  caret-color: var(--hp-green);
  box-shadow: var(--hp-shadow-soft);
  font: 11.5px Arial, sans-serif;
  box-sizing: border-box;
  margin-bottom: 6px;
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    background-color 0.22s ease;
}

.input-with-button input {
  width: 100%;
  text-align: left;
}

input[type="text"]::placeholder,
#searchInput::placeholder,
#address::placeholder,
.quicksearch-input::placeholder {
  color: var(--hp-muted);
}

input[type="text"]:focus,
#searchInput:focus,
#address:focus,
.quicksearch-input:focus {
  border-color: rgba(1, 92, 75, 0.42);
  background: #fff;
  box-shadow:
    0 0 0 3px rgba(1, 92, 75, 0.10),
    0 8px 20px rgba(0, 0, 0, 0.12);
}


/* ------------------------------
   Search selector
------------------------------ */
#searchSelector {
  gap: 6px;
  height: 55px;
  max-width: 300px;
  background: rgba(255, 250, 240, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
  color: #014d42;
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  border-radius: 50px;
  padding: 10px 2ch;
  font-family: 'Segoe UI', 'Georgia', serif;
  width: 100%;
  margin: 10px auto;
  font-size: 16px;
  box-sizing: border-box;
}



@media (max-width:768px){

    #schedule-form-container {
        width:65vw;
        max-width:65vw;
        padding:12px;
    }

}


#schedule-form label {
    display:block;
    margin-bottom:8px;
    font-size:14px;
    color:#555;
}


.container {
  max-width: 400px;      /* keeps it narrow */
  margin: 0px auto;     /* centers horizontally */
  text-align: center;
  font-family: 'Open Sans', sans-serif;
  color: white;
  box-sizing: border-box;
  
}


.container .quicksearch-container,
.container .input-with-button,
.container #address,
.container #searchInput {
  margin-left: auto;
  margin-right: auto;
}

.input-with-button {
    position: relative;
    width: 300px;
}

#address {
    width: 93%;
    padding-right: 0px; /* αφήνει χώρο για το κουμπί */
    box-sizing: border-box;
}

#searchBtn2 {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    width: 32px;
    height: 32px;
    padding: 0;
    z-index: 10;
}



@media (max-width: 768px) {
#searchSelector {
  max-width: 250px;
      padding: 8px 10px;
    font-size: 14px;
}

}

#searchSelector button,
#searchSelector a {
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    filter 0.2s ease,
    background-color 0.2s ease;
}

#searchSelector button,
#searchSelector a[aria-label="View map"] {
  box-shadow: 0 4px 12px rgba(1, 92, 75, 0.22);
}


/* ------------------------------
   Search results / smooth internal scroll
------------------------------ */
#searchResults {
  width: min(300px, 93vw);
  max-width: 300px;
  margin: 0 auto;
  padding: 0;
  overflow-x: hidden;
  overflow-y: visible;
  background: transparent;
}

#searchResults p {
  text-align: left;
}

#resultsList,
#results {
  width: min(400px, 93vw) !important;
  max-width: 400px;
  max-height: 260px;
  margin: 10px auto 0;
  padding: 2px 6px 4px;
  color: #000;
  font-size: 16px;
  list-style-position: inside;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
  scrollbar-gutter: stable both-edges;
  scroll-behavior: smooth;
  background: transparent;
  border-radius: var(--hp-radius);
    

}

#resultsList li,
#results li {
  display: list-item;
  color: #000;
  text-align: center;
  padding: 9px 10px;
  margin-bottom: 8px;
  border: 1px solid var(--hp-line);
  border-radius: 12px;
  background: var(--hp-panel);
  box-shadow: 0 5px 16px rgba(0, 0, 0, 0.10);
  line-height: 1.35;
  overflow-wrap: anywhere;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    background-color 0.22s ease;
}


#searchResults .result {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-panel);
  box-shadow: 0 5px 16px rgba(0, 0, 0, 0.10);
  overflow-wrap: anywhere;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

.searchResultLink {
  color: var(--hp-blue);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.searchResultLink:hover {
  color: var(--hp-green);
  opacity: 0.92;
}

#resultsList:empty,
#results:empty,
#quicksearchResults:empty,
.quicksearch-results:empty {
  display: none;
  margin: 0;
  padding: 0;
  border: 0;
  max-height: 0;
  min-height: 0;
  height: 0;
  overflow: hidden;
}

/* Smooth, discreet scrollbars */
#resultsList,
#results,
#quicksearchResults,
.quicksearch-results,
#popular-list,
#contributorsBox,
#haveGoneBox,
#favoritesBox {
  scrollbar-width: thin;
  scrollbar-color: rgba(1, 92, 75, 0.35) rgba(1, 92, 75, 0.06);
}

#resultsList::-webkit-scrollbar,
#results::-webkit-scrollbar,
#quicksearchResults::-webkit-scrollbar,
.quicksearch-results::-webkit-scrollbar,
#popular-list::-webkit-scrollbar,
#contributorsBox::-webkit-scrollbar,
#haveGoneBox::-webkit-scrollbar,
#favoritesBox::-webkit-scrollbar {
  width: 7px;
}

#resultsList::-webkit-scrollbar-track,
#results::-webkit-scrollbar-track,
#quicksearchResults::-webkit-scrollbar-track,
.quicksearch-results::-webkit-scrollbar-track,
#popular-list::-webkit-scrollbar-track,
#contributorsBox::-webkit-scrollbar-track,
#haveGoneBox::-webkit-scrollbar-track,
#favoritesBox::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.18);
  border-radius: var(--hp-radius-pill);
}

#resultsList::-webkit-scrollbar-thumb,
#results::-webkit-scrollbar-thumb,
#quicksearchResults::-webkit-scrollbar-thumb,
.quicksearch-results::-webkit-scrollbar-thumb,
#popular-list::-webkit-scrollbar-thumb,
#contributorsBox::-webkit-scrollbar-thumb,
#haveGoneBox::-webkit-scrollbar-thumb,
#favoritesBox::-webkit-scrollbar-thumb {
  background: rgba(1, 92, 75, 0.32);
  border-radius: var(--hp-radius-pill);
}


#schedule-form-container {

    display:none;
    position:fixed;
    top:58%;
    left:50%;
    transform:translate(-50%,-50%);
    background:rgb(143, 192, 129);
    width:420px;
    padding: 20px;
    border-radius:18px;
    box-shadow:0 15px 40px rgba(0,0,0,0.25);
    z-index:9999;
}


#schedule-form input {
    width:100%;
    padding:12px;
    margin-bottom:12px;
    border-radius:10px;
    border:1px solid #ebe7e7;
    font-size:16px;
}

#schedule-form {
   background:rgb(230, 235, 229);
    padding: 5px;
}


#schedule-form button {
    width:100%;
    padding:13px;
    background:#2d6a4f;
    color:white;
    border:none;
    border-radius:12px;
    font-size:17px;
    cursor:pointer;
}


#schedule-form button:hover {
    opacity:0.85;
}


#schedule-response {
    margin-top:15px;
    font-weight:bold;
}


#next-events {
    display:flex;
    gap:12px;

    flex-direction:row;
    flex-wrap:nowrap;

    justify-content:flex-start;

    width:60%;
    margin:20px auto 0;

    overflow-x:auto;
    overflow-y:hidden;

    padding:10px;

    border-radius:20px;
}

/* Κάθε μικρό κουτάκι */

.event-card {
    width:160px;
    background:white;
    padding:6px;
    padding-bottom:8px;
    border-radius:12px;
    box-shadow:0 4px 15px rgba(0,0,0,0.12);
    font-size:12px;
    height:auto;
    min-height:0;
    align-self:flex-start;
}


.event-card h3 {
    font-size:12px;
    margin:0 0 8px 0;
}



.event-card p {
    margin:5px 0;
}



.event-card a {
    display:inline-block;
    margin-top:8px;
    padding:4px 8px;
    background:#329aba;
    color:white;
    border-radius:8px;
    text-decoration:none;
    font-size:12px;
    line-height:1;
}


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


@media(max-width:768px){


#next-events{

    position: fixed;
    bottom: 30px;

    left: 55%;
    transform: translateX(-50%);

    width: 68%;
    max-width: 100vw;

    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;

    overflow-x: auto;
    overflow-y: hidden;

    gap: 10px;

    padding-left: 1px;
    padding-right: 1px;

    justify-content: flex-start !important;

    -webkit-overflow-scrolling: touch;
}


.event-card{
    flex:0 0 150px;
    width:130px;
    min-width:130px;

    height:auto;
    min-height:0;

    padding:5px;
    padding-bottom:7px;

    border-radius:12px;
    align-self:flex-start;
}



.event-card h3{
    font-size:12px;
}

.event-card,
.event-card h3,
.event-card p,
.event-card a{
    white-space:normal;
    overflow-wrap:break-word;
    word-break:break-word;
}



#locationOutput {
    position: fixed;
    top: 88%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 11px;

}

}



.event-label {
    display:inline-block;
    background:#08a10d;
    color:white;
    padding:3px 8px;
    border-radius:20px;
    font-size:10px;
    margin-bottom:6px;
}


@media (hover: hover) and (pointer: fine) {
  .input-with-button button:hover {
    background: rgba(1, 92, 75, 0.08);
  }

  .input-with-button button:hover svg,
  #searchSelector button:hover svg,
  #searchSelector a:hover svg {
    transform: scale(1.08);
    opacity: 0.92;
  }

  .quicksearch-item:hover,
  #searchResults .result:hover,
  #resultsList li:hover,
  #results li:hover {
    transform: translateY(-1px);
    box-shadow: var(--hp-shadow);
  }

  #popular-list li:hover,
  #contributorsBox li:hover {
    background: var(--hp-soft);
  }


  #toggleTop10:hover,
  .fixed-left:hover,
  #openHaveGone:hover,
  #openFavorites:hover,
  #locationBtn:hover,
  #compassBtn:hover {
    transform: translateY(-50%) scale(1.02);
  }
}


#hikinpedia-link {
    color: inherit;
    text-decoration: none;
    cursor: pointer;
}


/* ------------------------------
   Search mode visibility
------------------------------ */
.searchbox,
.container,
.searchcontainer {
  display: none;
}

.searchbox.visible,
.container.visible,
.searchcontainer.visible,
.visible {
  display: block;
}


/* ------------------------------
   Quick search
------------------------------ */
.quicksearch-container {
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.12));
}

.quicksearch-wrapper {
  position: relative;
  width: 300px;
  max-width: 90%;
}

.quicksearch-input {
  width: 100%;
  height: 55px;
  padding: 12px 45px 12px 16px;
  font-size: 14px;
}

.quicksearch-input::placeholder {
  font-size: 13.5px;
}

.quicksearch-button {
  position: absolute;
  right: 2px;
  top: 50%;
  font-size: 15px;
  transform: translateY(-55%);
  border: 0;
  background: transparent;
  color: var(--hp-green);
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 20px;
  cursor: pointer;
  transition: background-color 0.22s ease, color 0.22s ease;
}

.quicksearch-results,
#quicksearchResults {
  margin-top: 10px;
  text-align: center;
  max-height: 280px;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
  scroll-behavior: smooth;
}

.quicksearch-item {
  width: 330px;
  max-width: 90%;
  padding: 15px;
  margin: 10px auto;
  border-radius: var(--hp-radius);
  border: 1px solid var(--hp-line);
  background: var(--hp-panel);
  box-shadow: 0 5px 16px rgba(0, 0, 0, 0.10);
  overflow-wrap: anywhere;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    background-color 0.22s ease;
}

.quicksearch-link {
  color: #333;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.quicksearch-link:hover {
  color: var(--hp-green);
}

.quicksearch-empty {
  width: 100%;
  color: #fff;
  font-size: 16px;
  text-align: center;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.48);
}

/* =====================================
   SMALL SCREENS - GLOBAL FONT REDUCTION
   ===================================== */

@media (max-height: 700px) and (max-width: 430px)  {

  body {
    font-size: calc(100% - 4px);
  }

  h1 {
    font-size: calc(25px - 5px);
  }

  h2 {
    font-size: calc(18px - 5px);
  }

  p,
  li,
  a,
  button,
  input,
  textarea,
  label,
  td,
  th {
    font-size: calc(1em - 2px);
  }


  input::placeholder {
  font-size: calc(1em - 1px);
}


    #sosBtn {
    bottom: 125px;
  }

    /* Κατεβάζει λίγο το schedule */
  .schedule,
  #schedule {
    margin-top: 45px;
  }

  .quicksearch-input::placeholder {
    font-size: calc(1em - 0.3px) !important;
}


    #searchSelector {
        width: 70vw;
    }


.quicksearch-container {
    width: 90vw;
    max-width: 300px;
    margin: 0px auto;
    box-sizing: border-box;
}

.quicksearch-wrapper {
    width: 100%;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}

.quicksearch-input {
    flex: 1;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.quicksearch-button {
    flex-shrink: 0;
}


  #submission-form input {
    width: 50vw;
    max-width: 300px;
    box-sizing: border-box;
  }

  #submission-form {
    text-align: center;
  }



}


#toggleEventsBtn {
  display:none;
}



@media (max-width: 430px) and (max-height: 750px) {

  #toggleEventsBtn {
   display:block;
  position:fixed;
  left: 2px;
  bottom: 153px;
  padding:6px 9px;
  border-radius:20px;
  border:none;
  font-size:14px;
    background-color: #006fa8;
  }


  #next-events {
    display:none;
  }


}

@media (min-width: 600px) {
  #compassBtn,
  #compass {
    display: none !important;
  }
}


@media (min-width: 600px) {
  #locationBtn,
  #locationOutput {
    display: none !important;
  }
}


/* Κρυφό από προεπιλογή */
#sosBtn {
  display: none;

  position: fixed;
  bottom: 128px;
  left: 4px;

  background: transparent;
  border: none;
  padding: 0;

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

  font-size: 16px;
  cursor: pointer;
}

/* Εμφάνιση μόνο σε κινητά */
@media (max-width: 768px) {
  #sosBtn {
    display: flex;
  }
}


@media (min-width: 600px) {
  #openFavorites,
  #favoritesBox {
    display: none !important;
  }
}


#haveGoneBox,
#favoritesBox {
  background: rgba(255, 255, 255, 0.98) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;

  transform: none !important;
  filter: none !important;
  opacity: 1 !important;

  will-change: auto !important;
}


#openHaveGone {
    display: none !important;
}

/* μόνο mobile */
@media (max-width: 600px) {
    #openHaveGone {
        display: block !important; /* ή flex αν θες */
    }
}


@media (max-width: 768px) {
  body {
    min-height: 100svh;
    min-height: 100dvh;
  }

  .mobile-break {
    display: inline;
  }

  button[onclick^="selectSearch"],
  a[aria-label="View map"] {
    width: 37px;
    height: 37px;
  }


  #quicksearchResults,
  .quicksearch-results {
    max-height: min(280px, 45svh);
  }

  #copyright {
    left: auto;
    right: 10px;
    transform: none;
    text-align: right;
  }
}

@media (max-width: 600px) {
  #toggleTop10 {
    top: 88.5%;
    left: 4px;
    width: 60px;
    padding: 3.5px;
    font-size: 8px;
  }

  .fixed-left {
    top: 84%;
    left: 4px;
    width: 60px;
    padding: 1px;
    font-size: 8px;
  }

  #popular-list {
    left: 0;
    width: 70%;
    top: 14%;
  }

  #contributorsBox {
    left: 0;
    width: 70%;
    top: 14%;
    border-radius: 20px 0 0 20px;
  }

  .havegone-check {
    margin-left: 8px;
    font-size: 1.2em;
  }

  #haveGoneBox,
  #favoritesBox {
    width: 70%;
    top: 35%;
    border-radius: 20px 0 0 20px;
  }

  #openHaveGone {
    top: 85%;
    right: 4px;
  }

  

  #locationBtn {
    top: 89%;
    right: 4px;
  }

  #compassBtn {
    top: 93%;
    right: 4px;
  }

  #openFavorites {
    top: 81%;
    right: 4px;
  }

  .quicksearch-input {
    min-height: 52px;
  }

  .quicksearch-item {
    width: 280px;
    max-width: 90%;
    padding: 15px;
    margin: 10px auto;
  }

  .quicksearch-link {
    font-size: 12px;
  }

  #resultsList li,
  #results li {
    margin-bottom: 6px;
  }

  .fb-float {
    left: 5px;
    bottom: 34px;
    margin: 0;
    transform: none;
    z-index: 10000;
  }
}


#compass {
  top: 80%;
  width: 80px;
  height: 80px;
  padding: 3px;
  display: flex;
  justify-content: center;
  font-size: 100px;
  transition: transform 0.1s linear;
}


