/* ==========================================================================
   WEYWOT MASTER STYLES - MATRIX EDITION v21.0 (SAFE RESTORE - VERIFIED)
   - Fundament Systemu (Layout, Presety, Header, Footer).
   - Zawiera naprawę tła podstron (tzw. "otoczka").
   - Oczyszczony z modułów (HUD, Komentarze, Profile są w osobnych plikach).
   ========================================================================== */

:root {
    /* Ustawienia Layoutu */
    --w-container: 1200px;
    --w-radius: 4px;
    --w-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.2);

    /* Domyślne Fonty */
    --w-font-head: 'Helvetica Neue', Arial, sans-serif;
    --w-font-body: 'Helvetica Neue', Arial, sans-serif;
    --w-size-body: 16px;
}

/* ==========================================================================
   1. MATRIX PRESETS (10 STYLÓW)
   ========================================================================== */

/* 1. LIGHT */
body.weywot-preset-light {
    --w-col-bg: #ffffff;
    --w-col-panel: #f8f9fa;       /* Jasne karty */
    --w-col-header: #ffffff;
    --w-col-footer: #f1f1f1;
    --w-col-text: #333333;
    --w-col-h1: #111111;
    --w-col-link: #0073aa;
    --w-col-accent: #0073aa;
    --w-col-border: #e0e0e0;
    --w-col-footer-text: #555555;
    --w-col-meta: #777777;        /* Kolor daty i kategorii */
}

/* 2. DARK */
body.weywot-preset-dark {
    --w-col-bg: #121212;
    --w-col-panel: #1e1e1e;       /* Ciemne karty */
    --w-col-header: #1a1a1a;
    --w-col-footer: #000000;
    --w-col-text: #e0e0e0;
    --w-col-h1: #ffffff;
    --w-col-link: #4da6ff;
    --w-col-accent: #ffffff;
    --w-col-border: #333333;
    --w-col-footer-text: #888888;
    --w-col-meta: #aaaaaa;
}

/* 3. WEYWOT (PIOTR BOCIAN DE LUX) */
body.weywot-preset-weywot {
    --w-col-bg: #353535;      
    --w-col-panel: #3d3d3d;   
    --w-col-header: #353535;  
    --w-col-footer: #2b2b2b;  
    --w-col-text: #f2f2f2;    
    --w-col-h1: #ffffff;      
    --w-col-link: #81d742;    
    --w-col-accent: #81d742;  
    --w-col-border: #606060;  
    --w-col-footer-text: #cccccc;
    --w-col-meta: #bbbbbb;
    --w-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

/* 4. LUXURY GOLD */
body.weywot-preset-luxury {
    --w-col-bg: #0a0a0a;
    --w-col-panel: #141414;
    --w-col-header: #111111;
    --w-col-footer: #000000;
    --w-col-text: #d4af37;
    --w-col-h1: #f1dca7;
    --w-col-link: #ffffff;
    --w-col-accent: #d4af37;
    --w-col-border: #443c18;
    --w-col-footer-text: #a88a28;
    --w-col-meta: #a88a28;
}

/* 5. PAPER MINIMAL */
body.weywot-preset-paper {
    --w-col-bg: #fdfbf7;
    --w-col-panel: #ffffff;
    --w-col-header: #fdfbf7;
    --w-col-footer: #f4f1ea;
    --w-col-text: #4a4a4a;
    --w-col-h1: #2c2c2c;
    --w-col-link: #2c2c2c;
    --w-col-accent: #000000;
    --w-col-border: #dcdcdc;
    --w-col-footer-text: #666666;
    --w-col-meta: #888888;
}

/* 6. DEEP OCEAN */
body.weywot-preset-ocean {
    --w-col-bg: #001f3f;
    --w-col-panel: #002852;
    --w-col-header: #001b36;
    --w-col-footer: #001226;
    --w-col-text: #7fdbff;
    --w-col-h1: #ffffff;
    --w-col-link: #39cccc;
    --w-col-accent: #0074d9;
    --w-col-border: #004080;
    --w-col-footer-text: #5ea8cc;
    --w-col-meta: #5ea8cc;
}

/* 7. FOREST NATURE */
body.weywot-preset-forest {
    --w-col-bg: #1a2f1a;
    --w-col-panel: #233d23;
    --w-col-header: #152615;
    --w-col-footer: #0e1a0e;
    --w-col-text: #dcdcdc;
    --w-col-h1: #8fbc8f;
    --w-col-link: #98fb98;
    --w-col-accent: #228b22;
    --w-col-border: #2f4f2f;
    --w-col-footer-text: #8aa38a;
    --w-col-meta: #8aa38a;
}

/* 8. SUNSET VIBES */
body.weywot-preset-sunset {
    --w-col-bg: #2d1b2e;
    --w-col-panel: #3d253e;
    --w-col-header: #261626;
    --w-col-footer: #1a0f1a;
    --w-col-text: #ffccaa;
    --w-col-h1: #ff9966;
    --w-col-link: #ff9966;
    --w-col-accent: #ff5e62;
    --w-col-border: #5c3a5e;
    --w-col-footer-text: #cc9988;
    --w-col-meta: #cc9988;
}

/* 9. MIDNIGHT PURPLE */
body.weywot-preset-midnight {
    --w-col-bg: #1a0b2e;
    --w-col-panel: #261042;
    --w-col-header: #140824;
    --w-col-footer: #0d0517;
    --w-col-text: #e0d4fc;
    --w-col-h1: #9d70d6;
    --w-col-link: #a18cd1;
    --w-col-accent: #764ba2;
    --w-col-border: #432c7a;
    --w-col-footer-text: #9080b0;
    --w-col-meta: #9080b0;
}

/* 10. MONOCHROME */
body.weywot-preset-monochrome {
    --w-col-bg: #ffffff;
    --w-col-panel: #ffffff;
    --w-col-header: #ffffff;
    --w-col-footer: #000000;
    --w-col-text: #000000;
    --w-col-h1: #000000;
    --w-col-link: #000000;
    --w-col-accent: #000000;
    --w-col-border: #000000;
    --w-col-footer-text: #999999;
    --w-col-meta: #555555;
}


/* ==========================================================================
   GLOBAL STRUCTURE
   ========================================================================== */

body {
    background-color: var(--w-col-bg);
    color: var(--w-col-text);
    font-family: var(--w-font-body);
    font-size: var(--w-size-body);
    line-height: 1.6;
    margin: 0;
    transition: background 0.3s ease, color 0.3s ease;
}

a {
    color: var(--w-col-link);
    text-decoration: none;
    font-weight: 500;
    transition: 0.2s;
}

a:hover {
    filter: brightness(1.2);
    color: var(--w-col-accent);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--w-font-head);
    color: var(--w-col-h1);
    font-weight: 700;
    margin: 0 0 20px;
    letter-spacing: 0.5px;
}

