/* Helpie UI/UX Enhancements */

/* ===== SMOOTH SCROLLING ===== */
html {
    scroll-behavior: smooth;
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #e55a2b, #e8841a);
}

/* ===== FOCUS STYLES ===== */
*:focus {
    outline: 2px solid #ff6b35;
    outline-offset: 2px;
}

/* ===== SELECTION STYLES ===== */
::selection {
    background: rgba(255, 107, 53, 0.2);
    color: #2c3e50;
}

::-moz-selection {
    background: rgba(255, 107, 53, 0.2);
    color: #2c3e50;
}

/* ===== LOADING STATES ===== */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 1.5s infinite;
}

/* ===== GLASSMORPHISM ===== */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.glass-dark {
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== NEUMORPHISM ===== */
.neu-card {
    background: #f0f0f0;
    border-radius: 20px;
    box-shadow: 
        20px 20px 60px #d1d1d1,
        -20px -20px 60px #ffffff;
    transition: all 0.3s ease;
}

.neu-card:hover {
    box-shadow: 
        25px 25px 75px #d1d1d1,
        -25px -25px 75px #ffffff;
    transform: translateY(-2px);
}

.neu-button {
    background: #f0f0f0;
    border: none;
    border-radius: 15px;
    box-shadow: 
        8px 8px 16px #d1d1d1,
        -8px -8px 16px #ffffff;
    transition: all 0.3s ease;
}

.neu-button:hover {
    box-shadow: 
        4px 4px 8px #d1d1d1,
        -4px -4px 8px #ffffff;
}

.neu-button:active {
    box-shadow: 
        inset 4px 4px 8px #d1d1d1,
        inset -4px -4px 8px #ffffff;
}

/* ===== GRADIENT BORDERS ===== */
.gradient-border {
    position: relative;
    background: white;
    border-radius: 10px;
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 2px;
    background: linear-gradient(45deg, #ff6b35, #f7931e, #ff6b35);
    border-radius: inherit;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
}

/* ===== FLOATING ELEMENTS ===== */
.float {
    animation: float 3s ease-in-out infinite;
}

.float-delayed {
    animation: float 3s ease-in-out infinite;
    animation-delay: 1s;
}

/* ===== PULSE EFFECTS ===== */
.pulse-slow {
    animation: pulse 3s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.pulse-fast {
    animation: pulse 1s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* ===== HOVER LIFT ===== */
.hover-lift {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* ===== ROTATE ON HOVER ===== */
.hover-rotate {
    transition: transform 0.3s ease;
}

.hover-rotate:hover {
    transform: rotate(5deg);
}

/* ===== SCALE ON HOVER ===== */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

/* ===== GLOW EFFECTS ===== */
.glow-orange {
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.3);
}

.glow-orange:hover {
    box-shadow: 0 0 30px rgba(255, 107, 53, 0.5);
}

.glow-blue {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
}

.glow-blue:hover {
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.5);
}

/* ===== TEXT EFFECTS ===== */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.text-glow {
    text-shadow: 0 0 10px rgba(255, 107, 53, 0.5);
}

.text-gradient {
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ===== CARD HOVER EFFECTS ===== */
.card-3d {
    transform-style: preserve-3d;
    transition: transform 0.3s ease;
}

.card-3d:hover {
    transform: rotateY(5deg) rotateX(5deg);
}

.card-flip {
    perspective: 1000px;
}

.card-flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.card-flip:hover .card-flip-inner {
    transform: rotateY(180deg);
}

.card-flip-front, .card-flip-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
}

.card-flip-back {
    transform: rotateY(180deg);
}

/* ===== BUTTON EFFECTS ===== */
.btn-magnetic {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-magnetic:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.btn-liquid {
    position: relative;
    overflow: hidden;
}

.btn-liquid::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-liquid:hover::before {
    width: 300px;
    height: 300px;
}

/* ===== FORM ENHANCEMENTS ===== */
.form-floating {
    position: relative;
}

.form-floating input {
    padding-top: 1.5rem;
    padding-bottom: 0.5rem;
}

.form-floating label {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    padding: 1rem 0.75rem;
    pointer-events: none;
    border: 1px solid transparent;
    transform-origin: 0 0;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
}

.form-floating input:focus ~ label,
.form-floating input:not(:placeholder-shown) ~ label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}

/* ===== LOADING SPINNERS ===== */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.spinner-dots {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 80px;
}

.spinner-dots div {
    position: absolute;
    top: 33px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #ff6b35;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.spinner-dots div:nth-child(1) {
    left: 8px;
    animation: spinner-dots1 0.6s infinite;
}

.spinner-dots div:nth-child(2) {
    left: 8px;
    animation: spinner-dots2 0.6s infinite;
}

.spinner-dots div:nth-child(3) {
    left: 32px;
    animation: spinner-dots2 0.6s infinite;
}

.spinner-dots div:nth-child(4) {
    left: 56px;
    animation: spinner-dots3 0.6s infinite;
}

@keyframes spinner-dots1 {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

@keyframes spinner-dots3 {
    0% { transform: scale(1); }
    100% { transform: scale(0); }
}

@keyframes spinner-dots2 {
    0% { transform: translate(0, 0); }
    100% { transform: translate(24px, 0); }
}

/* ===== RESPONSIVE ENHANCEMENTS ===== */
@media (max-width: 768px) {
    .hover-lift:hover {
        transform: translateY(-4px);
    }
    
    .hover-scale:hover {
        transform: scale(1.02);
    }
    
    .card-3d:hover {
        transform: rotateY(2deg) rotateX(2deg);
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== DARK MODE SUPPORT ===== */
@media (prefers-color-scheme: dark) {
    .neu-card {
        background: #2d2d2d;
        box-shadow: 
            20px 20px 60px #1a1a1a,
            -20px -20px 60px #404040;
    }
    
    .neu-button {
        background: #2d2d2d;
        box-shadow: 
            8px 8px 16px #1a1a1a,
            -8px -8px 16px #404040;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}

.smooth-scroll {
    scroll-behavior: smooth;
}

/* ===== CUSTOM PROPERTIES ===== */
:root {
    --primary-color: #ff6b35;
    --secondary-color: #f7931e;
    --accent-color: #4f46e5;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --border-radius: 0.5rem;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
