/* ===================================
   Wszystko o Meblach — custom.css v3.0.0
   Standalone theme — custom styles
   =================================== */

/* Hide default header layout (WOM has custom header) */
.wom-header .stb-header-inner { display: none; }


/* === HEADER — 1 row: logo | nav | search === */
.wom-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    padding: 0;
}

.wom-header-inner {
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    min-height: 70px;
}

.wom-header-logo {
    flex: 0 0 auto;
    margin-right: 1.5rem;
}

.wom-header-logo .custom-logo-link img {
    max-height: 31px;
    width: auto;
}

.wom-site-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: #000;
    text-decoration: none;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.wom-header-nav {
    flex: 1;
    display: flex;
    align-items: center;
}

.wom-header-nav .stb-nav { display: flex; }

.wom-header-nav .stb-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.wom-header-nav .stb-menu li a {
    display: block;
    padding: 24px 1rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: #000;
    text-decoration: none;
    letter-spacing: -0.01em;
    transition: color 0.2s;
    font-family: var(--font-body);
}

.wom-header-nav .stb-menu li a:hover,
.wom-header-nav .stb-menu li.current-menu-item a {
    color: var(--color-accent);
}

.wom-header-nav .stb-menu-toggle { display: none; }

.wom-header-actions {
    flex: 0 0 auto;
    margin-left: 1rem;
}

.wom-header-divider {
    height: 1px;
    background: #eee;
}

.wom-search-toggle {
    background: none;
    border: none;
    color: #000;
    cursor: pointer;
    padding: 0.75rem;
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.wom-search-toggle:hover { opacity: 1; }

/* ==============================================
   HERO GRID — full-width
   Lewy obraz = wysokość 2 prawych + gap
   ============================================== */
.wom-hero {
    width: 100%;
}

/* Hero grid: 2 kolumny, stała wysokość 420px.
   Lewy rozciąga się na pełną wysokość, prawe po 208px każdy. */
.wom-hero-grid {
    display: grid;
    grid-template-columns: 58.5% 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 4px;
    height: 470px;
}

.wom-hero-big {
    grid-row: 1 / 3;
    overflow: hidden;
}

.wom-hero-small {
    display: contents;
}

.wom-hero-card {
    position: relative;
    overflow: hidden;
}

.wom-hero-link {
    display: block;
    height: 100%;
    position: relative;
    text-decoration: none;
    color: #fff;
}

.wom-hero-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.2, 0.96, 0.34, 1);
}

.wom-hero-big .wom-hero-card,
.wom-hero-big .wom-hero-link,
.wom-hero-big .wom-hero-img {
    height: 100%;
}

.wom-hero-card:hover .wom-hero-img {
    transform: scale(1.03);
}

.wom-hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem 2.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 100%);
}

.wom-hero-cat {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fff;
    background: var(--color-accent);
    padding: 0.2rem 0.6rem;
    border-radius: 2px;
}

.wom-hero-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.14;
    margin: 0 0 0.5rem;
    color: #fff;
    letter-spacing: -0.02em;
}

.wom-hero-title-sm {
    font-size: 1.5rem;
    line-height: 1.25;
}

.wom-hero-excerpt {
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

/* === SECTION HEADERS (Minerva title bar) === */
.wom-section-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #000;
}

.wom-section-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: #000;
    margin: 0;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    justify-content: space-between;
}



/* === POPULAR GRID — 2x2 === */
.wom-popular-section {
    margin-top: 2rem;
}

.wom-popular-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.wom-popular-card {
    overflow: hidden;
}

