/* ============================================
   ஊராட்சி மலர் - Tamil News Website Styles
   ============================================ */

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Serif Tamil', serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-variation-settings: "wdth" 100;
    font-size: 16px;
    line-height: 1.8;
    color: #141414;
    background-color: #fff;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

a:hover {
    color: #fe8400;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.header-top {
    background: #333;
    color: #fff;
    font-size: 13px;
    padding: 8px 0;
}

.header-top .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-top-left {
    display: flex;
    align-items: center;
}

    .header-top-right {
        display: flex;
        align-items: center;
        gap: 16px;
    }

    .lang-toggle {
        display: inline-flex;
    }

    .lang-btn {
        padding: 4px 12px;
        border: 1px solid rgba(255,255,255,0.4);
        border-radius: 4px;
        font-size: 0.8rem;
        font-weight: 500;
        color: #fff;
        text-decoration: none;
        transition: all 0.2s ease;
        white-space: nowrap;
    }

    .lang-btn:hover {
        background: rgba(255,255,255,0.15);
        border-color: #fff;
        color: #fff;
    }

.header-top-right a {
    color: #ccc;
    font-size: 13px;
}

.header-top-right a:hover {
    color: #fff;
}

.header-main {
    padding: 15px 0;
}

.header-main .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.site-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.logo h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: #0c4767;
    letter-spacing: 1px;
    line-height: 1.2;
}

.logo .tagline {
    font-size: 0.9rem;
    color: #666;
    margin-top: 2px;
}


/* Navigation */
.main-nav {
    background: #333;
    position: sticky;
    top: 0;
    z-index: 99;
}

.main-nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    position: relative;
}

.nav-menu > li > a {
    display: block;
    padding: 15px 18px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s ease;
}

.nav-menu > li > a:hover,
.nav-menu > li > a.active {
    background: #fe8400;
    color: #fff;
}

/* Dropdown */
.has-dropdown > .dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: #444;
    min-width: 200px;
    list-style: none;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease;
    z-index: 100;
}

.has-dropdown:hover > .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown li a {
    display: block;
    padding: 10px 20px;
    color: #fff;
    font-size: 13px;
}

.dropdown li a:hover {
    background: #fe8400;
    color: #fff;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    padding: 15px;
    cursor: pointer;
}

/* Nav Search */
.nav-search {
    padding: 0 15px;
}

