/* =========================================================
   ARTECH – wspólne style całej strony
   (reset, pasek górny, nagłówek z menu, menu boczne "Narzędzia",
   okienko "Zapytaj o ofertę"). Style konkretnej podstrony
   zostają w jej własnym bloku <style> i nadpisują te tutaj.
   ========================================================= */

/* Paleta firmowa (zieleń i granat z ulotki ARTECH).
   Zmiana koloru w tym miejscu zmienia go na całej stronie. */
:root {
    --brand-green: #6ea84f;        /* akcenty, przyciski, ikony */
    --brand-green-dark: #568a3b;   /* najechanie na przycisk */
    --brand-green-light: #eef5e9;  /* jasne tło ikon i kafelków */
    --brand-navy: #1e2838;         /* ciemne sekcje, stopka, pasek górny */
    --brand-navy-dark: #151e2b;
    --brand-navy-line: #2e3b50;    /* linie i elementy na granatowym tle */
}

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

/* Animacje wjeżdżające z boku (AOS fade-left/right) nie mogą poszerzać strony
   i powodować przewijania na boki, zwłaszcza na telefonach. */
html {
    overflow-x: hidden;
}

section:has([data-aos^="fade-left"], [data-aos^="fade-right"], [data-aos^="slide-"]) {
    overflow-x: clip;
}

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    color: #333;
    line-height: 1.6;
    background: #fff;
    scroll-behavior: smooth;
}

/* ---------- Pasek górny ---------- */
.top-bar {
    background: var(--brand-navy);
    color: #c9d1dc;
    padding: 10px 0;
    font-size: 13px;
}

.top-bar .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar a {
    color: inherit;
    text-decoration: none;
}

.top-bar a:hover {
    color: var(--brand-green);
}

/* ---------- Nagłówek ---------- */
.header {
    background: white;
    padding: 15px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.logo {
    font-size: 32px;
    font-weight: 800;
    color: #444;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    border-left: 5px solid var(--brand-green);
    padding-left: 15px;
    line-height: 0.8;
    display: inline-block;
}

.logo:hover {
    text-decoration: none;
    color: var(--brand-green);
}

/* ---------- Menu główne ---------- */
.nav {
    display: flex;
    gap: 25px;
    list-style: none;
}

.nav a {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    transition: color 0.3s;
}

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

.has-dropdown {
    position: relative;
}

.has-dropdown > a i {
    font-size: 10px;
    margin-left: 5px;
}

.dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    min-width: 250px;
    flex-direction: column;
    z-index: 1000;
    border-top: 3px solid var(--brand-green);
}

.has-dropdown:hover .dropdown {
    display: flex;
}

.nav .dropdown a {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: block;
    text-transform: none;
    font-weight: 500;
    color: #333;
    transition: background 0.3s, padding-left 0.3s;
}

.nav .dropdown a:hover {
    background: #f9f9f9;
    padding-left: 25px;
}

.mobile-only-cta {
    display: none;
}

.mobile-only-cta a {
    color: var(--brand-green);
}

/* ---------- Przycisk CTA ---------- */
.cta-button {
    background: var(--brand-green);
    color: white;
    padding: 10px 25px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
    text-transform: uppercase;
    transition: background 0.3s, transform 0.2s;
    display: inline-block;
    cursor: pointer;
    border: none;
}

.cta-button:hover {
    background: var(--brand-green-dark);
    transform: translateY(-2px);
    color: white;
}

/* ---------- Menu na telefonie i tablecie (poniżej 992 px menu nie mieści się w jednej linii) ---------- */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    color: #333;
    cursor: pointer;
    z-index: 1001;
    margin-left: auto;
}

@media (max-width: 992px) {
    .mobile-menu-btn {
        display: block;
    }

    .nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
        padding: 20px 0;
        text-align: center;
        gap: 15px;
    }

    .nav.active {
        display: flex;
    }

    .header .container {
        position: relative;
    }

    .header .cta-button {
        display: none;
    }

    .mobile-only-cta {
        display: block;
    }

    .dropdown {
        position: static;
        box-shadow: none;
        border-top: none;
        background: #f9f9f9;
        width: 100%;
    }
}

