/* Friendly googly eyes, a gold shimmer, and a soft press.
   The public lost-pet page does not load this file. */

.googly-brand {
  display: inline-flex;
  gap: 3px;
  align-items: center;
  width: auto;
  height: auto;
}

.googly-pair {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: none;
}

.googly-brand {
  flex: none;
}

.googly-eye {
  position: relative;
  display: block;
  width: 22px;
  height: 22px;
  overflow: hidden;
  border-radius: 50%;
  background: #fffdf8;
  box-shadow: inset 0 -2px 4px rgba(49, 35, 25, 0.16), 0 0 0 1.5px rgba(255, 255, 255, 0.35);
  transform-origin: center;
  transition: transform 0.22s cubic-bezier(0.2, 1.3, 0.36, 1);
}

.googly-brand .googly-eye {
  width: 16px;
  height: 16px;
  box-shadow: inset 0 -2px 3px rgba(49, 35, 25, 0.14), 0 0 0 1.5px var(--accent);
}

.googly-pupil {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 9px;
  margin: -4.5px 0 0 -4.5px;
  border-radius: 50%;
  background: #2a211c;
  will-change: transform;
}

.googly-brand .googly-pupil {
  width: 7px;
  height: 7px;
  margin: -3.5px 0 0 -3.5px;
}

.googly-pupil::after {
  content: "";
  position: absolute;
  left: 1px;
  top: 1px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
}

.is-pleased .googly-eye[data-side="left"] {
  transform: scaleY(0.46) rotate(-10deg);
}

.is-pleased .googly-eye[data-side="right"] {
  transform: scaleY(0.46) rotate(10deg);
}

.is-blink .googly-eye {
  transform: scaleY(0.12);
  transition-duration: 0.08s;
}

.primary-button[data-googly]:not(.wide) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.primary-button:not(.wide) .googly-eye {
  width: 18px;
  height: 18px;
}

.primary-button:not(.wide) .googly-pupil {
  width: 7px;
  height: 7px;
  margin: -3.5px 0 0 -3.5px;
}

.primary-button {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.primary-button > * {
  position: relative;
  z-index: 1;
}

.primary-button::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(105deg, transparent 32%, rgba(255, 248, 230, 0.45) 50%, transparent 68%);
  transform: translateX(-130%);
  pointer-events: none;
}

.primary-button:hover::after,
.primary-button:focus-visible::after {
  animation: paw-shimmer 0.85s ease;
}

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

.primary-button:active {
  transform: translateY(0) scale(0.98);
}

.secondary-button {
  transition: transform 0.18s cubic-bezier(0.2, 1.4, 0.4, 1), background 0.2s, border-color 0.2s;
}

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

.secondary-button:active {
  transform: scale(0.97);
}

.ratio-option,
.frame-option,
.template-picker label,
.sample-card {
  transition: transform 0.18s cubic-bezier(0.2, 1.4, 0.4, 1);
}

.ratio-option:active,
.frame-option:active,
.template-picker label:active {
  transform: scale(0.96);
}

#saveButton.wide {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 8px;
}

#saveButton .googly-label {
  min-width: 0;
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.googly-arrow {
  flex: none;
  width: 18px;
  height: 18px;
}

#saveButton:disabled {
  opacity: 0.72;
}

@keyframes paw-shimmer {
  from { transform: translateX(-130%); }
  to { transform: translateX(130%); }
}

@media (max-width: 800px) {
  #saveButton.wide:hover,
  #saveButton.wide:active {
    transform: none;
  }

  #saveButton .googly-eye {
    width: 18px;
    height: 18px;
  }

  #saveButton .googly-pupil {
    width: 7px;
    height: 7px;
    margin: -3.5px 0 0 -3.5px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .googly-eye,
  .primary-button,
  .secondary-button,
  .ratio-option,
  .frame-option,
  .template-picker label,
  .sample-card {
    transition: none;
  }

  .primary-button::after {
    animation: none;
  }
}