.search-toggle {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-toggle:hover {
    color: #fe8400;
}

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-container {
    width: 90%;
    max-width: 600px;
}

.search-container form {
    display: flex;
    gap: 10px;
}

.search-input {
    flex: 1;
    padding: 15px 20px;
    font-size: 18px;
    border: none;
    border-radius: 4px;
    font-family: inherit;
}

.search-submit,
.search-close {
    background: #fe8400;
    border: none;
    color: #fff;
    padding: 15px 20px;
    cursor: pointer;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-close {
    background: #666;
}

.search-submit:hover,
.search-close:hover {
    opacity: 0.9;
}

/* Hero Section */
.hero-section {
    padding: 20px 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.hero-card {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
}

.hero-card a {
    display: block;
}

.hero-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

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

.hero-card:hover .hero-image img {
    transform: scale(1.05);
}

.hero-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    padding: 20px;
}

.hero-content h2 {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
}

.hero-main .hero-image {
    height: 100%;
    min-height: 350px;
}

.hero-main .hero-content h2 {
    font-size: 1.3rem;
}

/* Placeholder Image */
.placeholder-image {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e0e0e0 0%, #f5f5f5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 14px;
}

.placeholder-image.small {
    height: 120px;
}


/* Category Section */
.category-section {
    padding: 30px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-top: 3px solid #0c4767;
}

.section-header h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #141414;
}

.more-link {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #0c4767;
    font-size: 14px;
    font-weight: 500;
}

.more-link:hover {
    color: #fe8400;
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.article-card {
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.article-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.article-card a {
    display: block;
}

.article-image {
    height: 180px;
    overflow: hidden;
}

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

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

.article-content {
    padding: 15px;
}

.article-content h3 {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: #222;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-date {
    font-size: 12px;
    color: #888;
    margin-top: 8px;
    display: block;
}

/* Article Page */
.article-page {
    padding: 30px 0;
}

.article-header {
    margin-bottom: 20px;
}

.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    font-size: 14px;
    color: #666;
}

.article-category {
    background: #0c4767;
    color: #fff;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.article-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.3;
    color: #141414;
}

.article-featured-image {
    margin-bottom: 25px;
    border-radius: 10px;
    overflow: hidden;
}

.article-featured-image img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
}

.article-body {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

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

.article-body h2 {
    font-size: 1.5rem;
    margin: 30px 0 15px;
    color: #141414;
}

.article-body h3 {
    font-size: 1.3rem;
    margin: 25px 0 12px;
    color: #141414;
}

.article-body img {
    border-radius: 8px;
    margin: 20px 0;
}

.article-body blockquote {
    border-left: 4px solid #0c4767;
    padding: 15px 20px;
    margin: 20px 0;
    background: #f9f9f9;
    font-style: italic;
}

.article-body ul,
.article-body ol {
    margin: 15px 0;
    padding-left: 30px;
}

.article-body li {
    margin-bottom: 8px;
}

.article-share {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 15px;
}

.share-label {
    font-weight: 600;
    color: #333;
}

.share-btn {
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    color: #fff;
}

.share-btn.facebook { background: #1877f2; }
.share-btn.twitter { background: #1da1f2; }
.share-btn.whatsapp { background: #25d366; }

.share-btn:hover {
    color: #fff;
    opacity: 0.9;
}

/* Related Articles */
.related-articles {
    padding: 40px 0;
    background: #f9f9f9;
    margin-top: 40px;
}

/* Category Page */
.category-page {
    padding: 30px 0;
}

.category-header {
    margin-bottom: 30px;
}

.category-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #0c4767;
    margin-bottom: 10px;
}

.category-header p {
    color: #666;
    font-size: 1.1rem;
}

.no-articles {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 1.1rem;
}

/* Search Page */
.search-page {
    padding: 30px 0;
}

.search-header {
    margin-bottom: 30px;
}

.search-header h1 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.search-header p {
    color: #666;
}

/* Static Pages */
.static-page {
    padding: 40px 0;
    max-width: 800px;
    margin: 0 auto;
}

.static-page h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #0c4767;
    margin-bottom: 25px;
}

.page-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

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

.page-content h2 {
    font-size: 1.5rem;
    margin: 30px 0 15px;
    color: #141414;
}

.page-content ul {
    margin: 15px 0;
    padding-left: 30px;
}

.page-content li {
    margin-bottom: 10px;
}

.contact-info {
    display: grid;
    gap: 25px;
    margin-top: 25px;
}

.contact-item {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.contact-item h3 {
    font-size: 1.1rem;
    color: #0c4767;
    margin-bottom: 8px;
}

/* Error Page */
.error-page {
    padding: 80px 20px;
    text-align: center;
}

.error-content h1 {
    font-size: 5rem;
    font-weight: 800;
    color: #0c4767;
    margin-bottom: 10px;
}

.error-content h2 {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 15px;
}

.error-content p {
    color: #666;
    margin-bottom: 25px;
}

.btn-home {
    display: inline-block;
    padding: 12px 30px;
    background: #0c4767;
    color: #fff;
    border-radius: 4px;
    font-weight: 500;
}

.btn-home:hover {
    background: #fe8400;
    color: #fff;
}

/* Footer */
.site-footer {
    background: #333;
    color: #fff;
}

.footer-links {
    padding: 20px 0;
    border-bottom: 1px solid #444;
}

.footer-links .container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.footer-links a {
    color: #ccc;
    font-size: 14px;
}

.footer-links a:hover {
    color: #fe8400;
}

.footer-main {
    padding: 20px 0;
}

.footer-main .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-left p {
    color: #999;
    font-size: 13px;
}

.footer-right {
    display: flex;
    gap: 15px;
}

.social-icon {
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #444;
    transition: all 0.2s ease;
}

.social-icon:hover {
    background: #fe8400;
    color: #fff;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #0c4767;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 50;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #fe8400;
    color: #fff;
}

/* ============================================
   Admin Styles
   ============================================ */

.admin-body {
    background: #f0f2f5;
    min-height: 100vh;
}

.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.login-box {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-box h1 {
    font-size: 2rem;
    color: #0c4767;
    margin-bottom: 5px;
}

.login-box h2 {
    font-size: 1rem;
    color: #666;
    font-weight: 400;
    margin-bottom: 30px;
}

.error-message {
    background: #ffebee;
    color: #c62828;
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 14px;
}

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

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #0c4767;
}

.btn-login {
    width: 100%;
    padding: 14px;
    background: #0c4767;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-login:hover {
    background: #fe8400;
}

.back-link {
    margin-top: 20px;
    font-size: 14px;
    color: #666;
}

.back-link a {
    color: #0c4767;
}

/* ============================================
   Dashboard
   ============================================ */

.dash-welcome {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    padding: 28px 32px;
    background: linear-gradient(135deg, #0c4767 0%, #1a6b8a 100%);
    border-radius: 14px;
    color: #fff;
}
.dash-welcome-text h1 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 4px;
}
.dash-welcome-text p {
    font-size: 0.85rem;
    opacity: 0.8;
}
.dash-welcome-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}
.dash-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    font-family: inherit;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}
.dash-btn-primary {
    background: #fe8400;
    color: #fff;
}
.dash-btn-primary:hover {
    background: #e57600;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(254,132,0,0.35);
}
.dash-btn-outline {
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
}
.dash-btn-outline:hover {
    background: rgba(255,255,255,0.25);
}

.dash-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 28px;
}
.dash-stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 22px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}
.dash-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.dash-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.dash-stat-info {
    display: flex;
    flex-direction: column;
}
.dash-stat-number {
    font-size: 1.6rem;
    font-weight: 700;
    color: #1a202c;
    line-height: 1.2;
}
.dash-stat-label {
    font-size: 0.78rem;
    color: #718096;
    font-weight: 500;
}

