/* 
 * jobs.root.hr Styles
 * Brand Color: #FF4500
 */

:root {
    --brand: #FF4500;
    --brand-hover: #e63e00;
    --brand-light: rgba(255, 69, 0, 0.1);
    --text: #333;
    --text-light: #666;
    --text-muted: #999;
    --bg: #ffffff;
    --bg-gray: #f8f9fa;
    --border: #e0e0e0;
    --success: #28a745;
    --error: #dc3545;
    --warning: #ffc107;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.15);
    --radius: 8px;
    --radius-lg: 12px;
    --transition: all 0.2s ease;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

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

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

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.3;
    color: #1a1a1a;
}

h1 {
    font-size: 2.2em;
}

h2 {
    font-size: 1.8em;
}

h3 {
    font-size: 1.4em;
}

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

a:hover {
    color: var(--brand-hover);
}

/* Navbar */
.navbar {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4em;
    font-weight: 700;
    color: var(--brand);
}

.navbar .logo-img {
    height: 32px;
    width: auto;
}

.logo-slogan {
    font-size: 0.7em;
    font-weight: 600;
    color: var(--text-muted);
}

.footer-logo {
    height: 28px;
    width: auto;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 10px;
    align-items: center;
}

.nav-menu a {
    padding: 10px 16px;
    color: var(--text);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-menu a:hover {
    background: var(--bg-gray);
    color: var(--brand);
}

/* Ensure btn-primary in nav has white text */
.nav-menu a.btn-primary,
.nav-menu a.btn-primary:hover {
    color: #fff;
    background: var(--brand);
}

.nav-menu a.btn-primary:hover {
    background: #e63e00;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    color: var(--text);
}

.nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: var(--brand);
    color: #fff;
    border-radius: 10px;
    font-size: 0.75em;
    font-weight: 600;
    margin-left: 5px;
}

/* Buttons - Style matching root.hr */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border: none;
    border-radius: 8px;
    font-size: 0.95em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    text-align: center;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-2px);
}

.btn:focus {
    outline: none;
}

/* Primary - Brand orange */
.btn-primary {
    background: var(--brand);
    color: #fff;
}

.btn-primary:hover {
    background: #e63e00;
    color: #fff;
    box-shadow: 0 4px 12px rgba(255, 69, 0, 0.25);
}

.btn-primary i {
    color: #fff;
}

/* Outline - Light gray background */
.btn-outline {
    background: #f3f4f6;
    color: var(--text);
}

.btn-outline:hover {
    background: #e5e7eb;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Small buttons */
.btn-sm {
    padding: 6px 14px;
    font-size: 0.85em;
}

/* Large buttons */
.btn-lg {
    padding: 12px 28px;
    font-size: 1em;
}

/* Block button */
.btn-block {
    width: 100%;
}

/* Success - Green */
.btn-success {
    background: #16a34a;
    color: #fff;
}

.btn-success:hover {
    background: #15803d;
    color: #fff;
}

/* Danger - Red */
.btn-danger {
    background: #dc2626;
    color: #fff;
}

.btn-danger:hover {
    background: #b91c1c;
    color: #fff;
}

/* Secondary - Gray */
.btn-secondary {
    background: #6b7280;
    color: #fff;
}

.btn-secondary:hover {
    background: #4b5563;
    color: #fff;
}

/* Light outline */
.btn-outline-light {
    background: transparent;
    color: var(--text-muted);
}

.btn-outline-light:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
    color: var(--text);
}

/* Icon-only buttons (same height, square) */
.btn-icon {
    min-width: 42px;
    width: 42px;
    padding: 10px;
}

.btn-icon.btn-sm {
    min-width: 34px;
    width: 34px;
    padding: 6px;
}

/* Button group for consistent action buttons */
.btn-group {
    display: inline-flex;
    gap: 8px;
    align-items: center;
}

.btn-group .btn {
    min-width: 80px;
}

/* Share buttons specific styling */
.share-btn {
    min-width: 110px;
    color: #ffffff !important;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

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

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 1em;
    transition: var(--transition);
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-light);
}

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

select.form-control {
    cursor: pointer;
}

.form-radio {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.form-radio label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 15px 25px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    transition: var(--transition);
    flex: 1;
    min-width: 200px;
}

.form-radio label:hover {
    border-color: var(--brand);
}

.form-radio input:checked+label,
.form-radio label:has(input:checked) {
    border-color: var(--brand);
    background: var(--brand-light);
}

