@charset "utf-8";

/* ---------------- Variables ---------------- */
:root {
  --primary: #FF6B6B;
  --secondary: #FFD93D;
  --accent: #4D96FF;
  --bg: #F0F2F5;
  --card-bg: #FFFFFF;
  --text-main: #2D3436;
  --text-sub: #636E72;
  --border-radius: 24px;
  --btn-radius: 16px;
  --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --font-family: 'Pretendard Variable', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
}

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

html {overflow-y: scroll;}

body {
  font-family: var(--font-family);
  background: var(--bg);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; }

.cover-container {
  width: 100%;
  max-width: 480px;
  background: var(--card-bg);
  min-height: 100vh;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  position: relative;
  /*padding-bottom: 80px;*/
  /* Mobile Ad Space */
}

/* ---------------- Ads ---------------- */


/* Ads */
.ad-pc-side {
  position: fixed;
  top: 100px;
  width: 160px;
  height: 600px;
  background: #f8f9fa;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #adb5bd;
  font-size: 0.8rem;
  border-radius: 8px;
  display: none;
  /* Mobile default */
}

.ad-pc-left {
  left: calc(50% - 240px - 180px);
}

.ad-pc-right {
  right: calc(50% - 240px - 180px);
}

.ad-mobile-bottom {
  /*
  position: fixed;
  bottom: 0;
  left: 0;
  */
  width: 100%;
  min-width: 360px;
  height: auto;
  /*height: 70px;*/
  /*background: #e0e0e0;*/
  margin-top: 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* PC Layout adjustments */
@media (min-width: 576px) { /*481px*/
  .ad-pc-side {
    display: flex;
  }

  .ad-mobile-bottom {
    /*display: none; */
	/*visibility: hidden;*/
  }

  .cover-container {
    min-height: auto;
    margin: 2rem auto;
    border-radius: var(--border-radius);
    overflow: hidden;
    height: auto;
    min-height: 800px;
    padding-bottom: 0;
  }

  body {
    align-items: flex-start;
    padding-bottom: 2rem;
  }

  /* Show PC ads, Hide Mobile ad */
  .ad-pc-side {
    display: flex;
  }

  .ad-mobile-bottom {
    /*display: none;*/
	/*visibility: hidden;*/
  }
}

/* Very narrow screen handling for PC ads */
@media (min-width: 576px) and (max-width: 860px) { /*481px*/
  .ad-pc-side {
    display: none;
  }

  /* Hide side ads if no room */
}

/* ---------------- Header ---------------- */
.masthead {
  padding: 1.2rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #efefef;
  margin-bottom: 1rem;
}

.masthead-brand {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-emoji {
  font-size: 1.8rem;
  animation: wave 2s infinite;
  display: inline-block;
}

/* Header Navigation */
.masthead-nav {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-btn {
  background: transparent;
  color: var(--text-sub);
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
  padding: 0.5rem 0.8rem;
  border-radius: 12px;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.nav-btn:hover {
  background: #F1F3F5;
  color: var(--primary);
}

.nav-btn.active {
  color: var(--primary);
  background: #FFF5F5;
}

.side-menu {
  position: fixed;
  top: 0;
  right: -280px;
  /* Hidden */
  width: 280px;
  height: 100vh;
  background: white;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  z-index: 1500;
  transition: right 0.3s ease;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  text-align: left;
}

.side-menu.open {
  right: 0;
}

.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1400;
  display: none;
}

.menu-overlay.open {
  display: block;
}

.menu-list {
  list-style: none;
  padding: 0;
  margin-top: 2rem;
}

.menu-list li {
  margin-bottom: 1.5rem;
}

.menu-list a {
  text-decoration: none;
  color: var(--text-main);
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.menu-close {
  align-self: flex-end;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}

@keyframes wave {

  0%,
  100% {
    transform: rotate(0deg);
  }

  25% {
    transform: rotate(-10deg);
  }

  75% {
    transform: rotate(10deg);
  }
}

/* ---------------- Main ---------------- */
.main-content {
  flex: 1;
  padding: 1rem 1.5rem;
}

/* ---------------- Form ---------------- */
.form-section {
  margin-bottom: 2rem;
}

.label-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 1rem;
  display: block;
}

/* Chip Group */
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.chip-item {
  position: relative;
}

.chip-input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.chip-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.2rem;
  background: #F1F3F5;
  color: var(--text-sub);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}

.chip-input:checked+.chip-label {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
  transform: translateY(-2px);
}

.chip-label:hover {
  background: #E9ECEF;
}

.chip-input:checked+.chip-label:hover {
  background: #FF5252;
}

/* Submit Button */
.btn-submit {
  width: 100%;
  padding: 1.1rem;
  margin-top: 1rem;
  border: none;
  border-radius: var(--btn-radius);
  background: linear-gradient(135deg, var(--primary), #FF8E53);
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 16px rgba(255, 107, 107, 0.25);
  transition: var(--transition);
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(255, 107, 107, 0.35);
}

.btn-submit:active {
  transform: scale(0.98);
}

.btn-submit:disabled {
  background: #DFE6ED;
  color: #AAB0B7;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* ---------------- Result / Grid ---------------- */
#result {
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
  min-height: 160px;
}

.result-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.result-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

.intro-card {
  background: #fff5f5;
  border: 1px solid #ffe3e3;
  border-radius: var(--btn-radius);
  padding: 1.25rem;
  margin-bottom: 2rem;
  font-size: 0.95rem;
  color: var(--text-main);
  line-height: 1.6;
  box-shadow: var(--shadow-sm);
}

.menu-card {
  background: white;
  border-radius: var(--btn-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  margin-bottom: 1rem;
  border: 1px solid #F1F3F5;
  padding: 1.5rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1.2rem;
}

.menu-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.menu-icon {
  font-size: 4.2rem;
  /* Increased size */
  line-height: 1;
  flex-shrink: 0;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
  transition: transform 0.3s;
  min-width: 80px;
  /* Ensure space */
  text-align: center;
}

.menu-card:hover .menu-icon {
  transform: scale(1.1) rotate(5deg);
}

.menu-content {
  flex: 1;
  /* Take remaining space */
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  overflow: hidden;
  /* Prevent overflow */
}

.menu-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
}

.menu-desc {
  font-size: 0.9rem;
  color: var(--text-sub);
  line-height: 1.5;
  word-break: keep-all;
}


/* Locate Specific Styles */
.search-container {
    padding-bottom: 1rem;
}

.search-box {
    display: flex;
    gap: 0.5rem;
}

.search-input {
    flex: 1;
    padding: 0.8rem;
    border: 2px solid #eee;
    border-radius: 12px;
    font-size: 1rem;
    outline: none;
}

.search-input:focus {
    border-color: var(--primary);
}

.search-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0 1.2rem;
    border-radius: 12px;
    font-weight: bold;
    cursor: pointer;
}

#map {
    width: 100%;
    height: 350px;
    border-radius: 16px;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

#placesList {
    list-style: none;
    padding: 0;
    margin: 0;
}

.place-item {
    padding: 1rem 0;
    border-bottom: 1px solid #f1f1f1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.place-info strong {
    display: block;
    font-size: 1.05rem;
    margin-bottom: 0.2rem;
    color: var(--text-main);
}

.place-info span {
    font-size: 0.85rem;
    color: var(--text-sub);
}

.place-link {
    background:white;
    border:1px solid #dee2e6;
    color:#495057;
    padding:0.5rem 1rem;
    border-radius:12px;
    font-size:0.9rem;
    font-weight:600;
    transition:all 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    white-space:nowrap;
    text-decoration: none;
}

.place-cate {
    font-size: 0.75rem !important;
    background: #FFF0F6;
    color: #FF6B6B !important;
    padding: 2px 6px;
    border-radius: 4px;

    display: inline-block;
    max-width: 100px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


/* ---------------- Footer ---------------- */
.mastfoot {
  text-align: center;
  padding: 1.2rem 0;
  color: #ADB5BD;
  font-size: 0.8rem;
  margin-top: auto;
  border-top: 1px solid #efefef;
  /*margin-top: 1rem;*/
  background-color: #fdfdfd;
}

.mastfoot a {
  color: #ADB5BD;
  text-decoration: none;
}

/* ---------------- Loading ---------------- */
.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 0;
  gap: 1rem;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #F1F3F5;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.loading-text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dots span {
  display: inline-block;
  width: 5px;
  height: 5px;
  background-color: var(--primary);
  border-radius: 50%;
  margin-left: 2px;
  animation: blink 1.4s infinite both;
}

.dots span:nth-child(1) {
  animation-delay: 0s;
}

.dots span:nth-child(2) {
  animation-delay: .2s;
}

.dots span:nth-child(3) {
  animation-delay: .4s;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes blink {

  0%,
  80%,
  100% {
    opacity: .2;
  }

  40% {
    opacity: 1;
  }
}

/* Guide Location */
.section {
    margin-bottom: 2.5rem;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.step-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.step-item {
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
    color: var(--text-sub);
    display: flex;
    gap: 0.5rem;
}

.step-num {
    color: var(--primary);
    font-weight: bold;
    min-width: 1.2rem;
}

.highlight {
    background: #FFF0F6;
    color: var(--primary);
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    font-weight: 600;
}