/*
  LastPick - Buttons
  This file contains all button styles.
*/

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 14px 28px;
  font-weight: 800;
  letter-spacing: 0.02em;
  will-change: transform; /* PERFORMANCE: Hint to the browser that this property will change. */
  transition: transform 200ms ease, box-shadow var(--transition-base), background-color var(--transition-base), color var(--transition-base);
}

.button:hover {
  /* POLISH: Changed hover from scale to a subtle lift for a more refined feel. */
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.button-primary {
  border: 1px solid rgba(255, 255, 255, 0.44);
  background: var(--warm-cream);
  color: var(--dark-green);
  box-shadow: var(--shadow-md);
}

.button-primary:hover {
  background: #fff;
  box-shadow: var(--shadow-lg);
}

.button-secondary {
  border: 1px solid rgba(15, 91, 60, 0.18);
  background: var(--dark-green);
  color: var(--warm-cream);
  box-shadow: 0 18px 34px rgba(15, 91, 60, 0.18);
}

.button-secondary:hover {
  background: #144f32;
  box-shadow: 0 22px 42px rgba(15, 91, 60, 0.24);
}

.button-tertiary {
  min-height: 48px;
  border: 1px solid rgba(15, 91, 60, 0.16);
  background: rgba(255, 253, 247, 0.54);
  color: var(--dark-green);
  padding: 13px 30px;
  box-shadow: 0 10px 24px rgba(15, 91, 60, 0.08);
}

.button-tertiary:hover {
  background: var(--warm-cream);
  border-color: rgba(15, 91, 60, 0.22); /* POLISH: Soften the hover border color. */
  box-shadow: 0 16px 30px rgba(15, 91, 60, 0.14);
  transform: translateY(-2px);
}

a:focus-visible,
button:focus-visible,
.button:focus-visible {
  outline: 3px solid rgba(167, 212, 111, 0.55);
  outline: 3px solid transparent; /* Fallback for Windows High Contrast mode */
  outline-offset: 4px;
}

/* PREMIUM POLISH BUTTONS */
.button {
  --shadow-color: rgba(15, 91, 60, 0.1);
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  border: 1px solid transparent;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  will-change: transform, box-shadow;
  transition: transform 300ms cubic-bezier(0.4, 0, 0.2, 1), box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1), background-color 300ms cubic-bezier(0.4, 0, 0.2, 1), color 300ms cubic-bezier(0.4, 0, 0.2, 1);
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: none; /* Ensure buttons are not all-caps unless intended */
}

.button:focus {
  outline: none;
}

.button:focus-visible {
  box-shadow: 0 0 0 3px var(--cream), 0 0 0 5px var(--leaf-green);
}

.button::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background-color: #fff;
  opacity: 0;
  transition: opacity 200ms ease;
}

.button:hover {
  transform: translateY(-3px);
}

.button:active {
  transform: translateY(-1px) scale(0.99);
  box-shadow: var(--shadow-sm);
}

.button:active::before {
  opacity: 0.1;
  transition: opacity 0ms ease;
}