/* ============================================
   Rozkar - Main Stylesheet
   Optimized for Performance & SEO
   ============================================ */

/* CSS Variables for Easy Theming */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --secondary-color: #10b981;
    --secondary-dark: #059669;
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --bg-white: #ffffff;
    --border-color: #e5e7eb;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --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);
    --shadow-button: 0 2px 4px rgba(37, 99, 235, 0.2);
    --radius: 8px;
    --radius-lg: 12px;
    --radius-button: 10px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s ease;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

input, select, textarea {
    font-family: inherit;
    font-size: inherit;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Checkbox styling - make it visible */
input[type="checkbox"] {
    -webkit-appearance: checkbox;
    -moz-appearance: checkbox;
    appearance: checkbox;
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    cursor: pointer;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    background-color: white;
    position: relative;
    flex-shrink: 0;
    margin-right: 0.5rem;
}

input[type="checkbox"]:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath fill='white' d='M11.5 3.5L5.5 9.5L2.5 6.5' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 12px;
}

input[type="checkbox"]:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

input[type="date"],
input[type="time"],
input[type="datetime-local"] {
    -webkit-appearance: none;
}

select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 12px;
    padding-right: 2.5rem;
}

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

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
}

/* Header */
.header {
    background: var(--bg-white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0.875rem 0;
}

@media (max-width: 768px) {
    .header {
        padding: 0.75rem 0;
    }
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (min-width: 769px) {
    .header-content {
        flex-wrap: nowrap;
    }
    
    .logo {
        flex-shrink: 0;
        display: flex;
        align-items: center;
    }
    
    .nav {
        flex: 1;
        display: flex;
        justify-content: flex-end;
        min-width: 0;
    }
    
    .nav ul {
        justify-content: flex-end;
        flex-wrap: nowrap;
    }
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.logo img {
    height: 50px;
    width: auto;
    max-width: 220px;
    object-fit: contain;
    display: block;
    transition: var(--transition-fast);
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}


.logo a {
    display: inline-flex;
    align-items: center;
    line-height: 0;
    text-decoration: none;
}

.logo-text-fallback {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    display: none;
}

@media (max-width: 768px) {
    .logo-text-fallback {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .logo-text-fallback {
        font-size: 1rem;
    }
}

.logo a:hover img {
    opacity: 0.9;
    transform: scale(1.02);
}

@media (max-width: 768px) {
    .logo h1 {
        font-size: 1.25rem;
    }
    
    .logo img {
        height: 38px;
        max-width: 160px;
        object-fit: contain;
    }
    
    .logo a {
        display: flex;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .logo img {
        height: 35px;
        max-width: 150px;
    }
}

.nav ul {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.nav ul li {
    display: flex;
    align-items: center;
}

.nav a {
    color: var(--text-color);
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    white-space: nowrap;
}

/* Ensure button text is always visible */
.nav .auth-links a.btn-login,
.nav .auth-links a.btn-register {
    color: inherit;
}

.nav ul li.auth-links a {
    padding: 0.625rem 1.5rem;
}

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

/* Don't override button colors on hover */
.nav .auth-links a.btn-login:hover,
.nav .auth-links a.btn-register:hover {
    color: inherit !important;
}

.nav a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-color);
}

.auth-links {
    display: flex;
    gap: 0.75rem;
    margin-left: 0.5rem;
    align-items: center;
    list-style: none;
}

.auth-links a {
    display: inline-block;
    text-decoration: none;
    color: inherit;
}

.auth-links .btn-login {
    color: var(--primary-color) !important;
}

.auth-links .btn-register {
    color: white !important;
}

@media (min-width: 769px) {
    .auth-links {
        gap: 0.875rem;
        margin-left: 1.5rem;
        flex-shrink: 0;
    }
    
    .auth-links a {
        padding: 0.625rem 1.5rem !important;
    }
    
    .btn-login,
    .btn-register {
        width: auto;
        min-width: 100px;
    }
}

.btn-login,
.btn-register {
    padding: 0.625rem 1.5rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition-fast);
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    line-height: 1.4;
    min-height: 40px;
    box-sizing: border-box;
    position: relative;
    z-index: 1;
    overflow: visible;
}

.btn-login::before,
.btn-register::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    border-radius: var(--radius-button);
    transition: var(--transition-fast);
}

.btn-login {
    color: var(--primary-color) !important;
    border: 1.5px solid var(--primary-color);
    background: transparent;
    position: relative;
    z-index: 1;
}

.btn-login:hover {
    background: var(--primary-color);
    color: white !important;
    transform: translateY(-1px);
    box-shadow: var(--shadow-button);
    text-decoration: none;
    border-color: var(--primary-color);
}

.btn-login:hover,
.btn-login:hover span,
.btn-login:hover * {
    color: white !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.btn-register {
    background: var(--primary-color);
    color: white !important;
    border: 1.5px solid var(--primary-color);
    box-shadow: var(--shadow-button);
    position: relative;
    z-index: 1;
}

.btn-register:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
    color: white !important;
    text-decoration: none;
    border-color: var(--primary-dark);
}

.btn-register:hover,
.btn-register:hover span,
.btn-register:hover * {
    color: white !important;
    opacity: 1;
    visibility: visible;
}

/* Desktop specific improvements - already handled above */

@media (max-width: 768px) {
    .btn-login,
    .btn-register {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
        width: 100%;
        text-align: center;
    }
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 24px;
    height: 2.5px;
    background: var(--text-color);
    transition: var(--transition-fast);
    border-radius: 2px;
}

.mobile-menu-toggle:hover span {
    background: var(--primary-color);
}

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

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

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

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    font-weight: 400;
}

@media (max-width: 768px) {
    .hero {
        padding: 2.5rem 0;
    }
    
    .hero-title {
        font-size: 1.75rem;
        margin-bottom: 0.75rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 2rem 0;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
    }
}

.search-box {
    max-width: 900px;
    margin: 0 auto;
}

.search-form {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
}

@media (max-width: 768px) {
    .search-form {
        padding: 1.25rem;
        border-radius: var(--radius);
    }
}

@media (max-width: 480px) {
    .search-form {
        padding: 1rem;
    }
}

.search-input-group {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 1rem;
    align-items: center;
}

.search-input-group input,
.search-input-group select {
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius);
    font-size: 0.95rem;
    transition: var(--transition-fast);
}

