/**
 * 12BET Theme - Additional Styles
 * Custom styles for enhanced functionality
 */

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

@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

/* Animation Classes */
.animate-fade-in {
    animation: fadeIn 0.6s ease-out;
}

.animate-slide-in {
    animation: slideIn 0.3s ease-out;
}

/* Enhanced Button Effects */
.hero-btn {
    position: relative;
    overflow: hidden;
}

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

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

/* Card Hover Effects */
.content-card {
    position: relative;
    overflow: hidden;
}

.content-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s;
}

.content-card:hover::after {
    left: 100%;
}

/* Loading Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Menu Enhancements */
@media (max-width: 768px) {
    .nav-mobile {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-out;
    }

    .nav-mobile.active {
        max-height: 500px;
    }

    .nav-mobile ul li {
        opacity: 0;
        transform: translateX(-20px);
        transition: opacity 0.3s, transform 0.3s;
    }

    .nav-mobile.active ul li {
        opacity: 1;
        transform: translateX(0);
    }

    .nav-mobile.active ul li:nth-child(1) { transition-delay: 0.1s; }
    .nav-mobile.active ul li:nth-child(2) { transition-delay: 0.15s; }
    .nav-mobile.active ul li:nth-child(3) { transition-delay: 0.2s; }
    .nav-mobile.active ul li:nth-child(4) { transition-delay: 0.25s; }
    .nav-mobile.active ul li:nth-child(5) { transition-delay: 0.3s; }
    .nav-mobile.active ul li:nth-child(6) { transition-delay: 0.35s; }
}

/* Form Styles */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s, box-shadow 0.3s;
    font-family: inherit;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(211, 47, 47, 0.1);
}

/* Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

table th,
table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

table th {
    background: var(--light-bg);
    font-weight: 600;
    color: var(--secondary-color);
}

table tr:hover {
    background: var(--light-bg);
}

/* Blockquote Styles */
blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 20px 30px;
    margin: 30px 0;
    background: var(--light-bg);
    font-style: italic;
    border-radius: 0 6px 6px 0;
}

blockquote cite {
    display: block;
    margin-top: 10px;
    font-size: 14px;
    color: #666;
}

/* Code Styles */
code {
    background: var(--light-bg);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: var(--primary-color);
}

pre {
    background: var(--secondary-color);
    color: var(--white);
    padding: 20px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 20px 0;
}

pre code {
    background: none;
    padding: 0;
    color: inherit;
}

/* Alert Boxes */
.alert {
    padding: 15px 20px;
    border-radius: 6px;
    margin: 20px 0;
    border-left: 4px solid;
}

.alert-info {
    background: #e3f2fd;
    border-color: #2196f3;
    color: #1976d2;
}

.alert-success {
    background: #e8f5e9;
    border-color: #4caf50;
    color: #388e3c;
}

.alert-warning {
    background: #fff3e0;
    border-color: #ff9800;
    color: #f57c00;
}

.alert-error {
    background: #ffebee;
    border-color: #f44336;
    color: #d32f2f;
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    height: 30px;
    background: var(--light-bg);
    border-radius: 15px;
    overflow: hidden;
    margin: 20px 0;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transition: width 0.5s ease;
    border-radius: 15px 0 0 15px;
}

/* Tooltip */
.tooltip {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.tooltip .tooltip-text {
    visibility: hidden;
    width: 200px;
    background-color: var(--secondary-color);
    color: var(--white);
    text-align: center;
    border-radius: 6px;
    padding: 8px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 14px;
}

.tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Badge */
.badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 12px;
    background: var(--primary-color);
    color: var(--white);
}

.badge-success {
    background: #4caf50;
}

.badge-warning {
    background: #ff9800;
}

.badge-info {
    background: #2196f3;
}

/* Responsive Video */
.video-container {
    position: relative;
    padding-bottom: 56.25%;
    padding-top: 30px;
    height: 0;
    overflow: hidden;
    margin: 20px 0;
}

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

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    z-index: 999;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background: var(--accent-color);
    transform: translateY(-5px);
}

/* Print Styles Enhancement */
@media print {
    .no-print {
        display: none !important;
    }

    body {
        font-size: 12pt;
        line-height: 1.5;
    }

    a {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }
}

/* Accessibility */
.skip-link {
    position: absolute;
    left: -9999px;
    top: 2.5em;
    z-index: 999999;
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 1em;
    text-decoration: none;
}

.skip-link:focus {
    left: 0;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #ff0000;
        --secondary-color: #000000;
        --text-color: #000000;
        --border-color: #000000;
    }
}

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