/* Prevent body scroll when in news section */
body.news-active {
    overflow: hidden;
    height: 100vh;
}

/* News System Styles */
.news-container {
    padding: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
    height: 100vh;
    overflow: visible;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: 100vh;
}

/* Fixed top section */
.news-top-section {
    flex-shrink: 0;
    background: var(--bg-primary);
    z-index: 100;
}

/* Custom scrollbar for scrollable content */
.news-scrollable-content::-webkit-scrollbar,
.news-editor-left::-webkit-scrollbar,
.news-editor-content::-webkit-scrollbar,
.news-preview-content::-webkit-scrollbar {
    width: 8px;
}

.news-scrollable-content::-webkit-scrollbar-track,
.news-editor-left::-webkit-scrollbar-track,
.news-editor-content::-webkit-scrollbar-track,
.news-preview-content::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 4px;
}

.news-scrollable-content::-webkit-scrollbar-thumb,
.news-editor-left::-webkit-scrollbar-thumb,
.news-editor-content::-webkit-scrollbar-thumb,
.news-preview-content::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
    transition: background 0.3s ease;
}

.news-scrollable-content::-webkit-scrollbar-thumb:hover,
.news-editor-left::-webkit-scrollbar-thumb:hover,
.news-editor-content::-webkit-scrollbar-thumb:hover,
.news-preview-content::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Firefox scrollbar */
.news-scrollable-content,
.news-editor-left,
.news-editor-content,
.news-preview-content {
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--bg-secondary);
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1rem 0;
    border-bottom: 2px solid var(--border-color);
    gap: 1rem;
    flex-shrink: 0;
}

.news-header h1 {
    flex: 1;
    margin: 0;
}

.news-header .btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    height: auto;
    line-height: 1.2;
}

.news-header h1 {
    color: var(--text-primary);
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
}

.news-filters {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    background: var(--bg-secondary);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    flex-shrink: 0;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 140px;
}

.filter-group label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-group select,
.filter-group input {
    padding: 0.5rem 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.8rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.filter-group select:hover,
.filter-group input:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.filter-group select:focus,
.filter-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 
        0 0 0 3px rgba(59, 130, 246, 0.1),
        0 4px 12px rgba(59, 130, 246, 0.15);
}

.news-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-shrink: 0;
}

.stat-card {
    background: var(--bg-secondary);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    text-align: center;
}

.stat-card .stat-number {
    display: block;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stat-card .stat-label {
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
}

/* Scrollable content area */
.news-scrollable-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1rem 1rem 2rem 0.5rem;
    min-height: 0;
    height: 100%;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 2.5rem;
    margin-bottom: 2rem;
    padding: 2rem 1rem;
    align-items: stretch;
}

/* Smooth scrolling for news section */
.news-container {
    scroll-behavior: smooth;
}


/* Add padding to ensure content doesn't get cut off */
.news-container > *:last-child {
    padding-bottom: 2rem;
}

