:root {
    --primary-color: #385a64;
    --primary-light: #4c727d;
    --primary-dark: #263e45;
    --logo-color-1: #2c92d0;
    --logo-color-2: #2cae96;
    --logo-color-3: #c5512c;
    --logo-color-4: #eaa22c;
    --text-main: #333333;
    --text-muted: #6b7280;
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 9999px;
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

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

html,
body {
    overflow-x: hidden;
    max-width: 100%;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Base Components */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1.2rem;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    font-family: 'Outfit', sans-serif;
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-large {
    padding: 0.8rem 2rem;
    font-size: 1.1rem;
}

/* Navbar */
.navbar {
    background-color: var(--bg-card);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-img {
    height: 48px;
    width: auto;
    object-fit: contain;
}

.logo-text {
    font-size: 1.4rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.color-1 {
    color: var(--logo-color-1);
}

.color-2 {
    color: var(--logo-color-2);
}

.color-3 {
    color: var(--logo-color-3);
}

.color-4 {
    color: var(--logo-color-4);
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-icon {
    font-size: 0.8rem;
    margin-left: 0.2rem;
    transition: transform var(--transition-fast);
}

.nav-dropdown:hover .dropdown-icon {
    transform: rotate(180deg);
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    background-color: var(--bg-card);
    box-shadow: var(--shadow-md);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    z-index: 1000;
    overflow: hidden;
    padding: 0.5rem 0;
}

.dropdown-content a {
    color: var(--text-main);
    padding: 0.8rem 1.2rem;
    text-decoration: none;
    display: block;
    font-size: 0.95rem;
    font-weight: 500;
    transition: background-color var(--transition-fast), color var(--transition-fast);
}

.dropdown-content a:hover {
    background-color: var(--bg-main);
    color: var(--primary-color);
}

.nav-dropdown:hover .dropdown-content {
    display: block;
}

.nav-actions {
    display: flex;
    gap: 1rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    color: white;
    padding: 6rem 2rem;
    text-align: center;
    margin-bottom: 3rem;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 3rem;
}

/* Search Box */
.search-container {
    background: var(--bg-card);
    padding: 0.5rem;
    border-radius: var(--radius-full);
    box-shadow: var(--shadow-lg);
    margin-bottom: 2rem;
}

.search-form {
    display: flex;
    align-items: center;
}

.input-group {
    display: flex;
    align-items: center;
    flex: 1;
    padding: 0.5rem 1.5rem;
    color: var(--text-muted);
}

.input-group i {
    margin-right: 1rem;
    color: var(--primary-color);
}

.input-group input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 1rem;
    font-family: inherit;
    color: var(--text-main);
}

.input-divider {
    width: 1px;
    height: 40px;
    background-color: var(--border-color);
}

.search-form .btn-primary {
    border-radius: var(--radius-full);
}

/* Tags */
.popular-searches {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.tag {
    background: rgba(255, 255, 255, 0.15);
    padding: 0.3rem 1rem;
    border-radius: var(--radius-full);
    transition: background var(--transition-fast);
}

.tag:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Main Layout */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem 4rem;
}

.content-wrapper {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
}

/* Sidebar */
.filter-card {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 90px;
}

.filter-card h3 {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--primary-dark);
}

.filter-group {
    margin-bottom: 1.5rem;
}

.filter-group h4 {
    font-size: 1rem;
    margin-bottom: 0.8rem;
    color: var(--text-main);
}

.checkbox-container {
    display: block;
    position: relative;
    padding-left: 30px;
    margin-bottom: 0.8rem;
    cursor: pointer;
    font-size: 0.95rem;
    color: var(--text-muted);
    user-select: none;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 2px;
    left: 0;
    height: 18px;
    width: 18px;
    background-color: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    transition: all var(--transition-fast);
}

.checkbox-container:hover input~.checkmark {
    border-color: var(--primary-color);
}

.checkbox-container input:checked~.checkmark {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked~.checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 6px;
    top: 2px;
    width: 4px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Job Listings */
.job-listings {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.section-header h2 {
    font-size: 1.5rem;
    color: var(--primary-dark);
}

.sort-by select {
    padding: 0.4rem 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    font-family: inherit;
    color: var(--text-main);
    outline: none;
    cursor: pointer;
}

/* Job Cards */
.jobs-grid {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.job-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.job-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--border-color);
    transform: translateY(-2px);
}

.job-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.job-company-info {
    display: flex;
    gap: 1rem;
    align-items: center;
    min-width: 0;
    flex: 1;
}

.company-logo {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-md);
    background-color: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary-color);
    border: 1px solid var(--border-color);
}

.job-title-container {
    min-width: 0;
    overflow: hidden;
}

.job-title-container h3 {
    font-size: 1.2rem;
    color: var(--text-main);
    margin-bottom: 0.2rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.company-name {
    font-size: 0.95rem;
    color: var(--text-muted);
}

.job-save {
    color: var(--text-muted);
    cursor: pointer;
    background: none;
    border: none;
    font-size: 1.2rem;
    transition: color var(--transition-fast);
}

.job-save:hover {
    color: var(--primary-color);
}

.job-details {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}

.job-detail-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    background: var(--bg-main);
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-full);
}

.job-description {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-wrap: break-word;
    overflow-wrap: break-word;
    max-width: 100%;
}

.job-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.job-posted-time {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.btn-page {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-main);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: inherit;
}

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

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

/* Legal Pages */
.legal-container {
    padding: 4rem 1rem;
    max-width: 800px;
    margin: 0 auto;
}

.legal-content h1 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.legal-content .last-updated {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.legal-section {
    margin-bottom: 2rem;
}

.legal-section h2 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.legal-section p {
    color: var(--text-main);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.legal-section ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    color: var(--text-main);
    line-height: 1.6;
}

/* Contact Page */
.contact-page {
    padding: 4rem 1rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-header h1 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.contact-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
}

.contact-info-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    text-align: center;
    border: 1px solid var(--border-color);
    height: 100%;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: rgba(33, 150, 243, 0.1);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 1.5rem;
}

.contact-info-card h3 {
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

.contact-info-card p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.support-email {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 1.1rem;
    word-break: break-all;
}

.contact-form {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-main);
}

.form-control {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 1rem;
    background: var(--bg-main);
    color: var(--text-main);
    transition: all var(--transition-fast);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

textarea.form-control {
    resize: vertical;
}

.btn-block {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
}

/* Footer */
footer {
    background-color: var(--primary-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: 4rem 2rem 1rem;
}

.footer-content {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.logo-img-footer {
    height: 40px;
    object-fit: contain;
}

.footer-col .logo-text {
    color: white;
}

.footer-col h4 {
    color: white;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.footer-col a:not(.nav-logo) {
    display: block;
    margin-bottom: 0.8rem;
    transition: color var(--transition-fast);
}

.footer-col .nav-logo {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.footer-col a:hover {
    color: white;
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.9rem;
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8) !important;
    font-size: 1rem;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.2s ease, color 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.15);
    margin-bottom: 0 !important;
}

.footer-social a:hover {
    transform: translateY(-2px);
    color: white !important;
}

.footer-social a.wa:hover {
    background: #25D366;
    border-color: #25D366;
}

.footer-social a.li:hover {
    background: #0A66C2;
    border-color: #0A66C2;
}

@media (max-width: 480px) {
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

/* Responsive */
/* Mobile Filters */
.mobile-filter-container {
    display: none;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

@media (max-width: 992px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
        width: 100% !important;
        margin-bottom: 2rem;
        position: relative;
        top: 0;
    }

    .sidebar.active {
        display: block;
        animation: slideDown 0.3s ease-out;
    }

    .mobile-filter-container {
        display: block;
    }

    .filter-card {
        position: static;
        width: 100%;
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .search-form {
        flex-direction: column;
        border-radius: var(--radius-lg);
        overflow: hidden;
    }

    .input-group {
        width: 100%;
        padding: 1rem;
        border-bottom: 1px solid var(--border-color);
    }

    .input-divider {
        display: none;
    }

    .search-form .btn-primary {
        border-radius: 0;
        width: 100%;
        padding: 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .footer-content {
        grid-template-columns: 1fr;
    }

    .job-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .job-footer .btn {
        width: 100%;
    }
}

/* --- Mobile Responsive Nav & Layout --- */
.menu-toggle {
    display: none;
    font-size: 1.5rem;
    color: var(--primary-dark);
    cursor: pointer;
}

@media (max-width: 992px) {
    .content-wrapper {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        margin-bottom: 2rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--bg-card);
        padding: 1rem 0;
        box-shadow: var(--shadow-md);
        z-index: 1000;
        text-align: center;
    }

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

    .nav-menu .nav-link {
        padding: 0.8rem 1rem;
        width: 100%;
    }

    .nav-actions {
        display: none;
    }

    .nav-container {
        flex-wrap: wrap;
        justify-content: space-between;
        position: relative;
    }

    .nav-dropdown .dropdown-content {
        position: static;
        box-shadow: none;
        display: none;
        padding-left: 0;
        text-align: center;
    }

    /* Disable hover on mobile to prevent sticky touch states */
    .nav-dropdown:hover .dropdown-content {
        display: none;
    }

    .nav-dropdown.active .dropdown-content {
        display: flex;
        flex-direction: column;
    }

    /* Force icon to obey JavaScript rotation, disable hover rotation */
    .nav-dropdown:hover .dropdown-icon {
        transform: none;
    }

    .nav-dropdown.active .dropdown-icon {
        transform: rotate(180deg);
    }

    /* Fix hero overflow */
    .hero {
        padding: 3rem 1rem !important;
        width: 100%;
        overflow: hidden;
    }

    .hero h1 {
        font-size: 1.6rem !important;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .hero p {
        font-size: 0.95rem;
        padding: 0 0.5rem;
    }

    .hero-content {
        padding: 0 0.5rem;
        width: 100%;
    }

    /* Fix containers */
    .container {
        padding: 1rem;
        width: 100%;
        max-width: 100%;
    }

    /* Fix search form */
    .search-container {
        width: 100%;
        padding: 0;
        border-radius: var(--radius-md);
        overflow: hidden;
    }

    .search-form {
        flex-direction: column;
        border-radius: var(--radius-md);
        width: 100%;
    }

    .input-group {
        width: 100%;
        padding: 0.8rem 1rem;
    }

    .input-divider {
        width: 100%;
        height: 1px;
        margin: 0;
        display: none;
    }

    .search-form .btn-primary {
        border-radius: 0 0 var(--radius-md) var(--radius-md);
        width: 100%;
        padding: 1rem;
    }

    .btn-large {
        width: 100%;
    }

    /* Fix job cards */
    .jobs-grid {
        grid-template-columns: 1fr !important;
        padding: 0;
    }

    .job-card {
        width: 100%;
    }

    /* Fix footer */
    .footer-content {
        flex-direction: column;
        gap: 2rem;
    }

    /* Legal pages */
    .legal-content {
        padding: 1rem;
    }

    /* Job detail card */
    .job-detail-container {
        padding: 1.5rem 1rem;
        margin: 1rem;
    }

    .job-meta-list {
        grid-template-columns: 1fr !important;
    }

    /* Contact page */
    .contact-container {
        grid-template-columns: 1fr;
    }

    /* Fix job card footer - stack vertically on mobile */
    .job-footer {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.75rem;
    }

    .job-footer .btn {
        width: 100% !important;
        text-align: center;
    }

    .job-footer .job-posted-time {
        font-size: 0.85rem;
    }

    /* Blog/projects grid */
    .projects-grid {
        grid-template-columns: 1fr;
        padding: 2rem 0.5rem;
    }
}