/* ============================================================================
   PREMIUM ANIMATIONS & INTERACTIONS
   ============================================================================
   Ultra-smooth, hardware-accelerated animations for premium feel
   ============================================================================ */

/* Hardware acceleration for all animated elements */
.revolutionary-card,
.hero-title,
.hero-centerpiece,
#cursor-ring,
#cursor-halo,
.nav-dropdown,
.mobile-menu,
.footer-watermark {
  will-change: transform, opacity;
  transform: translateZ(0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

/* Ultra-smooth transitions with premium easing */
.revolutionary-card {
  transition: 
    transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Premium hover lift with smooth shadow */
.revolutionary-card:hover {
  transform: translateY(-8px) translateZ(0) scale(1.01);
  box-shadow: 
    0 80px 160px rgba(0, 0, 0, 0.95),
    0 0 120px rgba(212, 186, 137, 0.2),
    inset 0 1px 2px rgba(255, 255, 255, 0.15);
}

/* Smooth glow effect on hover */
.revolutionary-card::before {
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.revolutionary-card:hover::before {
  opacity: 1;
  animation: pulseGlow 3s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%, 100% { opacity: 0.8; }
  50% { opacity: 1; }
}

/* ══════════════════════════════════════════════════════════════════════════
   BUTTON HIERARCHY SYSTEM - Premium SaaS Button States
   ══════════════════════════════════════════════════════════════════════════ */

/* Base Button Styles - All 5 States */
.btn-cv,
.btn-primary,
.submit-btn,
.action-card,
.recruiter-btn,
.quick-select-btn,
.pill-label,
.glossary-btn,
.mobile-nav-link,
.nav-item > a {
  transition:
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    filter 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
  position: relative;
  overflow: hidden;
}

/* State 1: Default (Base State) */
.btn-cv,
.btn-primary,
.submit-btn,
.recruiter-btn {
  cursor: pointer;
}

/* State 2: Hover */
.btn-cv:hover,
.btn-primary:hover,
.submit-btn:hover,
.recruiter-btn:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow:
    0 20px 50px rgba(212, 186, 137, 0.35),
    0 0 40px rgba(212, 186, 137, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  filter: brightness(1.08);
}

.action-card:hover {
  transform: translateY(-6px) translateZ(0);
  box-shadow:
    0 25px 60px rgba(212, 186, 137, 0.25),
    0 0 50px rgba(212, 186, 137, 0.15);
}

.action-card:hover .ac-icon {
  transform: scale(1.1) rotate(5deg);
  color: var(--accent-primary);
}

/* State 3: Focus (Accessibility) */
.btn-cv:focus-visible,
.btn-primary:focus-visible,
.submit-btn:focus-visible,
.recruiter-btn:focus-visible,
.action-card:focus-visible,
.quick-select-btn:focus-visible,
.pill-label:focus-visible,
.glossary-btn:focus-visible,
.mobile-nav-link:focus-visible,
.nav-item > a:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(212, 186, 137, 0.4),
    0 20px 50px rgba(212, 186, 137, 0.35);
}

/* State 4: Active (Pressed) */
.btn-cv:active,
.btn-primary:active,
.submit-btn:active,
.recruiter-btn:active {
  transform: translateY(-2px) scale(1.01);
  transition-duration: 0.1s;
  filter: brightness(0.95);
}

.action-card:active {
  transform: translateY(-3px) translateZ(0);
  transition-duration: 0.1s;
}

.quick-select-btn:active,
.pill-label:active,
.glossary-btn:active,
.mobile-nav-link:active,
.nav-item > a:active {
  transform: translateY(0) scale(0.98);
  transition-duration: 0.1s;
}

/* State 5: Disabled */
.btn-cv:disabled,
.btn-primary:disabled,
.submit-btn:disabled,
.recruiter-btn:disabled,
.action-card.disabled,
.quick-select-btn:disabled,
.pill-label.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  filter: none;
  pointer-events: none;
}

/* Premium button interactions */

.btn-cv:hover,
.submit-btn:hover,
.recruiter-btn:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow:
    0 20px 50px rgba(212, 186, 137, 0.35),
    0 0 40px rgba(212, 186, 137, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  filter: brightness(1.08);
}

.btn-cv:active,
.submit-btn:active,
.recruiter-btn:active {
  transform: translateY(-2px) scale(1.01);
  transition-duration: 0.1s;
  filter: brightness(0.95);
}

/* Focus-visible states for accessibility */
.btn-cv:focus-visible,
.submit-btn:focus-visible,
.recruiter-btn:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(212, 186, 137, 0.4),
    0 20px 50px rgba(212, 186, 137, 0.35);
}

/* Disabled state */
.btn-cv:disabled,
.submit-btn:disabled,
.recruiter-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  filter: none;
}

