/* My Style */
body {
  font-family: 'Open Sans', sans-serif;
  background-color: #f0f0f0;
  color: #424767;
}
canvas#rippleCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 10;
  mix-blend-mode: difference;
}


#navBar, dark-bg{
  background-color: #0d1b48;
}

.section-header {
  background-color: #0d1b48;
  color: #f0f0f0;
  border-bottom-left-radius: 100% 20%;
  border-bottom-right-radius: 100% 20%;
  border-bottom: 9px solid #7DF9FF;
}

/* DL Section header*/
.section-header-dl {
  padding-top:5%;
  height: 95vh;
  background-color: #f0f0f0;
  color: #0d1b48;
  border-bottom-left-radius: 100% 20%;
  border-bottom-right-radius: 100% 20%;
  border-bottom: 9px solid #7DF9FF;
}
#logo.dlLogo{
  margin-bottom: 0.5rem!important;
}

#title {
  font-family: 'Kanit', sans-serif !important;
}

.ticInfo {
  font-size: 1.2em;
}

.stationIcon {
  height: 1.3em;
  margin-bottom: 10px;

}

#mapSection {
  position: relative;
  z-index: 10000;
}

#mapBtn {
  background: linear-gradient(135deg, #0B62AC 20%, #00c7e6 50%, #0B62AC 80%);
  background-size: 300% 300%;
  background-position: 0% 50%;
  border: none;
  color: #fdfdfd;
  margin-bottom: 1em;
  padding: 0.75em 2em;
  font-family: 'Kanit', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 0.6em;
  margin-top: 1.5em;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.8);
  transition: background-position 0.8s ease, transform 0.3s ease, box-shadow 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

#mapBtn:hover, #mapBtn:focus, #mapBtn:active  {
  background-position: 100% 50%;
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

#mapRow{
  position: relative;
}
#map {
  height: 80vh;
  border: 2px #f0f0f0 solid;
  border-radius: 10px;
}

.card{
  margin-top: 3% !important;
}
.card-img-top{
  padding: 1em;
}
#nameDiv {
  margin-top: 1rem;
}
.title{
  text-align: center;
  display:block;
  width:80%;
  margin:0 auto;
}

/* FT / M Button Styling */
.tide-toggle {
  color: #0b62ac;
  border: 2px solid #0b62ac;
  background-color: #fff;
  font-weight: 600;
  padding: 0.375rem 1rem;
  transition: all 0.2s ease-in-out;
  border-radius: 5px;
}

.tide-toggle:hover {
  background-color: #0b62ac;
  color: #fff;
}

input:checked + .tide-toggle {
  background-color: #0d1b48;
  color: #fff;
  border-color: #0d1b48;
}


