/* --- 1. Brand & Design System --- */
:root {
    /* 2.1. Color Palette */
    --dark-bg: #0A0F1E;
    --primary-color: #4BC4EB;
    --accent-color: #4BC4EB; /* New Accent Color */
    --light-text: #EAEBF0;
    --muted-text: #a1a9c0;
    --card-bg: rgba(22, 29, 51, 0.5);
    --card-bg-solid-mobile: rgb(22, 29, 51); /* Solid background for mobile performance */
    --card-border: rgba(255, 255, 255, 0.1);
    --primary-glow: rgba(0, 123, 255, 0.5);

    /* 2.2. Typography */
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Poppins', sans-serif;

    /* Spacing */
    --container-width: 1140px;
    --section-padding: 45px;
}

/* --- Global Styles & Resets --- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px; /* Offset for sticky header */
}

body {
    background-color: var(--dark-bg);
    color: var(--light-text);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

body.no-scroll {
    overflow: hidden;
}

/* --- Google Material Symbols Adjustments --- */
.material-symbols-outlined {
  font-variation-settings:
  'FILL' 0,
  'wght' 300,
  'GRAD' 0,
  'opsz' 24;
  vertical-align: middle; /* Better alignment with text */
}

/* --- Aurora Background UI --- */
.aurora-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.aurora-shape-1, .aurora-shape-2 {
    position: absolute;
    border-radius: 50%;
    filter: blur(150px);
    opacity: 0.6;
}

.aurora-shape-1 {
    width: 600px;
    height: 600px;
    background: rgba(0, 123, 255, 0.2);
    top: -150px;
    left: -150px;
}

.aurora-shape-2 {
    width: 500px;
    height: 500px;
    background: rgba(80, 0, 255, 0.15);
    bottom: -100px;
    right: -100px;
}

/* --- Contact Links Grouping --- */
.contact-links-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    column-gap: 8px; /* Space between links */
    row-gap: 5px;    /* Space if links wrap to a new line */
}

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

@keyframes move-aurora {
    from { transform: translate(0, 0) rotate(0deg); }
    to { transform: translate(200px, 100px) rotate(180deg); }
}