.wom-popular-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.wom-popular-thumb {
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.wom-popular-thumb img {
    width: 100%;
    height: auto;
    aspect-ratio: 370 / 250;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.wom-popular-card:hover .wom-popular-thumb img {
    transform: scale(1.03);
}

.wom-popular-body {
    padding: 0 0.25rem;
}

.wom-popular-meta {
    display: flex;
    gap: 0.4rem;
    font-size: 0.78rem;
    color: #888;
    margin-bottom: 0.5rem;
    align-items: center;
}

.wom-popular-sep { opacity: 0.5; }

.wom-popular-card-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.3;
    margin: 0;
    color: #000;
    transition: color 0.2s;
}

.wom-popular-card:hover .wom-popular-card-title {
    color: var(--color-accent);
}

/* === LATEST SECTION === */
.wom-latest-section {
    margin-top: 2rem;
}

/* === LATEST POSTS — list style === */
.wom-list-post {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
}

.wom-list-post:last-child {
    border-bottom: none;
}

.wom-list-thumb {
    overflow: hidden;
}

.wom-list-img {
    width: 100%;
    height: auto;
    aspect-ratio: 370 / 250;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.wom-list-post:hover .wom-list-img {
    transform: scale(1.03);
}

.wom-list-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0.75rem 0;
}

.wom-list-meta {
    display: flex;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 0.5rem;
    align-items: center;
}

.wom-list-cat {
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 0.05em;
}

.wom-list-meta-sep { opacity: 0.5; }

.wom-list-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.25;
    margin: 0 0 0.75rem;
    letter-spacing: -0.02em;
}

.wom-list-title a {
    color: #000;
}

.wom-list-excerpt {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.5;
    margin: 0;
}

/* === SIDEBAR (single/archive) — NIE sticky === */
.stb-sidebar { position: static; }