.news-card {
    background: linear-gradient(145deg, #1a1a2e, #16213e);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Indicador visual de que la tarjeta es clickeable */
.news-card::after {
    content: '';
    position: absolute;
    top: 1rem;
    left: 1rem;
    width: 20px;
    height: 20px;
    background: rgba(59, 130, 246, 0.2);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 5;
}

.news-card:hover::after {
    opacity: 1;
}

.news-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(147, 51, 234, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.news-card:hover {
    transform: translateY(-4px) scale(1.01);
    box-shadow: 
        0 15px 30px rgba(0, 0, 0, 0.25),
        0 0 0 1px rgba(59, 130, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(59, 130, 246, 0.5);
    z-index: 10;
}

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

.news-card.featured {
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 
        0 0 0 1px rgba(59, 130, 246, 0.3),
        0 10px 30px rgba(59, 130, 246, 0.2);
    background: linear-gradient(145deg, #1e3a8a, #1e40af);
}

.news-card.breaking {
    border-color: rgba(239, 68, 68, 0.6);
    box-shadow: 
        0 0 0 1px rgba(239, 68, 68, 0.3),
        0 10px 30px rgba(239, 68, 68, 0.2);
    background: linear-gradient(145deg, #7f1d1d, #991b1b);
}

.news-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFFFFF;
    margin: 0 0 1.5rem 0;
    padding: 0 2rem;
    padding-top: 2rem;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 2;
    flex: 0 0 auto;
    min-height: 4.5rem;
    display: flex;
    align-items: center;
}

.news-card-footer {
    padding: 1.5rem 2rem;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.3));
    display: flex;
    flex-direction: column;
    gap: 1rem;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 2;
    margin-top: auto;
    flex: 0 0 auto;
}

/* Contenedor para el contenido principal de la tarjeta */
.news-card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.news-card-status-date {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.news-status {
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.news-status.draft {
    background: linear-gradient(135deg, #374151, #4B5563);
    color: #D1D5DB;
}

.news-status.published {
    background: linear-gradient(135deg, #059669, #10B981);
    color: white;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.news-status.scheduled {
    background: linear-gradient(135deg, #D97706, #F59E0B);
    color: white;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.news-status.archived {
    background: linear-gradient(135deg, #DC2626, #EF4444);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

/* Estilos para categorías como etiquetas */
.news-category {
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    max-width: fit-content;
}

.news-category i {
    width: 14px;
    height: 14px;
    font-size: 14px;
}

/* Colores específicos para categorías */
.news-category.inteligencia-artificial {
    background: linear-gradient(135deg, #8B5CF6, #A855F7);
    color: white;
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.3);
}

.news-category.innovacion {
    background: linear-gradient(135deg, #06B6D4, #0891B2);
    color: white;
    box-shadow: 0 4px 15px rgba(8, 145, 178, 0.3);
}

.news-category.tecnologia {
    background: linear-gradient(135deg, #3B82F6, #2563EB);
    color: white;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.news-category.negocios {
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
}

.news-category.ciencia {
    background: linear-gradient(135deg, #F59E0B, #D97706);
    color: white;
    box-shadow: 0 4px 15px rgba(217, 119, 6, 0.3);
}

.news-category.default {
    background: linear-gradient(135deg, #6B7280, #4B5563);
    color: #D1D5DB;
}

/* Hover effect para categorías */
.news-category:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.news-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}

.news-card-actions {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    gap: 0.5rem;
    align-items: center;
    z-index: 10;
}

.news-card-actions button {
    padding: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    color: rgba(255, 255, 255, 0.8);
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-card-actions button:hover {
    background: linear-gradient(135deg, var(--primary-color), #8B5CF6);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.delete-article-btn {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.3), rgba(220, 38, 38, 0.2)) !important;
    border-color: rgba(239, 68, 68, 0.4) !important;
    color: #FCA5A5 !important;
}

.delete-article-btn:hover {
    background: linear-gradient(135deg, #EF4444, #DC2626) !important;
    color: white !important;
    border-color: #EF4444 !important;
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4) !important;
}

.news-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    position: relative;
    z-index: 2;
}

.news-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.8rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.05));
    color: rgba(255, 255, 255, 0.9);
    border-radius: 1.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.news-tag:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.1));
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

/* Tags Input Styles */
.tags-input-container {
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.5rem;
    background: var(--bg-primary);
    min-height: 2.5rem;
}

.tags-display {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.tag-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    background: var(--primary-color);
    color: white;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.tag-remove {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0;
    width: 1rem;
    height: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.tag-remove:hover {
    background: rgba(255, 255, 255, 0.2);
}

.tag-selector {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.875rem;
}

.tag-selector option {
    background: #ffffff;
    color: #1a1a2e;
    padding: 0.5rem;
}

.tag-selector:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.news-card-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    position: relative;
    z-index: 1;
    flex: 0 0 250px;
}

.news-card-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 250px;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: rgba(255, 255, 255, 0.3);
    font-size: 4rem;
    position: relative;
    z-index: 1;
    flex: 0 0 250px;
}

.news-card-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(147, 51, 234, 0.1));
    z-index: -1;
}

/* News Editor Styles */
.news-editor {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 2rem;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.news-editor-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
    position: relative;
    z-index: 1;
    align-items: stretch;
    min-height: calc(100vh - 12rem);
    height: calc(100vh - 12rem);
    max-height: calc(100vh - 12rem);
}

.news-editor-left {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    max-height: 100%;
}

.news-editor-right {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    overflow: hidden;
}

.news-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    gap: 1rem;
}

.news-editor-header h2 {
    flex: 1;
    margin: 0;
}

.news-editor-header .btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    height: auto;
    line-height: 1.2;
}

.news-editor-header h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.news-editor-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    background: var(--bg-primary);
    padding: 0.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-color);
    position: relative;
    z-index: 3;
}

.news-editor-tab {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    z-index: 4;
    flex: 1;
    text-align: center;
}

.news-editor-tab.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.news-editor-tab:hover:not(.active) {
    background: var(--bg-primary);
    color: var(--text-primary);
    border-color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.news-editor-content {
    display: none;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
    height: 100%;
    max-height: 100%;
}

.news-editor-content.active {
    display: flex;
    flex-direction: column;
}

.news-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.news-form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.news-form-group.full-width {
    grid-column: 1 / -1;
}

.news-form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

.news-form-group input,
.news-form-group select,
.news-form-group textarea {
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.875rem;
    transition: all 0.3s ease;
    width: 100%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

.news-form-group input,
.news-form-group select {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
    min-width: 0;
    flex-shrink: 1;
}

.news-form-group textarea {
    resize: vertical;
    min-height: 100px;
    white-space: normal;
    overflow-wrap: break-word;
}

/* Specific styles for slug and long text fields */
.news-form-group input[type="text"][name="slug"],
.news-form-group input[type="text"][id*="slug"] {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
}

.news-form-group input[type="text"][name="slug"]:focus,
.news-form-group input[type="text"][id*="slug"]:focus {
    border-color: var(--primary-color);
    background: var(--bg-secondary);
}

/* Ensure proper spacing in form sections */
.news-form-section {
    margin-bottom: 2.5rem;
    padding: 2rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    position: relative;
    z-index: 1;
    overflow: visible;
}

.news-form-group input:focus,
.news-form-group select:focus,
.news-form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 
        0 0 0 3px rgba(59, 130, 246, 0.1),
        0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

.news-form-group input:hover,
.news-form-group select:hover,
.news-form-group textarea:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

/* Specific styles for select dropdowns */
.news-form-group select {
    background: var(--bg-secondary);
    color: var(--text-primary);
    cursor: pointer;
}

.news-form-group select option {
    background: #ffffff;
    color: #1a1a2e;
    padding: 0.5rem;
}

.news-form-group select:focus {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* Filter dropdowns specific styles */
.news-filters select {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.news-filters select:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.news-filters select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 
        0 0 0 3px rgba(59, 130, 246, 0.1),
        0 4px 12px rgba(59, 130, 246, 0.15);
}

.news-filters select option {
    background: #ffffff;
    color: #1a1a2e;
    padding: 0.75rem;
    border: none;
}

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

.news-form-group .rich-text-editor {
    min-height: 300px;
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    background: var(--bg-secondary);
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.news-form-group .rich-text-editor:focus {
    border-color: var(--primary-color);
    box-shadow: 
        0 0 0 3px rgba(59, 130, 246, 0.1),
        0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

.news-form-group .rich-text-editor:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.news-form-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    margin-top: 2rem;
    position: relative;
    z-index: 3;
}

.news-form-actions .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    z-index: 4;
    min-width: 140px;
    border: 1px solid transparent;
    height: auto;
    line-height: 1.2;
}

.news-form-actions .btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

.news-form-actions .btn-secondary:hover {
    background: var(--bg-primary);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.news-form-actions .btn-primary {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.news-form-actions .btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* News Preview Styles */
.news-preview-panel {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1rem;
    height: 100%;
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.news-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    position: relative;
    z-index: 4;
}

.news-preview-header h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.preview-language-toggle {
    display: flex;
    gap: 0.5rem;
    position: relative;
    z-index: 5;
}

.preview-lang-btn {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    position: relative;
    z-index: 6;
}

.preview-lang-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.preview-lang-btn:hover:not(.active) {
    background: var(--bg-primary);
    color: var(--text-primary);
    border-color: var(--primary-color);
}

.news-preview-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
    z-index: 3;
    padding: 0;
    min-height: 0;
    height: 100%;
    max-height: 100%;
}

.news-preview-article {
    color: var(--text-primary);
    line-height: 1.7;
    font-size: 0.95rem;
    position: relative;
    z-index: 4;
    padding: 0;
    margin: 0;
}

.news-preview-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.75rem 0;
    line-height: 1.3;
}

.news-preview-meta {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.news-preview-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.news-preview-body {
    color: var(--text-primary);
    line-height: 1.7;
    position: relative;
    z-index: 4;
}

/* Markdown content styling */
.news-preview-body h1,
.news-preview-body h2,
.news-preview-body h3,
.news-preview-body h4,
.news-preview-body h5,
.news-preview-body h6 {
    color: var(--text-primary);
    margin: 1.5rem 0 1rem 0;
    font-weight: 600;
    line-height: 1.3;
}

.news-preview-body h1 {
    font-size: 1.5rem;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.news-preview-body h2 {
    font-size: 1.25rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.25rem;
}

.news-preview-body h3 {
    font-size: 1.125rem;
}

.news-preview-body p {
    margin: 1rem 0;
    line-height: 1.7;
}

.news-preview-body ul,
.news-preview-body ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.news-preview-body li {
    margin: 0.5rem 0;
}

.news-preview-body blockquote {
    margin: 1rem 0;
    padding: 1rem 1.5rem;
    border-left: 4px solid var(--primary-color);
    background: var(--bg-secondary);
    font-style: italic;
    color: var(--text-secondary);
    border-radius: 0 0.5rem 0.5rem 0;
}

.news-preview-body a {
    color: var(--primary-color);
    text-decoration: underline;
    font-weight: 500;
}

.news-preview-body a:hover {
    color: var(--primary-dark);
    text-decoration: none;
}

.news-preview-body img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1rem 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.news-preview-body code {
    background: var(--bg-secondary);
    color: var(--primary-color);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    border: 1px solid var(--border-color);
}

.news-preview-body pre {
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    overflow-x: auto;
    border: 1px solid var(--border-color);
    margin: 1rem 0;
}

.news-preview-body strong {
    font-weight: 600;
    color: var(--text-primary);
}

.news-preview-body em {
    font-style: italic;
    color: var(--text-primary);
}

.news-preview-body h1,
.news-preview-body h2,
.news-preview-body h3 {
    color: var(--text-primary);
    margin: 1.5rem 0 1rem 0;
    font-weight: 600;
}

.news-preview-body h1 {
    font-size: 1.5rem;
}

.news-preview-body h2 {
    font-size: 1.25rem;
}

.news-preview-body h3 {
    font-size: 1.125rem;
}

.news-preview-body p {
    margin: 1rem 0;
}

.news-preview-body ul,
.news-preview-body ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.news-preview-body li {
    margin: 0.5rem 0;
}

.news-preview-body blockquote {
    margin: 1rem 0;
    padding: 1rem;
    border-left: 4px solid var(--primary-color);
    background: var(--bg-secondary);
    font-style: italic;
    color: var(--text-secondary);
}

.news-preview-body a {
    color: var(--primary-color);
    text-decoration: underline;
}

.news-preview-body a:hover {
    color: var(--primary-dark);
}

.news-preview-body img {
    max-width: 100%;
    height: auto;
    border-radius: 0.375rem;
    margin: 1rem 0;
}

.news-preview-body strong {
    font-weight: 600;
}

.news-preview-body em {
    font-style: italic;
}

.news-preview-body u {
    text-decoration: underline;
}

.news-preview-body s {
    text-decoration: line-through;
}

/* Markdown Preview Styles */
.markdown-placeholder {
    color: var(--text-secondary);
    font-style: italic;
    text-align: center;
    padding: 2rem;
    background: var(--bg-secondary);
    border-radius: 0.5rem;
    border: 2px dashed var(--border-color);
}

.markdown-h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 2rem 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
}

.markdown-h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 1.5rem 0 1rem 0;
    padding-bottom: 0.25rem;
    border-bottom: 1px solid var(--border-color);
}

.markdown-h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 1.25rem 0 0.75rem 0;
}

.markdown-h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 1rem 0 0.5rem 0;
}

.markdown-h5 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0.75rem 0 0.5rem 0;
}

.markdown-h6 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin: 0.5rem 0 0.25rem 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.markdown-strong {
    font-weight: 700;
    color: var(--text-primary);
}

.markdown-em {
    font-style: italic;
    color: var(--text-primary);
}

.markdown-ul {
    margin: 1rem 0;
    padding-left: 2rem;
    list-style-type: disc;
}

.markdown-ol {
    margin: 1rem 0;
    padding-left: 2rem;
    list-style-type: decimal;
}

.markdown-li {
    margin: 0.5rem 0;
    line-height: 1.6;
}

.markdown-link {
    color: var(--primary-color);
    text-decoration: underline;
    font-weight: 500;
}

.markdown-link:hover {
    color: var(--primary-dark);
    text-decoration: none;
}

.markdown-img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1rem 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.markdown-code {
    background: var(--bg-secondary);
    color: var(--primary-color);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    border: 1px solid var(--border-color);
}

.markdown-pre {
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    overflow-x: auto;
    border: 1px solid var(--border-color);
    margin: 1rem 0;
}

.markdown-blockquote {
    margin: 1rem 0;
    padding: 1rem 1.5rem;
    border-left: 4px solid var(--primary-color);
    background: linear-gradient(135deg, var(--bg-secondary), rgba(59, 130, 246, 0.05));
    font-style: italic;
    color: var(--text-secondary);
    border-radius: 0 0.5rem 0.5rem 0;
}

.markdown-p {
    margin: 1rem 0;
    line-height: 1.7;
    color: var(--text-primary);
}

.markdown-br {
    line-height: 1.5;
}

.news-preview-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.news-preview-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    line-height: 1.3;
}

.news-preview-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.news-preview-content {
    color: var(--text-primary);
    line-height: 1.7;
    font-size: 1rem;
}

.news-preview-content h1,
.news-preview-content h2,
.news-preview-content h3 {
    color: var(--text-primary);
    margin: 2rem 0 1rem 0;
}

.news-preview-content p {
    margin: 1rem 0;
}

.news-preview-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1rem 0;
}

/* Additional Card Effects */
.news-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.05));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

.news-card:hover::after {
    opacity: 1;
}

/* Glow effect for featured cards */
.news-card.featured::before {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(147, 51, 234, 0.2));
    opacity: 0.3;
}

.news-card.breaking::before {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
    opacity: 0.3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .news-container {
        padding: 1rem;
        height: calc(100vh - 2rem);
    }
    
    .news-top-section {
        padding: 0;
    }
    
    .news-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
        padding: 1rem 0;
        margin-bottom: 1rem;
    }
    
    .news-header .btn {
        width: 100%;
        justify-content: center;
    }
    
    .news-filters {
        margin: 0 0 1rem 0;
        padding: 1rem;
    }
    
    .news-stats {
        margin: 0 0 1rem 0;
        padding: 0;
    }
    
    .news-scrollable-content {
        flex: 1;
        overflow-y: auto;
    }
    
    .news-editor-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .news-editor-header .btn {
        width: 100%;
        justify-content: center;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 1.5rem 0.5rem;
    }
    
    .news-card-title {
        min-height: 3.5rem;
        font-size: 1.25rem;
    }
    
    .news-category {
        font-size: 0.7rem;
        padding: 0.4rem 0.8rem;
    }
    
    .news-category i {
        width: 12px;
        height: 12px;
        font-size: 12px;
    }
    
    .news-form-grid {
        grid-template-columns: 1fr;
    }
    
    .news-filters {
        flex-direction: column;
    }
    
    .news-stats {
        grid-template-columns: 1fr;
    }
    
    .news-card-title {
        padding: 0 1.5rem;
        padding-top: 1.5rem;
        font-size: 1.25rem;
    }
    
    .news-card-footer {
        padding: 1rem 1.5rem;
    }
    
    .news-card-status-date {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .news-card-actions {
        gap: 0.5rem;
        top: 0.75rem;
        right: 0.75rem;
    }
    
    .news-card-actions button {
        width: 2rem;
        height: 2rem;
        padding: 0.5rem;
    }
    
    .news-editor-layout {
        grid-template-columns: 1fr;
        gap: 1rem;
        height: auto;
        min-height: auto;
        max-height: none;
    }
    
    .news-editor-left {
        height: auto;
        max-height: 60vh;
        overflow-y: auto;
    }
    
    .news-editor-right {
        position: static;
        max-height: 40vh;
        order: -1;
        overflow: hidden;
    }
    
    .news-preview-content {
        max-height: 100%;
        overflow-y: auto;
    }
}

/* Loading States */
.news-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 4rem;
    color: var(--text-secondary);
}

.news-loading::after {
    content: '';
    width: 2rem;
    height: 2rem;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 1rem;
}

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

/* Empty States */
.news-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-secondary);
}

