/* C1 Button, account-page style (x-button on the 6.3 pages): taken out of css/shell/account.css on 26 Sep 2026
   so "Enter your code" can use it inside the public shell. Used by join.html and join-code.html.
   Load after the page's base layer (account.css, or the card's own base in pages/join-code.css). */

/* ---------- Buttons (ux C1) ----------
   .action_button is the shared base; add .is_primary (ICCF blue, the main action), .is_danger_outline (Log out)
   and .is_small, .is_full as needed. Sentence case always. */

.action_button {
  position: relative;
  z-index: 1;
  display: inline-block;
  padding: 19px 29px;
  font-family: var(--inter);
  font-size: 1rem;
  font-weight: var(--_font-weight---medium);
  line-height: 1;
  color: var(--color-bg);
  text-align: center;
  text-decoration: none;
  text-transform: none;
  vertical-align: middle;
  background-color: transparent;
  border: 1px solid transparent;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.action_button:hover {
  color: var(--color-bg);
}

.action_button:active {
  top: 1px;
}

.action_button:disabled {
  opacity: 0.5;
  pointer-events: none;
}

.action_button.is_full {
  width: 100%;
}

@media screen and (max-width: 1199px) {
  .action_button {
    font-size: 0.9375rem;
  }
}

@media screen and (max-width: 767px) {
  .action_button {
    padding: 14px 25px;
    font-size: 0.875rem;
  }
}

@media screen and (max-width: 575px) {
  .action_button {
    padding: 12px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .action_button {
    transition: none;
  }
}

/* Primary: ICCF blue, bold, 6px corners; on hover a darker blue slides in from the left */
.action_button.is_primary {
  padding-block: clamp(0.8rem, 0.8862rem + 0.5688vw, 1.3125rem);
  font-weight: var(--_font-weight---bold);
  background-color: var(--color-primary);
  border-radius: var(--radius);
}

.action_button.is_primary::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  background: var(--color-primary-dark);
  border: 1px solid transparent;
  border-radius: var(--radius);
  transform: scaleX(0);
  transform-origin: right bottom;
  transition: transform 0.3s;
}

.action_button.is_primary:hover::after {
  transform: scaleX(1);
  transform-origin: left bottom;
}

.action_button.is_primary:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 2px;
}

/* Small */
.action_button.is_small {
  padding: 10px 15px;
}

@media screen and (max-width: 767px) {
  .action_button.is_small {
    padding: 8px 12px;
  }
}

/* Danger outline (Log out): ICCF danger red border and text; fills red on hover */
.action_button.is_danger_outline {
  color: var(--color-danger);
  background-color: transparent;
  border: 1px solid var(--color-danger);
}

.action_button.is_danger_outline:hover {
  color: var(--color-bg);
  background-color: var(--color-danger);
}

.action_button__icon {
  margin-right: 5px;
}

/* Secondary (ux C1, added 27 Sep 2026 for 6.4 "Save and finish later"): white, 2px ICCF blue border, blue text;
   pale blue on hover (mouse only) and when pressed */
.action_button.is_secondary {
  padding-block: clamp(0.8rem, 0.8862rem + 0.5688vw, 1.3125rem);
  font-weight: var(--_font-weight---bold);
  color: var(--color-primary);
  background-color: var(--color-bg);
  border: 2px solid var(--color-primary);
  border-radius: var(--radius);
}

.action_button.is_secondary:active {
  background-color: var(--color-primary-bg);
}

@media (hover: hover) {
  .action_button.is_secondary:hover {
    color: var(--color-primary);
    background-color: var(--color-primary-bg);
  }
}

.action_button.is_secondary:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 2px;
}