.dash-row {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 20px;
}
.dash-col-main, .dash-col-side {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dash-panel {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    overflow: hidden;
}
.dash-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 22px;
    border-bottom: 1px solid #edf2f7;
}
.dash-panel-header h2 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1a202c;
}
.dash-link {
    font-size: 0.8rem;
    color: #fe8400;
    text-decoration: none;
    font-weight: 600;
}
.dash-link:hover {
    text-decoration: underline;
}

.dash-table-wrap {
    overflow-x: auto;
}
.dash-table {
    width: 100%;
    border-collapse: collapse;
}
.dash-table th {
    padding: 10px 22px;
    font-size: 0.72rem;
    font-weight: 600;
    color: #a0aec0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: left;
    background: #f7fafc;
    border-bottom: 1px solid #edf2f7;
}
.dash-table td {
    padding: 14px 22px;
    font-size: 0.85rem;
    color: #4a5568;
    border-bottom: 1px solid #f0f0f0;
}
.dash-table tr:last-child td {
    border-bottom: none;
}
.dash-table tr:hover td {
    background: #f7fafc;
}
.dash-td-title {
    max-width: 260px;
}
.dash-article-title {
    font-weight: 600;
    color: #2d3748;
}
.dash-td-date {
    color: #a0aec0;
    font-size: 0.8rem;
    white-space: nowrap;
}
.dash-td-action {
    text-align: right;
    width: 40px;
}
.dash-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    color: #718096;
    transition: all 0.15s;
}
.dash-action-btn:hover {
    background: #edf2f7;
    color: #0c4767;
}

.dash-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.3px;
}
.dash-badge-success {
    background: #f0fff4;
    color: #276749;
}
.dash-badge-warning {
    background: #fffaf0;
    color: #c05621;
}
.dash-badge-cat {
    background: #ebf8ff;
    color: #2b6cb0;
}
.dash-badge-star {
    background: #fefcbf;
    color: #975a16;
    margin-left: 4px;
}

.dash-pending-count {
    background: #ed8936;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}
.dash-pending-list {
    display: flex;
    flex-direction: column;
}
.dash-pending-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 22px;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
}
.dash-pending-item:last-child {
    border-bottom: none;
}
.dash-pending-item:hover {
    background: #f7fafc;
}
.dash-pending-item svg {
    color: #cbd5e0;
    flex-shrink: 0;
}
.dash-pending-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.dash-pending-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #2d3748;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.dash-pending-meta {
    font-size: 0.75rem;
    color: #a0aec0;
}

.dash-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 32px 20px;
    color: #c6f6d5;
}
.dash-empty p {
    margin-top: 8px;
    font-size: 0.85rem;
    color: #68d391;
    font-weight: 600;
}