.form-radio input {
    accent-color: var(--brand);
    width: 18px;
    height: 18px;
}

.form-radio i {
    font-size: 1.5em;
    color: var(--brand);
}

/* Cards */
.card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 25px;
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.card-title {
    font-size: 1.2em;
    margin-bottom: 5px;
}

.card-meta {
    color: var(--text-muted);
    font-size: 0.9em;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.card-meta i {
    color: var(--brand);
    margin-right: 5px;
}

/* Job Cards */
.job-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
    margin: 30px 0;
    align-items: stretch;
}

.job-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.job-card .card-header {
    flex: 1;
}

.job-card .company-logo {
    width: 50px;
    height: 50px;
    border-radius: var(--radius);
    object-fit: cover;
    background: var(--bg-gray);
}

.job-card .company-info {
    flex: 1;
}

.job-type {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    background: var(--brand);
    color: #ffffff;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
    white-space: nowrap;
}

.job-type i {
    font-size: 0.9em;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--brand) 0%, #ff6b35 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
}

.hero h1 {
    color: white;
    font-size: 2.5em;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2em;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 30px;
}

.hero .btn-primary {
    background: white;
    color: var(--brand) !important;
}

.hero .btn-primary:hover {
    background: #eeeeee;
    color: var(--brand) !important;
}

/* Hero Search Section */
.hero-search {
    position: relative;
    background: url('../slika.jpg') center center / cover no-repeat;
    padding: 60px 0;
    margin-bottom: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 69, 0, 0.75);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
}

.hero-content h1 {
    color: #fff;
    font-size: 2em;
    margin-bottom: 10px;
}

.hero-content p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1em;
    margin-bottom: 25px;
}

.hero-form {
    background: rgba(255, 255, 255, 0.15);
    padding: 20px;
    border-radius: var(--radius-lg);
}

.hero-form .form-control {
    background: #fff;
    border: none;
}

/* Search Bar (legacy) */
.search-bar {
    background: var(--bg-gray);
    padding: 30px 0;
    margin-bottom: 10px;
}

.search-form {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.search-form .form-control {
    flex: 1;
    min-width: 200px;
}

/* Page Content */
.page-content {
    padding: 20px 0;
}

.page-header {
    margin-bottom: 30px;
}

.page-header h1 {
    margin-bottom: 10px;
}

/* Auth Pages */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 200px);
    padding: 40px 20px;
}

.auth-card {
    width: 100%;
    max-width: 480px;
    background: var(--bg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 40px;
}

.auth-card h1 {
    text-align: center;
    margin-bottom: 30px;
}

.auth-card .logo {
    display: block;
    text-align: center;
    font-size: 1.8em;
    font-weight: 700;
    color: var(--brand);
    margin-bottom: 30px;
}

.auth-footer {
    text-align: center;
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid var(--border);
    color: var(--text-light);
}

/* Profile Dashboard */
.dashboard {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    padding: 40px 0;
}

.dashboard-sidebar {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 25px;
    height: fit-content;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 20px;
    display: block;
    background: var(--bg-gray);
    border: 3px solid var(--brand);
}

.profile-name {
    text-align: center;
    font-size: 1.3em;
    margin-bottom: 5px;
}

.profile-type {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9em;
    margin-bottom: 20px;
}

.sidebar-nav {
    list-style: none;
}

.sidebar-nav a:not(.btn-primary) {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    color: var(--text);
    border-radius: var(--radius);
    margin-bottom: 5px;
}

.sidebar-nav a:not(.btn-primary):hover,
.sidebar-nav a:not(.btn-primary).active {
    background: var(--brand-light);
    color: var(--brand);
}

.dashboard-content {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--bg-gray);
    padding: 25px;
    border-radius: var(--radius-lg);
    text-align: center;
}

.stat-card i {
    font-size: 2em;
    color: var(--brand);
    margin-bottom: 10px;
}

.stat-card .stat-value {
    font-size: 2em;
    font-weight: 700;
    color: var(--text);
}

.stat-card .stat-label {
    color: var(--text-muted);
    font-size: 0.9em;
}

/* Table */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.table th {
    background: var(--bg-gray);
    font-weight: 600;
}

.table tr:hover td {
    background: var(--bg-gray);
}