@media (max-width: 768px) {
    .search-input-group {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .search-input-group input,
    .search-input-group select {
        padding: 0.75rem 0.875rem;
        font-size: 0.9rem;
    }
}

.search-input-group input:focus,
.search-input-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.btn-search {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 1.75rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    white-space: nowrap;
}

.btn-search:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

.btn-search:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .btn-search {
        padding: 0.75rem 1.5rem;
        width: 100%;
        font-size: 0.9rem;
    }
}

/* Section Styles */
.section {
    padding: 4rem 0;
}

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

.section-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-color);
}

.view-all {
    color: var(--primary-color);
    font-weight: 600;
}

.bg-light {
    background: var(--bg-light);
}

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

/* Jobs Grid */
.jobs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.job-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

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

@media (max-width: 768px) {
    .job-card {
        padding: 1.25rem;
    }
}

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

.job-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.job-company {
    color: var(--text-light);
    font-size: 0.9rem;
}

.job-badge {
    background: var(--secondary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    display: inline-block;
    flex-shrink: 0;
}

.job-details {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.job-detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.job-description {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

@media (max-width: 768px) {
    .job-footer {
        flex-direction: column;
        align-items: stretch;
    }
    
    .job-footer .job-date {
        text-align: center;
        font-size: 0.85rem;
    }
}

.job-date {
    font-size: 0.85rem;
    color: var(--text-light);
}

.btn-apply {
    background: var(--primary-color);
    color: white;
    padding: 0.625rem 1.5rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition-fast);
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    white-space: nowrap;
}

.btn-apply:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

.btn-apply:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .btn-apply {
        padding: 0.5rem 1.25rem;
        font-size: 0.85rem;
        width: 100%;
        text-align: center;
    }
}


/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.category-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
    border-color: var(--primary-color);
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.category-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.category-card p {
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Newsletter */
.newsletter {
    text-align: center;
}

.newsletter-content h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.newsletter-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto 1rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
}

.newsletter-form input:focus {
    outline: none;
}

.btn-subscribe {
    background: white;
    color: var(--primary-color);
    padding: 0.75rem 2rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    border: 2px solid white;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-subscribe:hover {
    background: var(--bg-light);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

@media (max-width: 768px) {
    .btn-subscribe {
        padding: 0.75rem 1.5rem;
        width: 100%;
        font-size: 0.9rem;
    }
}

.newsletter-note {
    font-size: 0.85rem;
    opacity: 0.8;
}

/* SEO Content */
.seo-content {
    background: var(--bg-light);
}

.seo-article {
    max-width: 800px;
    margin: 0 auto;
}

.seo-article h2 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.seo-article h3 {
    font-size: 1.5rem;
    margin: 2rem 0 1rem;
    color: var(--text-color);
}

.seo-article p {
    margin-bottom: 1rem;
    color: var(--text-light);
    line-height: 1.8;
}

.seo-article ul {
    list-style: none;
    padding-left: 0;
}

.seo-article ul li {
    padding: 0.5rem 0;
    color: var(--text-light);
}

/* Footer */
.footer {
    background: var(--text-color);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (min-width: 769px) and (max-width: 1024px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

.footer-col h3,
.footer-col h4 {
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-col p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    transition: var(--transition);
}

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

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

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

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius);
    font-size: 0.95rem;
    transition: var(--transition-fast);
}

@media (max-width: 768px) {
    .form-input,
    .form-select,
    .form-textarea {
        padding: 0.625rem 0.875rem;
        font-size: 0.9rem;
    }
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition-fast);
    width: 100%;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Pagination (1, 2, 3, >, >>) */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}
.pagination-btn {
    min-width: 42px;
    height: 42px;
    padding: 0 0.75rem;
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-color);
    background: var(--bg-white);
    border: 2px solid var(--primary-color);
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition-fast);
}
.pagination-btn:hover:not(:disabled) {
    background: var(--primary-light);
    color: white;
    border-color: var(--primary-light);
}
.pagination-btn-active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}
.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination.pagination-hidden {
    display: none;
}