.dash-quick-stats {
    padding: 6px 22px;
}
.dash-qs-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}
.dash-qs-row:last-child {
    border-bottom: none;
}
.dash-qs-label {
    font-size: 0.83rem;
    color: #718096;
}
.dash-qs-value {
    font-size: 0.9rem;
    font-weight: 700;
    color: #2d3748;
}

/* Toggle Switch */
.dash-toggle {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    cursor: pointer;
}
.dash-toggle-track {
    width: 40px;
    height: 22px;
    background: #cbd5e0;
    border-radius: 11px;
    position: relative;
    transition: background 0.25s ease;
}
.dash-toggle-on .dash-toggle-track {
    background: #38b2ac;
}
.dash-toggle-thumb {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.25s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.dash-toggle-on .dash-toggle-thumb {
    transform: translateX(18px);
}

/* Danger Action Button */
.dash-action-danger:hover {
    background: #fff5f5;
    color: #e53e3e;
}

/* Admin Form Overrides */
.admin-form .form-group input,
.admin-form .form-group textarea,
.admin-form .form-group select {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color 0.2s ease;
    outline: none;
}
.admin-form .form-group input:focus,
.admin-form .form-group textarea:focus,
.admin-form .form-group select:focus {
    border-color: #fe8400;
    box-shadow: 0 0 0 3px rgba(254,132,0,0.1);
}
.admin-form .form-group label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.admin-form .form-group {
    margin-bottom: 18px;
}
.admin-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}
.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

/* Admin Layout */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 250px;
    background: #0c4767;
    color: #fff;
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.admin-logo {
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 20px;
}

.admin-logo h2 {
    font-size: 1.3rem;
    font-weight: 700;
}

.admin-logo p {
    font-size: 12px;
    opacity: 0.7;
}

.admin-nav {
    display: flex;
    flex-direction: column;
}

.admin-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 20px;
    color: rgba(255,255,255,0.7);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    text-decoration: none;
    border-left: 3px solid transparent;
}
.admin-nav a svg {
    flex-shrink: 0;
    opacity: 0.6;
}
.admin-nav a:hover,
.admin-nav a.active {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-left-color: #fe8400;
}
.admin-nav a.active svg {
    opacity: 1;
}

.admin-main {
    flex: 1;
    margin-left: 250px;
    padding: 30px;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.admin-header h1 {
    font-size: 1.5rem;
    color: #333;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    text-align: center;
}

.stat-card h3 {
    font-size: 14px;
    color: #666;
    font-weight: 500;
    margin-bottom: 10px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #0c4767;
}

.admin-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.btn-primary {
    display: inline-block;
    padding: 12px 24px;
    background: #0c4767;
    color: #fff;
    border-radius: 4px;
    font-weight: 500;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: #fe8400;
    color: #fff;
}

.btn-secondary {
    display: inline-block;
    padding: 12px 24px;
    background: #666;
    color: #fff;
    border-radius: 4px;
    font-weight: 500;
    border: none;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #555;
    color: #fff;
}

.recent-articles,
.admin-table-container,
.admin-form-container {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    margin-bottom: 25px;
}

.recent-articles h2,
.admin-table-container h2,
.admin-form-container h2 {
    font-size: 1.1rem;
    color: #333;
    margin-bottom: 20px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}

.admin-table th {
    background: #f9f9f9;
    font-weight: 600;
    color: #333;
}

.admin-table tr:hover {
    background: #f9f9f9;
}

.btn-edit {
    display: inline-block;
    padding: 6px 12px;
    background: #0c4767;
    color: #fff;
    border-radius: 4px;
    font-size: 12px;
    margin-right: 5px;
}

.btn-edit:hover {
    color: #fff;
}

.btn-delete {
    display: inline-block;
    padding: 6px 12px;
    background: #dc3545;
    color: #fff;
    border-radius: 4px;
    font-size: 12px;
}

.btn-delete:hover {
    color: #fff;
}

.btn-toggle {
    display: inline-block;
    padding: 6px 12px;
    background: #6c757d;
    color: #fff;
    border-radius: 4px;
    font-size: 12px;
    text-decoration: none;
}

.btn-toggle:hover {
    color: #fff;
    opacity: 0.85;
}

.btn-toggle.btn-active {
    background: #198754;
}

/* Admin Form */
.admin-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

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

.admin-form .checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.admin-form .checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 400;
}