.news-empty h3 {
    font-size: 1.5rem;
    margin: 0 0 1rem 0;
    color: var(--text-primary);
}

.news-empty p {
    margin: 0 0 2rem 0;
    font-size: 1rem;
}

/* Image Upload Styles */
.image-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: 0.75rem;
    padding: 3rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, var(--bg-primary), var(--bg-secondary));
    position: relative;
    overflow: hidden;
}

.image-upload-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(147, 51, 234, 0.05));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.image-upload-area:hover {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, var(--bg-secondary), var(--bg-primary));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.15);
}

.image-upload-area:hover::before {
    opacity: 1;
}

.image-upload-area.dragover {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(147, 51, 234, 0.1));
    transform: scale(1.02);
}

.image-upload-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.image-upload-text {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
    position: relative;
    z-index: 1;
}

.image-preview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.image-preview-item {
    position: relative;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.image-preview-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.image-preview-remove {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 2rem;
    height: 2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
}

.image-preview-remove:hover {
    background: rgba(0, 0, 0, 0.9);
}

/* Rich Text Editor Styles */
.rich-text-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    padding: 0.75rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-bottom: none;
    border-radius: 0.5rem 0.5rem 0 0;
    margin-bottom: 0;
}

.rich-text-toolbar.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px var(--primary-color);
}

