#news-kartabl-form {
    direction: rtl;
    font-family: Tahoma, sans-serif;
    max-width: 900px;
    margin: 0 auto;
    padding: 30px;
    background: #ffffff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-radius: 15px;
    border: 1px solid #e0e0e0;
}

.news-title label,
.custom-fields > label {
    display: block;
    font-size: 1.1em;
    color: #333;
    margin-bottom: 8px;
    font-weight: 500;
}

.news-title input,
.custom-fields input,
.custom-fields textarea,
.custom-fields select {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 25px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.news-title input:focus,
.custom-fields input:focus,
.custom-fields textarea:focus,
.custom-fields select:focus {
    border-color: #b20000;
    outline: none;
    box-shadow: 0 0 5px rgba(178, 0, 0, 0.2);
}

button[type="submit"] {
    background: #b20000;
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    margin-top: 25px;
    font-size: 1.1em;
    font-weight: 500;
    transition: background 0.3s ease;
}

button[type="submit"]:hover {
    background: #900000;
}

#image-section,
#video-section {
    margin-top: 15px;
    padding: 15px;
    border: 2px dashed #b20000;
    border-radius: 10px;
    background: #fff9f9;
    display: none;
}

#gallery-preview,
#featured-preview,
#lead-image-preview {
    display: flex;
    flex-wrap: wrap;
    margin-top: 10px;
}

#gallery-preview img,
#featured-preview img,
#lead-image-preview img {
    max-width: 120px;
    margin: 5px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    background-color: #f9ebeb;
    padding: 5px;
    transition: transform 0.3s ease;
}

#gallery-preview img:hover,
#featured-preview img:hover,
#lead-image-preview img:hover {
    transform: scale(1.05);
}

.wp-editor-container {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    margin-top: 8px;
}

.wp-editor-container textarea {
    border: none !important;
    border-radius: 0 !important;
}

#upload-gallery,
#upload-video,
#upload-featured,
#upload-lead-image {
    background: #f8f8f8;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    color: #b20000;
    font-weight: 500;
    transition: background 0.3s ease;
}

#upload-gallery:hover,
#upload-video:hover,
#upload-featured:hover,
#upload-lead-image:hover {
    background: #f0f0f0;
}

.media-section {
    border: 2px solid #b20000;
    padding: 20px;
    margin-top: 20px;
    border-radius: 10px;
    background: #fff9f9;
}

.upload-boxes {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    gap: 15px;
}

