/* Poplist — unified footer: logo, About / Plans / Privacy / Terms of Service, copyright
 *
 * Footer module: add class `footer-module` on the <footer> and copy the inner markup from
 * public/index.html (`#siteFooter`) — logo, nav (four links + data-*), copyright line.
 * Use `uf-footer--padded` on full-width pages; legal pages inside `.wrap` use `uf-footer--align` only.
 */

.uf-footer {
  --uf-bg: var(--bg, #ECEEF2);
  --uf-border: var(--border, #D4D7DD);
  --uf-t1: var(--t1, #111111);
  --uf-t3: var(--t3, #9CA3AF);
  --uf-accent: var(--blue, var(--accent, #3B82F6));
}

.uf-footer--fixed {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  padding: 0 20px;
  box-sizing: border-box;
  background: var(--uf-bg);
  z-index: 10;
}

.uf-footer__inner {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  border-top: 1px solid var(--uf-border);
  padding-top: 16px;
  padding-bottom: calc(20px + env(safe-area-inset-bottom, 0));
}

.uf-footer--static .uf-footer__inner {
  padding-bottom: 20px;
}

/* Centered column (480px). Side padding only when combined with .uf-footer--padded
   (matches nav). Inside pre-padded containers (e.g. legal .wrap), use --align alone. */
.uf-footer--align {
  width: 100%;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
  flex-shrink: 0;
}

.uf-footer--padded {
  padding-left: 20px;
  padding-right: 20px;
}

.uf-footer__logo {
  font-size: 15px;
  font-weight: 900;
  letter-spacing: -0.35px;
  color: var(--uf-t1);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
}

.uf-footer__logo em {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--uf-accent);
  border-radius: 50%;
  margin-left: 2px;
  vertical-align: super;
  font-style: normal;
}

.uf-footer__logo:hover {
  opacity: 0.88;
}

.uf-footer__nav {
  /* Reset any page-level `nav { … }` rules (border, sticky header, etc.) */
  position: static;
  top: auto;
  z-index: auto;
  width: auto;
  max-width: none;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0;
  line-height: 1;
}

/* Top-row items: same vertical box so JP labels (e.g. Poplistについて vs プラン) line up */
.uf-footer__nav > a,
.uf-footer__nav > .uf-footer-about {
  display: inline-flex;
  align-items: center;
  align-self: center;
  min-height: 1.5em;
}

.uf-footer__nav a {
  font-size: 10px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--uf-t3);
  text-decoration: none;
  padding: 0;
  transition: color 0.18s;
}

.uf-footer__nav > a:not(:last-child)::after,
.uf-footer__nav > .uf-footer-about > a::after {
  content: '·';
  display: inline-flex;
  align-items: center;
  align-self: center;
  margin: 0 10px;
  height: 1em;
  line-height: 1;
  color: var(--uf-t3);
  font-weight: 500;
  pointer-events: none;
}

.uf-footer__nav a:hover {
  color: var(--uf-accent);
}

/* About child menu (footer only) */
.uf-footer-about {
  position: relative;
  display: inline-flex;
  align-items: center;
}

/* Trigger link (not in .uf-footer-about-list): same row alignment as other nav links */
.uf-footer-about > a {
  display: inline-flex;
  align-items: center;
}

.uf-footer-about-list {
  position: absolute;
  left: 0;
  top: 100%;
  margin-top: 0;
  padding: 8px 14px 8px 22px; /* bigger + more indent */
  min-width: 180px;
  background: var(--uf-bg);
  box-shadow: 0 6px 20px rgba(0,0,0,.16);
  border-radius: 10px;
  display: none;
}

.uf-footer-about-list a {
  display: block;
  font-size: 11px;
  padding: 3px 0;
}

.uf-footer-about:hover .uf-footer-about-list,
.uf-footer-about:focus-within .uf-footer-about-list {
  display: block;
}

.uf-footer__copy {
  margin: 0;
  font-size: 10px;
  font-weight: 500;
  color: var(--uf-t3);
  text-align: center;
}
