/* Candidates Page Styles */
/* CSS variables are defined in design-system.css */

/* ═══════════════════════════════════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════════════════════════════════ */

.candidates-hero {
    background-color: var(--dark-hero);
    color: var(--text-inverse);
    padding: var(--hero-padding-top-desktop) 0 var(--hero-padding-bottom-desktop);
    text-align: center;
    position: relative;
    width: 100%;
    /* background-image set inline in PHP */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    margin-bottom: 0;
}

.candidates-hero.hero-light {
    /* Specific styles for hero-light if needed in future */
    position: relative;
    /* Ensure it has a position context */
}

/* Removed negative margin */

.candidates-hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(33, 48, 53, 0.60) 0%,
            rgba(22, 22, 21, 0.85) 100%);
    z-index: 0;
}

.candidates-hero-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    padding: 0 var(--container-padding, 20px);
}

.candidates-hero-label {
    display: inline-block;
    font-size: var(--font-size-xs);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--primary);
    margin-bottom: 1.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    opacity: 0;
}

.candidates-hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin: 0 0 1.5rem 0;
    color: white;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-wrap: balance;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    animation-delay: 0.1s;
    opacity: 0;
}

.candidates-hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.35rem);
    line-height: 1.6;
    color: var(--text-inverse);
    max-width: 724px;
    margin: 0 auto;
    font-weight: 400;
    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.25),
        0 6px 20px rgba(0, 0, 0, 0.25);
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    animation-delay: 0.2s;
    opacity: 0;
}

/* Hero Divider */
.hero-divider {
    position: absolute;
    top: 92px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(var(--container-width, 1280px) - 40px);
    max-width: calc(100% - 40px);
    height: 1px;
    background-color: var(--divider);
    border: none;
    z-index: 2;
}

@media (max-width: 1023px) {
    .hero-divider {
        top: 68px;
    }
}

.candidates-hero-actions {
    margin-top: 2.5rem;
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    animation-delay: 0.3s;
    opacity: 0;
}

.candidates-hero-actions .btn-primary svg,
.candidates-hero-actions .btn-secondary svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════
   CONTAINER & GENERAL
   ═══════════════════════════════════════════════════════════════════════ */

.candidates-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0;
    position: relative;
    z-index: 5;
}

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

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--text);
    margin: 0 0 1rem;
}

/* ═══════════════════════════════════════════════════════════════════════
   ZIG-ZAG SECTION
   ═══════════════════════════════════════════════════════════════════════ */

.zig-zag-section {
    padding: var(--section-spacing-desktop) 20px;
}

@media (max-width: 991px) {
    .zig-zag-section {
        padding: 75px 20px;
    }
}

@media (max-width: 768px) {
    .zig-zag-section {
        padding: var(--section-spacing-mobile) 20px;
    }
}

.zig-zag-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.zig-zag-item:not(:first-child) {
    padding-top: var(--section-spacing-desktop);
}

@media (max-width: 991px) {
    .zig-zag-item:not(:first-child) {
        padding-top: 75px;
    }
}

@media (max-width: 768px) {
    .zig-zag-item:not(:first-child) {
        padding-top: var(--section-spacing-mobile);
    }
}

.zig-zag-reverse .zig-zag-image {
    order: 2;
}

.zig-zag-reverse .zig-zag-content {
    order: 1;
}

