/* design tokens live in base.css */

body {
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  background: var(--bg);
  display: flex;
  justify-content: flex-start;
  align-items: center;
  flex-direction: column;
  padding: 32px 0 56px;
}

.page {
  width: 92%;
  max-width: 500px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.hero {
  border: var(--thick) solid var(--line);
  background: var(--bg);
  text-align: center;
}

.hero-title {
  padding: 18px 14px 8px;
  font-size: clamp(1.6rem, 7vw, 2.35rem);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -0.04rem;
}

.account-line {
  padding: 0 14px 14px;
  font-size: var(--fs-sm);
  font-weight: 900;
  line-height: 1.45;
  color: var(--muted);
}

.role-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--card);
  padding: 2px 6px;
  margin-left: 4px;
  font-size: var(--fs-xs);
  font-weight: 900;
  vertical-align: 1px;
}

.action-strip {
  border-top: var(--thin) solid var(--line);
  padding: 9px 10px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 5px;
  background: var(--bg);
}

.mini-btn,
.mini-btn:visited {
  border: var(--thin) solid var(--line);
  background: var(--card);
  min-height: 34px;
  padding: 6px 9px;
  font-size: var(--fs-xs);
  font-weight: 900;
  line-height: 1.14;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  letter-spacing: -0.01rem;
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.05s ease,
    box-shadow 0.05s ease;
}
.mini-btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 var(--line);
}
.mini-btn:active {
  transform: translate(1px, 1px);
  box-shadow: none;
}

.mini-btn.primary {
  background: var(--line);
  color: white !important;
}

.section {
  border: var(--thick) solid var(--line);
  background: var(--bg);
}

.section-head {
  padding: 11px 12px 9px;
  text-align: center;
  font-size: var(--fs-md);
  font-weight: 900;
  line-height: 1.2;
}

.section-rule {
  border-top: var(--thin) solid var(--line);
}

.section-body {
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 70px;
}

.empty {
  border: 1px dashed var(--faint);
  padding: 18px 10px;
  text-align: center;
  font-size: var(--fs-sm);
  font-weight: 800;
  line-height: 1.5;
  color: var(--muted);
}

.card {
  border: var(--thin) solid var(--line);
  background: var(--card);
  padding: 10px;
  box-shadow: var(--shadow);
}

.fav-card {
  cursor: pointer;
  transition:
    transform 0.05s ease,
    box-shadow 0.05s ease;
}
.fav-card:hover {
  transform: translate(-1px, -1px);
  box-shadow: 6px 6px 0 var(--line);
}
.fav-card:active {
  transform: translate(2px, 2px);
  box-shadow: none;
}

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 7px;
}

.card-name {
  min-width: 0;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.25;
  word-break: keep-all;
}

.status {
  flex-shrink: 0;
  border: 1px solid var(--line);
  background: var(--card);
  padding: 2px 7px;
  font-size: var(--fs-xs);
  font-weight: 900;
  line-height: 1.15;
  white-space: nowrap;
  box-shadow: 2px 2px 0 rgba(26, 26, 26, 0.06);
}

.status.pending {
  color: var(--point) !important;
}
.status.approved {
  color: #126b2f !important;
}
.status.rejected {
  color: #b00020 !important;
}
.status.open {
  color: var(--point) !important;
}
.status.resolved {
  color: #126b2f !important;
}

.card-text {
  border-top: 1px dashed var(--faint);
  padding-top: 7px;
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.45;
  color: var(--muted);
  word-break: keep-all;
}

.answer-box {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed var(--faint);
  display: grid;
  gap: 4px;
}

.answer-label {
  font-size: var(--fs-xs);
  font-weight: 900;
  line-height: 1.2;
  color: var(--muted);
}

.answer-text {
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.5;
  word-break: keep-all;
}

.answer-meta {
  font-size: var(--fs-xs);
  font-weight: 800;
  line-height: 1.4;
  color: var(--muted);
  word-break: keep-all;
}