.toolbar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--border-color);
    background: transparent;
    color: var(--text-secondary);
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.875rem;
}

.toolbar-btn:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--primary-color);
}

.toolbar-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.toolbar-separator {
    width: 1px;
    height: 2rem;
    background: var(--border-color);
    margin: 0 0.25rem;
}

.rich-text-content {
    min-height: 200px;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0 0 0.5rem 0.5rem;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 0.875rem;
    outline: none;
    transition: all 0.2s ease;
}

.rich-text-content:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.rich-text-content h1,
.rich-text-content h2,
.rich-text-content h3 {
    margin: 1.5rem 0 1rem 0;
    color: var(--text-primary);
    font-weight: 600;
}

.rich-text-content h1 {
    font-size: 1.5rem;
}

.rich-text-content h2 {
    font-size: 1.25rem;
}

.rich-text-content h3 {
    font-size: 1.125rem;
}

.rich-text-content p {
    margin: 1rem 0;
}

.rich-text-content ul,
.rich-text-content ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.rich-text-content li {
    margin: 0.5rem 0;
}

.rich-text-content blockquote {
    margin: 1rem 0;
    padding: 1rem;
    border-left: 4px solid var(--primary-color);
    background: var(--bg-secondary);
    font-style: italic;
    color: var(--text-secondary);
}