/* Smooth action card hover */
.action-card {
  transition: 
    transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.action-card:hover {
  transform: translateY(-6px) translateZ(0);
  box-shadow:
    0 25px 60px rgba(212, 186, 137, 0.25),
    0 0 50px rgba(212, 186, 137, 0.15);
}

.action-card:hover .ac-icon {
  transform: scale(1.1) rotate(5deg);
  color: var(--accent-primary);
}

/* Quick Select Buttons Enhancement */
.quick-select-btn {
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.quick-select-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(212, 186, 137, 0.15) 0%,
    transparent 50%
  );
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.quick-select-btn:hover {
  border-color: var(--accent-primary);
  color: var(--text);
  background: rgba(212, 186, 137, 0.1);
  box-shadow: 0 4px 20px rgba(212, 186, 137, 0.15);
  transform: translateY(-2px);
}

.quick-select-btn:hover::before {
  opacity: 1;
}

.quick-select-btn:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}

.quick-select-btn:active {
  transform: translateY(0);
  background: rgba(212, 186, 137, 0.15);
}

/* Submit Button Icon Animation */
.submit-btn:hover .btn-icon {
  transform: translateX(4px) translateY(-4px);
  filter: drop-shadow(0 4px 12px rgba(212, 186, 137, 0.8));
}

/* Premium cursor effects */
#cursor-ring {
  transition: 
    width 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

body.is-hovering #cursor-ring {
  width: 64px;
  height: 64px;
  border-width: 2px;
  border-color: rgba(212, 186, 137, 1);
  background: radial-gradient(circle, rgba(212, 186, 137, 0.1), transparent 70%);
  box-shadow: 
    0 0 30px rgba(212, 186, 137, 0.3),
    inset 0 0 20px rgba(212, 186, 137, 0.1);
}

#cursor-halo {
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body.is-hovering #cursor-halo {
  opacity: 0.25;
  filter: blur(40px);
}

/* Smooth reveal animations */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  filter: blur(10px);
  transition: 
    opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
    transform 1.2s cubic-bezier(0.16, 1, 0.3, 1),
    filter 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Staggered delays for premium sequence */
.reveal.delay-1 { transition-delay: 0.1s; }
.reveal.delay-2 { transition-delay: 0.2s; }

