/**
 * Custom Overrides
 * Cricketid App Platform
 */

/* ========================================
   Custom Scrollbar
   ======================================== */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--tiger-orange);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--tiger-deep);
}

/* Firefox scrollbar */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--tiger-orange) var(--light-gray);
}

/* ========================================
   Text Selection
   ======================================== */
::selection {
    background: var(--tiger-orange);
    color: var(--text-light);
}

::-moz-selection {
    background: var(--tiger-orange);
    color: var(--text-light);
}

/* ========================================
   Focus States
   ======================================== */
:focus-visible {
    outline: 3px solid var(--tiger-orange);
    outline-offset: 2px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 3px solid var(--tiger-orange);
    outline-offset: 2px;
}

/* ========================================
   Custom Animations
   ======================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-20px);
    }
    60% {
        transform: translateY(-10px);
    }
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.6s ease forwards;
}

.animate-slideIn {
    animation: slideIn 0.5s ease forwards;
}

/* Stagger animation delays */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }

/* ========================================
   Icon Styling
   ======================================== */
.icon-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    background: linear-gradient(135deg, rgba(255, 107, 0, 0.1), rgba(255, 107, 0, 0.2));
    color: var(--tiger-orange);
    margin: 0 auto var(--space-md);
}

.icon-lg {
    width: 80px;
    height: 80px;
    font-size: 32px;
}

/* ========================================
   Feature Box Variations
   ======================================== */
.feature-box {
    text-align: center;
    padding: var(--space-xl);
}

.feature-box-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--tiger-orange), var(--tiger-deep));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-lg);
    color: var(--text-light);
    font-size: 32px;
    box-shadow: var(--shadow-orange);
}

.feature-box-title {
    font-size: var(--text-xl);
    font-weight: 600;
    margin-bottom: var(--space-md);
}

.feature-box-desc {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ========================================
   Trust Badges
   ======================================== */
.trust-badges {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-xl);
    flex-wrap: wrap;
    padding: var(--space-lg);
    background: var(--light-gray);
    border-radius: var(--radius-lg);
}

.trust-badge {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
}

.trust-badge i {
    font-size: 20px;
    color: var(--success);
}

/* ========================================
   Image Overlay
   ======================================== */
.image-overlay {
    position: relative;
    overflow: hidden;
}

.image-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, transparent 50%);
    z-index: 1;
}

.image-overlay img {
    transition: transform 0.5s ease;
}

.image-overlay:hover img {
    transform: scale(1.05);
}

/* ========================================
   Gradient Text
   ======================================== */
.gradient-text-orange {
    background: linear-gradient(135deg, var(--tiger-orange), var(--tiger-deep));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gradient-text-dark {
    background: linear-gradient(135deg, #1A1A2E, #16213E);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========================================
   Custom Button Styles
   ======================================== */
.btn-glow {
    position: relative;
    overflow: hidden;
}

.btn-glow::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 70%
    );
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.btn-glow:hover::before {
    transform: translateX(100%);
}

.btn-shadow {
    box-shadow: 0 10px 40px rgba(255, 107, 0, 0.4);
}

.btn-shadow:hover {
    box-shadow: 0 15px 50px rgba(255, 107, 0, 0.5);
}

/* ========================================
   Custom Card Styles
   ======================================== */
.card-gradient {
    background: linear-gradient(135deg, var(--tiger-orange), var(--tiger-deep));
    color: var(--text-light);
}

.card-gradient .card-title,
.card-gradient .card-body {
    color: var(--text-light);
}

.card-elevated {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.card-border {
    border: 2px solid var(--border-gray);
    box-shadow: none;
}

.card-border:hover {
    border-color: var(--tiger-orange);
}

/* ========================================
   Decorative Elements
   ======================================== */
.decorative-dots {
    position: absolute;
    width: 100px;
    height: 100px;
    background-image: radial-gradient(var(--tiger-orange) 2px, transparent 2px);
    background-size: 10px 10px;
    opacity: 0.3;
}

.decorative-circle {
    position: absolute;
    border-radius: 50%;
    border: 2px solid var(--tiger-orange);
    opacity: 0.2;
}

/* ========================================
   Divider Lines
   ======================================== */
.divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--border-gray), transparent);
    margin: var(--space-2xl) 0;
}