.rich-text-content a {
    color: var(--primary-color);
    text-decoration: underline;
}

.rich-text-content a:hover {
    color: var(--primary-dark);
}

.rich-text-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.375rem;
    margin: 1rem 0;
}

.rich-text-content strong {
    font-weight: 600;
}

.rich-text-content em {
    font-style: italic;
}

.rich-text-content u {
    text-decoration: underline;
}

.rich-text-content s {
    text-decoration: line-through;
}

/* Responsive toolbar */
@media (max-width: 768px) {
    .rich-text-toolbar {
        flex-wrap: wrap;
        gap: 0.125rem;
    }
    
    .toolbar-btn {
        width: 1.75rem;
        height: 1.75rem;
        font-size: 0.75rem;
    }
    
    .toolbar-separator {
        height: 1.75rem;
    }
}

/* Form Sections */
.news-form-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    position: relative;
    z-index: 1;
}

.news-form-section:last-child {
    margin-bottom: 0;
}

.form-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 1.5rem 0;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    position: relative;
    z-index: 2;
}

.form-section-title i {
    color: var(--primary-color);
    font-size: 1.25rem;
}

/* Field Hints */
.field-hint {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    font-style: italic;
}

/* Image Upload Hints */
.image-upload-hint {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
    font-style: italic;
}