/* --- Core Components & Layouts --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--light-text);
    line-height: 1.2;
}

h1 { font-size: 4rem; font-weight: 800; }
h2 { font-size: 2.5rem; text-align: center; margin-bottom: 60px; }
h3 { font-size: 1.5rem; margin-bottom: 15px; }
h4 { font-size: 1.1rem; margin-bottom: 0; }


p {
    color: var(--muted-text);
    margin-bottom: 1rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--light-text);
}

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

.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    box-shadow: none;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--primary-glow);
    background-color: var(--primary-color);
    color: #fff;
}

.btn-secondary {
    background-color: transparent;
    color: var(--muted-text);
    border: 2px solid var(--card-border);
    padding: 4px 5px;
}

.btn-secondary:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}


.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

section {
    padding: var(--section-padding) 0;
    position: relative;
}

.card-grid {
    display: grid;
    gap: 30px;
}

.three-columns { grid-template-columns: repeat(3, 1fr); }
.two-columns { grid-template-columns: repeat(2, 1fr); }


.card {
    background: var(--card-bg-solid-mobile);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 40px;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.card:not(.map-card):not(.testimonial-card):hover {
    transform: translateY(-10px);
    border-color: var(--primary-color);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    display: block;
    margin-bottom: 20px;
}

/* --- 3. Header / Navigation --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    z-index: 1000;
    transition: background-color 0.3s ease, border-bottom 0.3s ease;
}

header.scrolled {
    background: rgba(22, 29, 51, 0.85);
    border-bottom: 1px solid var(--card-border);
}

/* PERFORMANCE FIX: Add blur, animations, and other desktop effects only on larger screens */
@media(min-width: 993px) {
    .card {
         background: var(--card-bg);
         backdrop-filter: blur(10px);
         -webkit-backdrop-filter: blur(10px);
    }
    header.scrolled {
        background: var(--card-bg);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
    .aurora-shape-1 {
        animation: move-aurora 25s infinite linear alternate;
    }
    .aurora-shape-2 {
        animation: move-aurora 30s infinite linear alternate-reverse;
    }

    /* Scroll animations */
    .animation-group > * {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    }

    .animation-group.is-visible > * {
        opacity: 1;
        transform: translateY(0);
    }
}


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

/* MODIFIED: Final Logo Styles with Theme-Specific Logic */
.logo {
    display: block;
    width: 125px;
    height: 28px; /* Sets the correct height for the navbar */
    position: relative;
}

.logo img {
    position: absolute;
    top: 50%; /* Center vertically */
    left: 0;
    height: 100%; /* Scale based on container height */
    width: auto;   /* Maintain aspect ratio */
    transform: translateY(-50%);
    transition: opacity 0.3s ease;
}

/* Default state: white logo visible, color logo hidden */
.logo .logo-color {
    opacity: 0;
}
.logo .logo-white {
    opacity: 1;
}

/* On LIGHT THEME ONLY, when header is scrolled, swap logos */
body.light-theme header.scrolled .logo .logo-white {
    opacity: 0;
}
body.light-theme header.scrolled .logo .logo-color {
    opacity: 1;
}

/* On LIGHT THEME ONLY, target the footer logo specifically */
body.light-theme footer .logo .logo-white {
    opacity: 0;
}
body.light-theme footer .logo .logo-color {
    opacity: 1;
}

.main-nav ul {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 40px;
}

.main-nav a {
    color: var(--muted-text);
    font-weight: 500;
    position: relative;
    padding-bottom: 5px;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav a:hover, .main-nav a.active {
    color: var(--light-text);
}

.main-nav a:hover::after {
    width: 100%;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}

.hamburger {
    background: none;
    border: none;
    color: var(--light-text);
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
}

.mobile-only,
.mobile-only-procena {
    display: none;
}

.mobile-controls {
    display: none;
}


/* --- 4. Main Content Sections --- */

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 20px;
    position: relative;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.hero-background::after { /* Dark overlay */
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 15, 30, 0.7);
}

.hero-background video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content {
    max-width: 800px;
}


.hero h1 {
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.25rem;
    color: var(--light-text);
    max-width: 600px;
    margin: 0 auto 40px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.scroll-down-arrow {
    position: absolute;
    bottom: 90px;
    left: 50%;
    transform: translate(-50%, 0);
    color: var(--light-text);
    animation: bounce 2s infinite;
}

.scroll-down-arrow .material-symbols-outlined {
    font-size: 3rem;
    font-variation-settings: 'wght' 200;
}
@keyframes bounce {
    0%, 100% {
        transform: translate(-50%, 0);
    }
    50% {
        transform: translate(-50%, -15px);
    }
}

/* Styles for the Zasto Mi card specifically */
.zasto-mi-card {
    position: relative;
    overflow: hidden; 
}
.zasto-mi-card .card-content {
    position: relative;
    z-index: 1;
}
.zasto-mi-card .icon {
    position: absolute;
    top: 50%;
    right: -20px;
    transform: translateY(-50%);
    z-index: 0;
    font-size: 9rem;
    opacity: 0.07;
    color: var(--primary-color);
    line-height: 1;
    margin: 0;
    transition: transform 0.4s ease;
}
.zasto-mi-card:hover .icon {
    transform: translateY(-50%) scale(1.1) rotate(-5deg);
}

/* ====================================================== */
/* START: PRODUCTS SECTION STYLES                   */
/* ====================================================== */

#products-section {
    padding-bottom: 70px;
}

/* --- Desktop Layout --- */
.product-selector-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.product-display-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    align-items: center;
}

