/* Estilos para Dojo de Triana - Sistema CTF */

:root {
    --primary-color: #8B0000;
    --secondary-color: #FFD700;
    --dark-color: #1a1a1a;
    --light-color: #f5f5f5;
    --success-color: #4CAF50;
    --warning-color: #FF9800;
    --danger-color: #f44336;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Styles */
.main-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #660000 100%);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.kanji-logo {
    font-size: 3em;
    color: var(--secondary-color);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    animation: pulse 2s infinite;
}

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

.logo-text h1 {
    color: white;
    font-size: 1.8em;
    margin-bottom: 5px;
}

.tagline {
    color: var(--secondary-color);
    font-size: 0.9em;
    font-style: italic;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 10px 15px;
    border-radius: 5px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
}

.nav-link:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
}

.decoration-bar {
    height: 5px;
    background: repeating-linear-gradient(
        90deg,
        var(--secondary-color),
        var(--secondary-color) 10px,
        transparent 10px,
        transparent 20px
    );
}

/* Main Content */
.main-content {
    flex: 1;
    padding: 40px 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 10px;
    box-shadow: var(--shadow);
    padding: 30px;
    margin-bottom: 30px;
    animation: fadeIn 0.5s ease-in;
}

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

.card-title {
    font-size: 2em;
    color: var(--primary-color);
    margin-bottom: 20px;
    border-bottom: 3px solid var(--secondary-color);
    padding-bottom: 10px;
}

/* Search Box */
.search-box {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(139,0,0,0.1);
    margin-bottom: 30px;
}

.search-form {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.search-input {
    flex: 1;
    padding: 15px 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(139,0,0,0.1);
}

.search-btn {
    padding: 15px 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #660000 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

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

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.data-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, #660000 100%);
    color: white;
}

.data-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9em;
    letter-spacing: 1px;
}

.data-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
}

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

.data-table tr:last-child td {
    border-bottom: none;
}

/* Belt Colors */
.belt-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: bold;
}

.belt-blanco { background: #f0f0f0; color: #333; }
.belt-amarillo { background: #FFD700; color: #333; }
.belt-naranja { background: #FF8C00; color: white; }
.belt-verde { background: #228B22; color: white; }
.belt-azul { background: #0066CC; color: white; }
.belt-marron { background: #8B4513; color: white; }
.belt-negro { background: #000000; color: white; }

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.stat-icon {
    font-size: 3em;
    margin-bottom: 10px;
}

.stat-number {
    font-size: 2.5em;
    font-weight: bold;
    color: var(--primary-color);
    margin: 10px 0;
}

.stat-label {
    color: #666;
    font-size: 1.1em;
}

/* Alert Messages */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-info {
    background: #e3f2fd;
    color: #1976d2;
    border-left: 4px solid #1976d2;
}

.alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    border-left: 4px solid #2e7d32;
}

.alert-warning {
    background: #fff3e0;
    color: #f57c00;
    border-left: 4px solid #f57c00;
}

.alert-danger {
    background: #ffebee;
    color: #c62828;
    border-left: 4px solid #c62828;
}

/* Feature List */
.feature-list {
    list-style: none;
    padding: 20px 0;
}

.feature-list li {
    padding: 15px 0;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature-list li:last-child {
    border-bottom: none;
}

.feature-icon {
    font-size: 1.5em;
}

/* Footer */
.main-footer {
    background: var(--dark-color);
    color: white;
    margin-top: auto;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.footer-section h3 {
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.footer-section p {
    margin: 8px 0;
    color: #ccc;
}

.footer-bottom {
    background: #0a0a0a;
    padding: 20px;
    text-align: center;
    color: #888;
    border-top: 1px solid #333;
}

/* Welcome Section */
.welcome-section {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, rgba(139,0,0,0.1) 0%, rgba(255,215,0,0.1) 100%);
    border-radius: 15px;
    margin-bottom: 40px;
}

.welcome-section h2 {
    font-size: 3em;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.welcome-section p {
    font-size: 1.2em;
    color: #666;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Japanese Elements */
.japanese-quote {
    background: linear-gradient(135deg, #fff 0%, #f9f9f9 100%);
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    margin: 30px 0;
    box-shadow: var(--shadow);
}

.japanese-text {
    font-size: 2em;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.japanese-translation {
    font-style: italic;
    color: #666;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.no-results-icon {
    font-size: 4em;
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .main-nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* CTF Hints (ocultos) */
.ctf-hint {
    display: none;
    /* Pista: Prueba con UNION SELECT */
}

/* Animaciones adicionales */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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