/* Reset and General Styling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Merriweather', Georgia, serif;
    background-color: #fffaf0;
    color: #3a2f25;
    line-height: 1.6;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background-color: #6e4b2f;
    color: white;
}

header .logo h1 {
    font-size: 24px;
}

header nav {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links li a {
    color: white;
    text-decoration: none;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    background-color: white;
    height: 3px;
    width: 30px;
    margin: 5px 0;
}

/* Search Box */
.search-section {
    text-align: center;
    margin: 20px 0;
}

.search-section input {
    padding: 10px;
    width: 70%;
    border: 2px solid #d97706;
    border-radius: 6px;
}

.search-section button {
    padding: 10px;
    background-color: #d97706;
    color: white;
    border: none;
    border-radius: 6px;
}

/* Hero Section */
.hero {
    background-color: #d97706;
    color: white;
    text-align: center;
    padding: 50px 20px;
}

/* AdSense Styling */
.adsense {
    text-align: center;
    padding: 15px;
    background-color: #fff1e6;
    margin: 20px auto;
    max-width: 100%;
}

/* Top Ad */
.ad-top {
    margin-bottom: 20px;
}

/* Bottom Ad */
.ad-bottom {
    margin-top: 20px;
}
/* Categories */
.categories {
    padding: 40px 20px;
    text-align: center;
}

.category-list {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.category-card {
    background-color: #fff1e6;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    width: 85%;
}

/* Articles */
.article-grid {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.article-card {
    background-color: #fff1e6;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    width: 45%;
}

/* Article View Page */
.article-view {
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    text-align: left;
}

.article-view h1 {
    text-align: center;
    margin-bottom: 10px;
    margin-left:10px;
}

.article-meta {
    text-align: center;
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 20px;
}

.article-image {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 20px;
}

.article-content p {
    margin-bottom: 15px;
    font-size: 17px;
    line-height: 1.8;
    margin-left:10px;
    margin-right:10px;
    text-align:justify;
}
.article-content ul {
margin-left:25px;
}
.article-content ol {
margin-left:25px;
}


/* User Link */
.user-link {
    margin-top: 30px;
    padding: 15px;
    background: #f4f4f4;
    border-left: 4px solid #d97706;
}

.user-link p {
    margin: 5px 0;
}

.user-link a {
    color: #d97706;
    text-decoration: none;
    font-weight: bold;
}

/* Footer Section */
footer {
    background-color: #6e4b2f;
    color: white;
    padding: 20px;
    text-align: center; /* Centers text */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.footer-content p {
    margin-bottom: 10px;
}

.footer-content .social-links a {
    color: white;
    margin: 0 10px;
    text-decoration: none;
}
/* Form Sections */
.login-form, .register-form {
    max-width: 400px;
    margin: 50px auto;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0,0,0,0.1);
}

.login-form h2, .register-form h2 {
    margin-bottom: 20px;
}

.login-form input, .register-form input {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #f1a7b5;
    border-radius: 6px;
}

button {
    width: 100%;
    padding: 10px;
    background-color: #d97706;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

/* Dashboard Section */
.dashboard {
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    text-align: left;
}

.dashboard h2 {
    text-align: center;
    margin-bottom: 20px;
}

/* Profile Section */
.profile-section {
    background: #f4f4f4;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.profile-section p {
    margin: 10px 0;
}

.edit-btn {
    background-color: #d97706;
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 6px;
}

/* User Articles Section */
.user-articles h3 {
    margin-bottom: 10px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

table th, table td {
    padding: 10px;
    border: 1px solid #f1a7b5;
    text-align: left;
}

.delete-btn {
    background-color: #dc2626;
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 6px;
}

/* Profile View Page */
.profile-view {
    max-width: 600px;
    margin: 40px auto;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.profile-view h2 {
    margin-bottom: 20px;
}

/* Profile Card */
.profile-card {
    background: #f4f4f4;
    padding: 15px;
    border-radius: 6px;
    text-align: center;
}

.profile-image {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin-bottom: 10px;
}

profile-card p {
    margin: 10px 0;
    font-size: 16px;
}
/* Edit Profile Section */
.edit-profile {
    max-width: 400px;
    margin: 50px auto;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0,0,0,0.1);
}

.edit-profile h2 {
    margin-bottom: 20px;
    text-align: center;
}

.edit-profile input,
.edit-profile textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #f1a7b5;
    border-radius: 6px;
}

.edit-profile textarea {
    height: 80px;
    resize: none;
}

button {
    width: 100%;
    padding: 10px;
    background-color: #d97706;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

/* Post Article Form */
.post-article {
    max-width: 600px;
    margin: 20px auto;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0px 0px 10px rgba(0,0,0,0.1);
}

.post-article h2 {
    text-align: center;
    margin-bottom: 15px;
}

.post-article input,
post-article select,
.post-article textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #f1a7b5;
    border-radius: 6px;
}

button {
    width: 100%;
    padding: 10px;
    background-color: #d97706;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

/* Responsive Design */
@media screen and (max-width: 768px) {

    .dashboard {
        width: 90%;
    }

    table {
        display: block;
        overflow-x: auto;
    }

    /* Responsive Menu */
    .hamburger {
        display: flex;
        }

    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 60px;
        left: 0;
        background-color: #6e4b2f;
    }

    .nav-links li {
        text-align: center;
        padding: 15px 0;
    }

    .nav-links.show {
        display: flex;
    }

    /* Responsive Grid */
    .category-list, .article-grid {
        flex-direction: column;
        align-items: center;
    }

    .category-card, .article-card {
        width: 99%;
    }
}

/* === Structural Pattern === */

/* Pattern E: Compact grids + banded footer + right-aligned search */
.category-list { display:grid; grid-template-columns: repeat(auto-fill, minmax(160px,1fr)); gap:.7rem; }
.article-grid { display:grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap:1rem; }
.search-section { display:flex; gap:.4rem; justify-content:flex-end; }
.search-section input { padding:.6rem .8rem; border:1px solid #f1a7b5; border-radius:6px; }
.search-section button { padding:.6rem .9rem; border-radius:6px; }
footer { border-top:4px solid #d97706; }
footer .footer-content { display:grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap:1rem; }

/* === Logo Style Variation === */

/* Logo Style 5: Slim uppercase + letterspacing */
.logo, .site-title, header .logo a {
  font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  color: #3a2f25; opacity: .95; text-decoration:none;
}
.site-logo img { height: 28px; width:auto; }

/* Shared polish */
a { color:#d97706; transition:all .2s ease; }
a:hover { opacity:.9; text-decoration:underline; }
input:focus, select:focus, textarea:focus { outline:none; border-color:#d97706; box-shadow:0 0 0 3px #d9770622; }
button { background:#d97706; color:white; font-weight:600; }
header { box-shadow:0 2px 6px rgba(0,0,0,.06); }
.article-card:hover, .category-card:hover { transform: translateY(-2px); transition: transform .15s ease; }

/* Theme extras for retro-beige */
header { padding: 22px; background: #6e4b2f; }
.logo, .site-title { font-weight: 600; color: inherit; }
.search-section input { border-radius: 10px; box-shadow: 0 3px 10px rgba(0,0,0,0.05); }
footer { background: #6e4b2f; }
