/* Non-Critical CSS for OctoPut.com */
/* This file contains styles that are not needed for above-the-fold content */

/* Advanced animations and transitions */
@keyframes slideInLeft {
    from { transform: translateX(-100px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideInRight {
    from { transform: translateX(100px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes bounceIn {
    0%, 20%, 40%, 60%, 80% {
        animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);
    }
    0% { opacity: 0; transform: scale3d(.3, .3, .3); }
    20% { transform: scale3d(1.1, 1.1, 1.1); }
    40% { transform: scale3d(.9, .9, .9); }
    60% { opacity: 1; transform: scale3d(1.03, 1.03, 1.03); }
    80% { transform: scale3d(.97, .97, .97); }
    100% { opacity: 1; transform: scale3d(1, 1, 1); }
}

@keyframes rotateIn {
    from { opacity: 0; transform: rotate3d(0, 0, 1, -200deg); }
    to { opacity: 1; transform: translate3d(0, 0, 0); }
}

@keyframes zoomIn {
    from { opacity: 0; transform: scale3d(.3, .3, .3); }
    50% { opacity: 1; }
}

/* Enhanced feature cards */
.feature-card {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.feature-card:hover::before {
    left: 100%;
}

.feature-card:nth-child(1) { animation: slideInLeft 0.8s ease-out 0.1s both; }
.feature-card:nth-child(2) { animation: fadeInUp 0.8s ease-out 0.2s both; }
.feature-card:nth-child(3) { animation: slideInRight 0.8s ease-out 0.3s both; }
.feature-card:nth-child(4) { animation: slideInLeft 0.8s ease-out 0.4s both; }
.feature-card:nth-child(5) { animation: fadeInUp 0.8s ease-out 0.5s both; }
.feature-card:nth-child(6) { animation: slideInRight 0.8s ease-out 0.6s both; }

/* Bookmaker cards enhancements */
.bookmaker-card {
    position: relative;
    transition: all 0.3s ease;
    transform-style: preserve-3d;
}

.bookmaker-card:hover {
    transform: translateY(-10px) rotateX(5deg);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.bookmaker-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-top: 20px solid #ff6b35;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.bookmaker-card:hover::after {
    opacity: 1;
}

/* Star rating animations */
.rating .star {
    transition: all 0.2s ease;
    display: inline-block;
}

.rating:hover .star {
    animation: starGlow 0.3s ease infinite alternate;
}

@keyframes starGlow {
    from { text-shadow: 0 0 5px #ffd700; }
    to { text-shadow: 0 0 20px #ffd700, 0 0 30px #ffd700; }
}

/* Enhanced button effects */
.cta-button {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.cta-button::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;
}

.cta-button:hover::before {
    width: 300px;
    height: 300px;
}

.cta-button:active {
    transform: scale(0.95);
}

/* Loading states */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ff6b35;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Progress bars */
.progress-bar {
    width: 100%;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #ff6b35, #f7931e);
    animation: loading 2s ease-in-out infinite;
}

@keyframes loading {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Tooltip styles */
.tooltip {
    position: relative;
    cursor: help;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.tooltip::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.tooltip:hover::before,
.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-5px);
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    max-width: 90%;
    max-height: 90%;
    position: relative;
    animation: zoomIn 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 2rem;
    cursor: pointer;
    color: #666;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #ff6b35;
}

/* Advanced form styles */
.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
}

.form-input:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.form-label {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    background: white;
    padding: 0 5px;
    color: #666;
    transition: all 0.3s ease;
    pointer-events: none;
}

.form-input:focus + .form-label,
.form-input:not(:placeholder-shown) + .form-label {
    top: 0;
    font-size: 0.8rem;
    color: #ff6b35;
}

.form-error {
    color: #e74c3c;
    font-size: 0.8rem;
    margin-top: 5px;
    display: none;
}

.form-input.error {
    border-color: #e74c3c;
}

.form-input.error + .form-label {
    color: #e74c3c;
}

.form-input.error ~ .form-error {
    display: block;
}

/* Success states */
.form-input.success {
    border-color: #27ae60;
}

.form-input.success + .form-label {
    color: #27ae60;
}

/* Checkbox and radio styles */
.custom-checkbox,
.custom-radio {
    position: relative;
    display: inline-block;
    cursor: pointer;
    user-select: none;
}

.custom-checkbox input,
.custom-radio input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark,
.radiomark {
    position: absolute;
    top: 0;
    left: 0;
    height: 20px;
    width: 20px;
    background: #eee;
    border: 2px solid #ddd;
    transition: all 0.3s ease;
}

.checkmark {
    border-radius: 4px;
}

.radiomark {
    border-radius: 50%;
}

.custom-checkbox:hover input ~ .checkmark,
.custom-radio:hover input ~ .radiomark {
    background: #f0f0f0;
    border-color: #ff6b35;
}

.custom-checkbox input:checked ~ .checkmark,
.custom-radio input:checked ~ .radiomark {
    background: #ff6b35;
    border-color: #ff6b35;
}

.checkmark::after,
.radiomark::after {
    content: '';
    position: absolute;
    display: none;
}

.custom-checkbox input:checked ~ .checkmark::after {
    display: block;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.custom-radio input:checked ~ .radiomark::after {
    display: block;
    top: 4px;
    left: 4px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: white;
}

/* Table styles */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.data-table th,
.data-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.data-table th {
    background: linear-gradient(45deg, #1e3c72, #2a5298);
    color: white;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 10;
}

.data-table tr {
    transition: background-color 0.3s ease;
}

.data-table tr:hover {
    background: #f8f9fa;
}

.data-table tr:nth-child(even) {
    background: #fafafa;
}

.data-table tr:nth-child(even):hover {
    background: #f0f0f0;
}

/* Responsive table */
@media (max-width: 768px) {
    .data-table {
        font-size: 0.8rem;
    }
    
    .data-table th,
    .data-table td {
        padding: 8px 10px;
    }
}

/* Scroll indicators */
.scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #ff6b35, #f7931e);
    z-index: 9999;
    transition: width 0.3s ease;
}

/* Back to top button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

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

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(255, 107, 53, 0.4);
}

/* Notification styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    border-left: 4px solid #ff6b35;
    z-index: 9999;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    max-width: 300px;
}

.notification.show {
    transform: translateX(0);
}

.notification.success {
    border-left-color: #27ae60;
}

.notification.error {
    border-left-color: #e74c3c;
}

.notification.warning {
    border-left-color: #f39c12;
}

.notification-close {
    position: absolute;
    top: 5px;
    right: 10px;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: #666;
}

/* Skeleton loading */
.skeleton {
    animation: skeleton-loading 1s linear infinite alternate;
}

@keyframes skeleton-loading {
    0% { background-color: #e2e5e7; }
    100% { background-color: #f6f7f8; }
}

.skeleton-text {
    width: 100%;
    height: 1rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.skeleton-text:last-child {
    width: 80%;
}

.skeleton-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
}

.skeleton-button {
    width: 120px;
    height: 40px;
    border-radius: 20px;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .container {
        max-width: none !important;
        padding: 0 !important;
    }
    
    .cta-button,
    .hero-buttons,
    .promo-banner {
        display: none !important;
    }
    
    .feature-card,
    .bookmaker-card {
        break-inside: avoid;
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .feature-card,
    .bookmaker-card {
        border: 2px solid #000;
    }
    
    .cta-button {
        border: 2px solid #000;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #1a1a1a;
        --text-color: #ffffff;
        --card-bg: #2d2d2d;
        --border-color: #404040;
    }
    
    body {
        background: var(--bg-color);
        color: var(--text-color);
    }
    
    .feature-card,
    .bookmaker-card {
        background: var(--card-bg);
        border-color: var(--border-color);
        color: var(--text-color);
    }
    
    .faq-answer {
        background: var(--card-bg);
        color: var(--text-color);
    }
    
    .form-input {
        background: var(--card-bg);
        border-color: var(--border-color);
        color: var(--text-color);
    }
    
    .data-table {
        background: var(--card-bg);
        color: var(--text-color);
    }
    
    .data-table tr:nth-child(even) {
        background: #333;
    }
    
    .data-table tr:hover {
        background: #404040;
    }
}

/* Lazy loading image placeholders */
.lazy-image {
    background: linear-gradient(90deg, #f0f0f0 25%, transparent 37%, #f0f0f0 63%);
    background-size: 400% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    min-height: 200px;
    border-radius: 8px;
}

.lazy-image.loaded {
    animation: none;
    background: none;
}

/* Advanced grid layouts */
.masonry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    grid-gap: 1rem;
    grid-auto-rows: max-content;
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 1rem;
}

/* Sticky elements */
.sticky-sidebar {
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.sticky-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Advanced hover effects */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.5);
}

.hover-rotate {
    transition: transform 0.3s ease;
}

.hover-rotate:hover {
    transform: rotate(5deg);
}

/* Parallax effects */
.parallax-element {
    transform: translateZ(0);
    will-change: transform;
}

/* Performance optimizations */
.gpu-accelerated {
    transform: translateZ(0);
    backface-visibility: hidden;
    perspective: 1000px;
}

.smooth-scroll {
    scroll-behavior: smooth;
}

/* Custom scrollbars */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #e55a2b, #e6841a);
}

/* Selection styles */
::selection {
    background: rgba(255, 107, 53, 0.3);
    color: #333;
}

::-moz-selection {
    background: rgba(255, 107, 53, 0.3);
    color: #333;
}

/* Focus styles for better accessibility */
.focus-visible {
    outline: 3px solid #ff6b35;
    outline-offset: 2px;
}

/* Enhanced typography */
.drop-cap::first-letter {
    float: left;
    font-size: 4em;
    line-height: 1;
    margin: 0 0.1em 0 0;
    color: #ff6b35;
    font-weight: bold;
}

.highlight-text {
    background: linear-gradient(120deg, rgba(255, 107, 53, 0.3) 0%, rgba(255, 107, 53, 0.3) 100%);
    background-repeat: no-repeat;
    background-size: 100% 40%;
    background-position: 0 90%;
    transition: background-size 0.3s ease;
}

.highlight-text:hover {
    background-size: 100% 100%;
}

/* Advanced button states */
.btn-group {
    display: inline-flex;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.btn-group .cta-button {
    border-radius: 0;
    border-right: 1px solid rgba(255,255,255,0.3);
}

.btn-group .cta-button:last-child {
    border-right: none;
}

.btn-group .cta-button:first-child {
    border-radius: 25px 0 0 25px;
}

.btn-group .cta-button:last-child {
    border-radius: 0 25px 25px 0;
}

/* Loading spinner variations */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.dots-spinner {
    display: inline-block;
    position: relative;
    width: 64px;
    height: 64px;
}

.dots-spinner div {
    position: absolute;
    top: 27px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #ff6b35;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.dots-spinner div:nth-child(1) {
    left: 6px;
    animation: dots1 0.6s infinite;
}

.dots-spinner div:nth-child(2) {
    left: 6px;
    animation: dots2 0.6s infinite;
}

.dots-spinner div:nth-child(3) {
    left: 26px;
    animation: dots2 0.6s infinite;
}

.dots-spinner div:nth-child(4) {
    left: 45px;
    animation: dots3 0.6s infinite;
}

@keyframes dots1 {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

@keyframes dots2 {
    0% { transform: translate(0, 0); }
    100% { transform: translate(19px, 0); }
}

@keyframes dots3 {
    0% { transform: scale(1); }
    100% { transform: scale(0); }
}

/* Breadcrumb enhancements */
.breadcrumb {
    position: relative;
}

.breadcrumb::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    z-index: -1;
}

.breadcrumb ol li a {
    position: relative;
    transition: all 0.3s ease;
}

.breadcrumb ol li a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #ffd700;
    transition: width 0.3s ease;
}

.breadcrumb ol li a:hover::after {
    width: 100%;
}

/* Enhanced FAQ styling */
.faq-item {
    transition: all 0.3s ease;
}

.faq-item.active {
    transform: scale(1.02);
    box-shadow: 0 5px 20px rgba(255, 107, 53, 0.2);
}

.faq-question {
    position: relative;
    cursor: pointer;
}

.faq-question::after {
    content: '+';
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    font-weight: bold;
    transition: transform 0.3s ease;
}

.faq-question[aria-expanded="true"]::after {
    content: '−';
    transform: translateY(-50%) rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-answer.show {
    max-height: 500px;
    padding: 1.5rem;
}

/* Social sharing buttons */
.social-share {
    display: flex;
    gap: 0.5rem;
    margin: 1rem 0;
}

.social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.social-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.social-btn.facebook { background: #3b5998; }
.social-btn.twitter { background: #1da1f2; }
.social-btn.telegram { background: #0088cc; }
.social-btn.zalo { background: #0068ff; }
.social-btn.whatsapp { background: #25d366; }

/* Cookie consent banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #333;
    color: white;
    padding: 1rem;
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-banner .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.cookie-banner p {
    flex: 1;
    margin: 0;
}

.cookie-banner .btn-group {
    display: flex;
    gap: 0.5rem;
}

/* Responsive enhancements */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .feature-card,
    .bookmaker-card {
        margin-bottom: 1rem;
    }
    
    .modal-content {
        margin: 1rem;
        padding: 1rem;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    .notification {
        left: 10px;
        right: 10px;
        max-width: none;
    }
    
    .cookie-banner .container {
        flex-direction: column;
        text-align: center;
    }
}

@media (min-width: 1400px) {
    .container {
        max-width: 1400px;
    }
    
    .features-grid,
    .bookmaker-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .hero h1 {
        font-size: 5rem;
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .parallax-element {
        transform: none !important;
    }
    
    .skeleton,
    .lazy-image,
    .loading::after,
    .progress-bar::before {
        animation: none;
    }
    
    .hover-lift:hover,
    .hover-rotate:hover {
        transform: none;
    }
}

/* Print optimizations */
@media print {
    .back-to-top,
    .cookie-banner,
    .notification,
    .modal {
        display: none !important;
    }
    
    .feature-card,
    .bookmaker-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
    
    h1, h2, h3 {
        page-break-after: avoid;
    }
}

/* Performance optimizations for animations */
.will-change-transform {
    will-change: transform;
}

.will-change-opacity {
    will-change: opacity;
}

.will-change-auto {
    will-change: auto;
}

/* Final performance tweaks */
.feature-card,
.bookmaker-card,
.cta-button {
    contain: layout style paint;
}