/*
 * 総選挙2026 特設サイト・投票システム統合用
 * 配置先: /web/sousenkyo/2026/css/vote-integration.css
 */
.voteDock {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1000;
  padding: 6px max(8px, env(safe-area-inset-right)) calc(6px + env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  background: rgba(5, 14, 24, 0.96);
  border-top: 1px solid rgba(211, 166, 69, 0.8);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(8px);
}

.voteDockList {
  display: grid;
  grid-template-columns: minmax(180px, 1.6fr) repeat(3, minmax(92px, 1fr));
  gap: 6px;
  width: min(100%, 980px);
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.voteDock a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 8px 12px;
  border: 1px solid rgba(211, 166, 69, 0.72);
  color: #fff;
  background: #122438;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
}

.voteDock .votePrimary {
  position: relative;
  overflow: hidden;
  color: #07121e;
  background: linear-gradient(135deg, #f7dfa0 0%, #d3a645 48%, #fff0b9 100%);
  border-color: #f4d477;
  font-size: 1.08em;
  box-shadow: 0 0 18px rgba(232, 190, 86, 0.58);
  animation: voteDockPulse 1.8s ease-in-out infinite;
}

.voteDock .votePrimary::after {
  position: absolute;
  top: -45%;
  left: -35%;
  width: 28%;
  height: 190%;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.82), transparent);
  transform: rotate(18deg);
  animation: voteDockShine 2.6s ease-in-out infinite;
}

.voteDock a:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 2px;
}

.voteDock a:hover {
  filter: brightness(1.12);
}

.integrationEmbedded .voteDock {
  display: none;
}

.integrationEmbedded .pageTop {
  bottom: 18px;
}

.siteFooter [data-admin-login-trigger] {
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.adminLoginModal[hidden] {
  display: none;
}

.adminLoginModal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 20px;
}

.adminLoginBackdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 8, 14, 0.82);
  backdrop-filter: blur(6px);
}

.adminLoginPanel {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  box-sizing: border-box;
  padding: 34px;
  color: #102438;
  background: #f8f4e9;
  border: 1px solid #d3a645;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.58);
}

.adminLoginPanel h2 {
  margin: 4px 0 10px;
  font-size: clamp(1.6rem, 5vw, 2.2rem);
}

.adminLoginEyebrow {
  margin: 0;
  color: #8a681f;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.adminLoginLead {
  margin: 0 0 22px;
}

.adminLoginClose {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 42px;
  height: 42px;
  border: 0;
  color: #102438;
  background: transparent;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

.adminLoginForm {
  display: grid;
  gap: 10px;
}

.adminLoginForm label {
  font-weight: 700;
}

.adminLoginForm input[type="password"] {
  box-sizing: border-box;
  width: 100%;
  min-height: 52px;
  padding: 10px 12px;
  border: 1px solid #9d864f;
  background: #fff;
  font: inherit;
}

.adminLoginForm button[type="submit"] {
  min-height: 52px;
  margin-top: 8px;
  border: 1px solid #f1d37c;
  color: #07121e;
  background: linear-gradient(135deg, #f7dfa0, #d3a645);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.adminLoginForm button[type="submit"]:disabled {
  cursor: wait;
  opacity: 0.55;
}

.adminLoginStatus {
  min-height: 1.5em;
  margin: 4px 0 0;
  color: #7b2830;
  font-size: 0.85rem;
}

body.adminLoginActive {
  overflow: hidden;
}

body:not(.integrationEmbedded) {
  padding-bottom: 72px;
}

@keyframes voteDockPulse {
  0%,
  100% {
    transform: translateY(0);
    box-shadow: 0 0 14px rgba(232, 190, 86, 0.48);
  }
  50% {
    transform: translateY(-2px);
    box-shadow: 0 0 26px rgba(255, 220, 124, 0.78);
  }
}

@keyframes voteDockShine {
  0%,
  58% {
    left: -35%;
  }
  100% {
    left: 120%;
  }
}

@media (max-width: 720px) {
  .voteDock {
    padding-top: 5px;
  }

  .voteDockList {
    grid-template-columns: 1.55fr repeat(3, 1fr);
    gap: 4px;
  }

  .voteDock a {
    min-height: 44px;
    padding: 6px 4px;
    font-size: 0.78rem;
  }

  .voteDock .votePrimary {
    font-size: 0.92rem;
  }

  body:not(.integrationEmbedded) {
    padding-bottom: 62px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .voteDock .votePrimary,
  .voteDock .votePrimary::after {
    animation: none;
  }
}
