/* BewerberSuite Custom Styles */

/* Smooth scroll + prevent horizontal overflow on mobile */
html { scroll-behavior: smooth; overflow-x: hidden; }
body { overflow-x: hidden; }

/* Kanban Drag & Drop */
.kanban-column { min-height: 200px; transition: all 0.2s; border-radius: 12px; padding: 4px; }
[draggable="true"] { cursor: grab; }
[draggable="true"]:active { cursor: grabbing; }

/* Info-Tooltip */
.info-tooltip {
  position: relative;
  display: inline-flex;
  cursor: help;
}

.info-tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #1a1a1a;
  color: white;
  font-size: 11px;
  line-height: 1.4;
  padding: 8px 12px;
  border-radius: 8px;
  white-space: normal;
  width: max-content;
  max-width: 250px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 100;
}

.info-tooltip:hover::after {
  opacity: 1;
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 0.5; }
  100% { transform: scale(1.5); opacity: 0; }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(30px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes count-up {
  from { opacity: 0; transform: scale(0.5); }
  to { opacity: 1; transform: scale(1); }
}

.animate-pulse-ring { animation: pulse-ring 1.5s ease-out infinite; }
.animate-float { animation: float 3s ease-in-out infinite; }
.animate-fade-in-up { animation: fade-in-up 0.6s ease-out forwards; }
.animate-slide-in-right { animation: slide-in-right 0.6s ease-out forwards; }
.animate-marquee { animation: marquee 30s linear infinite; }

/* Staggered animations */
.animate-delay-100 { animation-delay: 0.1s; }
.animate-delay-200 { animation-delay: 0.2s; }
.animate-delay-300 { animation-delay: 0.3s; }
.animate-delay-400 { animation-delay: 0.4s; }

/* Rocket CTA button effect */
.btn-rocket {
  position: relative;
  overflow: hidden;
}

.btn-rocket::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-rocket:hover::after {
  width: 300px;
  height: 300px;
}

/* Marquee container */
.marquee-container {
  overflow: hidden;
  white-space: nowrap;
}

.marquee-content {
  display: inline-flex;
  animation: marquee 40s linear infinite;
}

.marquee-container:hover .marquee-content {
  animation-play-state: paused;
}

/* Dashboard sidebar */
.sidebar-link {
  transition: all 0.2s ease;
}

.sidebar-link:hover {
  background-color: #f9fafb;
  color: #111827;
}
.sidebar-link.active {
  background-color: #f3f4f6;
  color: #000000;
}

/* Card hover effect */
.card-hover {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

/* Kanban column */
.kanban-column {
  min-height: 200px;
}

/* Step wizard */
.step-indicator {
  transition: all 0.3s ease;
}

.step-indicator.active {
  background-color: #C53030;
  color: white;
}

.step-indicator.completed {
  background-color: #C53030;
  color: white;
}

/* Checkbox styled */
.job-board-checkbox:checked + label {
  border-color: #C53030;
  background-color: rgba(229, 62, 62, 0.05);
}

/* Scrollbar styling */
.custom-scrollbar::-webkit-scrollbar {
  width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* Calendar Grid */
.calendar-grid-month {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}

.calendar-cell {
  min-height: 80px;
  border-right: 1px solid #f3f4f6;
  border-bottom: 1px solid #f3f4f6;
  padding: 4px 6px;
  cursor: pointer;
  transition: background-color 0.15s;
}

.calendar-cell:hover {
  background-color: rgba(0, 0, 0, 0.02);
}

.calendar-cell:nth-child(7n) {
  border-right: none;
}

.calendar-cell.today {
  background-color: rgba(229, 62, 62, 0.05);
}

.calendar-cell.other-month {
  opacity: 0.4;
}

.calendar-grid-week {
  display: grid;
  grid-template-columns: 60px repeat(7, 1fr);
}

.calendar-hour-label {
  font-size: 10px;
  color: #9ca3af;
  text-align: right;
  padding-right: 8px;
}

.calendar-week-cell {
  border-right: 1px solid #f3f4f6;
  border-bottom: 1px solid #f3f4f6;
  min-height: 48px;
  cursor: pointer;
  transition: background-color 0.15s;
  position: relative;
}

.calendar-week-cell:hover {
  background-color: rgba(0, 0, 0, 0.02);
}

.calendar-week-cell:last-child {
  border-right: none;
}

/* Document Dropzone */
.doc-dropzone-active {
  border-color: #C53030 !important;
  background-color: rgba(229, 62, 62, 0.05) !important;
}

/* ==========================================
   UI/UX Improvements
   ========================================== */

/* Overlay Animations */
@keyframes overlay-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes overlay-fade-out {
  from { opacity: 1; }
  to { opacity: 0; }
}
@keyframes overlay-scale-in {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes overlay-scale-out {
  from { opacity: 1; transform: scale(1) translateY(0); }
  to { opacity: 0; transform: scale(0.95) translateY(10px); }
}

.overlay-enter {
  animation: overlay-fade-in 0.2s ease-out forwards;
}
.overlay-enter > div {
  animation: overlay-scale-in 0.2s ease-out forwards;
}
.overlay-exit {
  animation: overlay-fade-out 0.15s ease-in forwards;
}
.overlay-exit > div {
  animation: overlay-scale-out 0.15s ease-in forwards;
}

/* View Switch Animation */
.view-fade-in {
  animation: fade-in-up 0.3s ease-out forwards;
}

/* Keyboard Focus Visible */
button:focus-visible,
a:focus-visible,
[role="button"]:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px white, 0 0 0 4px #C53030;
  border-radius: inherit;
}
select:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px white, 0 0 0 4px #C53030;
}

/* Sticky Header Smooth Transition */
#header {
  transition: box-shadow 0.3s ease, background-color 0.3s ease;
}

/* Nav Dropdown */
.nav-dropdown-menu {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.nav-dropdown:hover .nav-dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.nav-dropdown-menu a:hover {
  background-color: #f9fafb;
}

/* Calendar Week View Mobile */
@media (max-width: 639px) {
  .calendar-grid-week {
    grid-template-columns: 40px repeat(7, 1fr);
  }
  .calendar-hour-label {
    font-size: 9px;
    padding-right: 4px;
  }
  .calendar-cell {
    min-height: 60px;
    padding: 2px 4px;
  }
}

/* Feedback Chat Widget */
@keyframes feedback-slide-up {
  from { opacity: 0; transform: translateY(20px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes feedback-slide-down {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(20px) scale(0.95); }
}

@keyframes feedback-pulse {
  0% { box-shadow: 0 0 0 0 rgba(229, 62, 62, 0.4); }
  70% { box-shadow: 0 0 0 12px rgba(229, 62, 62, 0); }
  100% { box-shadow: 0 0 0 0 rgba(229, 62, 62, 0); }
}

.feedback-chat-enter {
  animation: feedback-slide-up 0.25s ease-out forwards;
}

.feedback-chat-exit {
  animation: feedback-slide-down 0.2s ease-in forwards;
}

.feedback-bubble-pulse {
  animation: feedback-pulse 2.5s ease-out infinite;
}

.feedback-bubble-pulse:hover {
  animation: none;
}

/* Addon Collapse Animation */
.addon-collapse-content {
  transition: max-height 0.25s ease-out;
  overflow: hidden;
}

/* PLZ Toggle Active State */
#mp-plz-toggle.border-rocket {
  border-color: #C53030;
  background-color: rgba(229, 62, 62, 0.05);
}

#mp-plz-toggle.border-rocket i {
  color: #C53030;
}