/* Status Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 500;
}

.badge-nova {
    background: var(--brand-light);
    color: var(--brand);
}

.badge-pregledano {
    background: #e3f2fd;
    color: #1976d2;
}

.badge-prihvaceno {
    background: #e8f5e9;
    color: #388e3c;
}

.badge-odbijeno {
    background: #ffebee;
    color: #d32f2f;
}

/* Flash Messages */
.flash {
    padding: 15px 0;
    font-weight: 500;
}

.flash-success {
    background: #e8f5e9;
    color: #388e3c;
}

.flash-error {
    background: #ffebee;
    color: #d32f2f;
}

.flash-warning {
    background: #fff8e1;
    color: #f57c00;
}

/* Footer */
.footer {
    border-top: 1px solid #e0e0e0;
    padding: 18px 20px;
    margin-top: 25px;
    background: #fff;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.82em;
    color: #888;
}

.footer a {
    color: #FF4500;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Job Detail Page Grid */
.job-detail-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
}

.job-detail-grid>div:first-child {
    order: 1;
}

.job-detail-grid>div:last-child {
    order: 2;
}

/* File Upload */
.file-upload {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 30px;
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
}

.file-upload:hover {
    border-color: var(--brand);
    background: var(--brand-light);
}

.file-upload input {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

.file-upload i {
    font-size: 2em;
    color: var(--brand);
    margin-bottom: 10px;
}

/* Company Card */
.company-header {
    display: flex;
    gap: 25px;
    align-items: flex-start;
    margin-bottom: 30px;
}

.company-logo-lg {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-lg);
    object-fit: cover;
    background: var(--bg-gray);
}

/* Responsive */
@media (max-width: 992px) {
    .dashboard {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar {
        display: flex;
        flex-wrap: wrap;
        gap: 20px;
        align-items: center;
    }

    .profile-avatar {
        width: 80px;
        height: 80px;
        margin: 0;
    }

    .sidebar-nav {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
        width: 100%;
    }

    .sidebar-nav a:not(.btn-primary) {
        margin: 0;
    }
}

@media (max-width: 768px) {
    .job-detail-grid {
        grid-template-columns: 1fr;
    }

    .job-detail-grid>div:first-child {
        order: 1;
    }

    .job-detail-grid>div:last-child {
        order: 2;
    }

    .nav-toggle {
        display: block;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        padding: 20px;
        gap: 5px;
        border-bottom: 1px solid var(--border);
        display: none;
    }

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

    .nav-menu li {
        width: 100%;
    }

    .nav-menu a {
        width: 100%;
    }

    .hero {
        padding: 60px 0;
    }

    .hero h1 {
        font-size: 2em;
    }

    .job-grid {
        grid-template-columns: 1fr;
    }

    /* Job detail page - center company header on mobile */
    .job-detail-grid .company-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .job-detail-grid .job-meta {
        justify-content: center;
        flex-wrap: wrap;
    }

    .job-detail-grid .card-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 10px;
    }

    .search-form {
        flex-direction: column;
    }

    .auth-card {
        padding: 30px 20px;
    }

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

    .footer-left,
    .footer-right {
        flex-direction: column;
        gap: 8px;
    }

    .footer-bottom {
        padding-top: 15px;
        font-size: 0.85em;
    }

    .footer-bottom p {
        line-height: 1.6;
    }

    .company-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.8em;
    }

    h2 {
        font-size: 1.5em;
    }

    .btn {
        padding: 10px 20px;
    }

    .card {
        padding: 20px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .form-radio {
        flex-direction: column;
    }

    .form-radio label {
        min-width: auto;
    }
}

/* Homepage Stats Cards */
.home-stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.home-stat-card {
    flex: 1;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 20px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.home-stat-card i {
    color: var(--brand);
    font-size: 1.1em;
}

.home-stat-card .stat-number {
    font-weight: 600;
    color: var(--brand);
}

.home-stat-card .stat-text {
    color: var(--text-muted);
}

@media (max-width: 768px) {
    .home-stats {
        flex-direction: column;
        gap: 12px;
        padding: 0 15px;
    }

    .home-stat-card {
        flex-direction: column;
        gap: 6px;
        padding: 16px 20px;
    }

    .home-stat-card i {
        font-size: 1.5em;
        margin-bottom: 4px;
    }

    .page-content {
        padding-left: 15px;
        padding-right: 15px;
    }

    .job-grid {
        padding: 0;
    }
}

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

.text-muted {
    color: var(--text-muted);
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.mb-30 {
    margin-bottom: 30px;
}