.divider-orange {
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--tiger-orange), transparent);
    width: 100px;
    margin: var(--space-lg) auto;
}

/* ========================================
   Tag/Pill Styles
   ======================================== */
.tag {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 600;
    background: var(--light-gray);
    color: var(--text-secondary);
}

.tag-primary {
    background: rgba(255, 107, 0, 0.1);
    color: var(--tiger-orange);
}

.tag-success {
    background: rgba(76, 175, 80, 0.1);
    color: var(--success);
}

.tag-warning {
    background: rgba(255, 193, 7, 0.1);
    color: var(--warning);
}

.tag-error {
    background: rgba(244, 67, 54, 0.1);
    color: var(--error);
}

/* ========================================
   Badge Notification
   ======================================== */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    background: var(--error);
    color: var(--text-light);
}

.badge-primary {
    background: var(--tiger-orange);
}

.badge-success {
    background: var(--success);
}

/* ========================================
   Custom Checkbox/Radio
   ======================================== */
.custom-checkbox,
.custom-radio {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
}

.custom-checkbox input,
.custom-radio input {
    display: none;
}

.custom-checkbox .checkmark,
.custom-radio .radio-mark {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-gray);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.custom-radio .radio-mark {
    border-radius: 50%;
}

.custom-checkbox input:checked + .checkmark,
.custom-radio input:checked + .radio-mark {
    background: var(--tiger-orange);
    border-color: var(--tiger-orange);
    color: var(--text-light);
}

/* ========================================
   Rating Stars
   ======================================== */
.rating {
    display: flex;
    gap: 2px;
    color: var(--tiger-yellow);
}

.rating i {
    font-size: 16px;
}

.rating-empty {
    color: var(--border-gray);
}

/* ========================================
   Table Custom Styles
   ======================================== */
.table-responsive {
    overflow-x: auto;
}

.table-custom {
    width: 100%;
    border-collapse: collapse;
}

.table-custom th,
.table-custom td {
    padding: var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--border-gray);
}

.table-custom th {
    background: var(--light-gray);
    font-weight: 600;
    color: var(--text-primary);
}

.table-custom tbody tr:hover {
    background: rgba(255, 107, 0, 0.03);
}

/* ========================================
   Video Container
   ======================================== */
.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--dark-bg);
}

.video-container iframe,
.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* ========================================
   Background Patterns
   ======================================== */
.bg-pattern-dots {
    background-image: radial-gradient(var(--border-gray) 1px, transparent 1px);
    background-size: 20px 20px;
}

.bg-pattern-lines {
    background-image: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 20px,
        var(--border-gray) 20px,
        var(--border-gray) 21px
    );
}

/* ========================================
   Loading Skeleton
   ======================================== */
.skeleton {
    background: linear-gradient(90deg, var(--light-gray) 25%, #e8e8e8 50%, var(--light-gray) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 16px;
    margin-bottom: var(--space-sm);
}

.skeleton-title {
    height: 24px;
    width: 60%;
    margin-bottom: var(--space-md);
}

.skeleton-image {
    height: 200px;
    width: 100%;
}

/* ========================================
   Notification Toast
   ======================================== */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: var(--space-md) var(--space-xl);
    border-radius: var(--radius-md);
    color: var(--text-light);
    font-weight: 500;
    z-index: 10000;
    opacity: 0;
    transition: all 0.3s ease;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast-success {
    background: var(--success);
}

.toast-error {
    background: var(--error);
}

.toast-warning {
    background: var(--warning);
    color: #000;
}

.toast-info {
    background: var(--info);
}