/**
 * Main Stylesheet
 * K8VN21 Theme
 */

/* ========================================
   BASE STYLES
   ======================================== */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Selection color */
::selection {
    background-color: rgba(26, 35, 126, 0.2);
    color: #1a237e;
}

/* Focus styles for accessibility */
*:focus {
    outline: 2px solid #ffc107;
    outline-offset: 2px;
}

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

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

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

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

/* ========================================
   HEADER ENHANCEMENTS
   ======================================== */
.site-header {
    transition: all 0.3s ease;
}

.site-header.scrolled {
    background: rgba(26, 35, 126, 0.95);
    backdrop-filter: blur(10px);
}

.menu-icon {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #fff;
    position: relative;
    transition: all 0.3s ease;
}

.menu-icon::before,
.menu-icon::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 3px;
    background-color: #fff;
    transition: all 0.3s ease;
}

.menu-icon::before {
    top: -8px;
}

.menu-icon::after {
    top: 8px;
}

.menu-toggle.active .menu-icon {
    background-color: transparent;
}

.menu-toggle.active .menu-icon::before {
    top: 0;
    transform: rotate(45deg);
}

.menu-toggle.active .menu-icon::after {
    top: 0;
    transform: rotate(-45deg);
}

/* ========================================
   HERO ENHANCEMENTS
   ======================================== */
.hero-section {
    position: relative;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100px;
    background: linear-gradient(to top, #f5f5f5, transparent);
}

/* ========================================
   CARD ENHANCEMENTS
   ======================================== */
.card {
    position: relative;
    overflow: hidden;
}

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

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

/* ========================================
   BUTTON ENHANCEMENTS
   ======================================== */
.btn {
    position: relative;
    overflow: hidden;
}

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

.btn:active::before {
    width: 300px;
    height: 300px;
}

/* ========================================
   FORM ENHANCEMENTS
   ======================================== */
.form-input:focus {
    box-shadow: 0 0 0 3px rgba(26, 35, 126, 0.1);
}

.form-submit {
    position: relative;
    overflow: hidden;
}

.form-submit::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        transparent 0%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 100%
    );
    transform: rotate(30deg);
    transition: all 0.6s ease;
}

.form-submit:hover::after {
    left: 100%;
}

/* ========================================
   PROMO CARD ENHANCEMENTS
   ======================================== */
.promo-card {
    transition: all 0.4s ease;
}

.promo-card:hover {
    transform: translateY(-10px) scale(1.02);
}

.promo-value {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* ========================================
   FAQ ENHANCEMENTS
   ======================================== */
.faq-question {
    position: relative;
    padding-right: 50px;
}

.faq-question::after {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

/* ========================================
   SCROLL TO TOP
   ======================================== */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #1a237e 0%, #0d1642 100%);
    color: #ffc107;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

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

.scroll-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* ========================================
   LOADING ANIMATION
   ======================================== */
.loading {
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #1a237e;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* ========================================
   ACCESSIBILITY
   ======================================== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Skip to main content link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #1a237e;
    color: #fff;
    padding: 8px;
    text-decoration: none;
    z-index: 10000;
}

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

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {
    .site-header,
    .site-footer,
    .scroll-to-top,
    .btn {
        display: none !important;
    }
    
    .page-content {
        padding-top: 20px !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    a {
        text-decoration: underline;
    }
    
    .content-wrapper {
        box-shadow: none !important;
    }
}

/* ========================================
   HIGH CONTRAST MODE
   ======================================== */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 2px solid #000;
    }
    
    .card {
        border: 2px solid #000;
    }
    
    .form-input {
        border: 2px solid #000;
    }
}

/* ========================================
   REDUCED MOTION
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}
