/* =========================================================
   UNIJOB – GLOBAL STYLESHEET
   ========================================================= */

/* Google Font (pastikan di-load di HTML) */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* Reset Dasar */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --success: #10b981;
    --success-hover: #059669;
    --danger: #ef4444;
    --warning: #f59e0b;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-light: #94a3b8;
    --bg-light: #f8fafc;
    --bg-page: #f1f5f9;
    --white: #ffffff;
    --border: #e2e8f0;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* =========================================================
   CONTAINER
   ========================================================= */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* =========================================================
   NAVBAR
   ========================================================= */
.navbar-main {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    height: 72px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    transition: background var(--transition);
}

.nav-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.nav-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.img-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

/* Nav Menu Links */
.nav-menu {
    display: flex;
    gap: 32px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 15px;
    transition: color var(--transition);
    position: relative;
    padding: 4px 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
    transition: width var(--transition);
}

.nav-menu a:hover {
    color: var(--primary);
}

.nav-menu a:hover::after {
    width: 100%;
}

/* Nav Actions (Auth buttons) */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 14px;
}

.nav-greeting {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-main);
}

.btn-login {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 15px;
    transition: color var(--transition);
}

.btn-login:hover {
    color: var(--primary);
}

.btn-register {
    background: var(--success);
    color: var(--white) !important;
    padding: 10px 22px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    transition: all var(--transition);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.25);
}

.btn-register:hover {
    background: var(--success-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

.btn-dash {
    text-decoration: none;
    color: var(--primary);
    font-weight: 700;
    font-size: 14px;
    transition: color var(--transition);
}

.btn-dash:hover {
    color: var(--primary-hover);
}

.btn-logout {
    text-decoration: none;
    color: var(--danger);
    font-weight: 600;
    font-size: 13px;
    padding: 7px 14px;
    border: 1px solid #fee2e2;
    border-radius: var(--radius-sm);
    background: #fef2f2;
    transition: all var(--transition);
}

.btn-logout:hover {
    background: #fee2e2;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2.5px;
    background: var(--text-main);
    border-radius: 4px;
    transition: var(--transition);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.5);
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    display: flex;
    opacity: 1;
}

.mobile-menu-content {
    background: var(--white);
    width: 280px;
    height: 100%;
    margin-left: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }

    to {
        transform: translateX(0);
    }
}

.mobile-close {
    align-self: flex-end;
    font-size: 28px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-main);
    margin-bottom: 20px;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mobile-nav-links a {
    padding: 12px 16px;
    font-weight: 600;
    font-size: 15px;
    color: var(--text-main);
    border-radius: var(--radius-sm);
    transition: background var(--transition);
}

.mobile-nav-links a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

.mobile-register {
    background: var(--success) !important;
    color: var(--white) !important;
    text-align: center;
    border-radius: var(--radius-sm) !important;
    margin-top: 10px;
}

.mobile-logout {
    color: var(--danger) !important;
}

/* =========================================================
   HERO SECTION (index.php)
   ========================================================= */
.hero {
    padding: 80px 0 60px;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 60%, #2563eb 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.15);
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.hero-text h1 {
    font-size: 42px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.hero-text .subtitle {
    font-size: 20px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 8px;
}

.hero-text .desc {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 32px;
    max-width: 440px;
}

.hero-btn {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    transition: all var(--transition);
    cursor: pointer;
    border: none;
}

.btn.primary {
    background: var(--white);
    color: var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.btn.secondary {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn.secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.6);
}

.hero-image {
    display: flex;
    justify-content: center;
}

.hero-image img {
    max-width: 420px;
    width: 100%;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3));
    animation: heroFloat 4s ease-in-out infinite;
}

@keyframes heroFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-12px);
    }
}

/* =========================================================
   INFO STRIP (index.php)
   ========================================================= */
.info {
    padding: 50px 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.info-box {
    text-align: center;
    padding: 30px 20px;
    border-radius: var(--radius-lg);
    background: var(--bg-light);
    border: 1px solid var(--border);
    transition: all var(--transition);
}

.info-box:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.info-box h3 {
    font-size: 20px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 8px;
}

.info-box p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* =========================================================
   FOOTER
   ========================================================= */
.footer {
    background: #0f172a;
    color: rgba(255, 255, 255, 0.5);
    text-align: center;
    padding: 28px 0;
    font-size: 14px;
}

/* =========================================================
   AUTH PAGES (login.php / register.php)
   ========================================================= */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 72px);
    padding: 40px 20px;
    background: radial-gradient(circle at 30% 30%, var(--primary-light) 0%, var(--bg-light) 70%);
}

.auth-box {
    background: var(--white);
    padding: 44px 40px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 440px;
    text-align: center;
    border: 1px solid var(--border);
    animation: fadeUp 0.5s ease-out;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-icon {
    font-size: 48px;
    margin-bottom: 8px;
}

.auth-title {
    color: var(--primary);
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 6px;
}

.auth-subtitle {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 28px;
}

/* Form Group */
.form-group {
    margin-bottom: 18px;
    text-align: left;
}

.form-group label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: #334155;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    outline: none;
    font-family: inherit;
    font-size: 15px;
    box-sizing: border-box;
    transition: border-color var(--transition), box-shadow var(--transition);
    background: var(--bg-light);
    color: var(--text-main);
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
    background: var(--white);
}

.form-group input::placeholder {
    color: var(--text-light);
}

/* Auth Submit Button */
.btn-submit {
    width: 100%;
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 16px;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--transition);
    margin-top: 8px;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.btn-submit:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.35);
}

.btn-submit.green {
    background: var(--success);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.25);
}

.btn-submit.green:hover {
    background: var(--success-hover);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

.auth-link {
    margin-top: 22px;
    font-size: 14px;
    color: var(--text-muted);
}

.auth-link a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
    transition: color var(--transition);
}

.auth-link a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

.auth-link a.green {
    color: var(--success);
}

.forgot-link {
    display: block;
    text-align: right;
    font-size: 13px;
    color: var(--text-muted);
    margin-top: -10px;
    margin-bottom: 10px;
    transition: color var(--transition);
}

.forgot-link:hover {
    color: var(--primary);
}

/* =========================================================
   BROWSE PROJECTS
   ========================================================= */
.browse-wrapper {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 24px;
}

.browse-title {
    text-align: center;
    font-size: 34px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #0f172a;
}

.subtitle {
    text-align: center;
    color: var(--text-muted);
    font-size: 16px;
    margin-bottom: 50px;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 28px;
}

.card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.project-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    height: 100%;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(37, 99, 235, 0.2);
}

.project-title {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #0f172a;
}

.project-desc {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.project-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.info-user {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
}

.info-budget {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    font-size: 14px;
    color: #16a34a;
}

.project-date {
    font-size: 13px;
    color: var(--text-light);
}

/* =========================================================
   RESPONSIVE BREAKPOINTS
   ========================================================= */
@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-text h1 {
        font-size: 32px;
    }

    .hero-text .desc {
        margin: 0 auto 28px;
    }

    .hero-btn {
        justify-content: center;
    }

    .hero-image {
        order: -1;
    }

    .hero-image img {
        max-width: 300px;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {

    .nav-menu,
    .nav-actions {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero {
        padding: 50px 0 40px;
    }

    .hero-text h1 {
        font-size: 28px;
    }

    .auth-box {
        padding: 30px 24px;
        border-radius: var(--radius-lg);
    }

    .browse-title {
        font-size: 26px;
    }

    .project-grid {
        grid-template-columns: 1fr;
    }
}