/* Guide page specific styles */

/* Tab navigation enhancements */
.tab-button {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.tab-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

.tab-button.active {
    background: linear-gradient(135deg, #f59e0b, #ea580c) !important;
    border-color: #f59e0b !important;
    color: white !important;
}

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

.tab-button:hover::before {
    left: 100%;
}

/* Progress bar styling */
.progress-container {
    background: rgba(0,0,0,0.3);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.progress-bar {
    background: linear-gradient(90deg, #f59e0b, #ea580c, #dc2626);
    background-size: 200% 100%;
    animation: progressGlow 3s ease-in-out infinite;
    transition: width 1s ease-out;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.5);
}

@keyframes progressGlow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Content sections styling */
.guide-section {
    border: 2px solid #374151;
    border-radius: 12px;
    background: linear-gradient(145deg, #1f2937, #111827);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.guide-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #f59e0b, #ea580c);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.guide-section:hover::before {
    opacity: 1;
}

.guide-section:hover {
    border-color: #f59e0b;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Key binding styling */
.key-binding {
    background: linear-gradient(145deg, #374151, #4b5563);
    border: 2px solid #6b7280;
    border-radius: 8px;
    padding: 8px 12px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    text-align: center;
    min-width: 80px;
    color: #f9fafb;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}

.key-binding:hover {
    background: linear-gradient(145deg, #4b5563, #6b7280);
    transform: scale(1.05);
}

/* Stats bars */
.stat-bar {
    height: 20px;
    background: rgba(0,0,0,0.3);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.stat-fill {
    height: 100%;
    border-radius: 10px;
    transition: width 2s ease-out;
    background: linear-gradient(90deg, var(--color-start), var(--color-end));
    position: relative;
    overflow: hidden;
}

.stat-fill::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

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

/* HP bar colors */
.hp-bar { --color-start: #ef4444; --color-end: #dc2626; }
.mp-bar { --color-start: #3b82f6; --color-end: #1d4ed8; }
.stamina-bar { --color-start: #10b981; --color-end: #059669; }
.exp-bar { --color-start: #f59e0b; --color-end: #d97706; }

/* Class cards */
.class-card {
    border: 2px solid #374151;
    background: linear-gradient(145deg, #1f2937, #111827);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.class-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(245, 158, 11, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.class-card:hover::before {
    opacity: 1;
}

.class-card:hover {
    border-color: #f59e0b;
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

.class-card.selected {
    border-color: #f59e0b !important;
    background: linear-gradient(145deg, #2d1810, #1a0f08);
    box-shadow: 0 0 30px rgba(245, 158, 11, 0.4);
}

.class-card.selected::after {
    content: '✓';
    position: absolute;
    top: 10px;
    right: 15px;
    background: #f59e0b;
    color: white;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
}

/* Tips section */
.tip-item {
    border-left: 4px solid #f59e0b;
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.1), transparent);
    padding: 16px;
    margin: 16px 0;
    border-radius: 0 8px 8px 0;
    position: relative;
}

.tip-item::before {
    content: '💡';
    position: absolute;
    left: -2px;
    top: 50%;
    transform: translateY(-50%);
    background: #f59e0b;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.tip-item:hover {
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.2), rgba(245, 158, 11, 0.05));
    transform: translateX(5px);
    transition: all 0.3s ease;
}

/* FAQ accordion */
.faq-item,
.guide-card {
    border: 1px solid #374151;
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
    background: linear-gradient(145deg, #1f2937, #111827);
    transition: all 0.3s ease;
}

.faq-question,
.accordion-header {
    background: linear-gradient(135deg, #374151, #4b5563);
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    width: 100%;
    text-align: left;
    color: #f9fafb;
    font-weight: 600;
    position: relative;
}

.faq-question:hover,
.accordion-header:hover {
    background: linear-gradient(135deg, #4b5563, #6b7280);
}

.accordion-header.active {
    background: linear-gradient(135deg, #f59e0b, #ea580c);
    color: white;
}

.faq-question::after,
.accordion-header i {
    transition: transform 0.3s ease;
}

.faq-answer,
.accordion-content {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s ease;
    background: rgba(31, 41, 55, 0.8);
}

.faq-answer.active,
.accordion-content.active {
    padding: 20px;
    max-height: 500px;
}

/* Responsive design */
@media (max-width: 768px) {
    .tab-button {
        font-size: 14px;
        padding: 8px 12px;
    }
    
    .guide-section {
        padding: 16px;
    }
    
    .key-binding {
        min-width: 60px;
        padding: 6px 8px;
        font-size: 12px;
    }
    
    .class-card {
        margin-bottom: 16px;
    }
}

/* Animation for section completion */
@keyframes completeSection {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.guide-section.completed {
    border-color: #10b981;
    background: linear-gradient(145deg, #1a2e1a, #0f1f0f);
    animation: completeSection 0.6s ease-out;
}

.guide-section.completed::before {
    background: linear-gradient(90deg, #10b981, #059669);
    opacity: 1;
}

/* Loading states */
.loading {
    opacity: 0.5;
    pointer-events: none;
}

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

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Print styles */
@media print {
    .tab-navigation,
    .progress-container {
        display: none;
    }
    
    .tab-content {
        display: block !important;
        page-break-inside: avoid;
    }
}
