/* KYMA UI polish: shared micro-interaction and depth tokens only. */
:root{
  --kyma-motion-fast:160ms;
  --kyma-motion-base:220ms;
  --kyma-motion-slow:320ms;
  --kyma-ease-ui:cubic-bezier(.22,.72,.24,1);
  --kyma-ease-emphasis:cubic-bezier(.16,.72,.24,1);
  --kyma-shadow-soft:0 6px 18px rgba(96,65,108,.08);
  --kyma-shadow-hover:0 10px 24px rgba(96,65,108,.14);
  --kyma-shadow-active:inset 0 1px 2px rgba(96,65,108,.10),0 3px 10px rgba(96,65,108,.08);
  --kyma-shadow-overlay:0 24px 64px rgba(62,39,69,.20);
  --kyma-border-hover:rgba(197,139,207,.82);
  --kyma-focus-ring:rgba(220,169,230,.95);
}

/* Shared control motion. Existing component colors/backgrounds remain authoritative. */
.navPage:not(.active),
.accountLogin,
.accountName,
.accountAdmin,
.accountLogout,
.musicDrawerToggle,
.musicControls button,
.monthControls button,
.todayButton,
.eventLink,
.scheduleAddLink,
.scheduleQuickEdit,
.songClipAction,
.songSoopControls button,
.songPlaylistClear,
.songPlaylistItem button,
.siteAdminRemote button,
.songClipEditorClose,
.songClipEditorActions button,
.songClipManageSection button,
.scheduleManageClose,
.scheduleManageItem button,
.scheduleEditorUploadButton,
.scheduleEditorPreview label,
.scheduleEditorPreview button,
.scheduleEditorActions button,
.scheduleEditorDeleteConfirm button,
.scheduleEditorClose,
.accountClose,
.accountTabs button,
.accountForm>button,
.logoutButton,
.primaryAction,
.rowSave,
.rowDelete,
.musicDelete,
.memberAccessNotice button,
.memberRole button,
.adminSidebar button:not(.active),
.adminFormToggle,
.adminManagerActions a,
.managerEditToggle,
.managerCompactDelete{
  transition-property:transform,border-color,background-color,box-shadow,color,opacity;
  transition-duration:var(--kyma-motion-base);
  transition-timing-function:var(--kyma-ease-ui);
}

/* Text-only actions keep their current visual weight. */
.weekScheduleHeading button,
.backLink,
.songSoopSource{
  transition:color var(--kyma-motion-fast) var(--kyma-ease-ui),opacity var(--kyma-motion-fast) var(--kyma-ease-ui);
}

/* Interactive card motion only; read-only schedule/detail cards are intentionally excluded. */
.weekEventCard,
.weekDayEvent,
.songClipCard,
.playlistItem{
  transition-property:transform,border-color,background-color,box-shadow;
  transition-duration:var(--kyma-motion-base);
  transition-timing-function:var(--kyma-ease-ui);
}

.playlistItem.active,
.songPlaylistItem[aria-current="true"],
.adminSidebar button.active{
  box-shadow:var(--kyma-shadow-soft);
}

/* Calendar cells remain fixed in place: only paint properties animate. */
.calendarDay{
  transition:background-color var(--kyma-motion-fast) var(--kyma-ease-ui),box-shadow var(--kyma-motion-fast) var(--kyma-ease-ui),color var(--kyma-motion-fast) var(--kyma-ease-ui);
}

/* Quick Links: preserve card geometry and move only the icon by one pixel. */
.quickIcon{
  transition:transform var(--kyma-motion-base) var(--kyma-ease-ui),box-shadow var(--kyma-motion-base) var(--kyma-ease-ui),border-color var(--kyma-motion-base) var(--kyma-ease-ui);
}
.quickIcon img{
  transition:transform var(--kyma-motion-base) var(--kyma-ease-ui);
}
.quickLinkCard:hover .quickIcon img{transform:scale(1.01)}
.quickLinkCard:active .quickIcon{transform:translateY(0) scale(.99)}

/* Member Live: only LIVE avatars gain extra depth; the pulse animation itself is untouched. */
.memberLiveAvatar{
  transition:box-shadow var(--kyma-motion-base) var(--kyma-ease-ui),border-color var(--kyma-motion-base) var(--kyma-ease-ui),transform var(--kyma-motion-fast) var(--kyma-ease-ui);
}
a.memberLiveItem.is-live:active .memberLiveAvatar{transform:scale(.99)}

/* Modal depth uses the same orchid-tinted overlay tier. Drawer geometry/transitions are untouched. */
.accountPanel{box-shadow:var(--kyma-shadow-overlay)}