@media (max-width: 768px) {
    .zig-zag-item {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    /* Na mobile obrázky stredované */
    .zig-zag-image {
        justify-content: center;
        margin: 0 auto;
    }

    .zig-zag-reverse .zig-zag-image {
        order: -1;
        /* Image always on top on mobile */
    }

    .zig-zag-reverse .zig-zag-content {
        order: 1;
    }

    .zig-zag-content {
        padding: 0;
        text-align: center;
    }

    .zig-zag-content .candidates-card-title {
        font-size: 1.75rem;
    }
}

@media (max-width: 768px) {
    .zig-zag-item:not(:last-child) {
        padding-bottom: var(--section-spacing-mobile);
    }
}

.zig-zag-image {
    display: flex;
    align-items: center;
}

/* Prvý item - obrázok vľavo */
.zig-zag-item:first-child .zig-zag-image {
    justify-content: flex-start;
}

/* Reverse item (druhý) - obrázok vpravo */
.zig-zag-item.zig-zag-reverse .zig-zag-image {
    justify-content: flex-end;
}

.zig-zag-image img {
    width: 512px;
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    object-fit: cover;
    aspect-ratio: 1/1;
    /* Square images */
}

.zig-zag-content {
    padding: 1rem;
}

.zig-zag-content .candidates-card-title {
    font-size: 2.25rem;
    margin-bottom: 1.5rem;
    margin-top: 0;
}

.zig-zag-content .intro-text-lead {
    font-size: 1.125rem;
    line-height: 1.6;
    color: var(--text);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.zig-zag-content .intro-text {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════════════════════════════
   TOOLS SECTION
   ═══════════════════════════════════════════════════════════════════════ */

.tools-section {
    padding: var(--section-spacing-desktop) 20px;
}

@media (max-width: 991px) {
    .tools-section {
        padding: 75px 20px;
    }
}

@media (max-width: 768px) {
    .tools-section {
        padding: var(--section-spacing-mobile) 20px;
    }
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1024px;
    margin: 0 auto;
}

.tool-card {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    height: 100%;
    position: relative;
    overflow: hidden;
    /* Subtle background pattern */
    background-image: radial-gradient(circle at 100% 0%, rgba(253, 198, 0, 0.03) 0%, transparent 25%),
        radial-gradient(circle at 0% 100%, rgba(0, 85, 136, 0.03) 0%, transparent 25%);
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.08);
    border-color: var(--primary);
    background-color: white;
    /* Enhance background on hover */
    background-image: radial-gradient(circle at 100% 0%, rgba(253, 198, 0, 0.08) 0%, transparent 30%),
        radial-gradient(circle at 0% 100%, rgba(0, 85, 136, 0.08) 0%, transparent 30%);
}

.tool-icon {
    width: 60px;
    height: 60px;
    background: var(--bg-subtle);
    color: var(--dark-hero);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.tool-card:hover .tool-icon {
    background: var(--primary);
    color: white;
}

.tool-icon svg {
    width: 32px;
    height: 32px;
    stroke-width: 1.5;
}

.tool-title {
    font-size: var(--h4-size);
    font-weight: 700;
    margin-block: 1rem;
    color: var(--text);
}

.tool-desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 1rem 0;
    flex-grow: 1;
}


/* ═══════════════════════════════════════════════════════════════════════
   PROCESS SECTION (Ako spolupráca prebieha)
   ═══════════════════════════════════════════════════════════════════════ */

/* Full width background wrapper */
.process-section-full {
    background-color: var(--bg-subtle);
    width: 100%;
    padding: var(--section-spacing-desktop) 20px;
}

@media (max-width: 991px) {
    .process-section-full {
        padding: 75px 20px;
    }
}

@media (max-width: 768px) {
    .process-section-full {
        padding: var(--section-spacing-mobile) 20px;
    }
}

/* Reset old process-section styles if any */
.process-section {
    margin-bottom: 0;
    background-color: transparent;
    padding: 0;
    border-radius: 0;
}

.process-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    position: relative;
    padding-top: 2rem;
}

/* Line connecting steps */
.process-steps::before {
    content: "";
    position: absolute;
    top: 57px;
    /* Align with center of 50px icon + 2rem padding-top (32px + 25px) */
    left: 12.5%;
    /* Center of first column (25% / 2) */
    right: 12.5%;
    /* Center of last column */
    height: 2px;
    background: var(--border-light);
    z-index: 0;
}

.process-step {
    position: relative;
    z-index: 1;
    text-align: center;
}

.companies-icon-wrapper {
    width: 52px;
    height: 52px;
    background: var(--bg-subtle);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.companies-icon-wrapper svg {
    color: var(--text);
    width: 24px;
    height: 24px;
}

.step-icon-wrapper {
    width: 50px;
    height: 50px;
    background: white;
    border: 2px solid var(--primary);
    color: var(--dark-hero);
    font-weight: 800;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.25rem;
    transition: all 0.3s ease;
    box-shadow: 0 0 0 10px var(--bg-subtle);
    /* Creates gap in the line matching section bg */
}

.process-step:hover .step-icon-wrapper {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

.step-content h3 {
    font-size: var(--h4-size);
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.step-content p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ═══════════════════════════════════════════════════════════════════════
   WHY US SECTION
   ═══════════════════════════════════════════════════════════════════════ */

.why-us-section {
    padding: var(--section-spacing-desktop) 20px;
}

@media (max-width: 991px) {
    .why-us-section {
        padding: 75px 20px;
    }
}

@media (max-width: 768px) {
    .why-us-section {
        padding: var(--section-spacing-mobile) 20px;
    }
}

.why-us-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.why-us-item {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: none;
    align-items: flex-start;
    transition: all 0.3s ease;
}

.why-us-item:hover {
    border-color: var(--border-light);
    /* No transform or shadow on hover to match companies */
}

.why-us-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: var(--bg-subtle);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.why-us-icon svg {
    width: 32px;
    height: 32px;
}

.why-us-content h3 {
    font-size: var(--h4-size);
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--text);
}

.why-us-content p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* CTA Split Layout moved to global-cta.css */

/* ═══════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════ */

@media (max-width: 991px) {
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .process-steps {
        grid-template-columns: 1fr;
        gap: 2rem;
        max-width: 600px;
        margin: 0 auto;
    }

    .process-steps::before {
        display: none;
    }

    /* Vertical line connecting steps on mobile */
    .process-step:not(:last-child)::after {
        content: "";
        position: absolute;
        left: 25px;
        /* Center of 50px icon */
        top: 50px;
        /* Bottom of icon */
        bottom: -2rem;
        /* Extend through the gap to the next item */
        width: 2px;
        background: var(--border-light);
        transform: translateX(-50%);
        z-index: -1;
    }

    .process-step {
        display: flex;
        gap: 1.5rem;
        text-align: left;
        align-items: flex-start;
    }

    .step-content h3 {
        margin-top: 0;
    }

    .step-icon-wrapper {
        margin: 0;
        flex-shrink: 0;
    }

    .why-us-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .candidates-hero {
        padding: var(--hero-padding-top-mobile) 0 var(--hero-padding-bottom-mobile);
    }

    .candidates-hero-title {
        font-size: 2.5rem;
    }

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

    /* Reduce Tool Icon Size on Mobile */
    .tool-icon {
        width: 48px;
        height: 48px;
        border-radius: 12px;
    }

    .tool-icon svg {
        width: 24px;
        height: 24px;
    }

    .process-steps {
        /* Ensure vertical layout on mobile */
        display: flex;
        flex-direction: column;
        gap: 2rem;
    }

    .process-step {
        flex-direction: row;
        /* Keep icon left, text right layout from 991px query */
        align-items: flex-start;
        text-align: left;
    }

    .step-icon-wrapper {
        margin: 0;
        /* Reset margin from desktop center layout */
        margin-right: 1.5rem;
        /* Add spacing between icon and text */
        flex-shrink: 0;
        /* Reduce Step Icon Size on Mobile */
        width: 40px;
        height: 40px;
        font-size: 1rem;
        box-shadow: 0 0 0 6px var(--bg-subtle);
    }

    .why-us-item {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
}


/* Utilities */
.mb-4 {
    margin-bottom: 1rem;
}

.mb-6 {
    margin-bottom: 1.5rem;
}

.mt-2 {
    margin-top: 2rem;
}