/*
Theme Name: Spodnie Skorzane
Author: Custom Theme
Description: portal informacyjny, analizy bukmacherskie, poradniki, recenzje
Version: 1.0.0
*/

@import url('https://fonts.googleapis.com/css2?family=Spectral:wght@400;700&family=Atkinson+Hyperlegible:wght@400;700&display=swap');

:root {
    --primary: #0d0d0d;
    --secondary: #9c4a1a;
    --accent: #2a2a2a;
    --bg-main: #faf5ef;
    --white: #ffffff;
    --text-main: #1a1a1a;
    --text-muted: #4a4a4a;
    --border: #9c4a1a;
    
    --container-width: 1200px;
    --content-width: 800px;
    --transition: all 0.3s ease;
    --section-pad: 5rem;
}

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

html, body {
    overflow-x: hidden;
    background: var(--bg-main);
    color: var(--text-main);
    font-family: 'Atkinson Hyperlegible', sans-serif;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6, .logo {
    font-family: 'Spectral', serif;
    font-weight: 700;
    line-height: 1.2;
    overflow-wrap: break-word;
    word-break: break-word;
}

h1 { font-size: clamp(2rem, 5vw, 4rem); margin-bottom: 2rem; }
h2 { font-size: clamp(1.8rem, 4vw, 3rem); margin-bottom: 2rem; }
h3 { font-size: 1.4rem; margin-bottom: 1rem; }

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: var(--transition); }

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.btn-arc {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: var(--secondary);
    color: var(--white);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9rem;
    border: 2px solid var(--secondary);
    transition: var(--transition);
}
.btn-arc:hover {
    background: transparent;
    color: var(--secondary);
}

/* N-E: Minimal top-bar <= 50px */
.site-header {
    height: 50px;
    display: flex;
    align-items: center;
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 9999;
    background: var(--bg-main);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 1.2rem;
    color: var(--primary);
    text-transform: lowercase;
}
.logo span {
    color: var(--secondary);
}

.main-nav ul { display: flex; list-style: none; gap: 2rem; }
.main-nav a { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; color: var(--text-main); }
.main-nav a:hover { color: var(--secondary); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; flex-direction: column; gap: 4px; }
.nav-toggle span { width: 24px; height: 2px; background: var(--text-main); transition: 0.3s; }

/* H-D: Breakout/Asymmetric Hero */
.hero-arc {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 70vh;
    border-bottom: 2px solid var(--border);
    margin-top: 50px;
}
.hero-content {
    padding: 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.hero-image-wrapper {
    height: 100%;
}
.hero-image {
    height: 100%;
    width: 100%;
    object-fit: cover;
}

/* V-D: Alternating section backgrounds */
.section-alt {
    background: var(--white);
}

/* D-B: Horizontal accent lines */
.accent-line {
    width: 100%;
    height: 2px;
    background: var(--secondary);
    margin: 3rem 0;
}

/* F-C: Accordion Features */
.accordion-container { margin: 2rem 0; }
.accordion-item {
    border-bottom: 1px solid var(--border);
    padding: 1.5rem 0;
    cursor: pointer;
}
.accordion-title {
    font-size: 1.5rem;
    font-family: 'Spectral', serif;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.accordion-title::after {
    content: '+';
    font-size: 1.5rem;
    color: var(--secondary);
}
.accordion-item.active .accordion-title::after { content: '−'; }
.accordion-content {
    display: none;
    padding-top: 1rem;
    color: var(--text-muted);
}
.accordion-item.active .accordion-content {
    display: block;
}

/* U-C: Horizontal scroll — tape of cards */
.showcase-arc { padding: var(--section-pad) 0; overflow: hidden; }
.horizontal-scroll {
    display: flex;
    overflow-x: auto;
    gap: 2rem;
    padding: 1rem 0 2rem;
    scroll-snap-type: x mandatory;
}
.scroll-item {
    flex: 0 0 350px;
    scroll-snap-align: start;
    background: var(--white);
    padding: 2.5rem;
    border: 1px solid var(--border);
}

/* C-D: Minimal without image — text list */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}
.post-card-arc {
    border-top: 2px solid var(--border);
    padding-top: 1.5rem;
}
.post-card-arc .thumb { display: none; }
.post-card-arc h3 { font-size: 1.3rem; margin-bottom: 1rem; }
.post-card-arc p { color: var(--text-muted); margin-bottom: 1.5rem; }
.post-card-arc .read-more {
    font-weight: 700;
    color: var(--secondary);
    text-transform: uppercase;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* FT-D: CTA-footer */
.site-footer {
    background: var(--primary);
    color: var(--white);
    text-align: center;
    padding: 6rem 0 2rem;
}
.cta-footer {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 2rem;
    color: var(--white);
}
.footer-info { margin-top: 4rem; color: #aaa; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: 3rem;
    padding-top: 2rem;
    font-size: 0.85rem;
    color: #666;
}

.pagination { display: flex; justify-content: center; gap: 1rem; margin: 4rem 0 0; }
.pagination .page-numbers {
    width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--border); background: transparent; font-weight: 700; color: var(--text-main);
}
.pagination .page-numbers.current { background: var(--secondary); color: var(--white); border-color: var(--secondary); }

@media (max-width: 1024px) {
    .hero-arc { grid-template-columns: 1fr; }
    .hero-image-wrapper { height: 400px; }
    .posts-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .posts-grid { grid-template-columns: 1fr; }
    .main-nav { display: none; }
    .nav-toggle { display: flex; }
    
    body.menu-open .nav-toggle span:nth-child(1) { transform: rotate(45deg) translate(4px, 4px); }
    body.menu-open .nav-toggle span:nth-child(2) { opacity: 0; }
    body.menu-open .nav-toggle span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }

    body.menu-open .main-nav {
        display: flex; position: fixed; top: 50px; left: 0; right: 0; bottom: 0;
        background: var(--bg-main); z-index: 9998; align-items: center; justify-content: center;
    }
    body.menu-open .main-nav ul { flex-direction: column; text-align: center; gap: 2rem; }
    body.menu-open .main-nav a { font-size: 1.5rem; }
}

/* RULE 21 FIX */
.post-card-arc {
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
}
.post-card-arc .thumb {
    display: block !important;
    height: clamp(180px, 25vw, 300px) !important;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}
.post-card-arc .thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}
.post-card-content {
    display: flex !important;
    flex-direction: column !important;
    flex-grow: 1 !important;
}
.post-card-content h3 {
    flex-grow: 1 !important;
}
.btn-read, .read-more-link {
    margin-top: auto !important;
}

.logo, .footer-logo { flex-wrap: wrap !important; }

/* FIX HERO OVERLAP RULE 16 */
.site-main > section:first-child {
    padding-top: clamp(140px, 15vh, 180px) !important;
}
.hero-split {
    padding-top: 0 !important;
}
.hero-split .hero-text {
    padding-top: clamp(140px, 15vh, 180px) !important;
}


.hero-arc {
    height: auto !important;
    min-height: max(400px, 50vh) !important;
}


/* FIX BACKGROUND VISIBILITY BUG (STACKING CONTEXT) */
section, .hero-arc, .hero-split, .site-main > section {
    isolation: isolate;
}
.hero-content, .hero-text {
    position: relative;
    z-index: 1;
}