.upload-box {
    border: 2px dashed #00bfff;
    padding: 20px;
    text-align: center;
    background: linear-gradient(135deg, #f0faff, #e0f0ff);
    border-radius: 10px;
    width: 30%;
    transition: transform 0.3s ease;
}

.upload-box:hover {
    transform: translateY(-5px);
    background: linear-gradient(135deg, #e0f0ff, #d0e5ff);
}

@media (max-width: 768px) {
    .upload-boxes {
        flex-direction: column;
    }
    .upload-box {
        width: 100%;
        margin-bottom: 15px;
    }
}

.news-type,
.news-structure {
    margin-top: 8px;
    display: flex;
    gap: 15px;
}

.news-type input[type="radio"],
.news-structure input[type="radio"],
.custom-fields input[type="checkbox"] {
    display: none;
}

.news-type input[type="radio"] + label,
.news-structure input[type="radio"] + label,
.custom-fields input[type="checkbox"] + label {
    position: relative;
    padding: 10px 15px;
    border: 2px solid #b20000;
    border-radius: 20px;
    color: #b20000;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
    display: inline-block;
    margin: 5px 0;
}

.news-type input[type="radio"]:checked + label,
.news-structure input[type="radio"]:checked + label,
.custom-fields input[type="checkbox"]:checked + label {
    background: #b20000;
    color: #fff;
    box-shadow: 0 2px 10px rgba(178, 0, 0, 0.3);
}

.news-type input[type="radio"] + label:hover,
.news-structure input[type="radio"] + label:hover,
.custom-fields input[type="checkbox"] + label:hover {
    background: #ffebee;
}

#success-message {
    display: none;
    color: #27ae60;
    font-size: 1.1em;
    margin-top: 15px;
    padding: 10px;
    background: #e8f5e9;
    border-radius: 8px;
    text-align: center;
}

/* Enhanced layout for image sections */
.image-section {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

.image-section .upload-box {
    flex: 1;
    border-color: #00bfff;
}

.image-section .upload-box img {
    border: 2px solid #ddd;
    border-radius: 8px;
}

/* Structure-based styling */
.post-content-wrapper {
    margin-top: 20px;
}

.post-featured-image {
    margin-bottom: 20px;
    text-align: center;
}

.post-featured-image img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.post-content-text {
    margin-bottom: 20px;
}

.structure-image .post-content-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.structure-image .post-content-text {
    flex: 2;
}

.structure-image .post-gallery {
    flex: 1;
    margin-top: 0;
}

/* Gallery Styling */
.post-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.post-gallery a {
    display: block;
}

.post-gallery img {
    max-width: 150px;
    border-radius: 10px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    background-color: #fff0f0;
    padding: 8px;
    transition: transform 0.3s ease;
}

.post-gallery img:hover {
    transform: scale(1.1);
}
/* Add to style.css */
.news-list-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.news-list-table th, .news-list-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

.news-list-table th {
    background-color: #f2f2f2;
}

.news-list-table a {
    margin: 0 5px;
    color: #b20000;
    text-decoration: none;
}

.news-list-table a:hover {
    text-decoration: underline;
}
/* Add to style.css */
.news-list-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.news-list-table th, .news-list-table td {
    padding: 12px 15px;
    text-align: center;
    border-bottom: 1px solid #e0e0e0;
}

.news-list-table th {
    background-color: #2c3e50;
    color: #ffffff;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.news-list-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

.news-list-table tr:hover {
    background-color: #ecf0f1;
    transition: background-color 0.3s ease;
}

.news-list-table a.edit-btn {
    display: inline-block;
    padding: 6px 12px;
    background-color: #3498db;
    color: #ffffff;
    text-decoration: none;
    border-radius: 4px;
    margin-right: 5px;
}

.news-list-table a.edit-btn:hover {
    background-color: #2980b9;
}

.news-list-table a.delete-btn {
    display: inline-block;
    padding: 6px 12px;
    background-color: #e74c3c;
    color: #ffffff;
    text-decoration: none;
    border-radius: 4px;
}

.news-list-table a.delete-btn:hover {
    background-color: #c0392b;
}

form {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

form input, form select, form button {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

form button {
    background-color: #2c3e50;
    color: #ffffff;
    border: none;
    cursor: pointer;
}

form button:hover {
    background-color: #34495e;
}
/* Add to style.css */
.news-list-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 20px;
    background-color: #ffffff;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    overflow: hidden;
    animation: fadeIn 0.5s ease-in-out;
}

.news-list-table th, .news-list-table td {
    padding: 15px 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.news-list-table th {
    background: linear-gradient(90deg, #2c3e50, #3498db);
    color: #ffffff;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    position: sticky;
    top: 0;
    z-index: 1;
}

.news-list-table td {
    border-bottom: 1px solid #e9ecef;
}

.news-list-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

.news-list-table tr:hover {
    background-color: #e9f4fb;
    transform: scale(1.01);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.news-list-table a.edit-btn {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    margin-right: 8px;
    transition: all 0.3s ease;
}

.news-list-table a.edit-btn:hover {
    background: linear-gradient(45deg, #2980b9, #1f5c8a);
    transform: translateY(-2px);
}

.news-list-table a.delete-btn {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(45deg, #e74c3c, #c0392b);
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.news-list-table a.delete-btn:hover {
    background: linear-gradient(45deg, #c0392b, #a93226);
    transform: translateY(-2px);
}

form {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    background: #f1f3f5;
    padding: 15px;
    border-radius: 8px;
}

form input, form select, form button {
    padding: 10px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

form input:focus, form select:focus {
    border-color: #3498db;
    outline: none;
}

form button {
    background: linear-gradient(90deg, #2c3e50, #34495e);
    color: #ffffff;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

form button:hover {
    background: linear-gradient(90deg, #34495e, #2c3e50);
    transform: translateY(-2px);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
/* Add to style.css */
#news-kartabl-form {
    max-width: 800px;
    margin: 20px auto;
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.form-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.form-header h2 {
    margin: 0;
    font-size: 24px;
    color: #2c3e50;
}

.form-body {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-weight: 600;
    color: #34495e;
}

.form-group input[type="text"],
.form-group input[type="date"],
.form-group textarea,
.form-group select {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="date"]:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: #3498db;
    outline: none;
}

.news-type, .news-structure {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.news-type input, .news-structure input {
    margin-right: 5px;
}

.news-content {
    margin-top: 10px;
}

.image-section {
    display: flex;
    gap: 20px;
}

.upload-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.upload-box button {
    padding: 8px 15px;
    background-color: #3498db;
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.upload-box button:hover {
    background-color: #2980b9;
}

#gallery-preview img, #lead-image-preview img, #featured-preview img {
    max-width: 120px;
    margin: 5px 0;
    border-radius: 5px;
}

button[type="submit"] {
    padding: 12px 20px;
    background: linear-gradient(90deg, #2c3e50, #34495e);
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    align-self: flex-start;
}

button[type="submit"]:hover {
    background: linear-gradient(90deg, #34495e, #2c3e50);
}

#success-message {
    margin-top: 10px;
    text-align: center;
}

/* News List Table Styles */
.news-list-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 20px;
    background-color: #ffffff;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    overflow: hidden;
    animation: fadeIn 0.5s ease-in-out;
}

.news-list-table th, .news-list-table td {
    padding: 15px 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.news-list-table th {
    background: linear-gradient(90deg, #2c3e50, #3498db);
    color: #ffffff;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    position: sticky;
    top: 0;
    z-index: 1;
}

.news-list-table td {
    border-bottom: 1px solid #e9ecef;
}

.news-list-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

.news-list-table tr:hover {
    background-color: #e9f4fb;
    transform: scale(1.01);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.news-list-table a.edit-btn {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    margin-right: 8px;
    transition: all 0.3s ease;
}

.news-list-table a.edit-btn:hover {
    background: linear-gradient(45deg, #2980b9, #1f5c8a);
    transform: translateY(-2px);
}

.news-list-table a.delete-btn {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(45deg, #e74c3c, #c0392b);
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.news-list-table a.delete-btn:hover {
    background: linear-gradient(45deg, #c0392b, #a93226);
    transform: translateY(-2px);
}

form {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    background: #f1f3f5;
    padding: 15px;
    border-radius: 8px;
}

form input, form select, form button {
    padding: 10px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

form input:focus, form select:focus {
    border-color: #3498db;
    outline: none;
}

form button {
    background: linear-gradient(90deg, #2c3e50, #34495e);
    color: #ffffff;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

form button:hover {
    background: linear-gradient(90deg, #34495e, #2c3e50);
    transform: translateY(-2px);
}

/* Stats Styles */
.stats-container {
    max-width: 1000px;
    margin: 20px auto;
    padding: 20px;
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.stats-container h2, .stats-container h3 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 20px;
}

.chart-container {
    position: relative;
    margin: 20px 0;
    height: 400px;
}

#authorFilter {
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 5px;
    border: 1px solid #ddd;
    width: 200px;
    align-self: center;
    display: block;
}

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