.product-display-text {
    min-height: 250px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-display-text h3 {
    color: var(--primary-color);
}

.btn-link {
    font-family: var(--font-heading);
    font-weight: 600;
    margin-top: auto; /* Pushes button to the bottom */
    padding-top: 20px; /* Ensures space between text and button */
    color: var(--primary-color);
    align-self: flex-start; /* Aligns button to the left */
}
.btn-link:hover {
    color: var(--light-text);
}


.product-display-image {
    padding: 0;
    overflow: hidden;
    height: 250px;
}

.product-display-image a {
    display: block;
    height: 100%;
}

.product-display-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.product-display-image:hover img {
    transform: scale(1.1);
}

/* --- Mobile Accordion Layout --- */
.product-accordion-item {
    border: 1px solid var(--card-border);
    border-radius: 16px;
    margin-bottom: 15px;
    overflow: hidden;
    background: var(--card-bg-solid-mobile);
}

.product-accordion-header {
    padding: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 15px;
}
.product-accordion-header:hover {
    background-color: rgba(255, 255, 255, 0.05);
}
.product-accordion-header .material-symbols-outlined {
    color: var(--primary-color);
    font-size: 1.8rem;
}
.product-accordion-header h4 {
    color: var(--light-text);
    margin-bottom: 0;
}

.product-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease-out, padding 0.5s ease-out;
    padding: 0 20px;
}

.product-accordion-item.is-active .product-accordion-content {
    max-height: 600px; 
    padding: 20px; 
}

.product-accordion-content img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 15px;
}
.product-accordion-content p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

.product-accordion-content .btn-link {
    display: inline-block;
    margin-top: 15px;
    padding-top: 0; /* Override default padding */
}

/* ====================================================== */
/* END: PRODUCTS SECTION STYLES                     */
/* ====================================================== */


/* ====================================================== */
/* START: INDUSTRIES SECTION STYLES                   */
/* ====================================================== */

#industries-section {
    position: relative;
    overflow: hidden;
    transition: background-color 0.5s ease;
    --bg-opacity: 0.4; /* Default opacity for the background image */
}

#industries-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image: var(--bg-image);
    background-size: cover;
    background-position: center;
    opacity: var(--bg-opacity);
    transition: opacity 0.4s ease-in-out;
}

#industries-section::after { /* Dark overlay on top of image */
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 15, 30, 0.6);
    z-index: -1;
}

.industries-layout {
    display: grid;
    gap: 30px;
}

.industry-selector-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.industry-selector-card {
    padding: 20px;
    text-align: center;
    cursor: pointer;
    border: 2px solid var(--card-border);
    transition: background-color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.industry-selector-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.industry-selector-card.is-active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--dark-bg);
}