@media(hover:hover){
  .navPage:not(.active):hover,
  .accountLogin:hover,
  .accountName:hover,
  .musicDrawerToggle:hover,
  .musicControls button:hover,
  .monthControls button:hover,
  .todayButton:hover,
  .eventLink:hover,
  .scheduleAddLink:hover,
  .scheduleQuickEdit:hover,
  .songClipAction:hover,
  .songSoopControls button:not(:disabled):hover,
  .songPlaylistClear:hover,
  .songPlaylistItem button:hover,
  .siteAdminRemote button:hover,
  .songClipEditorClose:hover,
  .songClipEditorActions button:not(:disabled):hover,
  .songClipManageSection button:hover,
  .scheduleManageClose:hover,
  .scheduleManageItem button:hover,
  .scheduleEditorUploadButton:hover,
  .scheduleEditorPreview label:hover,
  .scheduleEditorPreview button:hover,
  .scheduleEditorActions button:not(:disabled):hover,
  .scheduleEditorDeleteConfirm button:not(:disabled):hover,
  .scheduleEditorClose:hover,
  .accountClose:hover,
  .accountForm>button:not(:disabled):hover,
  .logoutButton:hover,
  .primaryAction:not(:disabled):hover,
  .rowSave:not(:disabled):hover,
  .rowDelete:not(:disabled):hover,
  .musicDelete:not(:disabled):hover,
  .memberAccessNotice button:hover,
  .memberRole button:not(:disabled):hover,
  .adminSidebar button:not(.active):hover,
  .adminFormToggle:hover,
  .adminManagerActions a:hover,
  .managerEditToggle:not(:disabled):hover,
  .managerCompactDelete:not(:disabled):hover{
    transform:translateY(-1px);
  }

  /* Controls that previously had little/no depth use the shared hover shadow tier. */
  .monthControls button:hover,
  .todayButton:hover,
  .eventLink:hover,
  .scheduleAddLink:hover,
  .scheduleQuickEdit:hover,
  .songClipAction:hover,
  .songSoopControls button:not(:disabled):hover,
  .songPlaylistClear:hover,
  .songPlaylistItem button:hover,
  .siteAdminRemote button:hover,
  .songClipEditorClose:hover,
  .songClipEditorActions button:not(:disabled):hover,
  .songClipManageSection button:hover,
  .scheduleManageClose:hover,
  .scheduleManageItem button:hover,
  .scheduleEditorUploadButton:hover,
  .scheduleEditorPreview label:hover,
  .scheduleEditorPreview button:hover,
  .scheduleEditorActions button:not(:disabled):hover,
  .scheduleEditorDeleteConfirm button:not(:disabled):hover,
  .scheduleEditorClose:hover,
  .accountForm>button:not(:disabled):hover,
  .logoutButton:hover,
  .primaryAction:not(:disabled):hover,
  .rowSave:not(:disabled):hover,
  .rowDelete:not(:disabled):hover,
  .musicDelete:not(:disabled):hover,
  .memberAccessNotice button:hover,
  .memberRole button:not(:disabled):hover,
  .adminSidebar button:not(.active):hover,
  .adminFormToggle:hover,
  .adminManagerActions a:hover,
  .managerEditToggle:not(:disabled):hover,
  .managerCompactDelete:not(:disabled):hover{
    box-shadow:var(--kyma-shadow-hover);
  }

  .weekEventCard:hover{
    box-shadow:var(--kyma-shadow-hover);
    transform:translateY(-2px);
  }
  .weekDayEvent:hover,
  .playlistItem:hover{
    box-shadow:var(--kyma-shadow-hover);
    transform:translateY(-1px);
  }
  .songClipCard:hover{
    box-shadow:var(--kyma-shadow-hover);
    transform:translateY(-2px);
  }
  .quickLinkCard:hover .quickIcon{box-shadow:var(--kyma-shadow-hover);transform:translateY(-1px)}
  a.memberLiveItem.is-live:hover .memberLiveAvatar{
    border-color:var(--kyma-border-hover);
    box-shadow:0 0 0 2px rgba(239,216,243,.92),var(--kyma-shadow-hover);
  }
  .weekScheduleHeading button:hover,
  .backLink:hover,
  .songSoopSource:hover{opacity:.86}
}

/* Press feedback is applied only where no positional transform is part of the component layout. */
.navPage:not(.active):active,
.accountLogin:active,
.accountName:active,
.accountAdmin:active,
.accountLogout:active,
.accountTabs button:active,
.musicDrawerToggle:active,
.musicControls button:active,
.monthControls button:active,
.todayButton:active,
.eventLink:active,
.scheduleAddLink:active,
.scheduleQuickEdit:active,
.songClipAction:active,
.songSoopControls button:not(:disabled):active,
.songPlaylistClear:active,
.songPlaylistItem button:active,
.siteAdminRemote button:active,
.songClipEditorClose:active,
.songClipEditorActions button:not(:disabled):active,
.songClipManageSection button:active,
.scheduleManageClose:active,
.scheduleManageItem button:active,
.scheduleEditorUploadButton:active,
.scheduleEditorPreview label:active,
.scheduleEditorPreview button:active,
.scheduleEditorActions button:not(:disabled):active,
.scheduleEditorDeleteConfirm button:not(:disabled):active,
.scheduleEditorClose:active,
.accountClose:active,
.accountForm>button:not(:disabled):active,
.logoutButton:active,
.primaryAction:not(:disabled):active,
.rowSave:not(:disabled):active,
.rowDelete:not(:disabled):active,
.musicDelete:not(:disabled):active,
.memberAccessNotice button:active,
.memberRole button:not(:disabled):active,
.adminSidebar button:not(.active):active,
.adminFormToggle:active,
.adminManagerActions a:active,
.managerEditToggle:not(:disabled):active,
.managerCompactDelete:not(:disabled):active{
  box-shadow:var(--kyma-shadow-active);
  transform:translateY(0) scale(.985);
  transition-duration:var(--kyma-motion-fast);
}
a.weekEventCard:active,
a.weekDayEvent:active{transform:translateY(0) scale(.99)}

