/* Caliche Catracho - Estilos principales */

.caliche-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.caliche-header {
    background: linear-gradient(135deg, #0066CC 0%, #003E7E 100%);
    color: white;
    text-align: center;
    padding: 40px 30px;
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 102, 204, 0.3);
}

.caliche-logo {
    font-size: 2.5em;
    font-weight: bold;
    margin-bottom: 10px;
}

.caliche-subtitle {
    font-size: 1.2em;
    opacity: 0.9;
    margin-bottom: 30px;
}

.search-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-box {
    width: 100%;
    padding: 15px 50px 15px 20px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    outline: none;
    box-sizing: border-box;
}

.search-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(45deg, #0066CC, #003E7E);
    border: none;
    color: white;
    padding: 10px 15px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
}

.search-btn:hover {
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.4);
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    margin-bottom: 30px;
}

.content-area {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    min-height: 400px;
}

.sidebar {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    height: fit-content;
}

.add-word-btn {
    width: 100%;
    background: linear-gradient(45deg, #00A86B, #00C97A);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 20px;
}

.add-word-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 168, 107, 0.4);
}

.word-card {
    background: white;
    border: 1px solid #e1e8ed;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s;
    border-left: 5px solid #0066CC;
}

.word-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.word-title {
    font-size: 1.5em;
    font-weight: bold;
    color: #0066CC;
    margin-bottom: 10px;
}

.word-definition {
    font-size: 1.1em;
    line-height: 1.6;
    margin-bottom: 15px;
    color: #333;
}

.word-example {
    font-style: italic;
    color: #666;
    background: #f8f9fa;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.word-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9em;
    color: #888;
}

.word-votes {
    display: flex;
    gap: 10px;
}

.vote-btn {
    background: none;
    border: 1px solid #ddd;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.vote-btn.up {
    color: #28a745;
    border-color: #28a745;
}

.vote-btn.down {
    color: #dc3545;
    border-color: #dc3545;
}

.vote-btn:hover {
    background: rgba(0, 0, 0, 0.05);
}

.vote-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: linear-gradient(45deg, #0066CC, #003E7E);
    color: white;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
}

.stat-number {
    font-size: 1.8em;
    font-weight: bold;
    display: block;
}

.stat-label {
    font-size: 0.9em;
    opacity: 0.9;
}

.categories {
    margin-bottom: 20px;
}

.categories h3 {
    color: #0066CC;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.category-tag {
    display: inline-block;
    background: #f8f9fa;
    color: #0066CC;
    padding: 8px 15px;
    border-radius: 20px;
    margin: 5px;
    font-size: 0.9em;
    text-decoration: none;
    transition: all 0.3s;
    cursor: pointer;
}

.category-tag:hover {
    background: #0066CC;
    color: white;
    text-decoration: none;
}

.recent-words {
    margin-bottom: 20px;
}

.recent-words h3 {
    color: #0066CC;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 20px;
    padding: 40px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #0066CC;
    box-shadow: 0 0 10px rgba(0, 102, 204, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.btn-primary {
    background: linear-gradient(45deg, #0066CC, #003E7E);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    margin-right: 10px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 102, 204, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: #5a6268;
}

.loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #0066CC;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

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

.no-results {
    text-align: center;
    padding: 40px;
    color: #666;
}

.no-results i {
    font-size: 3em;
    color: #ccc;
    margin-bottom: 20px;
    display: block;
}

/* Widget styles */
.caliche-widget {
    padding: 15px;
}

.palabra-widget {
    margin-bottom: 15px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #0066CC;
}

.palabra-widget strong {
    color: #0066CC;
}

/* Shortcode styles */
#caliche-shortcode-container {
    margin: 20px 0;
}

.caliche-search-widget {
    margin: 15px 0;
}

/* Responsive design */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .caliche-logo {
        font-size: 2em;
    }
    
    .caliche-header {
        padding: 30px 20px;
    }
    
    .modal-content {
        padding: 20px;
        width: 95%;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .word-meta {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .category-tag {
        margin: 3px;
        padding: 6px 12px;
        font-size: 0.8em;
    }
}

@media (max-width: 480px) {
    .caliche-container {
        padding: 10px;
    }
    
    .content-area,
    .sidebar {
        padding: 20px;
    }
    
    .caliche-logo {
        font-size: 1.8em;
    }
    
    .caliche-subtitle {
        font-size: 1em;
    }
    
    .search-box {
        padding: 12px 45px 12px 15px;
        font-size: 14px;
    }
    
    .word-title {
        font-size: 1.3em;
    }
    
    .vote-btn {
        padding: 4px 8px;
        font-size: 0.8em;
    }
}

/* Print styles */
@media print {
    .sidebar,
    .add-word-btn,
    .search-container,
    .word-votes {
        display: none;
    }
    
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .word-card {
        break-inside: avoid;
        border: 1px solid #333;
        margin-bottom: 10px;
    }
}