/* Checkbox Labels */
.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    background: var(--bg-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.checkbox-label:hover {
    background: var(--bg-primary);
    border-color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
}

.checkbox-label input[type="checkbox"] {
    width: 1.25rem;
    height: 1.25rem;
    margin: 0;
    accent-color: var(--primary-color);
    cursor: pointer;
    border-radius: 0.25rem;
    border: 2px solid var(--border-color);
    background: var(--bg-secondary);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.checkbox-label input[type="checkbox"]:checked {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.checkbox-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
}

.checkbox-text strong {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.checkbox-text small {
    color: var(--text-secondary);
    font-size: 0.75rem;
    line-height: 1.4;
}

/* Checkbox and Radio Styles */
.news-form-group input[type="checkbox"]:not(.checkbox-label input),
.news-form-group input[type="radio"] {
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.75rem;
    accent-color: var(--primary-color);
    cursor: pointer;
    border-radius: 0.25rem;
    border: 2px solid var(--border-color);
    background: var(--bg-secondary);
    transition: all 0.3s ease;
}

.news-form-group input[type="checkbox"]:not(.checkbox-label input):checked,
.news-form-group input[type="radio"]:checked {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.news-form-group label:has(input[type="checkbox"]:not(.checkbox-label input)),
.news-form-group label:has(input[type="radio"]) {
    cursor: pointer;
    padding: 0.75rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.news-form-group label:has(input[type="checkbox"]:not(.checkbox-label input):hover),
.news-form-group label:has(input[type="radio"]:hover) {
    background: var(--bg-secondary);
    border-color: var(--border-color);
}

/* Fix for overlapping elements */
.news-form-group {
    position: relative;
    z-index: 1;
    margin-bottom: 2rem;
    width: 100%;
    min-width: 0;
}

.news-form-group input,
.news-form-group select,
.news-form-group textarea {
    position: relative;
    z-index: 2;
}

/* Ensure proper spacing and prevent overflow */
.news-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2rem;
    align-items: start;
    width: 100%;
    min-width: 0;
}

.news-form-grid .news-form-group {
    min-width: 0;
    width: 100%;
    overflow: hidden;
}

@media (max-width: 768px) {
    .news-form-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.news-form-group.full-width {
    grid-column: 1 / -1;
}

/* Fix for rich text editor */
.rich-text-editor {
    position: relative;
    z-index: 2;
    min-height: 300px;
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    background: var(--bg-primary);
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    overflow: hidden;
}

.rich-text-editor:focus {
    border-color: var(--primary-color);
    box-shadow: 
        0 0 0 3px rgba(59, 130, 246, 0.1),
        0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

.rich-text-editor:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

/* Tags container fix */
.tags-input-container {
    position: relative;
    z-index: 2;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.5rem;
    background: var(--bg-primary);
    min-height: 2.5rem;
    overflow: hidden;
}

/* Image upload area fix */
.image-upload-area {
    position: relative;
    z-index: 2;
    border: 2px dashed var(--border-color);
    border-radius: 0.75rem;
    padding: 3rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--bg-primary);
    overflow: hidden;
}

/* Milytics Modal Styles */
.milytics-modal {
    max-width: 800px;
    width: 95%;
    max-height: 90vh;
    overflow: hidden;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 1rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 10000;
    margin: 2rem;
}

.milytics-modal .modal-header {
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.milytics-modal .modal-header h2 {
    margin: 0;
    color: #333;
    font-size: 1.25rem;
    font-weight: 600;
}

.milytics-modal .modal-close-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 0.25rem;
    transition: all 0.2s ease;
}

.milytics-modal .modal-close-btn:hover {
    background: #e9ecef;
    color: #333;
}

#milytics-modal-content {
    padding: 0;
    overflow: hidden;
}

/* Ensure modal overlay is properly displayed */
#milytics-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

#milytics-modal-overlay.show {
    display: flex !important;
}

/* Force modal to be visible when shown */
#milytics-modal-overlay[style*="flex"] {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.milytics-form-container {
    padding: 1.5rem;
}

.milytics-form-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.milytics-form-header h3 {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 0.75rem 0;
}

.milytics-form-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.5;
}

.milytics-iframe-container {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.milytics-iframe-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(147, 51, 234, 0.05));
    z-index: 1;
    pointer-events: none;
}