.card-actions {
  margin-top: 8px;
  display: flex;
  justify-content: flex-end;
}

.card-actions .mini-btn {
  background: var(--card);
  font-size: var(--fs-xs);
}

.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.modal {
  background: var(--bg);
  width: 88%;
  max-width: 380px;
  max-height: 86vh;
  overflow-y: auto;
  padding: 20px;
  border: var(--thick) solid var(--line);
}

.modal-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

#m-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}

.tag-small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--card);
  padding: 2px 6px;
  font-size: 0.66rem;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
}

.tag-pick {
  background: var(--line);
  color: #fff;
  border-color: var(--line);
  letter-spacing: 0.02em;
  box-shadow: var(--shadow-sm);
}

.modal-copy {
  margin-bottom: 15px;
  display: grid;
  gap: 8px;
  word-break: keep-all;
}

.modal-copy-text {
  padding: 12px;
  border: 1px dashed var(--line);
  background: var(--card);
  font-size: var(--fs-md);
  font-weight: 700;
  line-height: 1.7;
}

.modal-signature {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 0 2px;
  color: var(--muted);
}

.modal-signature-label {
  flex: 0 0 auto;
  border: 1px solid var(--faint);
  background: var(--card);
  padding: 2px 6px;
  font-size: var(--fs-xs);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: 0.02em;
}

.modal-signature-value {
  min-width: 0;
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.5;
}

.modal-copy-empty {
  padding: 12px;
  border: 1px dashed var(--line);
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--muted);
}

.fav-btn {
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
  height: auto;
  border: none;
  background: transparent;
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0 2px;
  box-shadow: none;
}

.fav-btn.is-on {
  color: var(--point);
}

.modal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.modal-btn {
  width: 100%;
  padding: 12px 10px;
  border: var(--thin) solid var(--line);
  background: var(--card);
  font-weight: 900;
  letter-spacing: -0.01rem;
  cursor: pointer;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.05s ease,
    box-shadow 0.05s ease;
}
.modal-btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 var(--line);
}
.modal-btn:active {
  transform: translate(1px, 1px);
  box-shadow: none;
}

.modal-btn.is-hidden {
  visibility: hidden;
  pointer-events: none;
}

@media (max-width: 360px) {
  body {
    padding-top: 24px;
  }
  .page {
    width: 94%;
  }
  .hero-title {
    font-size: 1.55rem;
  }
  .card-top {
    flex-direction: column;
  }
  .status {
    align-self: flex-start;
  }
}

.modal-title {
  font-size: var(--fs-xl);
  font-weight: 900;
  border-bottom: var(--thick) solid var(--line);
  padding-bottom: 10px;
  margin-bottom: 15px;
}

.page-legal-footer {
  width: 92%;
  max-width: 500px;
  margin: 16px auto 0;
  text-align: center;
  font-size: 0.72rem;
  font-weight: 800;
  opacity: 0.72;
}
.page-legal-footer a {
  color: var(--ink) !important;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}

/* Low-emphasis account-deletion section (권리행사 채널, PIPA 35-5/36/37). */
.danger-section {
  border-color: rgba(26, 26, 26, 0.55);
  opacity: 0.92;
}

.danger-copy {
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.55;
  opacity: 0.78;
  word-break: keep-all;
}

.mini-btn.danger {
  align-self: flex-start;
  border-color: #b00020;
  color: #b00020 !important;
}

.modal-btn.danger {
  border-color: #b00020;
  color: #b00020 !important;
}

.delete-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.delete-field-label {
  font-size: 0.72rem;
  font-weight: 900;
  opacity: 0.8;
}

.delete-field input {
  border: var(--thin) solid var(--line);
  background: var(--bg);
  padding: 10px 12px;
  font-size: 0.85rem;
  font-weight: 700;
}

.delete-msg {
  min-height: 1.1em;
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.4;
  color: #b00020 !important;
}