@media (max-width: 768px) {
    .btn-primary {
        padding: 0.75rem 1.5rem;
        font-size: 0.95rem;
    }
}

/* ============================================
   Loading States & Animations
   ============================================ */

/* Modern Spinner Loader */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    min-height: 400px;
    color: var(--text-light);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 1.5rem;
}

.loading-spinner-large {
    width: 60px;
    height: 60px;
    border-width: 5px;
}

.loading-text {
    font-size: 1rem;
    color: var(--text-light);
    margin-top: 1rem;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-dots {
    display: inline-block;
}

.loading-dots::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Skeleton Loader for Job Details */
.skeleton-loader {
    width: 100%;
    animation: skeleton-pulse 1.5s ease-in-out infinite;
}

.skeleton-item {
    background: linear-gradient(90deg, 
        var(--bg-light) 0%, 
        #e5e7eb 50%, 
        var(--bg-light) 100%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius);
    margin-bottom: 1rem;
}

.skeleton-title {
    height: 32px;
    width: 70%;
    margin-bottom: 1rem;
}

.skeleton-subtitle {
    height: 24px;
    width: 50%;
    margin-bottom: 2rem;
}

.skeleton-text {
    height: 16px;
    width: 100%;
    margin-bottom: 0.75rem;
}

.skeleton-text-short {
    height: 16px;
    width: 80%;
    margin-bottom: 0.75rem;
}

.skeleton-text-medium {
    height: 16px;
    width: 60%;
    margin-bottom: 0.75rem;
}

.skeleton-card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.skeleton-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.skeleton-grid-item {
    height: 80px;
    background: var(--bg-light);
    border-radius: var(--radius);
}

@keyframes skeleton-shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

@keyframes skeleton-pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

/* Job Details Skeleton */
.job-details-skeleton {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 0;
}

.job-details-skeleton .skeleton-title {
    height: 40px;
    width: 60%;
    margin-bottom: 0.75rem;
}

.job-details-skeleton .skeleton-subtitle {
    height: 28px;
    width: 40%;
    margin-bottom: 2rem;
}

.job-details-skeleton .skeleton-grid {
    margin-bottom: 2.5rem;
}

.job-details-skeleton .skeleton-text {
    margin-bottom: 1rem;
}

.job-details-skeleton .skeleton-button {
    height: 50px;
    width: 200px;
    border-radius: var(--radius-button);
    margin-top: 2rem;
}

/* Page Loader Overlay */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    backdrop-filter: blur(5px);
}

.page-loader.hidden {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

/* Button Loading State */
.btn-loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* Smooth Fade In Animation */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* Responsive Loading */
@media (max-width: 768px) {
    .loading {
        padding: 3rem 1.5rem;
        min-height: 300px;
    }
    
    .loading-spinner {
        width: 40px;
        height: 40px;
        border-width: 3px;
    }
    
    .loading-text {
        font-size: 0.9rem;
    }
    
    .skeleton-card {
        padding: 1.5rem;
    }
    
    .skeleton-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .job-details-skeleton {
        padding: 1.5rem 0;
    }
}

/* Alert Messages */
.alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    font-size: 0.95rem;
    line-height: 1.5;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1.5px solid #10b981;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1.5px solid #ef4444;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1.5px solid #3b82f6;
}

@media (max-width: 768px) {
    .alert {
        padding: 0.875rem 1rem;
        font-size: 0.9rem;
    }
}

/* Job Details Page Styles */
.job-details-section {
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.job-details-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

.back-link {
    color: var(--primary-color);
    margin-bottom: 1rem;
    display: inline-block;
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition-fast);
}

.back-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.job-details-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
}

.job-details-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.job-details-title-section {
    flex: 1;
    min-width: 200px;
}

.job-details-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-weight: 700;
    line-height: 1.2;
}

.job-details-company {
    font-size: 1.25rem;
    color: var(--text-light);
    font-weight: 500;
}

.job-badge-large {
    font-size: 1rem;
    padding: 0.5rem 1rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.job-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius);
}

.job-info-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.job-info-label {
    font-size: 0.9rem;
    color: var(--text-color);
    font-weight: 600;
    display: block;
}

.job-info-value {
    font-size: 0.95rem;
    color: var(--text-light);
    margin: 0;
    line-height: 1.5;
}

.job-description-section {
    margin-bottom: 1.5rem;
}

.job-description-title {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
    font-weight: 600;
}

.job-description-content {
    line-height: 1.7;
    color: var(--text-color);
    white-space: pre-wrap;
    font-size: 0.95rem;
}

.job-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 1.5rem;
}

.btn-apply-large {
    font-size: 1.1rem;
    padding: 1rem 2rem;
    text-decoration: none;
    display: inline-block;
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.4;
}

.btn-action {
    width: auto;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
}

.btn-share {
    background: var(--secondary-color);
}

.btn-share:hover {
    background: var(--secondary-dark);
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