/* ---------- Menu boczne "Narzędzia" ---------- */
.side-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100vh;
    background: white;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    z-index: 990;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    padding-top: 100px;
    overflow-y: auto;
}

.side-menu.active {
    transform: translateX(0);
}

.side-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 980;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
}

.side-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.tile-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 0 20px 20px;
    margin-top: 50px;
}

.menu-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
    border: 2px dashed var(--brand-green);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    text-decoration: none;
    color: #333;
    width: 100%;
    transition: all 0.3s;
}

.menu-tile:hover {
    background: var(--brand-green-light);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(110, 168, 79, 0.2);
    border-style: solid;
}

.menu-tile.alt {
    border-color: #333;
}

.menu-tile.alt .tile-icon {
    color: #333;
}

.tile-icon {
    font-size: 32px;
    color: var(--brand-green);
    margin-bottom: 10px;
}

.tile-title {
    font-size: 16px;
    font-weight: 800;
    color: #333;
    display: block;
    margin-bottom: 5px;
    text-transform: uppercase;
}

.tile-desc {
    font-size: 11px;
    color: #666;
    font-weight: normal;
    text-transform: none;
    line-height: 1.4;
}

/* ---------- Okienko "Zapytaj o ofertę" ---------- */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 2000;
    display: flex;
    justify-content: flex-end;
    align-items: stretch;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.offer-modal {
    background: white;
    padding: 40px;
    width: 100%;
    max-width: 500px;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.2);
    position: relative;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-left: 5px solid var(--brand-green);
    overflow-y: auto;
    height: 100%;
}

.modal-backdrop.active .offer-modal {
    transform: translateX(0);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #333;
}

.modal-title {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #333;
    text-transform: uppercase;
}

.modal-subtitle {
    font-size: 14px;
    color: #666;
    margin-bottom: 25px;
}

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

.form-label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #444;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--brand-green);
}

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

.submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--brand-green);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    text-transform: uppercase;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s;
}

.submit-btn:hover {
    background: var(--brand-green-dark);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: wait;
}

/* ---------- Baner zgód na cookies (js/cookies.js) ---------- */
html.cc-lock,
html.cc-lock body {
    overflow: hidden;
}

.cc-root {
    position: fixed;
    inset: 0;
    z-index: 5000; /* nad wszystkim, także nad okienkiem promocyjnym */
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.cc-root.cc-open {
    display: flex;
}

.cc-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(21, 30, 43, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: ccFade 0.3s ease;
}

.cc-dialog {
    position: relative;
    width: 100%;
    max-width: 620px;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    background: white;
    border-radius: 10px;
    border-top: 5px solid var(--brand-green);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
    padding: 36px 36px 30px;
    color: #333;
    animation: ccRise 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
}

@keyframes ccFade { from { opacity: 0; } }
@keyframes ccRise { from { opacity: 0; transform: translateY(24px); } }

.cc-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 26px;
    line-height: 1;
    color: #999;
    cursor: pointer;
}

.cc-close:hover {
    color: var(--brand-navy);
}

.cc-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--brand-green-light);
    color: var(--brand-green);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    margin-bottom: 18px;
}

.cc-dialog h2 {
    font-size: 22px;
    font-weight: 800;
    color: var(--brand-navy);
    margin-bottom: 12px;
}

.cc-dialog p {
    font-size: 14px;
    line-height: 1.65;
    color: #555;
}

.cc-dialog a {
    color: var(--brand-green-dark);
    text-decoration: underline;
}

