body {
  padding: 0;
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, sans-serif;
  background: linear-gradient(135deg, #7498fc, #e0ecff);
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  padding: 40vh 20px 0px;
  transition: transform 0.6s ease, margin 0.6s ease, padding 0.6s ease;
}

/* Search bar large initially */
.search-bar {
  position: relative;
  max-width: 600px;
  width: 100%;
}

@media (min-width: 600px) {
  .search-bar {
    transition: transform 0.6s ease, margin 0.6s ease;
    transform: scale(1.2);
  }

  #search-header {
    transition: opacity 0.6s ease,
      transform 0.6s ease,
      margin 0.6s ease;
    position: absolute;
    width: 100%;
    bottom: 100%;
    opacity: 1;
  }

  body.search-active #search-header {
    transform: translateY(-100%);
    opacity: 0;
  }
}

#search-block {
  max-height: 70vh;
  overflow-y: scroll;
  position: absolute;
  width: 100%;
  z-index: -1;
}

/* After search: slide up & shrink */
body.search-active {
  padding: 20px;
}

body.search-active .search-bar {
  margin-bottom: 20px;
}

/* Hidden results until active */
.results-container .visually-hidden {
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  max-width: 900px;
  width: 100%;
}

.results-container {
  transform: translateY(0);
}

.cloud-layer {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin: 8px 0;
}

.cloud-text {
  font-weight: bold;
  padding-bottom: 2px;
}

.cloud-underline {
  display: block;
  width: 100%;
  height: 6px;
  background: #bbb;
  border-radius: 3px;
  margin-top: 2px;
  margin-bottom: 2px;
}

.cloud-ceiling .cloud-underline {
  background: #222;
}

.clouds-right {
  position: absolute;
  right: 0;
  top: 0;
  width: 220px;
  min-height: 120px;
  padding: 16px 12px 16px 16px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 0 0 0 16px;
  box-shadow: -2px 2px 12px rgba(0, 0, 0, 0.07);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin: 0;
}

.card {
  min-width: 70vw;
}

.card-body .row {
  display: flex;
  gap: 16px;
}

.card-body .col-12 {
  flex: 1 1 0;
  min-width: 0;
}

@media (max-width: 700px) {
  .card-body .row {
    flex-direction: column;
    gap: 0;
  }
}

.list-group-item {
  border: none;
  border-bottom: 1px solid #eee;
}

.list-group-item:last-child {
  border-bottom: none;
}

.input-group-text {
  background-color: #f8f9fa;
}

.settings-btn {
  position: relative;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;

  /* Square hitbox */
  width: 2.5rem;
  /* adjust as needed */
  height: 2.5rem;

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

.settings-btn i {
  position: absolute;
  transition: opacity 0.25s ease;
}

.icon-outline {
  opacity: 1;
}

.icon-fill {
  opacity: 0;
}

/* Hover fade */
.settings-btn:hover .icon-outline {
  opacity: 0;
}

.settings-btn:hover .icon-fill {
  opacity: 1;
}

/* Click toggle fade */
.settings-btn.active .icon-outline {
  opacity: 0;
}

.settings-btn.active .icon-fill {
  opacity: 1;
}

/* Spin animation */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* Apply spin when modal open (button active) */
.settings-btn.active i {
  animation: spin 2s linear infinite;
}