h2, h3, h4 { color: var(--w-col-h1); opacity: 0.9; }

/* Kontener Główny */
.weywot-container {
    max-width: var(--w-container);
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================================================
   HEADER & BRANDING
   ========================================================================== */

.site-header {
    background-color: var(--w-col-header);
    border-bottom: 1px solid var(--w-col-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: background 0.3s;
}

.site-header .weywot-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
}

/* --- BRANDING --- */
.site-branding {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.custom-logo-link img {
    height: auto;
    max-height: 80px;
    width: auto;
    transition: transform 0.3s;
}

.custom-logo-link:hover img { transform: scale(1.05); }

.site-title {
    margin: 0;
    line-height: 1;
    font-size: 2rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.site-title a {
    color: var(--w-col-h1);
    text-decoration: none;
}

.site-description {
    margin: 5px 0 0 0;
    font-size: 0.85rem;
    color: var(--w-col-text);
    opacity: 0.7;
    letter-spacing: 1px;
    font-weight: 300;
    text-transform: uppercase;
    border-left: 2px solid var(--w-col-accent);
    padding-left: 10px;
}

/* --- NAWIGACJA (GŁÓWNY POZIOM) --- */
.main-navigation {
    display: flex;
    align-items: center;
    gap: 20px;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 5px;
}

/* --- WAŻNE: To naprawia pozycjonowanie Dropdownów --- */
.main-navigation ul li {
    position: relative; /* DZIĘKI TEMU SUB-MENU WIE GDZIE JEST */
}

.main-navigation ul li a {
    position: relative;
    padding: 10px 15px;
    color: var(--w-col-h1);
    font-family: var(--w-font-head);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: 0.3s;
    display: block; /* Poprawa klikalności */
}

.main-navigation ul > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--w-col-accent);
    transition: width 0.3s ease, left 0.3s ease;
}

.main-navigation ul > li:hover > a::after,
.main-navigation ul > li.current-menu-item > a::after {
    width: 100%;
    left: 0;
}

.main-navigation ul li a:hover,
.main-navigation ul li.current-menu-item a {
    color: var(--w-col-accent);
}

/* --- KOSZYK --- */
.weywot-cart-menu {
    position: relative;
    margin-left: 15px;
    border-left: 1px solid var(--w-col-border);
    padding-left: 15px;
}

.weywot-cart-menu a {
    color: var(--w-col-h1);
    font-size: 24px;
    display: flex;
    align-items: center;
}

.weywot-cart-count {
    position: absolute;
    top: -5px;
    right: -8px;
    background: var(--w-col-accent);
    color: var(--w-col-bg);
    font-size: 10px;
    font-weight: bold;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 5px var(--w-col-accent);
}

/* FIX: Jeśli tło licznika jest Jasnozielone (#81d742), to tekst musi być CZARNY */
body.weywot-preset-weywot .weywot-cart-count { color: #000 !important; }


.menu-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--w-col-border);
    color: var(--w-col-accent);
    font-size: 24px;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 4px;
}