.industry-selector-card .material-symbols-outlined {
    font-size: 2rem;
    display: block;
    margin: 0 auto 10px;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.industry-selector-card h4 {
    color: var(--light-text);
    font-weight: 500;
    transition: color 0.3s ease;
}

.industry-selector-card.is-active .material-symbols-outlined,
.industry-selector-card.is-active h4 {
    color: var(--dark-bg);
}

.service-card,
.industry-selector-card,
.slider-btn,
.product-accordion-header {
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.industry-display-card {
    display: none;
    flex-direction: column;
    justify-content: center;
    min-height: 400px;
    padding: 40px;
}
.industry-display-card h3 {
    color: var(--primary-color);
}
.industry-display-card p {
    color: var(--light-text);
    font-size: 1.1rem;
}
.industry-display-contact-btn {
    margin-top: 30px;
    align-self: flex-start; /* Aligns button to the left in the flex column */
}


/* Desktop view for the Industries section */
@media (min-width: 993px) {
    .industries-layout {
        grid-template-columns: 1fr 1fr;
        align-items: center;
    }
    .industry-display-card {
        display: flex;
    }
}

/* Stats Counter Section */
#stats {
    padding-top: 0;
}

.stats-card {
    display: flex;
    justify-content: space-around;
    align-items: center;
    text-align: center;
    padding: 30px 40px;
}

.stat-item h3 {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.stat-item p {
    margin: 0;
    font-family: var(--font-heading);
    font-weight: 500;
    color: var(--muted-text);
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

/* Services Section */
.service-card {
    text-align: center;
    cursor: pointer;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.service-front, .service-back {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    backface-visibility: hidden;
    transition: opacity 0.5s ease, transform 0.5s ease;
    position: absolute;
    top: 0;
    left: 0;
    padding: 30px;
    z-index: 1;
}

.service-back {
    opacity: 0;
    transform: translateY(20px);
}
.service-back p {
    font-size: 0.95rem;
}
.service-back h3 {
    margin-bottom: 15px;
}

.service-back-btn {
    margin-top: 20px;
    padding: 10px 20px;
    font-size: 0.9rem;
}

.service-card:hover .service-front,
.service-card.is-active .service-front {
    opacity: 0;
    transform: translateY(-20px);
}

.service-card:hover .service-back,
.service-card.is-active .service-back {
    opacity: 1;
    transform: translateY(0);
}

.btn-text {
    font-family: var(--font-heading);
    font-weight: 600;
    margin-top: auto;
    color: var(--primary-color);
}


/* Testimonials & Slider Styles */
.testimonial-slider {
    position: relative;
    max-width: 820px;
    margin: 0 auto;
    padding-bottom: 60px;
}

.testimonial-slider-viewport {
    overflow: hidden;
    max-width: 700px;
    margin: 0 auto;
}

.testimonial-wrapper {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.testimonial-card {
    flex: 0 0 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    min-height: 250px;
    justify-content: center;
}

.testimonial-card blockquote {
    font-style: italic;
    color: var(--light-text);
    margin-bottom: 20px;
    flex-grow: 1;
    font-size: 1.1rem;
    line-height: 1.7;
}

.testimonial-stars {
    color: #FFC107;
    margin-bottom: 20px;
    font-size: 1rem;
}

.testimonial-card cite {
    font-style: normal;
    font-weight: 600;
    color: var(--muted-text);
    align-self: flex-start;
}

.slider-btn {
    position: absolute;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--card-border);
    color: var(--light-text);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s ease, transform 0.3s ease;
    z-index: 10;
}
.slider-btn:hover {
    background-color: var(--primary-color);
    transform: scale(1.1);
}

.slider-btn.prev-btn {
    left: 60px; 
}
.slider-btn.next-btn {
    right: 60px; 
}

.slider-dots {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    padding: 10px;
}

.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.3);
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    padding: 0;
}

.slider-dot:hover {
    background-color: rgba(255, 255, 255, 0.6);
    transform: scale(1.2);
}

.slider-dot.active {
    background-color: var(--primary-color);
    transform: scale(1.2);
}


/* Generic Scrolling Carousel Styles */
.scrolling-carousel {
    overflow: hidden;
    position: relative;
    width: 100%;
    -webkit-mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
    mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
}

.scrolling-track {
    display: flex;
    animation-play-state: running;
}

.scrolling-carousel:hover .scrolling-track {
    animation-play-state: paused;
}

/* Partners Carousel Specifics */
#partners-track {
    width: calc(250px * 12); 
    animation: scroll-logos 40s linear infinite;
}

#partners .scrolling-carousel img {
    height: 75px;
    width: auto;
    margin: 0 40px;
    filter: grayscale(1) opacity(0.7);
    transition: filter 0.3s ease;
}

#partners .scrolling-carousel img:hover {
    filter: grayscale(0) opacity(1);
}

/* Certificates Carousel Specifics */
#certificates {
    padding-top: 60px;
}

#certificates-track {
    width: calc(200px * 10);
    animation: scroll-logos 30s linear infinite;
}

#certificates .scrolling-carousel img {
    width: 100%;
    max-width: 100px;
    height: 100px;
    margin: 0 25px;
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

#certificates .scrolling-carousel img:hover {
    filter: grayscale(0%);
}

@keyframes scroll-logos {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* Contact Section */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: stretch;
}

.contact-card {
    display: flex;
    flex-direction: column;
}

.contact-info {
    list-style: none;
    margin: 20px 0;
}

.contact-info li {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    color: var(--primary-color);
}

.contact-info li a {
    color: var(--primary-color);
    font-weight: 500;
}
.contact-info li a:hover {
    color: var(--light-text);
}


.contact-info .material-symbols-outlined {
    color: var(--primary-color);
    margin-right: 15px;
    font-size: 1.5rem;
}

.map-card {
    padding: 0;
    overflow: hidden;
    border-radius: 16px;
    border: 1px solid var(--card-border);
    display: block;
}
.map-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-color);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}


.map-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.map-card:hover img {
    transform: scale(1.1);
}

