:root {
    --primary-color: #f39c12;
    --secondary-color: #e67e22;
    --dark-color: #2c3e50;
    --light-bg: #f8f9fa;
    --border-color: #ddd;
    --text-color: #333;
    --white: #ffffff;
}

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

body {
    font-family: 'Roboto', 'Arial', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: #f5f5f5;
}

/* Header */
.top-bar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 8px 0;
    font-size: 13px;
}

.header-main {
    background-color: var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 20px 0;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-right: 10px;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text span:first-child {
    font-size: 32px;
    font-weight: 700;
    color: var(--dark-color);
    letter-spacing: -1px;
}

.logo-text span:last-child {
    font-size: 14px;
    color: #999;
    letter-spacing: 3px;
    text-transform: uppercase;
}

/* Navigation */
.main-nav {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.main-nav .navbar-nav {
    width: 100%;
}

.main-nav .nav-link {
    color: var(--white) !important;
    padding: 15px 20px !important;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.main-nav .nav-link:hover,
.main-nav .nav-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    border-bottom-color: var(--white);
}

/* Featured Section */
.featured-section {
    background-color: var(--white);
    padding: 40px 0;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.featured-card {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    height: 300px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    transition: transform 0.3s ease;
    cursor: pointer;
}

.featured-card:hover {
    transform: translateY(-5px);
}

.featured-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-card:hover img {
    transform: scale(1.1);
}

.featured-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
    padding: 25px;
    color: var(--white);
}

.featured-category {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 3px;
    margin-bottom: 10px;
}

.featured-overlay h3 {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.featured-overlay h3 a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.featured-overlay h3 a:hover {
    color: var(--primary-color);
}

.featured-meta {
    font-size: 12px;
    opacity: 0.8;
    margin-top: 10px;
}

/* Article Cards */
.article-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    margin-bottom: 30px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    transform: translateY(-3px);
}

.article-image {
    position: relative;
    overflow: hidden;
    height: 220px;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .article-image img {
    transform: scale(1.1);
}

.article-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 5px 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 3px;
}

.article-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.article-content h3 {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 12px;
}

.article-content h3 a {
    color: var(--dark-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.article-content h3 a:hover {
    color: var(--primary-color);
}

.article-excerpt {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
    flex-grow: 1;
}

.article-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    font-size: 12px;
    color: #999;
}

.article-meta i {
    margin-right: 5px;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 20px;
}

.sidebar-widget {
    background-color: var(--white);
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.sidebar-widget h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary-color);
}

.sidebar-article {
    display: flex;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.sidebar-article:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-article-image {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    margin-right: 15px;
}

.sidebar-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-article-content h4 {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 8px;
}

.sidebar-article-content h4 a {
    color: var(--dark-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.sidebar-article-content h4 a:hover {
    color: var(--primary-color);
}

.sidebar-article-meta {
    font-size: 11px;
    color: #999;
}

/* Article Page */
.article-single {
    background-color: var(--white);
    border-radius: 8px;
    padding: 40px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    margin-bottom: 30px;
}

.article-single-header {
    margin-bottom: 30px;
}

.article-single-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--dark-color);
    line-height: 1.3;
    margin-bottom: 20px;
}

.article-single-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 15px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
    color: #666;
}

.article-single-meta i {
    color: var(--primary-color);
    margin-right: 5px;
}

.article-single-image {
    margin: 30px 0;
    border-radius: 8px;
    overflow: hidden;
}

.article-single-image img {
    width: 100%;
    height: auto;
    display: block;
}

.article-single-content {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-color);
}

.article-single-content p {
    margin-bottom: 20px;
}

.article-single-content h2 {
    font-size: 28px;
    font-weight: 700;
    margin: 30px 0 20px;
    color: var(--dark-color);
}

.article-single-content h3 {
    font-size: 24px;
    font-weight: 600;
    margin: 25px 0 15px;
    color: var(--dark-color);
}

/* Footer */
footer {
    background-color: var(--dark-color);
    color: var(--white);
    padding: 40px 0 20px;
    margin-top: 50px;
}

.footer-logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 15px;
}

.footer-description {
    color: #bbb;
    font-size: 14px;
    line-height: 1.6;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #bbb;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 14px;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    margin-top: 30px;
    text-align: center;
    color: #999;
    font-size: 13px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    margin: 40px 0;
}

.pagination .page-link {
    color: var(--dark-color);
    border-color: var(--border-color);
    padding: 10px 15px;
    margin: 0 5px;
    border-radius: 5px;
}

.pagination .page-link:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
}

.pagination .page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Admin Styles */
.admin-container {
    max-width: 1200px;
    margin: 50px auto;
    padding: 0 15px;
}

.admin-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 30px;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.admin-card {
    background-color: var(--white);
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    margin-bottom: 30px;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(243, 156, 18, 0.25);
}

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

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

.table-hover tbody tr:hover {
    background-color: #f8f9fa;
}

/* Responsive */
@media (max-width: 768px) {
    .featured-card {
        height: 250px;
    }
    
    .featured-overlay h3 {
        font-size: 16px;
    }
    
    .article-single {
        padding: 20px;
    }
    
    .article-single-title {
        font-size: 28px;
    }
    
    .main-nav .nav-link {
        padding: 12px 15px !important;
    }
}

/* Loading Spinner */
.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 50px auto;
}

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

/* Alert Messages */
.alert {
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.alert-success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
}
