/* TEMP: hide top main nav for presentation */
.main-nav {
  display: none !important;
}

/* Global settings */
html {
  scroll-behavior: smooth;
}

/* Show only the current language */
html[lang="ja"] [lang="en"] { display: none !important; }
html[lang="en"] [lang="ja"] { display: none !important; }

body {height: 40px;
  font-family: 'Raleway', 'Noto Sans JP', sans-serif;
  line-height: 1.6;
  margin: 0;
  padding: 0;

  /* Background image + fog */
  background-image:
    linear-gradient(rgba(255,255,255,0.62), rgba(255,255,255,0.62)),
    url('../images/bg-sagrada.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;

  color: #333;
}

/* ---------- Header ---------- */
.site-header {
  background-color: #004d40;
  color: #fff;
  padding: 0.75rem 1rem;
  position: relative;
  text-align: center;
  min-height: 64px;         /* ensures room for all three */
}

@media (min-width: 768px) {
  .site-header { min-height: 72px; }
}

/* ---------- Centered Logo ---------- */
.site-logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  line-height: 0;
  z-index: 1;
}

.site-logo a {
  display: inline-block;
}

.site-logo img {
  display: block;
  height: 44px;   /* was 40px → now 110% */
  width: auto;
}

@media (min-width: 768px) {
  .site-logo img {
    height: 53px;  /* was 48px → now 110% */
  }
}

/* --- Logo in light sections (footer, hero, etc.) --- */
.light-section .site-logo img,
.site-footer .site-logo img {
  filter: none;                          /* keep original dark logo */
  transition: filter 0.25s ease;
}
.light-section .site-logo a:hover img,
.site-footer .site-logo a:hover img {
  filter: brightness(0.4);               /* soften on hover */
}


/* ---------- Language toggle ---------- */
.lang-toggle {
  position: absolute;
  top: 50%;                            /* vertical centering */
  transform: translateY(-50%);
  left: 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  width: 112px;
  height: 34px;
  padding: 2px;
  border-radius: 9999px;
  background: #fff;
  border: 1px solid #004d40;
  box-sizing: border-box;
  z-index: 1002;
}
.lang-toggle::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: calc(50% - 4px);
  height: calc(100% - 4px);
  border-radius: 9999px;
  background: #004d40;
  transition: transform .25s ease;
  z-index: 1;
  pointer-events: none;
}
.lang-toggle.active-ja::before { transform: translateX(0); }
.lang-toggle.active-en::before { transform: translateX(calc(100% + 4px)); }

