/* Shared icon foundation for the five-tab Web/App mobile navigation. */
.v942-mobile-app-tabbar .v796-nav-icon,
.koirea-app-bottom-nav .koirea-app-nav-icon {
  width: 30px;
  height: 27px;
  display: inline-grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: inherit;
  transition: background-color .16s ease, border-color .16s ease, color .16s ease, transform .16s ease;
}

.v942-mobile-app-tabbar .v796-nav-icon svg,
.koirea-app-bottom-nav .koirea-app-nav-icon svg {
  width: 22px;
  height: 22px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.v942-mobile-app-tabbar a.active .v796-nav-icon,
.koirea-app-bottom-nav a.is-active .koirea-app-nav-icon {
  border-color: rgba(246, 105, 138, .22);
  background: #fff0f5;
  color: #d92d5c;
  transform: translateY(-1px);
}

.v942-mobile-app-tabbar a.active,
.koirea-app-bottom-nav a.is-active {
  color: #d92d5c;
}

.koirea-app-bottom-nav a {
  position: relative;
}

.koirea-app-bottom-nav .koirea-app-nav-badge {
  position: absolute;
  top: 2px;
  left: calc(50% + 7px);
  z-index: 1;
  display: inline-grid;
  place-items: center;
  min-width: 17px;
  height: 17px;
  padding: 0 5px;
  margin: 0;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #d92d5c;
  color: #fff;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

/* App dock owns its final geometry; the Web rail below keeps a separate surface. */
body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav {
  position: relative;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2px;
  margin: 0 max(8px, env(safe-area-inset-right, 0px))
    calc(6px + env(safe-area-inset-bottom, 0px))
    max(8px, env(safe-area-inset-left, 0px));
  padding: 4px;
  border: 1px solid rgba(222, 204, 203, .88);
  border-radius: 19px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(23, 35, 58, .075);
  backdrop-filter: none;
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav a {
  min-width: 0;
  min-height: 50px;
  padding: 4px 0;
  grid-template-rows: 23px auto;
  align-content: center;
  gap: 2px;
  border-radius: 14px;
  background: transparent;
  color: #5d697b;
  box-shadow: none;
  text-align: center;
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav a.is-active {
  background: #fff2ef;
  color: #bd284b;
  box-shadow: inset 0 0 0 1px rgba(217, 54, 93, .10);
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav .koirea-app-nav-icon {
  width: 26px;
  height: 23px;
  border: 0;
  border-radius: 0;
  background: transparent;
  transform: none;
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav .koirea-app-nav-icon svg {
  width: 22px;
  height: 22px;
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav strong {
  max-width: none;
  overflow: visible;
  font-size: 10px;
  line-height: 1.1;
  text-overflow: clip;
  white-space: nowrap;
}

body.koirea-app-body:is([data-koirea-quality="v00100"], .koirea-app-embedded) .koirea-app-bottom-nav .koirea-app-nav-badge {
  top: 2px;
  left: calc(50% + 5px);
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  font-size: 9px;
}

@media (prefers-reduced-motion: reduce) {
  .v942-mobile-app-tabbar .v796-nav-icon,
  .koirea-app-bottom-nav .koirea-app-nav-icon {
    transition-duration: .001ms;
  }
}

/*
 * Authenticated Web navigation.
 *
 * Web uses an edge-to-edge browser rail with a top selection marker. The App
 * keeps its floating rounded dock in app-ui.css. Keeping these surfaces in
 * separate owners prevents the legacy native-tabbar rules from making both
 * products look identical.
 */
@media (max-width: 760px) {
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav {
    position: fixed;
    z-index: 145;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: stretch;
    min-height: calc(50px + env(safe-area-inset-bottom));
    padding: 0 max(6px, env(safe-area-inset-right)) env(safe-area-inset-bottom) max(6px, env(safe-area-inset-left));
    border: 0;
    border-top: 1px solid rgba(91, 67, 74, .14);
    border-radius: 0;
    background: rgba(255, 253, 252, .985);
    box-shadow: 0 -10px 28px rgba(54, 34, 41, .08);
    backdrop-filter: blur(18px) saturate(1.08);
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a {
    position: relative;
    min-width: 0;
    min-height: 50px;
    display: grid;
    grid-template-rows: 24px auto;
    place-items: center;
    align-content: center;
    gap: 2px;
    padding: 4px 1px 3px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: #6c6870;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.1;
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    transition: color .16s ease, background-color .16s ease;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    width: 0;
    height: 3px;
    border-radius: 0 0 3px 3px;
    background: #d9365d;
    transform: translateX(-50%);
    transition: width .16s ease;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active {
    background: #fff0f4;
    color: #bd284b;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active::before {
    width: 30px;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav .v796-nav-icon,
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active .v796-nav-icon {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: inherit;
    transform: none;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav .v796-nav-icon svg,
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active .v796-nav-icon svg {
    width: 24px;
    height: 24px;
    color: inherit;
    stroke: currentColor;
    stroke-width: 2;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav .v48-tab-badge {
    position: absolute;
    z-index: 2;
    top: 5px;
    left: calc(50% + 8px);
    width: max-content;
    min-width: 22px;
    height: 22px;
    display: inline-grid;
    place-items: center;
    margin: 0;
    padding: 0 5px;
    border: 2px solid #fffdfc;
    border-radius: 999px;
    background: #d92d5c;
    color: #fff;
    font-size: 11px;
    font-style: normal;
    font-weight: 900;
    line-height: 1;
  }

  /* The shared outline assets contain fixed v14 paint. Web navigation owns
     selection color; preserve native assets and their existing rendering. */
  body.koirea-member-web .koirea-web-bottom-nav svg [stroke]:not([stroke="none"]) { stroke: currentColor; }
  body.koirea-member-web .koirea-web-bottom-nav svg [fill]:not([fill="none"]) { fill: currentColor; }

  body.koirea-member-web:not(.is-chat-page) .native-container {
    padding-bottom: calc(84px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 360px) {
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a {
    font-size: 9px;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav .v796-nav-icon,
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active .v796-nav-icon {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
  }

  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav .v796-nav-icon svg,
  body.koirea-member-web:not(.is-chat-page) .koirea-web-bottom-nav a.active .v796-nav-icon svg {
    width: 24px;
    height: 24px;
  }
}

@media (min-width: 761px) {
  .koirea-web-bottom-nav {
    display: none;
  }
}