.admin-form .checkbox-group input[type="checkbox"] {
    width: auto;
}

.current-image {
    margin-top: 10px;
}

.current-image img {
    max-width: 200px;
    border-radius: 4px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

/* ============================================
   Responsive Design
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-main {
        grid-column: span 2;
    }

    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .section-header h3 {
        font-size: 1.1rem;
    }

    .hero-content h2 {
        font-size: 1rem;
    }

    .hero-main .hero-content h2 {
        font-size: 1.2rem;
    }

    .article-page {
        padding: 25px 0;
    }

    .article-title {
        font-size: 1.7rem;
    }

    .article-body {
        font-size: 1rem;
    }

    .static-page {
        padding: 30px 20px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    .container {
        padding: 0 15px;
    }

    .header-top {
        display: none;
    }

    .header-main {
        padding: 12px 0;
    }

    .header-main .container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }


    .site-logo {
        height: 45px;
    }

    .logo h1 {
        font-size: 1.6rem;
    }

    .logo .tagline {
        font-size: 0.75rem;
    }

    .menu-toggle {
        display: block;
        padding: 10px;
    }

    .nav-search {
        padding: 0 5px;
    }

    .main-nav .container {
        flex-wrap: nowrap;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #333;
        flex-direction: column;
        z-index: 100;
        max-height: 70vh;
        overflow-y: auto;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu > li > a {
        padding: 14px 20px;
        border-bottom: 1px solid #444;
        font-size: 15px;
    }

    .has-dropdown > .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        background: #444;
        display: none;
    }

    .has-dropdown.open > .dropdown {
        display: block;
    }

    .dropdown li a {
        padding-left: 40px;
        font-size: 14px;
    }

    .hero-section {
        padding: 10px 0;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .hero-main {
        grid-column: span 1;
    }

    .hero-main .hero-image {
        min-height: 200px;
    }

    .hero-card {
        border-radius: 8px;
    }

    .hero-content {
        padding: 15px;
    }

    .hero-content h2 {
        font-size: 14px;
        line-height: 1.3;
    }

    .hero-main .hero-content h2 {
        font-size: 16px;
    }



    .category-section {
        padding: 20px 0;
    }

    .section-header {
        margin-bottom: 15px;
        padding-bottom: 8px;
    }

    .section-header h3 {
        font-size: 1rem;
    }

    .more-link {
        font-size: 13px;
    }

    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .article-card {
        border-radius: 8px;
    }

    .article-image {
        height: 120px;
    }

    .article-content {
        padding: 10px;
    }

    .article-content h3 {
        font-size: 13px;
        line-height: 1.3;
        -webkit-line-clamp: 2;
    }

    .article-date {
        font-size: 11px;
        margin-top: 5px;
    }

    /* Article Page Mobile */
    .article-page {
        padding: 15px 0;
    }

    .article-meta {
        flex-wrap: wrap;
        gap: 10px;
        margin-bottom: 12px;
        font-size: 12px;
    }

    .article-title {
        font-size: 1.4rem;
        line-height: 1.3;
    }

    .article-featured-image {
        margin-bottom: 20px;
        border-radius: 8px;
    }

    .article-featured-image img {
        max-height: 250px;
    }

    .article-body {
        font-size: 1rem;
        line-height: 1.7;
    }

    .article-body p {
        margin-bottom: 15px;
    }

    .article-body h2 {
        font-size: 1.3rem;
        margin: 20px 0 12px;
    }

    .article-body h3 {
        font-size: 1.1rem;
        margin: 18px 0 10px;
    }

    .article-share {
        flex-wrap: wrap;
        gap: 10px;
    }

    .share-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    .related-articles {
        padding: 25px 0;
        margin-top: 25px;
    }

    /* Category Page Mobile */
    .category-page {
        padding: 15px 0;
    }

    .category-header h1 {
        font-size: 1.5rem;
    }

    /* Search Page Mobile */
    .search-header h1 {
        font-size: 1.2rem;
    }

    /* Static Pages Mobile */
    .static-page {
        padding: 20px 15px;
    }

    .static-page h1 {
        font-size: 1.5rem;
    }

    .page-content {
        font-size: 1rem;
    }

    .contact-info {
        gap: 15px;
    }

    .contact-item {
        padding: 15px;
    }

    /* Error Page Mobile */
    .error-content h1 {
        font-size: 3.5rem;
    }

    .error-content h2 {
        font-size: 1.2rem;
    }

    /* Footer Mobile */
    .footer-links .container {
        gap: 15px;
        padding: 15px 0;
    }

    .footer-links a {
        font-size: 13px;
    }

    .footer-main {
        padding: 15px 0;
    }

    .footer-main .container {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .footer-left p {
        font-size: 12px;
    }

    .footer-right {
        gap: 12px;
    }

    .social-icon {
        width: 36px;
        height: 36px;
    }

    /* Back to Top Mobile */
    .back-to-top {
        width: 42px;
        height: 42px;
        bottom: 20px;
        right: 20px;
    }

    /* Search Overlay Mobile */
    .search-container {
        width: 95%;
    }

    .search-input {
        padding: 12px 15px;
        font-size: 16px;
    }

    .search-submit,
    .search-close {
        padding: 12px 15px;
    }

    /* Admin Mobile */
    .admin-wrapper {
        flex-direction: column;
    }

    .admin-sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }

    .admin-logo {
        padding: 15px;
    }

    .admin-nav {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 0 10px 10px;
    }

    .admin-nav a {
        padding: 8px 12px;
        font-size: 13px;
    }

    .admin-main {
        margin-left: 0;
        padding: 15px;
    }

    .admin-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .admin-header h1 {
        font-size: 1.3rem;
    }

    .admin-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .stat-card {
        padding: 20px;
    }

    .stat-number {
        font-size: 2rem;
    }

    .admin-actions {
        flex-direction: column;
        gap: 10px;
    }

    .admin-actions .btn-primary,
    .admin-actions .btn-secondary {
        width: 100%;
        text-align: center;
    }

    .recent-articles,
    .admin-table-container,
    .admin-form-container {
        padding: 15px;
        overflow-x: auto;
    }

    .admin-table {
        min-width: 600px;
    }

    .admin-form .form-row {
        grid-template-columns: 1fr;
    }

    .login-box {
        padding: 25px;
        margin: 15px;
    }

    .login-box h1 {
        font-size: 1.5rem;
    }

    .dash-welcome {
        flex-direction: column;
        gap: 16px;
        padding: 22px 20px;
        text-align: center;
    }
    .dash-welcome-actions {
        justify-content: center;
    }
    .dash-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    .dash-row {
        grid-template-columns: 1fr;
    }
    .dash-col-side {
        order: -1;
    }
    .dash-table th:nth-child(3),
    .dash-table td:nth-child(3) {
        display: none;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }

    .article-image {
        height: 180px;
    }

    .article-content h3 {
        font-size: 14px;
        -webkit-line-clamp: 3;
    }

    .dash-stats {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .dash-stat-card {
        padding: 16px 14px;
    }
    .dash-stat-number {
        font-size: 1.3rem;
    }
    .dash-btn {
        padding: 8px 14px;
        font-size: 0.78rem;
    }
    .dash-table th:nth-child(4),
    .dash-table td:nth-child(4) {
        display: none;
    }
}

/* Newspaper Page */
.newspaper-page {
    padding: 40px 0;
}

.newspaper-page .page-header {
    text-align: center;
    margin-bottom: 40px;
}

.newspaper-page .page-header h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.newspaper-page .page-subtitle {
    color: #666;
    font-size: 1rem;
}

.newspaper-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.newspaper-card {
    background: #fafafa;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.newspaper-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

.newspaper-icon {
    color: #dc3545;
    margin-bottom: 16px;
}

.newspaper-info h3 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.newspaper-filename {
    color: #888;
    font-size: 0.8rem;
    margin-bottom: 2px;
}

.newspaper-size {
    color: #aaa;
    font-size: 0.75rem;
    margin-bottom: 16px;
}

.newspaper-actions {
    display: flex;
    gap: 10px;
}

.newspaper-actions a {
    padding: 8px 18px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s ease;
}

.no-papers {
    text-align: center;
    padding: 80px 20px;
    color: #999;
}

.no-papers p {
    margin-top: 16px;
    font-size: 1.1rem;
}

.no-papers-hint {
    color: #ccc;
    font-size: 0.9rem !important;
}

@media (max-width: 600px) {
    .newspaper-grid {
        grid-template-columns: 1fr;
    }
    .newspaper-card {
        padding: 20px 16px;
    }
}
