/**
* INTERACTIVE ELEMENTS
* Enhanced buttons, cards, and interactive components
* 2025/2026 Premium Interactive Design
*/

/* ============================================
  ENHANCED BUTTONS
  ============================================ */
.btn-premium {
    position: relative;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 15px rgba(102, 126, 234, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

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

.btn-premium:hover::before {
    width: 300px;
    height: 300px;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-premium:active {
    transform: translateY(0);
}

.btn-premium-outline {
    background: transparent;
    border: 2px solid #667eea;
    color: #667eea;
    box-shadow: none;
}

.btn-premium-outline:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

/* ============================================
  ENHANCED CARDS
  ============================================ */
.card-premium {
    position: relative;
    background: var(--background-color);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.08),
        0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.card-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.card-premium:hover::before {
    transform: scaleX(1);
}

.card-premium:hover {
    transform: translateY(-8px);
    box-shadow: 
        0 12px 40px rgba(102, 126, 234, 0.15),
        0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: rgba(102, 126, 234, 0.3);
}

body.dark-mode .card-premium {
    background: var(--dark-background-color);
    border-color: rgba(102, 126, 234, 0.2);
}

/* ============================================
  FLOATING ACTION BUTTONS
  ============================================ */
.fab-premium {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.4),
        0 0 0 0 rgba(102, 126, 234, 0.5);
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    animation: pulse-fab 2s infinite;
}

@keyframes pulse-fab {
    0%, 100% {
        box-shadow: 
            0 8px 25px rgba(102, 126, 234, 0.4),
            0 0 0 0 rgba(102, 126, 234, 0.5);
    }
    50% {
        box-shadow: 
            0 8px 25px rgba(102, 126, 234, 0.6),
            0 0 0 10px rgba(102, 126, 234, 0);
    }
}

.fab-premium:hover {
    transform: scale(1.1) rotate(90deg);
    box-shadow: 
        0 12px 35px rgba(102, 126, 234, 0.6),
        0 0 0 0 rgba(102, 126, 234, 0.5);
}

/* ============================================
  ENHANCED INPUT FIELDS
  ============================================ */
.input-premium {
    position: relative;
    width: 100%;
    margin-bottom: 20px;
}

.input-premium input,
.input-premium textarea {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 1rem;
    background: var(--background-color);
    color: var(--text-color);
    transition: all 0.3s ease;
    font-family: inherit;
}

.input-premium input:focus,
.input-premium textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
}

.input-premium label {
    position: absolute;
    left: 20px;
    top: 16px;
    color: var(--text-color-light);
    pointer-events: none;
    transition: all 0.3s ease;
    background: var(--background-color);
    padding: 0 8px;
}

.input-premium input:focus + label,
.input-premium input:not(:placeholder-shown) + label,
.input-premium textarea:focus + label,
.input-premium textarea:not(:placeholder-shown) + label {
    top: -10px;
    left: 12px;
    font-size: 0.85rem;
    color: #667eea;
    font-weight: 600;
}

/* ============================================
  LOADING ANIMATIONS
  ============================================ */
.loader-premium {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(102, 126, 234, 0.2);
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-dots {
    display: inline-flex;
    gap: 8px;
}

.loader-dots span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #667eea;
    animation: bounce 1.4s infinite ease-in-out;
}

.loader-dots span:nth-child(1) { animation-delay: -0.32s; }
.loader-dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes bounce {
    0%, 80%, 100% {
        transform: scale(0);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ============================================
  PROGRESS BARS
  ============================================ */
.progress-bar-premium {
    width: 100%;
    height: 8px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.progress-bar-premium::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    animation: progress-fill 2s ease-out;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
}

@keyframes progress-fill {
    from {
        width: 0%;
    }
}

/* ============================================
  TOOLTIPS
  ============================================ */
.tooltip-premium {
    position: relative;
    display: inline-block;
}

.tooltip-premium::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    border-radius: 8px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    margin-bottom: 8px;
}

.tooltip-premium:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ============================================
  BADGES & TAGS
  ============================================ */
.badge-premium {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    color: #667eea;
    border: 1px solid rgba(102, 126, 234, 0.2);
    transition: all 0.3s ease;
}

.badge-premium:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

/* ============================================
  SWITCH TOGGLES
  ============================================ */
.switch-premium {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}

.switch-premium input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-premium-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 28px;
}

.switch-premium-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.switch-premium input:checked + .switch-premium-slider {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.switch-premium input:checked + .switch-premium-slider:before {
    transform: translateX(22px);
}

/* ============================================
  RESPONSIVE DESIGN
  ============================================ */
@media (max-width: 768px) {
    .fab-premium {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
        font-size: 1.2rem;
    }

    .btn-premium {
        padding: 12px 24px;
        font-size: 0.9rem;
    }

    .card-premium {
        padding: 20px;
    }
}

/* ============================================
  ACCESSIBILITY
  ============================================ */
@media (prefers-reduced-motion: reduce) {
    .btn-premium,
    .card-premium,
    .fab-premium,
    .loader-premium,
    .loader-dots span {
        animation: none;
        transition: none;
    }

    .btn-premium:hover,
    .card-premium:hover {
        transform: none;
    }
}

