/**
 * PostsVortex - Estilos Principales
 */

/* Reset y base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Navegación del sidebar */
.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.75rem;
    border-radius: 0.5rem;
    color: #4b5563;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

.nav-item:hover {
    background-color: #f3f4f6;
    color: #111827;
}

.nav-item.active {
    background-color: #eff6ff;
    color: #2563eb;
}

.dark .nav-item {
    color: #9ca3af;
}

.dark .nav-item:hover {
    background-color: #374151;
    color: #f3f4f6;
}

.dark .nav-item.active {
    background-color: rgba(37, 99, 235, 0.2);
    color: #60a5fa;
}

/* Badges de estado */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.status-draft {
    background-color: #f3f4f6;
    color: #4b5563;
}

.status-scheduled {
    background-color: #dbeafe;
    color: #1e40af;
}

.status-published {
    background-color: #d1fae5;
    color: #065f46;
}

.status-failed {
    background-color: #fee2e2;
    color: #991b1b;
}

.status-pending {
    background-color: #fef3c7;
    color: #92400e;
}

.dark .status-draft {
    background-color: #374151;
    color: #d1d5db;
}

.dark .status-scheduled {
    background-color: rgba(30, 64, 175, 0.3);
    color: #93c5fd;
}

.dark .status-published {
    background-color: rgba(6, 95, 70, 0.3);
    color: #6ee7b7;
}

.dark .status-failed {
    background-color: rgba(153, 27, 27, 0.3);
    color: #fca5a5;
}

.dark .status-pending {
    background-color: rgba(146, 64, 14, 0.3);
    color: #fcd34d;
}

/* Iconos de redes sociales */
.network-icon {
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.625rem;
    font-weight: bold;
}

.network-facebook { background-color: #1877F2; }
.network-instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.network-twitter { background-color: #000000; }
.network-linkedin { background-color: #0A66C2; }
.network-tiktok { background-color: #000000; }
.network-youtube { background-color: #FF0000; }
.network-pinterest { background-color: #BD081C; }

/* Calendario */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background-color: #e5e7eb;
    border-radius: 0.5rem;
    overflow: hidden;
}

.calendar-cell {
    background-color: white;
    min-height: 100px;
    padding: 0.5rem;
}

.dark .calendar-cell {
    background-color: #1f2937;
}

.calendar-cell-header {
    text-align: center;
    padding: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    color: #6b7280;
}

.calendar-day-number {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.25rem;
}

.dark .calendar-day-number {
    color: #d1d5db;
}

.calendar-day-number.today {
    background-color: #3b82f6;
    color: white;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-event {
    font-size: 0.75rem;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    margin-bottom: 0.125rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
}

/* Formularios */
.form-input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    background-color: white;
    color: #111827;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.dark .form-input {
    background-color: #374151;
    border-color: #4b5563;
    color: #f9fafb;
}

.dark .form-input:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

/* Botones */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.5rem;
    transition: all 0.2s;
    cursor: pointer;
}

.btn-primary {
    background-color: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background-color: #2563eb;
}

.btn-secondary {
    background-color: #f3f4f6;
    color: #374151;
}

.btn-secondary:hover {
    background-color: #e5e7eb;
}

.dark .btn-secondary {
    background-color: #374151;
    color: #f9fafb;
}

.dark .btn-secondary:hover {
    background-color: #4b5563;
}

.btn-danger {
    background-color: #ef4444;
    color: white;
}

.btn-danger:hover {
    background-color: #dc2626;
}

/* Tarjetas de planes */
.pricing-card {
    background-color: white;
    border: 2px solid #e5e7eb;
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.3s;
}

.pricing-card:hover {
    border-color: #3b82f6;
    transform: translateY(-4px);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.1);
}

.pricing-card.featured {
    border-color: #3b82f6;
    position: relative;
}

.pricing-card.featured::before {
    content: attr(data-badge);
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #3b82f6;
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.dark .pricing-card {
    background-color: #1f2937;
    border-color: #374151;
}

.dark .pricing-card:hover {
    border-color: #60a5fa;
}

/* Animaciones */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { 
        opacity: 0;
        transform: translateY(20px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.3s ease-out;
}

.animate-slide-up {
    animation: slideUp 0.4s ease-out;
}

/* Utilidades */
.line-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Scrollbar personalizada */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.dark ::-webkit-scrollbar-track {
    background: #1f2937;
}

.dark ::-webkit-scrollbar-thumb {
    background: #4b5563;
}

.dark ::-webkit-scrollbar-thumb:hover {
    background: #6b7280;
}

/* Toast notifications */
.toast {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 50;
    animation: slideUp 0.3s ease-out;
}

.toast-success {
    background-color: #10b981;
    color: white;
}

.toast-error {
    background-color: #ef4444;
    color: white;
}

/* Responsive */
@media (max-width: 1024px) {
    .calendar-cell {
        min-height: 80px;
    }
}

@media (max-width: 640px) {
    .calendar-cell {
        min-height: 60px;
        padding: 0.25rem;
    }
    
    .calendar-day-number {
        font-size: 0.75rem;
    }
}
