/* ==========================================================================
   PARTY MODE
   ========================================================================== */

:root {
  --cat-small-size: 10rem;    /* dancing cats */
  --cat-large-size: 20rem;    /* vibing/happy cats */
  --cat-top-offset: 10rem;
  --header-font-size: 3em;
  --text-padding: 2rem;
  --iframe-max-width: 560px;
  --close-btn-size: 40px;
}

.animation-area {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  pointer-events: auto;
  z-index: 750;
  display: none;
}

.background {
  position: absolute;
  width: 100%;
  height: 100%;
  animation: backgroundChange 10s infinite;
  z-index: -1;
}

.close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  font-size: 1.5em;
  border: none;
  border-radius: 50%;
  width: var(--close-btn-size);
  height: var(--close-btn-size);
  cursor: pointer;
  z-index: 1000;
}

.close-btn:hover {
  background-color: red;
}

.dancing_catLeft {
  top: var(--cat-top-offset);
  animation-delay: 0s;
  position: absolute;
  width: var(--cat-small-size);
  animation: moveLeft 3s linear infinite;
}

.dancing_catRight {
  top: var(--cat-top-offset);
  animation-delay: 0s;
  position: absolute;
  width: var(--cat-small-size);
  animation: moveRight 3s linear infinite;
}

.vibing_cat {
  position: absolute;
  width: var(--cat-large-size);
  bottom: 0;
  left: 0;
}

.happy_cat {
  position: absolute;
  width: var(--cat-large-size);
  bottom: 0;
  right: 0;
  animation: bounce 1s infinite;
}

.partyHeader {
  font-family: 'Inter', sans-serif;
  font-size: var(--header-font-size);
  position: relative;
  margin-top: 2em;
  color: white;
  animation: strobe 1s infinite;
}

.partyText {
  background-color: white;
  color: black;
  padding: var(--text-padding);
}

.party-iframe-wrapper {
  width: 100%;
  max-width: var(--iframe-max-width);
  margin: 0 auto;
}

.party-iframe-wrapper iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
}

/* ==========================================================================
   KEYFRAMES
   ========================================================================== */

@keyframes backgroundChange {
  0%   { background-color: blue; }
  50%  { background-color: green; }
  100% { background-color: red; }
}

@keyframes strobe {
  0%   { color: white; }
  20%  { color: yellow; }
  40%  { color: red; }
  60%  { color: blue; }
  80%  { color: green; }
  100% { color: purple; }
}

@keyframes moveLeft {
  0%   { transform: translateX(100vw); }
  100% { transform: translateX(-100px); }
}

@keyframes moveRight {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100vw); }
}

@keyframes bounce {
  0%, 100% { transform: translateY(-15vh); }
  50%       { transform: translateY(0); }
}

/* ==========================================================================
   REDUCED MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .background,
  .partyHeader,
  .dancing_catLeft,
  .dancing_catRight,
  .happy_cat {
    animation: none;
  }
}

/* ==========================================================================
   PARTY MODAL — Portfolio theme overrides
   Scoped to #partyModal to avoid affecting any other Bootstrap modal.
   ========================================================================== */

#partyModal .modal-content {
  background-color: #FEFBF1;
  border: 1px solid #e8e4dd;
  border-radius: 10px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.10);
}

#partyModal .modal-header {
  border-bottom: 1px solid #e8e4dd;
  padding: 1.25rem 1.5rem 1rem;
}

#partyModal .modal-title {
  font-family: 'EB Garamond', serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: hsla(0, 0%, 0%, 0.78);
  line-height: 1.2;
}

#partyModal .btn-close {
  filter: none;
  opacity: 0.55;
}

#partyModal .btn-close:hover {
  opacity: 1;
}

#partyModal .modal-body {
  font-family: 'Inter', sans-serif;
  padding: 1.25rem 1.5rem 1.5rem;
}

#partyModal .modal-body p {
  font-size: 1rem;
  color: #666;
  line-height: 1.55;
  margin-bottom: 0.75rem;
}

#partyModal .modal-body p:first-child em {
  font-style: normal;
  font-weight: 600;
  color: #1a1a1a;
}

#partyModal #startAnimation {
  display: inline-block;
  margin-top: 0.5rem;
  background-color: #EA7404;
  color: #ffffff;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: 0.5rem 1.25rem;
  cursor: pointer;
  transition: background-color 150ms ease;
}

#partyModal #startAnimation:hover {
  background-color: #D06903;
}

#partyModal #startAnimation:focus-visible {
  outline: 2px solid #EA7404;
  outline-offset: 3px;
}

#partyModal .btn.btn-primary {
  background-color: #EA7404 !important;
  border-color: #EA7404 !important;
  color: #ffffff !important;
  box-shadow: none;
}

#partyModal .btn.btn-primary:hover,
#partyModal .btn.btn-primary:active,
#partyModal .btn.btn-primary:focus {
  background-color: #D06903 !important;
  border-color: #D06903 !important;
  box-shadow: none !important;
}
