/* =========================
   GLOBAL RESET + BASE
========================= */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    background: #f4f7fb;
    color: #1e2a3e;
    line-height: 1.6;
}

/* =========================
   CONTAINER
========================= */

.container {
    width: 100%;
    max-width: 1200px;
    margin: auto;
    padding: 15px;
}

/* =========================
   NAVBAR
========================= */

.navbar .nav-link {
    font-weight: 500;
    color: #2c3e50;
    transition: 0.2s ease;
}

.navbar .nav-link:hover {
    color: #198754;
}

.navbar .nav-link.active {
    color: #198754;
    font-weight: 600;
}

/* =========================
   HERO
========================= */

.hero-search {
    background: linear-gradient(135deg, #198754, #20c997);
    padding: 15px;
    border-radius: 8px;
    color: #fff;
}

/* =========================
   LISTING CARD (PRO JOB STYLE)
========================= */

.listing-card {
    display: flex;
    gap: 15px;
    padding: 15px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #e9ecef;
    align-items: center;
    transition: 0.2s ease;
    margin-bottom: 15px;
    cursor: pointer;
}

.listing-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.06);
}

/* IMAGE */
.listing-card img {
    width: 120px;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

/* CONTENT */
.listing-card .content {
    flex: 1;
}

/* TITLE */
.listing-card .post-title {
    font-size: 16px;
    font-weight: 700;
    margin: 0;
    line-height: 1.4;

    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.listing-card .post-title a {
    color: #198754;
    text-decoration: none;
}

.listing-card .post-title a:hover {
    text-decoration: underline;
}

/* META */
.listing-card .meta {
    font-size: 13px;
    color: #6c757d;
    margin-top: 5px;
}

/* DEADLINE */
.listing-card small {
    font-size: 12px;
    color: #dc3545;
    font-weight: 600;
}

/* =========================
   BADGES
========================= */

.badge-deadline {
    background: #ffe5e5;
    color: #c0392b;
    font-size: 0.7rem;
    border-radius: 20px;
    padding: 0.3rem 0.7rem;
}

.badge-type {
    background: #e9ecef;
    color: #2c3e50;
    font-size: 0.7rem;
    border-radius: 20px;
    padding: 0.3rem 0.7rem;
}

/* =========================
   ANIMATION
========================= */

.fade-up {
    opacity: 0;
    transform: translateY(20px);
    transition: 0.6s ease;
}

.fade-up.appear {
    opacity: 1;
    transform: translateY(0);
}

/* =========================
   POST CONTENT
========================= */

.post-content {
    font-size: 16px;
    line-height: 1.9;
    color: #212529;
    word-wrap: break-word;
    max-width: 100%;
}

/* HEADINGS */
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
    color: #198754;
    font-weight: 700;
    margin-top: 25px;
    margin-bottom: 15px;
}

/* PARAGRAPH */
.post-content p {
    margin-bottom: 15px;
}

/* LISTS */
.post-content ul,
.post-content ol {
    margin-left: 25px;
    margin-bottom: 15px;
}

.post-content li {
    margin-bottom: 8px;
}

/* MEDIA */
.post-content img,
.post-content iframe,
.post-content table {
    max-width: 100%;
}

/* TABLE */
.post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: #fff;
}

.post-content table th {
    background: #198754;
    color: #fff;
    padding: 12px;
    border: 1px solid #ddd;
}

.post-content table td {
    padding: 12px;
    border: 1px solid #ddd;
}

/* BLOCKQUOTE */
.post-content blockquote {
    border-left: 5px solid #198754;
    background: #f8f9fa;
    padding: 15px;
    margin: 20px 0;
    font-style: italic;
}

/* LINKS */
.post-content a {
    color: #198754;
    font-weight: 600;
    text-decoration: none;
}

.post-content a:hover {
    text-decoration: underline;
}

/* =========================
   LISTING DESCRIPTION FIX
========================= */

.listing-description {
    color: #212529;
    background: transparent;
}

.listing-description h3,
.listing-description h4,
.listing-description h5 {
    font-size: 18px;
    font-weight: 600;
    margin-top: 15px;
    color: #198754;
}

.listing-description ol,
.listing-description ul {
    padding-left: 20px;
}

.listing-description li {
    margin-bottom: 8px;
}

/* =========================
   ACCESSIBILITY
========================= */

a:focus {
    outline: 2px solid #198754;
    outline-offset: 2px;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 768px) {

    body {
        font-size: 15px;
    }

    .container {
        padding: 10px;
    }

    .listing-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .listing-card img {
        width: 100%;
        height: auto;
    }

    .hero-search {
        padding: 10px;
    }
}