.milytics-iframe-container iframe {
    position: relative;
    z-index: 2;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.milytics-form-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 0;
    border-top: 1px solid var(--border-color);
}

.milytics-form-actions .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 160px;
    border: 1px solid transparent;
    height: auto;
    line-height: 1.2;
}

.milytics-form-actions .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.milytics-keywords-preview {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.milytics-keywords-preview h4 {
    color: var(--text-primary);
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.milytics-keywords-preview h4::before {
    content: '🔑';
    font-size: 1.25rem;
}

.keywords-display {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.keyword-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--primary-color), #8B5CF6);
    color: white;
    border-radius: 1.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
}

.keyword-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.keyword-tag::before {
    content: '#';
    font-weight: 700;
    opacity: 0.8;
}

/* Loading state for iframe */
.milytics-iframe-container.loading {
    position: relative;
}

.milytics-iframe-container.loading::after {
    content: 'Cargando formulario de Milytics...';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--text-secondary);
    font-size: 0.875rem;
    z-index: 3;
    background: var(--bg-primary);
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Milytics Keywords in Editor */
.milytics-keywords-section {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(147, 51, 234, 0.05));
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

.milytics-keywords-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.02), rgba(147, 51, 234, 0.02));
    z-index: 1;
    pointer-events: none;
}

.milytics-keywords-section .keywords-display {
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.milytics-keywords-section .keyword-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--primary-color), #8B5CF6);
    color: white;
    border-radius: 1.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
    position: relative;
    z-index: 3;
}

.milytics-keywords-section .keyword-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.milytics-keywords-section .keyword-tag::before {
    content: '🔑';
    font-size: 0.875rem;
    margin-right: 0.25rem;
}

