/* Antigravity — Custom Styles */

/* Animations */
@keyframes slide-in {
    from { transform: translateX(100%); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}
@keyframes fade-in {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse-soft {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.animate-slide-in { animation: slide-in 0.4s ease-out; }
.animate-fade-in  { animation: fade-in 0.3s ease-out; }
.animate-pulse-soft { animation: pulse-soft 2s ease-in-out infinite; }

/* Skeleton loader */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* Product card hover */
.product-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px -12px rgba(0,0,0,0.15);
}

/* Color swatch */
.color-swatch {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}
.color-swatch:hover {
    transform: scale(1.15);
}
.color-swatch.selected {
    border-color: #4f46e5;
    box-shadow: 0 0 0 2px #c7d2fe;
}
.color-swatch.out-of-stock {
    opacity: 0.3;
    cursor: not-allowed;
}
.color-swatch .check {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
}
.color-swatch.selected .check {
    display: block;
}

/* Size chip */
.size-chip {
    min-width: 40px;
    padding: 6px 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}
.size-chip:hover:not(.out-of-stock) {
    border-color: #4f46e5;
    color: #4f46e5;
}
.size-chip.selected {
    background: #4f46e5;
    border-color: #4f46e5;
    color: white;
}
.size-chip.out-of-stock {
    opacity: 0.3;
    cursor: not-allowed;
    text-decoration: line-through;
}

/* Pill chip (variant selector) */
.pill-chip {
    padding: 6px 16px;
    border: 1.5px solid #e5e7eb;
    border-radius: 9999px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.pill-chip:hover:not(.out-of-stock) {
    border-color: #4f46e5;
    background: #eef2ff;
}
.pill-chip.selected {
    background: #4f46e5;
    border-color: #4f46e5;
    color: white;
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Glass effect */
.glass {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Priority borders for tickets */
.priority-urgent { border-left: 4px solid #ef4444; }
.priority-high   { border-left: 4px solid #f97316; }
.priority-medium { border-left: 4px solid #3b82f6; }
.priority-low    { border-left: 4px solid #6b7280; }

/* Internal note styling */
.internal-note {
    background: #fef9c3;
    border-left: 3px solid #eab308;
}

/* Image aspect ratio */
.aspect-product {
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

/* Custom range input */
input[type="range"] {
    -webkit-appearance: none;
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    outline: none;
}
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #4f46e5;
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Button hover effect */
.btn-primary {
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: white;
    transition: all 0.3s;
}
.btn-primary:hover {
    background: linear-gradient(135deg, #4338ca, #4f46e5);
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.3);
    transform: translateY(-1px);
}

/* Quantity stepper */
.qty-stepper {
    display: flex;
    align-items: center;
    border: 1.5px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
}
.qty-stepper button {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9fafb;
    border: none;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.2s;
}
.qty-stepper button:hover {
    background: #e5e7eb;
}
.qty-stepper input {
    width: 48px;
    height: 36px;
    text-align: center;
    border: none;
    border-left: 1px solid #e5e7eb;
    border-right: 1px solid #e5e7eb;
    font-weight: 600;
    font-size: 14px;
    outline: none;
}

/* Responsive tables */
@media (max-width: 640px) {
    .responsive-table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}