.cc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.cc-btn {
    flex: 1 1 auto;
    padding: 13px 20px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.cc-btn i {
    margin-right: 6px;
}

.cc-btn-primary {
    background: var(--brand-green);
    border: 2px solid var(--brand-green);
    color: white;
}

.cc-btn-primary:hover {
    background: var(--brand-green-dark);
    border-color: var(--brand-green-dark);
}

/* "Tylko niezbędne" – równie widoczne jak akceptacja (wymóg przepisów) */
.cc-btn-outline {
    background: white;
    border: 2px solid var(--brand-navy);
    color: var(--brand-navy);
}

.cc-btn-outline:hover {
    background: var(--brand-navy);
    color: white;
}

.cc-btn-ghost {
    background: #f1f3f6;
    border: 2px solid #f1f3f6;
    color: var(--brand-navy);
}

.cc-btn-ghost:hover {
    border-color: #d5dae1;
}

.cc-btn:focus-visible,
.cc-cat-toggle:focus-visible,
.cc-switch input:focus-visible + .cc-slider {
    outline: 3px solid rgba(110, 168, 79, 0.45);
    outline-offset: 2px;
}

.cc-list {
    margin-top: 18px;
    border: 1px solid #e5e8ec;
    border-radius: 6px;
}

.cc-cat + .cc-cat {
    border-top: 1px solid #e5e8ec;
}

.cc-cat-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}

.cc-cat-toggle {
    background: none;
    border: none;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    color: var(--brand-navy);
    cursor: pointer;
    text-align: left;
    padding: 0;
}

.cc-cat-toggle i {
    width: 14px;
    margin-right: 6px;
    font-size: 12px;
    color: #999;
    transition: transform 0.2s;
}

.cc-cat-toggle[aria-expanded="true"] i {
    transform: rotate(90deg);
}

.cc-cat-desc {
    padding: 0 16px 14px 36px;
}

.cc-cat-desc p {
    font-size: 13px;
}

.cc-cookies {
    margin-top: 6px;
    color: #888 !important;
}

.cc-always {
    font-size: 12px;
    font-weight: 700;
    color: var(--brand-green-dark);
    white-space: nowrap;
}

.cc-switch {
    position: relative;
    display: inline-block;
    width: 46px;
    height: 26px;
    flex-shrink: 0;
    cursor: pointer;
}

.cc-switch input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    cursor: pointer;
}

.cc-slider {
    position: absolute;
    inset: 0;
    background: #cfd5dd;
    border-radius: 26px;
    transition: background 0.2s;
    pointer-events: none;
}

.cc-slider::before {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    left: 3px;
    top: 3px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: transform 0.2s;
}

.cc-switch input:checked + .cc-slider {
    background: var(--brand-green);
}

.cc-switch input:checked + .cc-slider::before {
    transform: translateX(20px);
}

.cc-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

@media (max-width: 600px) {
    .cc-dialog { padding: 28px 20px 22px; }
    .cc-actions { flex-direction: column; }
    .cc-dialog h2 { font-size: 19px; }
}

/* Miejsce na treść zewnętrzną przed zgodą (np. mapa Google) */
.consent-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px;
    text-align: center;
    background: #eef1f5;
    color: #555;
    font-size: 14px;
}

.consent-placeholder i {
    font-size: 36px;
    color: var(--brand-green);
}

.consent-placeholder .cta-button {
    margin-top: 4px;
}

.cookie-settings-link {
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

/* Pole-pułapka na boty – niewidoczne dla ludzi i czytników ekranu */
.hp-field {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.form-consent {
    margin-top: 12px;
    font-size: 12px;
    line-height: 1.5;
    color: #888;
}

.form-consent a {
    color: inherit;
    text-decoration: underline;
}

.form-status:empty {
    display: none;
}

.form-status {
    margin-bottom: 15px;
    padding: 12px 14px;
    border-radius: 4px;
    font-size: 14px;
    background: #fdecec;
    border: 1px solid #f5c2c2;
    color: #b42318;
}

.form-success {
    text-align: center;
    padding: 30px 10px;
}

.form-success i {
    font-size: 48px;
    color: var(--brand-green);
    margin-bottom: 15px;
}

.form-success h4 {
    font-size: 20px;
    color: var(--brand-navy);
    margin-bottom: 8px;
}

.form-success p {
    color: #666;
}
