/**
 * Layout Styles - HIRVU Child Theme
 * 
 * Header and Footer styles using Blocksy CSS variables
 */

/* ============================================
   CSS Variables - Fonts
   ============================================ */
:root {
    --font-sans: 'Saira', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Rubik', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Open Sans', sans-serif;
    --font-condensed: 'Saira Semi Condensed', 'Roboto Condensed', sans-serif;
}

/* Apply fonts globally */
body {
    font-family: var(--font-sans);
    padding-top: 116px; /* 48px + 68px - compensate for sticky header */
    background-color: var(--theme-palette-color-8)!important;
    background-image: url('../images/pattern.png')!important;
    background-repeat: repeat;
}

/* Admin Bar Fix - dodatkowy margin gdy zalogowany */
body.admin-bar {
    padding-top: calc(116px + 32px); /* 116px header + 32px admin bar */
}

body.admin-bar .site-header {
    top: 32px; /* Admin bar height */
}

/* Desktop admin bar (> 782px) */
@media screen and (min-width: 783px) {
    body.admin-bar {
        padding-top: calc(116px + 32px);
    }
    
    body.admin-bar .site-header {
        top: 32px;
    }
}

/* Mobile admin bar (< 782px) */
@media screen and (max-width: 782px) {
    body.admin-bar {
        padding-top: calc(116px + 46px); /* 116px header + 46px mobile admin bar */
    }
    
    body.admin-bar .site-header {
        top: 46px; /* Mobile admin bar height */
    }
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
}


/* ============================================
   HEADER STYLES
   ============================================ */

/* Sticky Header Container */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0px 1px 20px 0px rgba(0, 0, 0, 0.05);
}

/* Top Bar (48px) */
.top-bar {
    background-color: var(--theme-palette-color-3); /* Brand Secondary #1A1849 */
    color: var(--theme-palette-color-8); /* #ffffff */
    height: 48px;
}

.top-bar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding-left: 12px;
}

/* Social Media Icons - Left Side */
.social-icons {
    display: flex;
    align-items: center;
    gap: 8px;
}

.social-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: var(--theme-palette-color-1); /* Brand Primary #E30A6C */
    color: var(--theme-palette-color-8); /* #ffffff */
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.social-icon:hover {
    background-color: var(--theme-palette-color-2); /* Brand Primary Dark #bb0155 */
    color: var(--theme-palette-color-8); /* #ffffff */
}

/* Right Side Container */
.top-bar-right {
    display: flex;
    align-items: center;
    height: 100%;
}

/* Language Selector Placeholder - Right Side */
.language-selector-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    height: 48px;
    background-color: var(--theme-palette-color-1); /* Brand Primary */
    padding: 0 16px 0 10px; /* Extra padding left for diagonal */
}

/* Diagonal element before language selector */
.language-selector-wrapper::before {
    content: '';
    position: absolute;
    left: -48px;
    top: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 0 48px 48px;
    border-color: transparent transparent var(--theme-palette-color-1) transparent;
}

.language-selector-placeholder {
    color: var(--theme-palette-color-8); /* #ffffff */
    font-family: var(--font-condensed);
    font-size: 14px;
    font-weight: 500;
}

/* Main Header (68px) */
.main-header {
    background-color: var(--theme-palette-color-8); /* #ffffff */
    height: 68px;
}

.main-header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding-right: 20px;
}

/* Logo Section with Triangle */
.logo-wrapper {
    position: relative;
    width: 177px;
    height: 68px;
}

.logo-link {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

/* Background rectangle */
.logo-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 68px;
    background-color: var(--theme-palette-color-1); /* Brand Primary */
    transition: background-color 0.3s ease;
}

.logo-link:hover .logo-background {
    background-color: var(--theme-palette-color-2); /* Brand Primary Dark */
}

/* Triangle on the right */
.logo-triangle {
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 68px 68px 0 0;
    border-color: var(--theme-palette-color-1) transparent transparent transparent;
    transform: translateX(100%);
    transition: border-color 0.3s ease;
}

.logo-link:hover .logo-triangle {
    border-top-color: var(--theme-palette-color-2);
}

/* Logo Image */
.logo-image {
    position: relative;
    padding: 16px 8px 16px 20px;
    z-index: 1;
}

.logo-image img {
    height: 32px;
    width: auto;
    display: block;
}

/* Menu Placeholder - Right Side */
.menu-placeholder {
    font-family: var(--font-condensed);
    font-size: 18px;
    font-weight: 500;
    color: var(--theme-palette-color-3); /* Brand Secondary */
}


/* ============================================
   RESPONSIVE - Mobile (< 1000px)
   ============================================ */
@media (max-width: 999px) {
    .menu-placeholder {
        font-size: 16px;
    }

    .language-selector-wrapper {
        padding: 0 12px 0 48px;
    }

    .language-selector-placeholder {
        font-size: 12px;
    }
}


/* ============================================
   RESPONSIVE - Small Mobile (< 690px)
   ============================================ */
@media (max-width: 689px) {
    body {
        padding-top: 116px;
    }

    .social-icons {
        gap: 6px;
    }

    .social-icon {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }

    .logo-wrapper {
        width: 150px;
    }

    .logo-image {
        padding: 18px 8px 18px 16px;
    }

    .logo-image img {
        height: 28px;
    }

    .menu-placeholder {
        font-size: 14px;
    }

    .language-selector-wrapper {
        padding: 0 8px 0 40px;
    }

    .language-selector-wrapper::before {
        left: -40px;
        border-width: 0 0 48px 40px;
    }

    .language-selector-placeholder {
        font-size: 11px;
    }

    .main-header-container {
        padding-right: 12px;
    }
}


/* ============================================
   Footer Styles
   ============================================ */
.site-footer {
    background-color: var(--theme-palette-color-3); /* Brand Secondary #1A1849 */
    color: var(--theme-palette-color-8); /* #ffffff */
    padding: 1rem 0;
}

.footer-container {
    max-width: 1280px; /* Tailwind max-w-7xl equivalent */
    margin: 0 auto;
    padding: 0 1rem;
    text-align: center;
}

.footer-copyright {
    margin: 0;
    font-size: 0.875rem; /* 14px */
    font-family: var(--font-condensed);
    line-height: 1.5;
}


/* ============================================
   JOB FILTERS PAGE - Container & Typography
   ============================================ */

.job-filters-page {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

.page-header {
    margin-bottom: 1rem;
    padding-top: 2rem;
}

.page-title {
    font-family: var(--font-heading);
    font-size: 32px;
    font-weight: 700;
    color: var(--theme-palette-color-3); /* Brand Secondary */
    margin: 0;
    line-height: 0.85;
}

.page-subtitle {
    font-family: var(--font-condensed);
    font-size: 16px;
    color: var(--theme-palette-color-6);
    margin: 2px 0 0 0;
}

.page-subtitle .subtitle-count {
    font-weight: 500;
}

/* Responsive Typography */
@media (max-width: 689px) {

    .page-header {
        padding-top: 1.5rem;
    }

    .page-title {
        font-size: 24px;
    }
    
    .page-subtitle {
        font-size: 14px;
    }
    
    .job-filters-page {
        padding: 0 16px;
    }
}


/* ============================================
   GLOBAL - Minimum Width
   ============================================ */

html,
body {
    min-width: 320px;
    overflow-x: auto;
}

/* Prevent content from shrinking below 320px */
#main-container {
    min-width: 320px;
}