/* ============================================================
   Base — Reset + global type + app shell
   ============================================================ */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  text-rendering: optimizeLegibility;
  /* Disable pull-to-refresh (mobile) — applied at the document root */
  overscroll-behavior-y: none;
}

body {
  min-height: 100vh;
  min-height: 100lvh;
  font-family: var(--font-family-base);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  color: var(--color-text-primary);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overscroll-behavior-y: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

input,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* App shell — mobile-first, becomes a centered card on desktop.
   Uses the LARGE viewport (100lvh) so the map fills the full screen and
   extends *behind* the browser's bottom toolbar (the map shows through behind
   the translucent chrome — no white/ivory strip). The bottom nav is a
   position:fixed floating element, which iOS keeps above the browser toolbar. */
.app {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: var(--layout-max-width);
  height: 100vh;
  height: 100lvh;
  margin: 0 auto;
  background: var(--color-bg);
  overflow: hidden;
}

@media (min-width: 768px) {
  body {
    background: var(--color-surface-tonal);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-8) 0;
  }

  .app {
    height: min(900px, calc(100vh - var(--space-16)));
    min-height: auto;
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
  }
}

/* Bilingual sub-text (translated name/address below Korean) */
.i18n-sub {
  display: block;
  font-size: 0.8em;
  font-weight: var(--font-weight-regular);
  color: var(--color-brand-primary);
  opacity: 0.7;
  margin-top: 2px;
  line-height: var(--line-height-snug);
}

.i18n-sub--inline {
  display: inline;
  margin-top: 0;
  margin-left: var(--space-2);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