/* ==========================================================================
   FRONT PAGE & CONTENT
   ========================================================================== */
.weywot-home-content {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
    padding-top: 0 !important; /* FIX: Usuwa duży odstęp na głównej */
}

.weywot-card {
    background-color: var(--w-col-panel);
    border: 1px solid var(--w-col-border);
    border-radius: var(--w-radius);
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--w-shadow);
    transition: transform 0.3s, border-color 0.3s;
}

.weywot-card:hover {
    transform: translateY(-5px);
    border-color: var(--w-col-accent);
}

/* BUTTONS */
.btn-weywot,
button,
input[type="submit"] {
    display: inline-block;
    padding: 12px 30px;
    border: 1px solid var(--w-col-accent);
    color: var(--w-col-accent) !important;
    text-transform: uppercase;
    font-family: var(--w-font-head);
    font-weight: bold;
    font-size: 13px;
    text-align: center;
    border-radius: var(--w-radius);
    cursor: pointer;
    background: transparent;
    transition: 0.3s;
}

.btn-weywot:hover,
button:hover,
input[type="submit"]:hover {
    background-color: var(--w-col-accent);
    color: var(--w-col-bg) !important;
    box-shadow: 0 0 15px var(--w-col-accent);
}

/* FIX: Przycisk po najechaniu ma czarny tekst (bo tło jest zielone) */
body.weywot-preset-weywot .btn-weywot:hover { color: #000 !important; }


.weywot-seo-panel { padding: 60px 0; width: 100%; }
.seo-panel-title {
    text-transform: uppercase;
    font-size: 2rem;
    border-left: 5px solid;
    padding-left: 20px;
}

/* ==========================================================================
   FOOTER ULTIMATE (3-COL ASYMMETRIC GRID)
   ========================================================================== */
.site-footer {
    background-color: var(--w-col-footer);
    color: var(--w-col-footer-text);
    padding: 70px 0 30px;
    border-top: 3px solid var(--w-col-accent);
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.8fr 1.2fr 0.8fr;
    gap: 40px;
    margin-bottom: 50px;
}

.footer-heading {
    color: var(--w-col-accent);
    font-family: var(--w-font-head);
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: inline-block;
    padding-bottom: 10px;
    margin-bottom: 25px;
    font-size: 1.1rem;
    letter-spacing: 1px;
}

/* KOLUMNA 1: SZEROKIE DANE */
.company-owner { margin-bottom: 15px; opacity: 0.8; }
.footer-legal-data {
    margin-bottom: 25px;
    font-size: 0.9rem;
    color: var(--w-col-footer-text);
    line-height: 1.8;
    opacity: 0.9;
    border-left: 2px solid rgba(255, 255, 255, 0.1);
    padding-left: 15px;
}

.legal-item { display: inline-block; margin-right: 20px; margin-bottom: 5px; }
.legal-item strong { color: var(--w-col-footer-text); opacity: 1; font-weight: 700; }

.footer-bank {
    background: rgba(255, 255, 255, 0.03);
    padding: 20px;
    border-radius: var(--w-radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: inline-block;
    min-width: 300px;
}

.bank-label { display: block; font-size: 0.75rem; text-transform: uppercase; opacity: 0.6; margin-bottom: 5px; }
.bank-number { display: block; font-family: 'Courier New', monospace; font-size: 1.2rem; color: #fff; letter-spacing: 1px; font-weight: bold; }

/* KOLUMNA 2: KONTAKT I MAPA */
.weywot-contact-list { list-style: none; padding: 0; margin: 0; }
.weywot-contact-list li {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    align-items: flex-start;
    color: var(--w-col-footer-text);
    font-size: 0.95rem;
}

.weywot-contact-list li .dashicons { color: var(--w-col-accent); font-size: 20px; margin-top: 3px; }
.weywot-contact-list a { color: var(--w-col-footer-text); transition: 0.3s; }
.weywot-contact-list a:hover { color: var(--w-col-accent); }

/* Mapa (Embed) */
.footer-map-embed iframe {
    width: 100%;
    height: 180px;
    border: 0;
    border-radius: var(--w-radius);
    opacity: 0.8;
    transition: 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-map-embed iframe:hover { opacity: 1; box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3); }

/* KOLUMNA 3: MENU */
.footer-menu-list { list-style: none; padding: 0; margin: 0; }
.footer-menu-list li {
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    padding-bottom: 8px;
}
.footer-menu-list li a { color: var(--w-col-footer-text); font-size: 0.95rem; transition: 0.2s; display: block; }
.footer-menu-list li a:hover { color: var(--w-col-accent); padding-left: 8px; }

/* COPYRIGHT */
.site-info-area {
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    opacity: 0.6;
}
.site-info-area a { color: inherit; text-decoration: underline; }

/* ==========================================================================
   MODUŁ "O MNIE" (COMPACT)
   ========================================================================== */
.weywot-about-wrapper {
    padding: 40px 0;
    overflow: hidden;
    position: relative;
}
.page .entry-content .weywot-about-wrapper { margin-top: -40px; }

.about-flex { display: flex; align-items: center; gap: 60px; margin-bottom: 60px; }
.about-visual { flex: 1; position: relative; }
.about-visual img {
    border-radius: var(--w-radius);
    box-shadow: var(--w-shadow);
    display: block; width: 100%; height: auto;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.about-content { flex: 1; }
.about-sub {
    color: var(--w-col-accent); font-weight: bold; text-transform: uppercase;
    font-size: 0.9rem; letter-spacing: 1px; display: block; margin-bottom: 15px;
}
.about-head { font-size: 2.5rem; margin-bottom: 25px; line-height: 1.2; }
.about-text { opacity: 0.9; font-size: 1.05rem; line-height: 1.8; }

/* STYL 1: CLASSIC */
.weywot-about-wrapper.style-classic .about-visual-deco {
    position: absolute; top: 20px; left: 20px; right: -20px; bottom: -20px;
    border: 2px solid var(--w-col-accent); z-index: -1; border-radius: var(--w-radius); opacity: 0.5;
}
/* STYL 2: MODERN */
.weywot-about-wrapper.style-modern { background: linear-gradient(90deg, rgba(255, 255, 255, 0.02) 50%, transparent 50%); }
.weywot-about-wrapper.style-modern .about-flex { flex-direction: row-reverse; }
.weywot-about-wrapper.style-modern .about-head { border-left: 5px solid var(--w-col-accent); padding-left: 20px; }
/* STYL 3: CREATIVE */
.weywot-about-wrapper.style-creative .about-flex { flex-direction: column; text-align: center; }
.weywot-about-wrapper.style-creative .about-visual { width: 100%; max-width: 800px; margin: 0 auto; }
.weywot-about-wrapper.style-creative .about-visual img { -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 100%); }
.weywot-about-wrapper.style-creative .about-content { margin-top: -60px; position: relative; z-index: 2; }

/* HISTORY */
.weywot-history-wrapper { margin-top: 60px; padding-top: 40px; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.history-main-title { text-align: center; margin-bottom: 40px; text-transform: uppercase; font-size: 1.5rem; letter-spacing: 2px; }

.weywot-history-wrapper.style-timeline .history-items { display: flex; justify-content: space-between; position: relative; }
.weywot-history-wrapper.style-timeline .history-items::before {
    content: ''; position: absolute; top: 15px; left: 0; width: 100%; height: 2px; background: rgba(255, 255, 255, 0.1); z-index: 0;
}
.weywot-history-wrapper.style-timeline .history-item { text-align: center; flex: 1; position: relative; z-index: 1; padding: 0 10px; }
.weywot-history-wrapper.style-timeline .h-year {
    display: inline-block; background: var(--w-col-accent); color: var(--w-col-bg); padding: 5px 15px; border-radius: 20px; font-weight: bold; margin-bottom: 15px; box-shadow: 0 0 10px var(--w-col-accent);
}

.weywot-history-wrapper.style-cards .history-items { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.weywot-history-wrapper.style-cards .history-item {
    background: rgba(255, 255, 255, 0.03); padding: 20px; border: 1px solid rgba(255, 255, 255, 0.05); border-radius: var(--w-radius); text-align: center; transition: 0.3s;
}
.weywot-history-wrapper.style-cards .history-item:hover { transform: translateY(-5px); border-color: var(--w-col-accent); }
.weywot-history-wrapper.style-cards .h-year { font-size: 2rem; color: var(--w-col-accent); font-weight: 900; opacity: 0.3; margin-bottom: 10px; }

.weywot-history-wrapper.style-minimal .history-items { display: flex; flex-direction: column; gap: 15px; max-width: 700px; margin: 0 auto; }
.weywot-history-wrapper.style-minimal .history-item { display: flex; align-items: center; gap: 20px; border-bottom: 1px solid rgba(255, 255, 255, 0.05); padding-bottom: 15px; }
.weywot-history-wrapper.style-minimal .h-year { font-size: 1.5rem; font-weight: bold; color: var(--w-col-accent); min-width: 80px; }

/* ==========================================================================
   WEYWOT COMMENTS DARK MODE FIX
   ========================================================================== */
#respond input[type="text"], #respond input[type="email"], #respond input[type="url"], #respond textarea {
    background-color: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); color: #ffffff;
    padding: 15px; border-radius: var(--w-radius); width: 100%; box-sizing: border-box; transition: 0.3s; font-family: var(--w-font-body);
}
#respond input:focus, #respond textarea:focus {
    background-color: rgba(0, 0, 0, 0.3); border-color: var(--w-col-accent); outline: none;
    box-shadow: 0 0 10px rgba(129, 215, 66, 0.2);
}
#respond label { color: #cccccc; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 5px; display: block; }
.nav-links a { color: #888; font-weight: bold; text-transform: uppercase; font-size: 0.85rem; }
.nav-links a:hover { color: var(--w-col-accent); }
.entry-footer, .cat-links, .tags-links { color: #666; font-size: 0.85rem; }
.entry-footer a { color: var(--w-col-accent); }

/* ==========================================================================
   WEYWOT SUB-MENUS (DROPDOWNS) - FIX
   ========================================================================== */

/* 1. UKRYCIE DOMYŚLNE */
.main-navigation ul ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 240px; /* Szerokość rozwijanego menu */
    background-color: var(--w-col-header); /* Tło takie jak nagłówek */
    padding: 10px 0;
    box-shadow: 0 15px 40px rgba(0,0,0,0.5); /* Mocny cień */
    border-top: 3px solid var(--w-col-accent); /* Zielony pasek na górze */
    z-index: 9999;
    border-radius: 0 0 4px 4px;
}

/* 2. POKAZYWANIE NA HOVER */
.main-navigation ul li:hover > ul {
    display: block;
    animation: fadeInMenu 0.3s ease;
}

/* 3. SUB-SUB MENU (Wysuwane w prawo) */
.main-navigation ul ul ul {
    top: -10px; /* Lekka korekta w pionie */
    left: 100%; /* Wyskakuje w prawo */
    border-top: none;
    border-left: 3px solid var(--w-col-accent); /* Pasek z boku */
}

/* 4. STYL LINKÓW W DROPDOWNIE */
.main-navigation ul ul li {
    display: block;
    width: 100%;
    border-bottom: 1px solid rgba(255,255,255,0.05); /* Delikatna linia oddzielająca */
}
.main-navigation ul ul li:last-child {
    border-bottom: none;
}

.main-navigation ul ul li a {
    display: block;
    padding: 12px 20px;
    font-size: 0.85rem;
    text-transform: none; /* Wyłączamy ciągły CapsLock dla czytelności */
    font-weight: 500;
    color: var(--w-col-text);
    transition: 0.2s;
}
.main-navigation ul ul li a::after {
    display: none; /* Usuwamy dolną kreskę z głównego menu */
}

/* Hover w sub-menu */
.main-navigation ul ul li a:hover {
    background-color: rgba(255,255,255,0.05); /* Podświetlenie tła */
    color: var(--w-col-accent);
    padding-left: 25px; /* Lekkie przesunięcie tekstu */
}

/* STRZAŁKI (Wskaźniki, że jest coś niżej) */
.menu-item-has-children > a {
    padding-right: 25px !important;
    /* position: relative jest już w rodzicu li */
}
.menu-item-has-children > a::before {
    content: '\f140'; /* Dashicon strzałki w dół */
    font-family: 'dashicons';
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    opacity: 0.7;
}
/* Strzałka w prawo dla sub-sub */
.main-navigation ul ul .menu-item-has-children > a::before {
    content: '\f139'; /* Dashicon strzałki w prawo */
}

/* Animacja pojawiania się */
@keyframes fadeInMenu {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* MOBILE FIX (RESPONSIVE) */
@media (max-width: 900px) {
    .main-navigation ul ul {
        position: relative;
        box-shadow: none;
        top: 0;
        background: rgba(0,0,0,0.2);
        border-top: none;
        animation: none;
        display: none; /* Mobile - klikanie otwiera */
    }
    .main-navigation ul ul.toggled-on { display: block; }
    
    .main-navigation ul ul ul { left: 0; border-left: none; }
    
    /* Na mobile pokazujemy zawsze po hover/click dla uproszczenia w tym motywie */
    .menu-item-has-children:hover > ul { display: block; }
    
    .hud-grid { flex-direction: column; text-align: center; }
    .hud-center { order: -1; margin-bottom: 10px; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
    .company-info-wide { grid-column: auto; }
}
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .company-info-wide { grid-column: span 2; }
}
@media (max-width: 600px) {
    .weywot-history-wrapper.style-cards .history-items { grid-template-columns: 1fr; }
}


/* ==========================================================================
   WEYWOT BLOG & PAGE SYSTEM v4.0 (SMART COLORS FIXED + PAGE FIX)
   ========================================================================== */

/* 1. TŁO I STRUKTURA GŁÓWNA */
.weywot-blog-system,
.single, 
.page {
    /* Ujednolicone tło dla wszystkich podstron */
    background-color: var(--w-col-bg); 
    padding-bottom: 80px;
    min-height: 60vh;
}

/* 2. NAGŁÓWKI PODSTRON (Nowy Standard) */
.weywot-page-header {
    background: var(--w-col-header); /* Pobiera z presetu */
    border-bottom: 1px solid var(--w-col-border);
    padding: 80px 0;
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    overflow: hidden;
    transition: background 0.3s;
}

.weywot-page-header .page-title {
    font-size: 3.5rem;
    color: var(--w-col-h1);
    text-transform: uppercase;
    font-weight: 800;
    margin: 0;
    letter-spacing: 2px;
}

.weywot-page-header .archive-description,
.weywot-page-header .sub-title {
    color: var(--w-col-accent);
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 15px;
    display: block;
}

.weywot-page-header .decor-line {
    width: 60px; height: 3px; background: var(--w-col-accent);
    margin: 25px auto 0;
    box-shadow: 0 0 10px var(--w-col-accent);
}

/* 3. NAPRAWA "O NAS" I INNYCH STRON (OTOCZKA) */
/* Dodaje tło i ramkę do treści na podstronach */
.page .entry-content,
.single .entry-content {
    background-color: var(--w-col-panel);
    border: 1px solid var(--w-col-border);
    border-radius: var(--w-radius);
    padding: 40px;
    box-shadow: var(--w-shadow);
    margin-bottom: 40px;
    color: var(--w-col-text);
}

/* Wyjątek: Jeśli używamy "Pełnej szerokości", usuwamy padding */
.page-template-full-width .entry-content {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

/* Nagłówek dla pojedynczego wpisu (z datą) */
.post-meta-header {
    color: var(--w-col-meta);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    font-weight: 600;
}
.post-meta-header .post-cat a { color: var(--w-col-accent); }
.post-meta-header .sep { margin: 0 10px; opacity: 0.3; }


/* 3. UKŁAD GRID (Treść + Sidebar) */
.weywot-blog-grid,
.weywot-grid-layout {
    display: grid;
    grid-template-columns: 1fr 340px; /* Treść | Sidebar */
    gap: 60px;
    align-items: start;
}

/* 4. KARTY WPISÓW (BLOG) */
.weywot-tech-card,
.blog-card {
    background: var(--w-col-panel); /* ZMIENNA: Tło panelu */
    border: 1px solid var(--w-col-border); /* ZMIENNA: Ramka */
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 50px;
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

.weywot-tech-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--w-shadow);
    border-color: var(--w-col-accent);
}

.card-thumb {
    height: 300px;
    overflow: hidden;
    position: relative;
}
.card-thumb img {
    width: 100%; height: 100%; object-fit: cover; transition: 0.5s;
}
.weywot-tech-card:hover .card-thumb img { transform: scale(1.05); }

.card-content { padding: 35px; color: var(--w-col-text); }

.entry-header .meta-data {
    font-size: 0.8rem; color: var(--w-col-meta); text-transform: uppercase; margin-bottom: 10px;
    display: flex; gap: 15px; letter-spacing: 1px;
}
.entry-title { font-size: 2rem; margin: 10px 0 20px; line-height: 1.3; }
.entry-title a { color: var(--w-col-h1); text-decoration: none; transition: 0.2s; }
.entry-title a:hover { color: var(--w-col-accent); }

.entry-summary { color: var(--w-col-text); opacity: 0.8; line-height: 1.7; margin-bottom: 30px; }


/* 5. POJEDYNCZY WPIS (SINGLE) - CZYTANIE */
.weywot-single-article .entry-content {
    font-size: 1.1rem;
    line-height: 1.8;
}
.weywot-single-article .entry-content p { margin-bottom: 25px; }
.weywot-single-article .entry-content h2 { font-size: 2rem; margin-top: 40px; margin-bottom: 20px; border-left: 4px solid var(--w-col-accent); padding-left: 20px; color: var(--w-col-h1); }
.weywot-single-article .entry-content img { max-width: 100%; height: auto; border-radius: 4px; margin: 30px 0; }
.weywot-single-article .entry-content blockquote {
    background: rgba(0,0,0,0.2);
    padding: 30px;
    border-left: 3px solid var(--w-col-accent);
    font-style: italic;
    margin: 40px 0;
    color: var(--w-col-text);
}

.single-post-thumbnail img {
    width: 100%; height: auto; max-height: 500px; object-fit: cover;
    border-radius: 8px; margin-bottom: 40px;
    box-shadow: var(--w-shadow);
}

.post-tags { margin-top: 40px; border-top: 1px solid var(--w-col-border); padding-top: 20px; font-size: 0.9rem; color: var(--w-col-meta); }
.post-tags a { background: var(--w-col-panel); padding: 5px 10px; border-radius: 4px; color: var(--w-col-text); margin-right: 5px; font-size: 0.8rem; border: 1px solid var(--w-col-border); }
.post-tags a:hover { background: var(--w-col-accent); color: var(--w-col-bg); }

/* 6. SIDEBAR (Wspólny dla Bloga i Single) */
.blog-sidebar-area {
    background: var(--w-col-panel); /* ZMIENNA: Tło panelu */
    padding: 30px;
    border-radius: 8px;
    border: 1px solid var(--w-col-border); /* ZMIENNA: Ramka */
    position: sticky; top: 100px;
    color: var(--w-col-text);
}

.blog-sidebar-area h2.widget-title {
    font-size: 1rem; color: var(--w-col-h1); text-transform: uppercase; letter-spacing: 1px;
    border-bottom: 1px solid var(--w-col-border); padding-bottom: 10px; margin-bottom: 20px;
}
.blog-sidebar-area ul li {
    padding: 8px 0; border-bottom: 1px solid var(--w-col-border); font-size: 0.95rem;
}
.blog-sidebar-area ul li a { color: var(--w-col-text); transition: 0.2s; opacity: 0.8; }
.blog-sidebar-area ul li a:hover { color: var(--w-col-accent); padding-left: 5px; opacity: 1; }

/* 7. PAGINACJA */
.weywot-pagination { margin-top: 60px; text-align: center; }
.weywot-pagination .page-numbers {
    display: inline-block; width: 45px; height: 45px; line-height: 43px;
    border: 1px solid var(--w-col-border); color: var(--w-col-text); margin: 0 5px; border-radius: 4px;
    font-weight: bold; transition: 0.3s;
}
.weywot-pagination .page-numbers.current,
.weywot-pagination .page-numbers:hover {
    background: var(--w-col-accent); color: var(--w-col-bg); border-color: var(--w-col-accent);
}

/* 8. KOMENTARZE */
.comments-area { margin-top: 60px; border-top: 1px solid var(--w-col-border); padding-top: 40px; }
.comments-title { font-size: 1.5rem; text-transform: uppercase; margin-bottom: 30px; color: var(--w-col-h1); }

/* 9. RESPONSYWNOŚĆ */
@media (max-width: 992px) {
    .weywot-blog-grid, .weywot-grid-layout {
        grid-template-columns: 1fr; /* Sidebar spada na dół */
    }
    .weywot-page-header { padding: 50px 0; }
    .weywot-page-header .page-title { font-size: 2.2rem; }
    .blog-sidebar-area { position: static; margin-top: 40px; }
    /* Na mobile zmniejszamy padding wewnątrz karty */
    .page .entry-content, .single .entry-content { padding: 20px; }
}
/* ==========================================================================
   HOTFIX: FRONT PAGE WIDTH & SPACING (FORCE FULL WIDTH)
   Ten kod wymusza szerokość 1200px i usuwa "odcięcia" na stronie głównej.
   Wklej to na sam dół main.css.
   ========================================================================== */

/* 1. Kontener Główny - Szerokość 1200px */
.weywot-home-content {
    max-width: var(--w-container) !important; /* 1200px */
    width: 100% !important;
    padding-top: 0 !important; /* Zerujemy, żeby odstęp był minimalny */
    margin: 0 auto !important;
}

/* 2. Usuwamy "pudełko" (ramki, tła, paddingi) z wnętrza strony głównej */
.weywot-home-content .entry-content {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
}

/* 3. Rozciągamy moduł "O Nas" na pełną szerokość */
.weywot-about-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    padding: 20px 0 !important;
    margin-top: 0 !important;
}

/* 4. Naprawa Flexboxa w O Nas */
.about-flex {
    gap: 40px !important;
    justify-content: space-between !important;
    width: 100% !important;
}

/* 5. Obrazek - pełna dostępna szerokość */
.about-visual {
    width: 50% !important;
    flex: 0 0 50% !important;
    max-width: none !important; 
}

/* 6. Tekst - pełna dostępna szerokość */
.about-content {
    width: 50% !important;
    flex: 0 0 50% !important;
}

/* --- MOBILE FIX --- */
@media (max-width: 900px) {
    .about-flex {
        flex-direction: column !important;
    }
    .about-visual, .about-content {
        width: 100% !important;
        flex: 0 0 100% !important;
    }
}
/* ==========================================================================
   WEYWOT HEADER REFORM - TYLKO ZMIANA UKŁADU (BEZ PSUJA RESZTY)
   ========================================================================== */

/* Wymuszamy układ pionowy w kontenerze header */
.site-header .weywot-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 15px 20px;
}

/* Opis strony na całą szerokość na samej górze */
.site-description {
    width: 100%;
    margin: 0 0 15px 0 !important;
    display: block !important;
    order: -1;
    /* Gwarancja, że będzie pierwszy */
}

/* Nowy wiersz dla Nazwy i Menu */
.branding-bottom-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
}

/* Nazwa strony nie może się kurczyć */
.branding-main {
    flex-shrink: 0;
}

/* Twoje Menu z odstępem 90px */
.main-navigation {
    margin-left: 90px !important;
    /* Odstęp od nazwy strony */
    flex-grow: 1;
    display: flex;
    align-items: center;
}

/* Koszyk zawsze do prawej */
.weywot-cart-menu {
    margin-left: auto !important;
}

/* Mobilny fix, żeby na telefonie się nie rozjechało */
@media (max-width: 900px) {
    .branding-bottom-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .main-navigation {
        margin-left: 0 !important;
        margin-top: 15px;
    }
}
/* ==========================================================================
   WEYWOT DYNAMIC HEADER - SCROLL EFFECT
   ========================================================================== */

/* 1. Płynne ukrywanie opisu */
.site-header .site-description {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 100px; /* Wysokość robocza */
    opacity: 1;
    overflow: hidden;
}

/* 2. Stan po zjechaniu w dół (klasa dodawana przez Twój app.js) */
.site-header.is-scrolled {
    padding-top: 5px !important;
    padding-bottom: 5px !important;
    box-shadow: 0 8px 25px rgba(0,0,0,0.25) !important;
}

/* 3. Całkowite wygaszenie i zwinięcie opisu */
.site-header.is-scrolled .site-description {
    max-height: 0;
    opacity: 0;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    pointer-events: none; /* Żeby nie dało się kliknąć w "niewidzialne" */
}

/* 4. Opcjonalne: Zmniejszenie nazwy strony dla oszczędności miejsca */
.site-header.is-scrolled .site-title {
    font-size: 1.5rem !important;
}

/* 5. Utrzymanie Menu obok Nazwy (Branding Bottom Row) */
.site-header.is-scrolled .branding-bottom-row {
    margin-top: 0 !important;
}
/* ==========================================================================
   WEYWOT FOOTER & BODY SYNC - SALINA EDITION
   ========================================================================== */

/* 1. Usunięcie białego prześwitu pod stopką */
html {
    background-color: var(--w-col-footer) !important; /* Tło całego dokumentu takie jak stopka */
}

body {
    background-color: var(--w-col-bg); /* Treść ma swoje tło */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

#weywot-page {
    flex: 1 0 auto; /* Wypycha stopkę zawsze na dół, nawet przy małej ilości treści */
}

/* 2. Reset marginesów w stopce i elementach po niej */
.site-footer {
    margin-top: 0 !important; /* Usuwamy margines, bo sekcje wyżej mają własne */
    padding-bottom: 50px !important;
    position: relative;
    z-index: 10;
}

/* 3. Zabicie paska pod copyrightem */
.site-info-area {
    margin-bottom: 0 !important;
    padding-bottom: 20px !important;
}

/* 4. Ukrycie zdublowanych kontenerów (NASA-Cleanup) */
#weywot-comms-dock + #weywot-comms-dock,
#weywot-cookie-modal + #weywot-cookie-modal {
    display: none !important;
}

/* 5. Fix dla Salina Bankiet - jeśli używasz jasnych teł sekcji */
.weywot-home-content, .entry-content {
    margin-bottom: 0 !important;
}