.milytics-keywords-section .field-hint {
    position: relative;
    z-index: 2;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-style: italic;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.milytics-keywords-section .field-hint::before {
    content: '✨';
    font-size: 0.9rem;
}

/* Responsive design for Milytics modal */
@media (max-width: 768px) {
    .milytics-modal {
        width: 98%;
        max-height: 95vh;
        margin: 1rem;
    }
    
    .milytics-form-container {
        padding: 1rem;
    }
    
    .milytics-iframe-container {
        padding: 0.5rem;
    }
    
    .milytics-iframe-container iframe {
        height: 400px;
    }
    
    .milytics-form-actions {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .milytics-form-actions .btn {
        width: 100%;
        min-width: auto;
    }
    
    .keywords-display {
        gap: 0.5rem;
    }
    
    .keyword-tag {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    .milytics-keywords-section {
        padding: 1rem;
    }
    
    .milytics-keywords-section .keywords-display {
        gap: 0.5rem;
    }
    
    .milytics-keywords-section .keyword-tag {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}

/* Instagram Status Styles */
.instagram-status {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.instagram-status i {
    width: 1.2rem;
    height: 1.2rem;
    transition: all 0.3s ease;
}

/* Estado no publicado (apagado) */
.instagram-status.not-published {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.4);
}

.instagram-status.not-published:hover {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.6);
    transform: scale(1.05);
}

/* Estado publicado (encendido) */
.instagram-status.published {
    background: linear-gradient(135deg, #E4405F, #C13584);
    border: 1px solid rgba(196, 53, 132, 0.6);
    color: white;
    box-shadow: 0 0 10px rgba(196, 53, 132, 0.3);
}

.instagram-status.published:hover {
    background: linear-gradient(135deg, #F56040, #D62976);
    box-shadow: 0 0 15px rgba(196, 53, 132, 0.5);
    transform: scale(1.05);
}

/* Animación de pulso para estado publicado */
.instagram-status.published::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #E4405F, #C13584);
    border-radius: 0.5rem;
    opacity: 0.3;
    transform: translate(-50%, -50%) scale(1);
    animation: instagram-pulse 2s infinite;
    z-index: -1;
}

@keyframes instagram-pulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.3;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.1;
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.3;
    }
}

/* Responsive para Instagram status */
@media (max-width: 768px) {
    .instagram-status {
        width: 1.8rem;
        height: 1.8rem;
    }
    
    .instagram-status i {
        width: 1rem;
        height: 1rem;
    }
}

/* Botón de generar imagen para redes sociales */
.generate-social-image-btn {
    /* Hereda los estilos de .news-card-actions button */
}

.generate-social-image-btn i {
    width: 1.2rem;
    height: 1.2rem;
}

/* Botón de plantilla */
.template-btn {
    /* Hereda los estilos de .news-card-actions button */
}

.template-btn i {
    width: 1.2rem;
    height: 1.2rem;
}

/* Clase para ocultar elementos temporales durante la generación */
.template-generator-hidden {
    position: absolute;
    left: -9999px;
    top: 0;
    width: 1080px;
    height: 1350px;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}

/* Modal para generar imagen para redes sociales */
.social-image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

.social-image-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.social-image-modal-content {
    position: relative;
    background: linear-gradient(135deg, rgba(30, 30, 40, 0.95), rgba(20, 20, 30, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 0;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

.social-image-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.social-image-modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #FFFFFF;
}

.social-image-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.social-image-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
}

.social-image-modal-close i {
    width: 1.2rem;
    height: 1.2rem;
}

.social-image-modal-body {
    padding: 1.5rem;
}

.social-image-form-group {
    margin-bottom: 2rem;
}

.social-image-form-group:last-of-type {
    margin-bottom: 0;
}

.social-image-label {
    display: block;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.social-image-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.social-image-option {
    position: relative;
    cursor: pointer;
}

.social-image-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.social-image-option-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.5rem 1rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
    text-align: center;
}

.social-image-option-content i {
    width: 2rem;
    height: 2rem;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
}

.social-image-option-content span {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}

.social-image-option:hover .social-image-option-content {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.social-image-option:hover .social-image-option-content i,
.social-image-option:hover .social-image-option-content span {
    color: #FFFFFF;
}

.social-image-option input[type="radio"]:checked + .social-image-option-content,
.social-image-option input[type="checkbox"]:checked + .social-image-option-content,
.social-image-option-always-selected .social-image-option-content {
    border-color: #4F46E5;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.2), rgba(79, 70, 229, 0.1));
    box-shadow: 0 0 20px rgba(79, 70, 229, 0.3);
    cursor: default;
}

.social-image-option input[type="radio"]:checked + .social-image-option-content i,
.social-image-option input[type="radio"]:checked + .social-image-option-content span,
.social-image-option input[type="checkbox"]:checked + .social-image-option-content i,
.social-image-option input[type="checkbox"]:checked + .social-image-option-content span,
.social-image-option-always-selected .social-image-option-content i,
.social-image-option-always-selected .social-image-option-content span {
    color: #818CF8;
}

.social-image-option-always-selected {
    cursor: default;
    pointer-events: none;
}

.social-image-option-always-selected:hover .social-image-option-content {
    transform: none;
    border-color: #4F46E5;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.2), rgba(79, 70, 229, 0.1));
}

.social-image-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.social-image-modal-footer .btn {
    min-width: 120px;
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* Responsive para el modal */
@media (max-width: 768px) {
    .social-image-modal-content {
        width: 95%;
        max-width: none;
    }
    
    .social-image-options {
        grid-template-columns: 1fr;
    }
    
    .social-image-modal-footer {
        flex-direction: column;
    }
    
    .social-image-modal-footer .btn {
        width: 100%;
    }
    
    .generate-social-image-btn {
        width: 1.8rem;
        height: 1.8rem;
    }
    
    .generate-social-image-btn i {
        width: 1rem;
        height: 1rem;
    }
    
    .template-btn {
        width: 1.8rem;
        height: 1.8rem;
    }
    
    .template-btn i {
        width: 1rem;
        height: 1rem;
    }
}

/* Modal de preview de plantilla */
.template-preview-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    animation: fadeIn 0.2s ease;
}

.template-preview-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(4px);
}

.template-preview-modal-content {
    position: relative;
    background: linear-gradient(135deg, rgba(30, 30, 40, 0.98), rgba(20, 20, 30, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 0;
    width: 95%;
    max-width: 1200px;
    max-height: 95vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
    animation: slideUp 0.3s ease;
    display: flex;
    flex-direction: column;
}

.template-preview-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.template-preview-modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #FFFFFF;
}

.template-preview-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.template-preview-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
}

.template-preview-modal-close i {
    width: 1.2rem;
    height: 1.2rem;
}

.template-preview-modal-body {
    padding: 1.5rem;
    flex: 1;
    overflow: auto;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    min-height: 0;
    max-height: calc(95vh - 200px);
}

.template-preview-image-container {
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 0.5rem;
    padding: 1rem;
    overflow: auto;
}

.template-preview-image-container img {
    max-width: 100%;
    max-height: 70vh;
    height: auto;
    width: auto;
    border-radius: 0.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.template-preview-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.template-preview-modal-footer .btn {
    min-width: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.template-preview-modal-footer .btn i {
    width: 1rem;
    height: 1rem;
}

@media (max-width: 768px) {
    .template-preview-modal-content {
        width: 98%;
        max-height: 98vh;
    }
    
    .template-preview-image-container {
        padding: 0.5rem;
    }
    
    .template-preview-image-container img {
        max-height: 60vh;
    }
    
    .template-preview-modal-footer {
        flex-direction: column;
    }
    
    .template-preview-modal-footer .btn {
        width: 100%;
    }
}

/* Template Editor Styles moved to css/template-editor.css */