/* Fill gaps where a focus-visible ring was not already defined. */
.monthControls button:focus-visible,
.todayButton:focus-visible,
.eventLink:focus-visible,
.accountClose:focus-visible,
.accountTabs button:focus-visible,
.accountForm>button:focus-visible,
.siteAdminRemote button:focus-visible,
.songClipEditorClose:focus-visible,
.songClipEditorActions button:focus-visible,
.songClipManageSection button:focus-visible,
.scheduleManageClose:focus-visible,
.scheduleManageItem button:focus-visible,
.scheduleEditorUploadButton:focus-visible,
.scheduleEditorPreview label:focus-visible,
.scheduleEditorPreview button:focus-visible,
.scheduleEditorActions button:focus-visible,
.scheduleEditorDeleteConfirm button:focus-visible,
.scheduleEditorClose:focus-visible,
.logoutButton:focus-visible,
.primaryAction:focus-visible,
.rowSave:focus-visible,
.rowDelete:focus-visible,
.musicDelete:focus-visible,
.memberAccessNotice button:focus-visible,
.memberRole button:focus-visible,
.adminSidebar button:focus-visible,
.adminFormToggle:focus-visible{
  outline:3px solid var(--kyma-focus-ring);
  outline-offset:2px;
}

@media(prefers-reduced-motion:reduce){
  .navPage:not(.active),
  .accountLogin,
  .accountName,
  .musicDrawerToggle,
  .musicControls button,
  .monthControls button,
  .todayButton,
  .eventLink,
  .scheduleAddLink,
  .scheduleQuickEdit,
  .songClipAction,
  .songSoopControls button,
  .songPlaylistClear,
  .songPlaylistItem button,
  .siteAdminRemote button,
  .songClipEditorClose,
  .songClipEditorActions button,
  .songClipManageSection button,
  .scheduleManageClose,
  .scheduleManageItem button,
  .scheduleEditorUploadButton,
  .scheduleEditorPreview label,
  .scheduleEditorPreview button,
  .scheduleEditorActions button,
  .scheduleEditorDeleteConfirm button,
  .scheduleEditorClose,
  .accountClose,
  .accountForm>button,
  .logoutButton,
  .primaryAction,
  .rowSave,
  .rowDelete,
  .musicDelete,
  .memberAccessNotice button,
  .memberRole button,
  .adminSidebar button,
  .adminFormToggle,
  .adminManagerActions a,
  .managerEditToggle,
  .managerCompactDelete,
  .weekEventCard,
  .weekDayEvent,
  .songClipCard,
  .playlistItem,
  .quickIcon,
  .quickIcon img,
  .memberLiveAvatar{
    transition-duration:.01ms!important;
  }

  .navPage:not(.active):hover,
  .accountLogin:hover,
  .accountName:hover,
  .musicDrawerToggle:hover,
  .musicControls button:hover,
  .monthControls button:hover,
  .todayButton:hover,
  .eventLink:hover,
  .scheduleAddLink:hover,
  .scheduleQuickEdit:hover,
  .songClipAction:hover,
  .songSoopControls button:hover,
  .songPlaylistClear:hover,
  .songPlaylistItem button:hover,
  .siteAdminRemote button:hover,
  .songClipEditorClose:hover,
  .songClipEditorActions button:hover,
  .songClipManageSection button:hover,
  .scheduleManageClose:hover,
  .scheduleManageItem button:hover,
  .scheduleEditorUploadButton:hover,
  .scheduleEditorPreview label:hover,
  .scheduleEditorPreview button:hover,
  .scheduleEditorActions button:hover,
  .scheduleEditorDeleteConfirm button:hover,
  .scheduleEditorClose:hover,
  .accountClose:hover,
  .accountForm>button:hover,
  .logoutButton:hover,
  .primaryAction:hover,
  .rowSave:hover,
  .rowDelete:hover,
  .musicDelete:hover,
  .memberAccessNotice button:hover,
  .memberRole button:hover,
  .adminSidebar button:hover,
  .adminFormToggle:hover,
  .adminManagerActions a:hover,
  .managerEditToggle:hover,
  .managerCompactDelete:hover,
  .weekEventCard:hover,
  .weekDayEvent:hover,
  .songClipCard:hover,
  .playlistItem:hover,
  .quickLinkCard:hover .quickIcon,
  .quickLinkCard:hover .quickIcon img,
  a.memberLiveItem.is-live:hover .memberLiveAvatar{
    transform:none;
  }
}