/* --- 5. Footer --- */
footer {
    background: #060a14;
    padding: 60px 0 20px;
    border-top: 1px solid var(--card-border);
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h4 {
    margin-bottom: 20px;
    color: var(--light-text);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul a {
    color: var(--muted-text);
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border: 1px solid var(--card-border);
    border-radius: 50%;
    margin-right: 10px;
    color: var(--muted-text);
}
.social-links a:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--card-border);
    color: var(--muted-text);
    font-size: 0.9rem;
}

/* --- 6. Animations --- */
/* Removed from global scope for performance */


/* --- Modal & Form Styles --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 15, 30, 0.95);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    position: relative;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: var(--muted-text);
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s ease;
    z-index: 10;
}

.modal-close-btn:hover {
    color: var(--light-text);
}

.modal-content .form-container h3 {
    text-align: center;
    margin-bottom: 10px;
}
.modal-content .form-container p {
    text-align: center;
    margin-bottom: 30px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.form-group {
    position: relative;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group .material-symbols-outlined {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    color: var(--primary-color);
    pointer-events: none;
}

.form-group-textarea .material-symbols-outlined {
    top: 15px;
    transform: none;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 12px 15px 12px 50px; 
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    color: var(--light-text);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

textarea {
    padding: 15px 15px 15px 50px;
    min-height: 120px;
    resize: vertical;
}

select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%234EC0E6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    padding-right: 40px;
}
select:invalid {
  color: var(--muted-text);
}
select option {
    background: var(--dark-bg);
    color: var(--light-text);
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-submit-btn {
    width: 100%;
    text-align: center;
}
.form-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Success Message */
.form-success-message {
    display: none; 
    text-align: center;
    animation: fadeIn 0.5s ease;
    padding: 40px 0;
}

.form-success-message .material-symbols-outlined {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    display: inline-block;
}

.form-success-message h4 {
    color: var(--light-text);
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* Validation Styling */
form.was-validated :invalid {
    border-color: #e74c3c; 
}

form.was-validated :invalid:focus {
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.5); 
}

/* in style.css */

/* --- 7. Utility Components --- */
/* --- Contact Section Work Hours --- */
.contact-info .work-hours {
    align-items: flex-start; /* Align icon to the top */
    padding-top: 5px;
}

.status-dot {
    flex-shrink: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 15px;
    position: relative;
    top: 6px; /* Align with first line of text */
}

.status-dot::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    animation-duration: 1.5s;
    animation-iteration-count: infinite;
}

/* Open Status (Green) */
.status-dot.is-open {
    background-color: #2ECC71;
}
.status-dot.is-open::before {
    animation-name: pulse-green;
}

/* Closed Status (Red) */
.status-dot.is-closed {
    background-color: #e74c3c;
}
.status-dot.is-closed::before {
    animation-name: pulse-red;
}


.work-hours-text {
    display: flex;
    flex-direction: column;
    color: var(--muted-text);
    font-weight: 500;
}

.work-hours-text strong {
    color: var(--primary-color);
    margin-bottom: 5px;
}

@keyframes pulse-green {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.7);
    }
    100% {
        transform: scale(1.5);
        box-shadow: 0 0 0 10px rgba(46, 204, 113, 0);
    }
}

@keyframes pulse-red {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.7);
    }
    100% {
        transform: scale(1.5);
        box-shadow: 0 0 0 10px rgba(231, 76, 60, 0);
    }
}
/* --- Loader Overlay Styles --- */
#loader-overlay {
    position: fixed;
    inset: 0; /* A shorthand for top, right, bottom, left = 0 */
    background-color: var(--dark-bg); /* Uses your theme's background color */
    z-index: 9999; /* Ensures it's on top of everything */
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease-in-out;
    pointer-events: auto; /* It can be interacted with initially */
}

#loader-overlay.loader-hidden {
    opacity: 0;
    pointer-events: none; /* Allows clicks to pass through after it fades out */
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 4px solid var(--card-border);
    border-top-color: var(--primary-color);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}


/* --- 7. Utility Components --- */