/* Premium nav dropdown */
.nav-dropdown {
  transition: 
    opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-item:hover .nav-dropdown {
  animation: dropdownSlide 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes dropdownSlide {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(20px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

/* Smooth dropdown links */
.dropdown-link {
  transition: 
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.dropdown-link:hover {
  transform: translateX(6px);
}

/* Premium footer watermark */
.footer-watermark {
  transition: 
    opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
    filter 1s cubic-bezier(0.16, 1, 0.3, 1),
    transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-watermark-link:hover .footer-watermark {
  filter: drop-shadow(0 0 100px rgba(212, 186, 137, 0.35));
  transform: scale(1.02);
}

/* Smooth signature card */
.sig-card {
  transition: 
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.sig-card:hover {
  transform: translateY(-12px) scale(1.01);
  box-shadow: 
    0 100px 200px rgba(0, 0, 0, 0.95),
    0 0 100px rgba(212, 186, 137, 0.15),
    inset 0 1px 2px rgba(255, 255, 255, 0.1);
}

/* Premium form inputs */
.form-input,
.form-textarea {
  transition: 
    border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.form-input:focus,
.form-textarea:focus {
  transform: translateY(-2px);
  box-shadow: 
    0 10px 30px rgba(212, 186, 137, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

/* Smooth pill selection */
.pill-label {
  transition: 
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.pill-label:hover {
  transform: translateY(-2px);
}

.pill-radio:checked + .pill-label {
  animation: pillSelect 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes pillSelect {
  0% {
    transform: scale(0.95);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

/* Premium glossary button */
.glossary-btn {
  transition: 
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.glossary-btn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

/* ══════════════════════════════════════════════════════════════════════════
   GLOSSARY TOOLTIP STYLING
   ══════════════════════════════════════════════════════════════════════════ */

body.glossary-active .glossary-btn {
  animation: glossaryPulse 2s ease-in-out infinite;
}

@keyframes glossaryPulse {
  0%, 100% {
    box-shadow: 0 0 20px rgba(125, 211, 252, 0.1);
  }
  50% {
    box-shadow: 0 0 40px rgba(125, 211, 252, 0.3);
  }
}

/* Glossary Tooltip */
#glossary-tooltip {
  position: fixed;
  z-index: 9999;
  padding: 12px 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-accent);
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text);
  pointer-events: none;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  backdrop-filter: blur(12px);
  box-shadow:
    0 10px 40px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(125, 211, 252, 0.1);
  max-width: 280px;
}

#glossary-tooltip.show {
  opacity: 1;
  transform: translateY(0);
}

#glossary-tooltip strong {
  display: block;
  color: var(--accent-glossary);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

/* Glossary Term Styling */
.glossary-term {
  color: var(--accent-glossary);
  cursor: help;
  border-bottom: 1px dotted var(--accent-glossary);
  transition: all 0.3s ease;
}

body.glossary-active .glossary-term {
  cursor: pointer;
  border-bottom: 1px solid var(--accent-glossary);
}

body.glossary-active .glossary-term:hover {
  color: var(--text);
  background: rgba(125, 211, 252, 0.1);
  padding: 0 4px;
  border-radius: 3px;
}

/* Smooth mobile menu */
.mobile-menu {
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-nav-link {
  transition: 
    color 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-nav-link:hover {
  transform: translateX(8px);
}

/* Premium page progress */
.page-progress__bar {
  transition: width 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* High refresh rate optimization */
@media (min-resolution: 120dpi) {
  .revolutionary-card,
  .btn-cv,
  .submit-btn,
  #cursor-ring {
    transition-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
  }
}

/* ══════════════════════════════════════════════════════════════════════
   GLOSSARY SYSTEM - Term Highlighting & Tooltips
   ════════════════════════════════════════════════════════════════════ */

/* Glossary Term Highlighting */
.glossary-term {
  position: relative;
  display: inline;
  color: var(--accent-glossary);
  border-bottom: 2px dotted var(--accent-glossary);
  cursor: help;
  transition: all 0.2s ease;
  padding: 0 2px;
  border-radius: 3px;
}

body.glossary-active .glossary-term {
  background: rgba(125, 211, 252, 0.1);
  border-bottom: 2px solid var(--accent-glossary);
  cursor: pointer;
}

.glossary-term:hover {
  background: rgba(125, 211, 252, 0.15);
  transform: translateY(-1px);
}

/* Glossary Tooltip Card */
.glossary-tooltip {
  position: fixed;
  z-index: 9999;
  max-width: 320px;
  padding: 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-accent);
  border-radius: 10px;
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(125, 211, 252, 0.15);
  pointer-events: none;
  opacity: 0;
  transform: translateY(8px) scale(0.95);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.glossary-tooltip.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.glossary-tooltip-term {
  font-weight: 700;
  font-size: 13px;
  color: var(--accent-glossary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.glossary-tooltip-category {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 10px;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  background: var(--accent-primary);
  color: var(--bg);
  border-radius: 100px;
}

.glossary-tooltip-definition {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
}

/* Glossary Panel */
.glossary-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 400px;
  height: 100vh;
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.3);
  z-index: 9998;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.glossary-panel.open {
  transform: translateX(0);
}

.glossary-panel-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.glossary-panel-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 12px;
}

.glossary-term-count {
  font-size: 11px;
  color: var(--text-soft);
  font-family: var(--mono);
  background: var(--bg-surface);
  padding: 4px 12px;
  border-radius: 100px;
}

.glossary-panel-close {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.glossary-panel-close:hover {
  background: var(--bg-surface);
  color: var(--text);
  border-color: var(--border-accent);
}

.glossary-panel-search {
  padding: 16px 24px 20px;
  border-bottom: 1px solid var(--border);
}

.glossary-search-input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 14px;
  transition: all 0.3s ease;
}

.glossary-search-input:focus {
  outline: none;
  border-color: var(--accent-glossary);
  box-shadow: 0 0 0 3px rgba(125, 211, 252, 0.2);
}

.glossary-panel-content {
  flex: 1;
  overflow-y: auto;
  padding: 0 24px 24px;
}

.glossary-panel-content::-webkit-scrollbar {
  width: 6px;
}

.glossary-panel-content::-webkit-scrollbar-track {
  background: var(--bg-surface);
}

.glossary-panel-content::-webkit-scrollbar-thumb {
  background: var(--border-accent);
  border-radius: 3px;
}

.glossary-letter-divider {
  padding: 16px 0 8px;
  border-bottom: 1px solid var(--border);
}

.glossary-letter {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-primary);
  font-family: var(--mono);
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.glossary-entry {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
  transition: background 0.2s ease;
}

.glossary-entry:hover {
  background: rgba(125, 211, 252, 0.05);
}

.glossary-entry-term {
  font-weight: 700;
  font-size: 14px;
  color: var(--accent-glossary);
  margin-bottom: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.glossary-entry-term:hover {
  color: var(--text);
}

.glossary-entry-definition {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-soft);
  margin-bottom: 4px;
}

.glossary-entry-example {
  font-size: 12px;
  font-style: italic;
  color: var(--text-dim);
}

/* Glossary Mode Indicator Banner */
.glossary-mode-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--accent-glossary) 0%, var(--accent-primary) 100%);
  color: var(--bg);
  z-index: 9997;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  transform: translateY(-100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 20px rgba(125, 211, 252, 0.3);
}

body.glossary-mode-active .glossary-mode-banner {
  transform: translateY(0);
}

.glossary-mode-text {
  font-size: 13px;
  font-weight: 600;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.glossary-mode-dismiss {
  padding: 6px 16px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  color: var(--text);
  font-size: 11px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.glossary-mode-dismiss:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
}

/* Glossary Button Active State */
body.glossary-active .glossary-btn {
  background: rgba(125, 211, 252, 0.15);
  border-color: var(--accent-glossary);
  color: var(--accent-glossary);
}

body.glossary-active .glossary-btn .gl-icon {
  background: var(--accent-glossary);
  border-color: var(--accent-glossary);
  color: var(--bg);
}

body.glossary-active .glossary-btn .gl-text {
  color: var(--accent-glossary);
}

body.glossary-active .glossary-btn .gl-dot {
  background: var(--bg);
}