.stb-sidebar .stb-widget {
    background: #fff;
    border: 1px solid var(--color-border, #eee);
    border-radius: 0;
    padding: 20px;
    margin-bottom: 24px;
}

.stb-widget-title {
    color: #000;
    border-bottom: 2px solid #000;
    letter-spacing: -0.02em;
}

/* Sidebar grid fix */
.stb-layout-sidebar .stb-layout-inner .stb-sidebar {
    grid-column: 2;
    grid-row: 1 / -1;
}
.stb-layout-sidebar .stb-layout-inner .stb-related {
    grid-column: 1;
}

/* --- Najnowsze artykuły (sidebar) --- */
.wom-recent-list { display: flex; flex-direction: column; gap: 14px; }
.wom-recent-item { display: flex; gap: 12px; text-decoration: none; color: inherit; align-items: flex-start; }
.wom-recent-item:hover .wom-recent-title { color: var(--color-accent); }
.wom-recent-thumb { width: 70px; height: 70px; flex-shrink: 0; overflow: hidden; background: #f5f5f5; }
.wom-recent-thumb img { width: 100%; height: 100%; object-fit: cover; }
.wom-recent-info { flex: 1; min-width: 0; }
.wom-recent-title { font-size: 13px; font-weight: 600; line-height: 1.4; margin: 0 0 4px; color: #000; transition: color 0.2s; }
.wom-recent-date { font-size: 11px; color: #999; }

/* --- Kategorie (sidebar) --- */
.wom-sidebar-categories .wom-cat-list { list-style: none; padding: 0; margin: 0; }
.wom-sidebar-categories .wom-cat-list li { border-bottom: 1px solid #f0f0f0; }
.wom-sidebar-categories .wom-cat-list li:last-child { border-bottom: none; }
.wom-sidebar-categories .wom-cat-list a { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; color: #000; text-decoration: none; font-size: 14px; transition: color 0.2s; }
.wom-sidebar-categories .wom-cat-list a:hover { color: var(--color-accent); }
.wom-sidebar-categories .wom-cat-count { font-size: 12px; color: #aaa; }

/* --- Kreacja ad slots (sidebar) --- */
.wom-sidebar-ad { margin-bottom: 24px; }

/* === FOOTER — dark === */
.wom-footer {
    background: #000;
    color: #999;
    padding: 2.5rem 0 0;
}

.wom-footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.wom-footer-logo .custom-logo-link img {
    max-height: 28px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.wom-footer-site-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    text-decoration: none;
}

.wom-footer-links { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.wom-footer-links a { font-size: 0.85rem; color: #999; text-decoration: none; transition: color 0.2s; }
.wom-footer-links a:hover { color: #fff; }
.wom-footer-sep { color: #555; font-size: 0.85rem; }

/* Hide plugin compliance footer */
body > nav.footer-legal, body > p.copyright, body > p.company-info { display: none; }

.wom-footer .stb-footer-legal { text-align: center; color: #666; font-size: 0.8rem; padding: 1rem 0; margin-top: 0; border-top: none; }
.wom-footer .stb-footer-legal p { margin: 0; }

/* === BREADCRUMBS BAR (archive/single) === */
.stb-archive-header {
    background: var(--color-bg-alt, #000);
    color: #fff;
    margin-bottom: 0;
}

.stb-archive-header-inner {
    padding-top: 1.1rem;
    padding-bottom: 0.9rem;
}

.stb-archive-header + .stb-main { padding-top: 5px; }

.stb-archive-header h1,
.stb-archive-header .stb-post-title {
    color: #fff;
    font-size: 0.85rem;
    font-weight: 400;
    margin: 0;
}

.stb-archive-header .stb-breadcrumbs { color: rgba(255,255,255,0.7); }
.stb-archive-header .stb-breadcrumbs a { color: rgba(255,255,255,0.7); }
.stb-archive-header .stb-breadcrumbs a:hover { color: #fff; }
.stb-archive-header .stb-breadcrumbs-sep { color: rgba(255,255,255,0.4); }
.stb-archive-header .stb-breadcrumbs-current { color: rgba(255,255,255,0.9); }

/* === BODY + LINKI === */
body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.5;
    background: #fff;
    color: #000;
}

/* Linki — animated underline od lewej do prawej */
.stb-post-content a,
.stb-content a,
.wom-list-title a,
.wom-popular-card-title,
.stb-card-title,
.stb-related-card-title,
.wom-footer-links a,
.wom-header-nav .stb-menu li a {
    position: relative;
    text-decoration: none;
}

.stb-post-content a::after,
.stb-content a::after,
.wom-list-title a::after,
.wom-popular-card-title::after,
.stb-card-title::after,
.stb-related-card-title::after,
.wom-footer-links a::after,
.wom-header-nav .stb-menu li a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s ease;
}

/* Menu — underline bliżej tekstu, nie na dole paddingu */
.wom-header-nav .stb-menu li a {
    display: inline-block;
    vertical-align: middle;
    padding: 24px 1rem;
}

.wom-header-nav .stb-menu li a::after {
    bottom: 18px;
}

.stb-post-content a:hover::after,
.stb-content a:hover::after,
.wom-list-title a:hover::after,
.wom-popular-card:hover .wom-popular-card-title::after,
.stb-card:hover .stb-card-title::after,
.stb-related-card:hover .stb-related-card-title::after,
.wom-footer-links a:hover::after,
.wom-header-nav .stb-menu li a:hover::after {
    width: 100%;
}

.stb-post-content a,
.stb-content a {
    color: #333;
    transition: color 0.2s;
}

.stb-post-content a:hover,
.stb-content a:hover {
    color: #000;
}

/* === CONTACT FORM === */
.wom-contact-page { max-width: 640px; margin: 2rem auto 3rem; padding: 0 1rem; }
.wom-contact-title { font-family: var(--font-heading); font-size: 2rem; font-weight: 700; margin-bottom: 0.5rem; }
.wom-contact-intro { color: #666; margin-bottom: 2rem; line-height: 1.6; }
.wom-form-row { margin-bottom: 1.25rem; }
.wom-form-row label { display: block; font-weight: 600; margin-bottom: 0.35rem; font-size: 0.95rem; }
.wom-required { color: var(--color-accent); }
.wom-form-row input, .wom-form-row select, .wom-form-row textarea { width: 100%; padding: 0.65rem 0.85rem; border: 1px solid var(--color-border); border-radius: 0; font-family: var(--font-body); font-size: 1rem; background: #fff; color: #000; transition: border-color 0.2s; }
.wom-form-row input:focus, .wom-form-row select:focus, .wom-form-row textarea:focus { outline: none; border-color: var(--color-accent); }
.wom-form-row textarea { resize: vertical; min-height: 120px; }
.wom-submit-btn { display: inline-block; padding: 0.75rem 2rem; background: var(--color-accent); color: #fff; border: none; font-family: var(--font-body); font-size: 1rem; font-weight: 600; cursor: pointer; transition: opacity 0.2s; }
.wom-submit-btn:hover { opacity: 0.85; }
.wom-submit-btn:disabled { opacity: 0.6; cursor: wait; }
.wom-form-status { margin-top: 1rem; padding: 0.75rem 1rem; font-size: 0.95rem; }
.wom-form-success { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.wom-form-error { background: #fce4ec; color: #c62828; border: 1px solid #ef9a9a; }
.grecaptcha-badge { visibility: hidden; }

/* ==============================================
   RESPONSIVE
   ============================================== */
@media (max-width: 1024px) {
    .wom-hero-grid { grid-template-columns: 1fr 1fr; height: 320px; }
    .wom-hero-title { font-size: 2rem; }
    .wom-hero-title-sm { font-size: 1.25rem; }
    .wom-list-post { grid-template-columns: 250px 1fr; }
    .wom-list-title { font-size: 1.25rem; }
}

@media (max-width: 768px) {
    /* Header mobile */
    .wom-header-nav { position: relative; }
    .wom-header-nav .stb-menu-toggle { display: flex; flex-direction: column; gap: 4px; background: none; border: none; cursor: pointer; padding: 0.5rem; position: absolute; right: 0; top: 50%; transform: translateY(-50%); }
    .wom-header-nav .stb-menu-toggle span { display: block; width: 22px; height: 2px; background: #000; }
    .wom-header-nav .stb-nav { display: none; position: absolute; top: 100%; left: -100%; right: -100%; background: #fff; border-bottom: 1px solid #eee; box-shadow: 0 4px 8px rgba(0,0,0,0.1); z-index: 99; }
    .wom-header-nav .stb-nav.stb-nav-open { display: block; }
    .wom-header-nav .stb-menu { flex-direction: column; }
    .wom-header-nav .stb-menu li a { padding: 0.75rem 1.5rem; border-bottom: 1px solid #f0f0f0; }

    /* Hero mobile — stack */
    .wom-hero-grid { grid-template-columns: 1fr; grid-template-rows: auto auto auto; height: auto; }
    .wom-hero-big { grid-row: auto; }
    .wom-hero-big .wom-hero-card, .wom-hero-big .wom-hero-link, .wom-hero-big .wom-hero-img { height: auto; }
    .wom-hero-img { aspect-ratio: 16 / 9; height: auto; }
    .wom-hero-title { font-size: 1.5rem; }
    .wom-hero-title-sm { font-size: 1.25rem; }
    .wom-hero-excerpt { display: none; }

    /* Popular mobile */
    .wom-popular-grid { grid-template-columns: 1fr; gap: 1rem; }

    /* Latest posts mobile */
    .wom-list-post { grid-template-columns: 1fr; }
    .wom-list-thumb { width: 100%; max-height: 250px; overflow: hidden; }
    .wom-footer-inner { flex-direction: column; align-items: center; text-align: center; }

    /* Sidebar below content */
    .stb-layout-sidebar .stb-layout-inner .stb-sidebar { grid-column: 1; grid-row: auto; }
    .stb-layout-sidebar .stb-layout-inner .stb-related { grid-column: 1; }
}

@media (max-width: 480px) {
    .wom-hero-overlay { padding: 1rem 1.25rem; }
    .wom-hero-title { font-size: 1.2rem; }
    .wom-hero-title-sm { font-size: 1rem; }
    .wom-hero-cat { display: none; }
    .wom-section-title { font-size: 1.2rem; }
}

/* === ACCESSIBILITY === */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}
.wom-hero-link:focus-visible { outline-offset: -2px; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .wom-hero-card:hover .wom-hero-img, .wom-list-post:hover .wom-list-img { transform: none; }
}