.jump-to-top-btn {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 44px;
    height: 44px;
    background-color: var(--card-bg-solid-mobile);
    border: 1px solid var(--card-border);
    color: var(--light-text);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 998; /* Just below header and modal */
    transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.jump-to-top-btn.is-visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.jump-to-top-btn:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.jump-to-top-btn .material-symbols-outlined {
    font-variation-settings: 'wght' 400;
}

@media(min-width: 993px) {
    .jump-to-top-btn {
        background-color: var(--card-bg);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
}

/* --- START: Mobile Services Grid & Popup Styles --- */

/* Grid layout for mobile services */
.services-grid-mobile {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Individual mobile service card */
.service-card-mobile {
    text-align: center;
    padding: 30px 20px;
    cursor: pointer;
}

.service-card-mobile h3 {
    margin-bottom: 0;
    font-size: 1.1rem;
}

.service-card-mobile:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}


/* Popup Overlay - the dark background */
.service-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 15, 30, 0.85);
    z-index: 2500; /* Higher than header */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.service-popup-overlay.is-visible {
    opacity: 1;
    pointer-events: all;
}

/* Popup Content - the card itself */
.service-popup-content {
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 0; /* Remove default card padding */
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.service-popup-overlay.is-visible .service-popup-content {
    transform: scale(1);
}

/* Close button for the popup */
.service-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.3);
    border: none;
    color: var(--light-text);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s ease;
    z-index: 10;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-popup-close:hover {
    color: var(--primary-color);
}

/* Image container */
.service-popup-image-container {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.service-popup-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Text content area */
.service-popup-text {
    padding: 30px;
}

.service-popup-text h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.service-popup-text p {
    color: var(--light-text);
    margin-bottom: 0;
    font-size: 1rem;
}

.service-popup-contact-btn {
    display: inline-block;
    margin-top: 25px;
}

/* --- END: Mobile Services Grid & Popup Styles --- */



/* --- 8. Responsiveness --- */

.mobile-only {
    display: block;
}
.desktop-only {
    display: none;
}
@media (min-width: 993px) {
    .mobile-only {
        display: none;
    }
    .desktop-only {
        display: block;
    }
}


@media (max-width: 992px) {
    :root { --section-padding: 80px; }
    h1 { font-size: 3rem; }
    h2 { font-size: 2rem; }

    .three-columns, .industry-selector-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .two-columns {
        grid-template-columns: 1fr;
    }
        
    .contact-layout {
        grid-template-columns: 1fr;
    }
    
    .certificate-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-top {
        grid-template-columns: 1fr 1fr;
    }

    .product-selector-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .product-display-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    :root { --section-padding: 60px; }
    h1 { font-size: 2.5rem; }

    .main-nav {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: var(--dark-bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 999;
    }

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

    .main-nav ul {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .main-nav a {
        font-size: 1.5rem;
    }
    
    .mobile-only-procena {
        display: block;
        margin-top: 20px;
    }
    .mobile-only-procena a {
        font-size: 1.2rem;
        font-weight: 600;
        color: var(--primary-color);
        border: 2px solid var(--primary-color);
        padding: 10px 20px;
        border-radius: 8px;
    }
    .mobile-only-procena a:hover {
        background: var(--primary-color);
        color: #fff;
    }
     .mobile-only-procena a::after {
        display: none;
    }

    .header-controls {
        display: none;
    }
    
    .mobile-controls {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-controls .lang-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    .hamburger {
        display: block;
        z-index: 1001;
    }
    
    .three-columns, .two-columns {
        grid-template-columns: 1fr;
    }
    
    .industry-selector-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-card {
        flex-direction: column;
        gap: 30px;
    }

    .stat-item h3 {
        font-size: 2.5rem;
    }

    .footer-col .logo {
    margin: 0 auto 15px;
    }
        
    .footer-top {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .zasto-mi-card .icon {
        font-size: 7rem;
        right: -10px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }

    .slider-btn.prev-btn {
        left: 10px;
    }
    .slider-btn.next-btn {
        right: 10px;
    }
    .scroll-down-arrow {
    display: none;
}
}

/* --- 9. Light Theme & Theme Toggle --- */

/* Light theme color variable overrides */
body.light-theme {
    --dark-bg: #F4F7FC;
    --primary-color: #2ECC71;
    --accent-color: #2ECC71; /* New Accent Color for Light Theme */
    --light-text: #1A202C;
    --muted-text: #5A647B;
    --card-bg: rgba(255, 255, 255, 0.6);
    --card-bg-solid-mobile: #FFFFFF;
    --card-border: rgba(0, 0, 0, 0.1);
    --primary-glow: rgba(59, 130, 246, 0.4);
}

/* Specific overrides for light theme */
body.light-theme .aurora-shape-1,
body.light-theme .aurora-shape-2 {
    opacity: 0.3;
}

/* Make Hero text visible on light theme */
body.light-theme .hero h1,
body.light-theme .hero p,
body.light-theme .scroll-down-arrow {
    color: #EAEBF0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.7);
}

/* Light theme no longer needs a special logo rule */

body.light-theme header:not(.scrolled) .main-nav a:hover,
body.light-theme header:not(.scrolled) .lang-switcher a:hover,
body.light-theme header:not(.scrolled) .hamburger,
body.light-theme header:not(.scrolled) .mobile-controls .theme-toggle-btn {
    color: #EAEBF0;
}

body.light-theme header:not(.scrolled) .main-nav a,
body.light-theme header:not(.scrolled) .lang-switcher a {
    color: #a1a9c0;
}

body.light-theme header:not(.scrolled) .mobile-controls .lang-btn {
    color: #a1a9c0;
    border-color: rgba(255, 255, 255, 0.2);
}

body.light-theme header.scrolled {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

body.light-theme #industries-section::after {
    background: rgba(244, 247, 252, 0.6);
}

body.light-theme .zasto-mi-card .icon {
    opacity: 0.05;
}

body.light-theme .industry-selector-card.is-active {
    color: #FFFFFF;
}

body.light-theme .industry-selector-card.is-active .material-symbols-outlined,
body.light-theme .industry-selector-card.is-active h4 {
    color: #FFFFFF;
}

body.light-theme footer {
    background: #EAEBF0;
}

body.light-theme .social-links a:hover {
    color: #fff;
}

/* Theme Toggle Button Styles */
.theme-toggle-btn {
    background: none;
    border: none;
    color: var(--muted-text);
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease, background-color 0.3s ease;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.theme-toggle-btn:hover {
    color: var(--light-text);
    background-color: rgba(128, 128, 128, 0.1);
}

.theme-toggle-btn .material-symbols-outlined {
    font-size: 1.5rem;
}
/* Make form placeholder text darker and more visible on light theme */
body.light-theme .form-group input::placeholder,
body.light-theme .form-group textarea::placeholder {
    color: var(--muted-text);
    opacity: 1; /* Override browser defaults that might make it transparent */
}

/* Ensure the initial/placeholder text in the select dropdown is also visible */
body.light-theme .form-group select:invalid {
    color: var(--muted-text);
}

/* Ensure the typed text color is the main dark text color */
body.light-theme .form-group input,
body.light-theme .form-group select,
body.light-theme .form-group textarea {
    color: var(--light-text);
    background-color: rgba(0, 0, 0, 0.04); /* Slightly off-white background for fields */
}
/* --- 10. Blog Page Styles --- */

.blog-hero {
    padding-top: 150px;
    padding-bottom: 60px;
    text-align: center;
}
.blog-hero h1 {
    font-size: 3.5rem;
}
.blog-hero p {
    font-size: 1.2rem;
    color: var(--muted-text);
    max-width: 600px;
    margin: 15px auto 0;
}
body.light-theme .blog-hero p {
    color: var(--muted-text);
}

.blog-main {
    padding-top: 0;
    padding-bottom: 80px;
}

.blog-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

@media(min-width: 993px) {
    .blog-layout {
        grid-template-columns: 1fr 2.5fr; /* Sidebar on left for desktop */
        gap: 50px;
    }
    .blog-sidebar {
        grid-column: 1 / 2;
        grid-row: 1 / 2;
    }
    .blog-posts {
        grid-column: 2 / 3;
    }
}

.blog-posts {
    display: grid;
    gap: 30px;
    align-content: start;
}

.blog-post {
    padding: 0;
    display: flex;
    flex-direction: column;
}

.post-header {
    padding: 20px 30px;
    border-bottom: 1px solid var(--card-border);
}

.post-category {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--primary-color);
}

.post-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.post-content h3 {
    font-size: 1.6rem;
    margin-bottom: 15px;
    color: var(--light-text);
    transition: color 0.3s ease;
}

.post-content a:hover h3 {
    color: var(--primary-color);
}

.post-content p {
    margin-bottom: 25px;
    flex-grow: 1;
}

.post-meta {
    font-size: 0.9rem;
    color: var(--muted-text);
    margin-top: auto;
}

/* Sidebar and Dropdown Styles */
.blog-sidebar {
    display: grid;
    gap: 20px;
    grid-template-columns: 1fr;
}

@media(min-width: 550px) {
    .blog-sidebar {
        grid-template-columns: 1fr 1fr;
    }
}

@media(min-width: 993px) {
    .blog-sidebar {
        position: sticky;
        top: 120px;
        align-self: start;
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.sidebar-widget {
    background: var(--card-bg-solid-mobile);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
}

@media(min-width: 993px) {
    .sidebar-widget {
        background: var(--card-bg);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        padding: 30px;
    }
}

.sidebar-widget h3 {
    font-size: 1.3rem;
    margin: 0;
}

.search-bar {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}
.search-bar input {
    width: 100%;
    padding: 12px 45px 12px 15px;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    color: var(--light-text);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.search-bar input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow);
}
.search-bar .material-symbols-outlined {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    color: var(--muted-text);
}

/* Category Dropdown */
.category-dropdown summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    list-style: none; /* Hide default arrow */
}
.category-dropdown summary::-webkit-details-marker {
    display: none; /* Hide default arrow for Safari */
}
.category-dropdown summary .material-symbols-outlined {
    transition: transform 0.3s ease;
}
.category-dropdown[open] > summary .material-symbols-outlined {
    transform: rotate(180deg);
}
.category-dropdown .category-list {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--card-border);
    max-height: 250px;
    overflow-y: auto;
}

.category-list {
    list-style: none;
}
.category-list li {
    margin-bottom: 5px;
}
.category-list button {
    background: none;
    border: none;
    color: var(--muted-text);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    padding: 8px 0;
    width: 100%;
    text-align: left;
    transition: color 0.3s ease;
}

.category-list button:hover {
    color: var(--light-text);
}

.category-list button.active {
    color: var(--primary-color);
    font-weight: 600;
}

.no-results-message {
    text-align: center;
    padding: 40px 0;
    font-size: 1.2rem;
}

/* --- 11. Blog Page Specific Header Colors --- */

/* REMOVED: Specific blog logo override */

/* Make mobile blog controls black from the start on light theme */
body.light-theme.blog-page header:not(.scrolled) .mobile-controls .theme-toggle-btn,
body.light-theme.blog-page header:not(.scrolled) .mobile-controls .hamburger {
    color: var(--light-text);
}

body.light-theme.blog-page header:not(.scrolled) .mobile-controls .lang-btn {
    color: var(--muted-text);
    border-color: var(--card-border);
}

/* --- 12. Single Blog Post Styles --- */
.blog-post-full {
    padding-top: 150px;
    padding-bottom: 80px;
}

.post-full-header {
    text-align: center;
    margin-bottom: 50px;
    border-bottom: 1px solid var(--card-border);
    padding-bottom: 40px;
}

.post-full-header .post-category {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    color: var(--primary-color);
    display: block;
    margin-bottom: 15px;
}

.post-full-header h1 {
    font-size: 2.8rem;
    margin-bottom: 20px;
}

.back-to-blog-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 30px;
    color: var(--muted-text);
    font-weight: 500;
}

.back-to-blog-link:hover {
    color: var(--primary-color);
}

.post-full-content {
    max-width: 750px;
    margin: 0 auto;
}

.post-full-content h2 {
    text-align: left;
    font-size: 2rem;
    margin-top: 40px;
    margin-bottom: 20px;
}

.post-full-content p, .post-full-content li {
    color: var(--muted-text);
    font-size: 1.1rem;
    line-height: 1.7;
}

.post-full-content ul {
    list-style-position: outside;
    padding-left: 20px;
    margin-bottom: 1rem;
}

.post-full-content li {
    margin-bottom: 10px;
}

@media (max-width: 768px) {
    .post-full-header h1 {
        font-size: 2.2rem;
    }
}