/*Download Button*/
.ical-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: transparent;
  color: #0B62AC;
  border: 2px solid #0B62AC;
  border-radius: 10px;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: 'Kanit', sans-serif;
  box-shadow: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.ical-btn:hover {
  background-color: #0B62AC;
  color: white;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.ical-btn:active {
  transform: scale(0.97);
}

.ical-text {
  display: inline-block;
}

/* Warning for Download */
.install-warning {
  background: #fff7ed;
  border: 2px solid #fdba74;
  padding: 1rem;
  border-radius: 10px;
  text-align: center;
}

.install-warning img {
  max-height: 550px;
  object-fit: contain;
}
/* Tide Toggle Button Styling */
.tide-toggle {
  color: #0b62ac;
  border: 2px solid #0b62ac;
  background-color: #fff;
  font-weight: 600;
  padding: 0.375rem 1rem;
  transition: all 0.2s ease-in-out;
  border-radius: 5px;
  cursor: pointer;
}

.tide-toggle:hover {
  background-color: #0b62ac;
  color: #fff;
}

input:checked + .tide-toggle {
  background-color: #0d1b48;
  color: #fff;
  border-color: #0d1b48;
}

/* Carousel Button Match */
.carousel-btn {
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.25rem 0.75rem;
  min-width: 2.5rem;
  text-align: center;
  border-radius: 5px;
}

/* Optional Counter Styling */
.carousel-counter {
  font-size: 1rem;
  color: #0d1b48;
  font-weight: 600;
}


/* MAP: Leaflet popup wrapper */
.leaflet-popup-content {
  margin: 0;
  padding: 0;
  width: min(84vw, 235px); /* responsive width */
  font-family: 'Inter', sans-serif;
  color: #151b48;
}

/* Card container */
.leaflet-popup-content .card {
  border: none;
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  padding: 0.9rem;
  background-color: #ffffff;
}

/* Soft label like "Tide Station:" */
.leaflet-popup-content .card-label {
  font-size: 0.85rem;
  color: #888;
  margin-top:0;
  margin-bottom: 0.25rem;
}

/* Station title (e.g., "Port Renfrew") */
.leaflet-popup-content h2 {
  font-weight: 800;
  margin: 0 0 0.4rem 0;
  font-size: 1.4rem;
}

/* Supporting description text */
.leaflet-popup-content h6 {
  font-size: 0.85rem;
  font-weight: 400;
  line-height: 1.4;
  margin: 0 0 0.4rem 0;
  color: #333;
}

/* Location type text (e.g., "CANADA Tide Station") */
.leaflet-popup-content .card-text:last-of-type {
  font-size: 0.8rem;
  color: #666;
  margin-bottom: 0.8rem;
}

/* Download Button */
.leaflet-popup-content .btn {
  display: inline-block;
  background: linear-gradient(135deg, #0B62AC 20%, #00c7e6 50%, #0B62AC 80%);
  background-size: 300% 300%;
  background-position: 0% 50%;
  color: #fdfdfd;
  border: none;
  padding: 0.55rem 1rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1.05rem;
  font-family: 'Kanit', sans-serif;
  text-decoration: none;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.8);
  transition: background-position 0.8s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

/* Hover effect */
.leaflet-popup-content .btn:hover {
  transform: translateY(-3px);
  background-position: 100% 50%;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Optional calendar icon inside the button */
.leaflet-popup-content .btn img {
  height: 1em;
  vertical-align: middle;
  margin-right: 6px;
  margin-bottom: 5px; /* aligns better with text */
}

/* === Leaflet Geocoder Overrides === */

/* kill default bar look */
.leaflet-control-geocoder.leaflet-bar {
  border: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}

/* position */
.leaflet-control-container .leaflet-top .leaflet-control-geocoder {
  margin: 10px !important;
  z-index: 600;
}

/* pill */
.leaflet-control-geocoder .leaflet-control-geocoder-form {
  width: 220px;                 /* smaller by default */
  transition: width 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  display: flex; align-items: center; gap: 8px;
  min-height: 42px !important;
  background: linear-gradient(135deg, #0B62AC 20%, #00c7e6 80%);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  padding: 4px 14px 4px 42px;      /* room for icon */
  box-shadow: 0 10px 24px rgba(0,0,0,0.35);
}

/* === ON FOCUS / ACTIVE === */
.leaflet-control-geocoder .leaflet-control-geocoder-form:focus-within {
  width: 280px;                 /* grows when active */
  box-shadow: 0 0 12px rgba(0,199,230,0.6); /* glow effect */
}

/* draw the magnifier INSIDE the pill */
.leaflet-control-geocoder .leaflet-control-geocoder-form::before {
  content: "";
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; opacity: .9; pointer-events: none;
  background: no-repeat center/contain
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
}

/* hide the plugin’s toggle button so it can't drift */
.leaflet-control-geocoder .leaflet-control-geocoder-icon {
  display: none !important;
}

/* Form Input */
.leaflet-control-geocoder-form input {
  border: 0 !important; outline: none !important;
  background: transparent !important;
  color: #eaf2ff !important; font-weight: 600; font-size: 16px;
  width: 260px;
  -webkit-appearance: none;        /* iOS: keep styling consistent */
  caret-color: #eaf2ff;            /* visible caret on dark bg */
}
.leaflet-control-geocoder-form input::placeholder {
  color: rgba(234,242,255,0.7) !important;
}

/* clear (X) — force-render on iOS & make tappable */
.leaflet-control-geocoder .leaflet-control-geocoder-clear {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 30px;               /* bigger hit area */
  height: 30px;
  min-width: 30px;
  min-height: 30px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.10);
  color: #fff;
  cursor: pointer;
  z-index: 1000;
  -webkit-tap-highlight-color: transparent;
}

/* draw the X explicitly so Safari can’t drop it */
.leaflet-control-geocoder .leaflet-control-geocoder-clear::before {
  content: '✕';
  font-size: 18px;
  line-height: 1;
  display: block;
  transform: translateY(-1px);
}

/* hide when empty (the plugin toggles this class) */
.leaflet-control-geocoder .leaflet-control-geocoder-clear.leaflet-control-geocoder-clear-disabled {
  display: none !important;
}

/* results panel */
.leaflet-control-geocoder-alternatives {
  margin-top: 8px !important;
  background: rgba(21,27,72,0.97) !important;
  border: 1px solid rgba(255,255,255,0.18) !important;
  border-radius: 14px !important; overflow: hidden !important;
  box-shadow: 0 14px 30px rgba(0,0,0,0.4) !important;
  color: #fff
}
.leaflet-control-geocoder-alternatives li {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;   /* left-align everything */
  min-height: 52px;          /* same height for each */
  line-height: 1.3;
  padding: 8px 14px !important;
}
.leaflet-control-geocoder-alternatives li:last-child { border-bottom: 0 !important; }
.leaflet-control-geocoder-alternatives li:hover,
.leaflet-control-geocoder-selected {
  background: rgba(0,199,230,0.18) !important;
color: white;
}


/* city / region text */
.leaflet-control-geocoder-alternatives li strong,
.leaflet-control-geocoder-alternatives li b,
.leaflet-control-geocoder-alternatives li .leaflet-control-geocoder-address,
.leaflet-control-geocoder-alternatives li .leaflet-control-geocoder-name {
  font-size: 15px;
  font-weight: 600;
  color: #fff !important;
  margin: 0;
  padding: 0;
}
/* second line (region/context) */
.leaflet-control-geocoder-alternatives li small,
.leaflet-control-geocoder-address-context,
.leaflet-control-geocoder-address-detail {
  font-size: 13px;
  color: rgba(234,242,255,0.76) !important;
  margin: 2px 0 0 0;
  padding: 0;
}
/* Make the primary line (city/place) bright */
.leaflet-control-geocoder-alternatives a,
.leaflet-control-geocoder-alternatives a:link,
.leaflet-control-geocoder-alternatives a:visited {
  color: #fff !important;
  text-decoration: none !important;
  opacity: 1 !important;
}

/* Some builds wrap the name in these spans—cover them all */
.leaflet-control-geocoder-alternatives a .leaflet-control-geocoder-address,
.leaflet-control-geocoder-alternatives a .leaflet-control-geocoder-name,
.leaflet-control-geocoder-alternatives b,
.leaflet-control-geocoder-alternatives strong {
  color: #fff !important;
  opacity: 1 !important;
}

/* Keep it white even when the row is hovered/selected */
.leaflet-control-geocoder-alternatives li:hover a,
.leaflet-control-geocoder-alternatives .leaflet-control-geocoder-selected a {
  color: #fff !important;
}

/* 1) Remove the centered group separators so only real results show */
.leaflet-control-geocoder-separator {
  display: none !important;
}

/* 2) Make every result line left-aligned and block-level */
.leaflet-control-geocoder-alternatives a,
.leaflet-control-geocoder-alternatives li,
.leaflet-control-geocoder-alternatives li * {
  text-align: left !important;
}

/* 3) Keep rows tidy on one line with ellipsis (optional) */
.leaflet-control-geocoder-alternatives li strong,
.leaflet-control-geocoder-alternatives li b,
.leaflet-control-geocoder-alternatives li .leaflet-control-geocoder-address,
.leaflet-control-geocoder-alternatives li .leaflet-control-geocoder-name,
.leaflet-control-geocoder-alternatives li small,
.leaflet-control-geocoder-address-context,
.leaflet-control-geocoder-address-detail {
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}




/* mobile */
@media (max-width: 640px) {
  .leaflet-control-geocoder-form input { width: 58vw !important; }
}





.footer {
  font-size: 0.85rem;
  color: #888;
  text-align: center;
}

.wave-trio {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: none;
  bottom: -25px;
}

.wave-trio svg {
  width: 100%;
  height: 100%;
  display: block;
}

@keyframes pulseGradient {
  0%, 100% {
    stop-color: rgba(21, 27, 72, 1);
  }
  50% {
    stop-color: #0B62AC;
  }
}

@keyframes pulseLight {
  0%, 100% {
    stop-color: #00e0ff;
  }
  50% {
    stop-color: #f0f0f0;
  }
}

#stop1a, #stop2a, #stop3a {
  animation: pulseGradient 10s ease-in-out infinite;
}

#stop1b, #stop2b, #stop3b {
  animation: pulseLight 10s ease-in-out infinite;
}

/** FOOTER **/

#footer {
  background-color: #0d1b48;
  color: white;
  font-weight: bold;
}

/* Responsive fix for map on small screens */
@media (max-width: 8208px) {
  #map {
    height: 70vh; /* reduce height for mobile */
  }

  .section-header-dl {
    height: auto; /* let content expand naturally */
    padding-bottom: 2rem; /* add breathing room */
  }

  #contact { padding-top: 1rem;}
  #foot {margin-top: 1rem!important;}
}