.lang-toggle .lang-opt {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  font-weight: 700;
  font-size: .9rem;
  text-decoration: none;
  user-select: none;
  color: #004d40;
}
.lang-toggle.active-ja .lang-opt[data-lang="ja"],
.lang-toggle.active-en .lang-opt[data-lang="en"] { color: #fff; }

@media (min-width: 768px) {
  .lang-toggle { top: .9rem; right: 1rem; left: auto; }
}

/* ---------- Hamburger ---------- */
.hamburger {
  font-size: 2.5rem;
  background: none;
  border: none;
  color: yellow;
  position: absolute;
  top: 50%;                 /* center vertically */
  transform: translateY(-50%);
  right: 1rem;
  cursor: pointer;
  z-index: 1001;
}

/* ---------- Side menu ---------- */
.side-nav {
  position: fixed;
  top: 0;
  right: -250px;
  width: 220px;
  height: 100%;
  background-color: #004d40;
  color: #fff;
  padding-top: 4rem;
  transition: right 0.3s ease;   /* <-- was left; must be right */
  z-index: 1000;
}
.side-nav.open { right: 0; }

.side-nav ul { list-style: none; margin: 0; padding: 0; }
.side-nav li { margin-bottom: 0.5rem; }

.submenu { display: none; padding-left: 1.5rem; }
.submenu-toggle {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.2rem;
  width: 100%;
  text-align: left;
  padding: 0.5rem 1rem;
  cursor: pointer;
}

/* ---------- Utility ---------- */
.visually-hidden {
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden;
  clip: rect(1px,1px,1px,1px);
  white-space: nowrap;
} 

.hero {
  position: relative;
  display: grid;
  place-items: center;
  text-align: center;
  color: #fff;
  padding: 2.25rem 1rem;                     /* ↓ reduced from 3.5rem */
  min-height: clamp(200px, 30vh, 400px);     /* ↓ tighter vertical range */

  background-image:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url('../images/bg-sagrada.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero h2,
.hero p {
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
}

.hero p {
  max-width: 60ch;
  margin: 0.5rem auto 0;
  font-size: clamp(1rem, 1vw + 0.75rem, 1.1rem);
  color: rgba(255, 255, 255, 0.95);  /* brightened slightly */
}

/* ▼ arrow animation */
.toggle-arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}

/* when open — rotate ▼ downward (180° becomes ^) */
.main-toggle.open .toggle-arrow {
  transform: rotate(180deg);
}

.main-toggle-section {
  padding: 2rem 1rem;
  max-width: 600px;
  margin: 0 auto;
}

.main-toggle {
  margin-bottom: 1.5rem;
}

.main-toggle.open .main-submenu {
  display: block;   /* show when container has .open */
}

.main-submenu-toggle {
  width: 100%;
  font-size: 1.2rem;
  background-color: #004d40;
  color: white;
  border: none;
  padding: 0.75rem;
  text-align: left;
  border-radius: 6px;
  cursor: pointer;
}

@media screen {
  .cards > .card:first-child {
    display: none;
  }
}

.main-submenu-toggle:focus-visible {
  outline: 3px solid #80cbc4;
  outline-offset: 2px;
}

.main-submenu {
  display: none;  /* start hidden */
  list-style: none;
  padding-left: 1rem;
  margin: 1rem 0 0 0;
}

.main-submenu li {
  margin-bottom: 0.5rem;
}

.main-submenu a {
  color: #004d40;
  text-decoration: none;
  font-weight: bold;
}
/* Footer */
.site-footer {
background-color: #eeeeee;
text-align: center;
font-size: 0.9rem;
padding: 1rem;
margin-top: 2rem;
}

@media (min-width: 768px) {
  /* Show desktop nav */
  .main-nav {
    display: block;
  }

  .hamburger {
    display: none;
  }

  .side-nav {
    display: none;
  }

  /* Layout adjustments for wider screens */
  .main-nav ul {
    flex-direction: row;
    justify-content: center;
  }

  .main-nav li {
    margin: 0.5rem 1rem;
  }

  .city-links ul {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
  }
}

/* Card container wrapper (was .city-cards) */
.cards {
  padding: 2rem 1rem;
  max-width: 900px;
  margin: auto;
}

.card {
  background-color: #e0f2f1;
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.card-toggle {
  width: 100%;
  text-align: left;
  background-color: #004d40;
  color: white;
  font-size: 1.2rem;
  padding: 1rem;
  border: none;
  cursor: pointer;
}

.card-content {
  display: none;
  padding: 1rem;
}

.card-content img {
  width: 100%;
  border-radius: 4px;
  margin-bottom: 0.5rem;
}

.card-content p {
  margin-bottom: 0.5rem;
}

.more-button {
  display: inline-block;
  margin-top: 0.5rem;
  background-color: #00796b;
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  text-decoration: none;
}

.more-button:hover {
  background-color: #00796b;
}

/* City page layout */
.city-page {
  max-width: 920px;      /* readable line length */
  margin: 0 auto;        /* center the page */
  padding: 1.5rem 1rem;  /* page margin */
}

/* Title + hero image */
.city-hero h1 {
  margin: 0 0 0.75rem;
  font-size: 1.8rem;
  line-height: 1.2;
}

.city-hero figure {
  margin: 0 0 1rem;
}

.city-hero img {
  display: block;     /* remove inline gap */
  width: 100%;        /* responsive */
  height: auto;       /* keep aspect ratio */
  border-radius: 8px; /* soft corners */
}

/* Body text */
.city-intro p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #333;
}

/* Back link */
.city-back {
  margin-top: 1.25rem;
}
.city-back .back-link {
  color: #00695c;
  text-decoration: none;
  font-weight: 600;
}
.city-back .back-link:hover {
  text-decoration: underline;
}

/* --- City: responsive two-column on desktop --- */
@media (min-width: 960px) {
  .city-article {
    display: grid;
    grid-template-columns: 1fr 1.1fr;         /* image | text */
    grid-template-areas:
      "title title"
      "image body";
    column-gap: 2rem;
    row-gap: 1.5rem;
    align-items: start;
  }

  /* Flatten the wrapper so its children can be grid items */
  .city-hero { display: contents; }

  .city-hero h1 { 
    grid-area: title;
    font-size: 2rem;
    margin-bottom: 0;
  }

  .city-hero figure {
    grid-area: image;
    margin: 0;
  }

  .city-intro { 
    grid-area: body; 
  }

  .city-hero img {
    width: 100%;
    height: auto;              /* keep aspect ratio */
    border-radius: 10px;
    /* Optional: limit towering images */
    max-height: 520px;
    object-fit: cover;
  }

  .city-intro p {
    font-size: 1.1rem;
    line-height: 1.85;
  }
}

/* --- Weekly Picks --- */
.featured { margin: 0 0 1.5rem; }
.featured-title {
  margin: 0 0 .75rem;
  font-size: 1.25rem;
  border-left: 4px solid #00796b;
  padding-left: .5rem;
}
.featured-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.featured-card {
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 10px;
  padding: .85rem;
  box-shadow: 0 2px 6px rgba(0,0,0,.06);
  transition: box-shadow .2s ease, transform .2s ease;
}
.featured-card:hover { box-shadow: 0 6px 14px rgba(0,0,0,.12); transform: translateY(-1px); }
.featured-card__link { text-decoration: none; color: inherit; }
.featured-card__img { width: 100%; height: 140px; object-fit: cover; border-radius: 8px; }
.featured-card__title { margin: .5rem 0 .25rem; font-size: 1.05rem; }
.featured-card__meta { margin: 0 0 .4rem; color: #666; font-size: .9rem; }
.featured-card__desc { margin: 0 0 .5rem; color: #555; font-size: .93rem; }
.featured-card__price { margin: .25rem 0 .6rem; font-weight: 700; color: #00796b; font-size: .95rem; }
.featured-more { text-align: center; margin-top: .75rem; }

/* Schools list (grid) */
.city-heading {
  margin: 2rem 0 1rem;
  font-size: 1.5rem;
  border-bottom: 2px solid #e5e5e5;
  padding-bottom: .3rem;
}

.school-cards {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.school-card {
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 10px;
  padding: 1rem;
  box-shadow: 0 2px 6px rgba(0,0,0,.06);
  transition: box-shadow .2s ease, transform .2s ease;
}

.school-card:hover {
  box-shadow: 0 6px 14px rgba(0,0,0,.12);
  transform: translateY(-1px);
}

.school-card__link {
  text-decoration: none;
  color: inherit;
}

.school-card__img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 8px;
}

.school-card__title {
  margin: .6rem 0 .4rem;
  font-size: 1.1rem;
}

.school-card__desc {
  margin: 0 0 .5rem;
  color: #555;
  font-size: .95rem;
}

.from-price {
  font-weight: 700;
  color: #00796b;
  margin: .25rem 0 .6rem;
  font-size: .95rem;
}

.school-filters .filters-row {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  align-items: center;
  padding: .5rem 0; /* subtle spacing */
}

/* nicer spacing under each city block */
.city-block { margin-bottom: 2.5rem; }









