/* --- TRACKPOINT GLOBAL CSS ---
   Global layout + magazín
*/

:root {
    --mustard: #fea500;
    --dark-olive: #2b3022;
    --cream-bg: #f9f5f0;
    --charcoal: #1a1a1a;
    --white: #ffffff;
    --border-color: #edf2f7;
    --radius-lg: 22px;
    --radius-md: 15px;
}

/* --- ZÁKLADNÍ RESET A TYPOGRAFIE --- */
body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    background-color: var(--cream-bg);
    font-family: 'Poppins', sans-serif;
    color: var(--charcoal);
    line-height: 1.6;
}

/* HLAVNÍ OBAL */
.tp-master-wrapper {
    max-width: 1280px !important;
    margin: 0 auto;
    background: var(--white);
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.05);
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* SJEDNOCENÝ KONTEJNER */
.tp-section-container {
    max-width: 1200px !important;
    margin: 0 auto;
    padding: 0 40px;
    box-sizing: border-box;
}

/* --- TLAČÍTKA --- */
.tp-btn-yellow {
    background: var(--mustard);
    color: #171a16;
    padding: 14px 28px;
    border-radius: 10px;
    font-weight: 800;
    text-decoration: none;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    border: none;
    transition: 0.22s ease;
}

.tp-btn-yellow:hover {
    background: #e99500;
    color: #171a16;
    transform: translateY(-2px);
}

.tp-btn-outline-dark {
    background: rgba(43, 48, 34, 0.05);
    color: var(--dark-olive);
    padding: 14px 28px;
    border-radius: 10px;
    text-decoration: none;
    border: 2px solid var(--dark-olive);
    font-weight: 700;
    transition: 0.22s ease;
}

.tp-btn-outline-dark:hover {
    background: var(--dark-olive);
    color: #fff;
}

/* ==========================================================================
   MAGAZÍN
   ========================================================================== */

.tp-magazine-wrapper {
    background-color: var(--cream-bg);
    padding: 54px 0 72px;
    flex-grow: 1;
}

.mag-header {
    text-align: center;
    margin-bottom: 42px;
}

.mag-header h1 {
    margin: 0 0 12px;
    color: var(--charcoal);
    font-size: clamp(2.25rem, 4vw, 3.2rem);
    line-height: 1.08;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.mag-header p {
    max-width: 680px;
    margin: 0 auto;
    color: #718096;
    font-size: 1.05rem;
    line-height: 1.6;
}

/* FEATURED ČLÁNEK */
.mag-card-featured {
    display: grid;
    grid-template-columns: minmax(0, 46%) minmax(0, 54%);
    height: 320px;
    min-height: 0;
    margin-bottom: 38px;
    overflow: hidden;
    border: 1px solid rgba(37, 41, 31, 0.10);
    border-radius: var(--radius-lg);
    background: var(--white);
    color: inherit;
    text-decoration: none;
    box-shadow: 0 14px 38px rgba(33, 39, 25, 0.08);
    transition:
        transform 0.22s ease,
        box-shadow 0.22s ease,
        border-color 0.22s ease;
}

.mag-card-featured:hover {
    transform: translateY(-3px);
    border-color: rgba(254, 165, 0, 0.48);
    box-shadow: 0 20px 48px rgba(33, 39, 25, 0.12);
    color: inherit;
}

.mag-featured-img {
    height: 320px;
    min-height: 0;
    overflow: hidden;
    background: #eef2ec;
}

.mag-featured-img img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.mag-card-featured:hover .mag-featured-img img {
    transform: scale(1.04);
}

.mag-featured-content {
    min-width: 0;
    height: 320px;
    box-sizing: border-box;
    overflow: hidden;
    padding: 28px 36px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    text-align: left;
}

.mag-badge,
.mag-badge-small,
.mag-card-featured .mag-badge,
.mag-grid-card .mag-badge-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: 32px;
    padding: 0 14px;
    border: 0;
    border-radius: 999px;
    background: #ffffff;
    color: #171a16 !important;
    font-size: 0.7rem;
    line-height: 1;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-decoration: none !important;
    box-shadow: 0 8px 18px rgba(33, 39, 25, 0.08);
}

.mag-badge:hover,
.mag-badge:focus,
.mag-badge-small:hover,
.mag-badge-small:focus,
.mag-card-featured:hover .mag-badge,
.mag-grid-card:hover .mag-badge-small {
    background: #ffffff;
    color: #171a16 !important;
    border: 0;
    text-decoration: none !important;
}

.mag-badge {
    margin-bottom: 15px;
}

.mag-featured-content h2 {
    margin: 0 0 14px;
    color: var(--charcoal);
    font-size: clamp(1.6rem, 2.6vw, 2.15rem);
    line-height: 1.18;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.mag-featured-content h2 a,
.mag-card-featured h2 a,
.mag-card-body h3 a {
    color: inherit !important;
    text-decoration: none !important;
}

.mag-featured-content h2 a:hover,
.mag-card-featured h2 a:hover,
.mag-card-body h3 a:hover {
    color: inherit !important;
    text-decoration: none !important;
}

.mag-featured-content p {
    margin: 0;
    color: #667085;
    font-size: 0.96rem;
    line-height: 1.62;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
    white-space: normal;
}

.mag-featured-content h2,
.mag-featured-content h2 a,
.mag-featured-content p,
.mag-meta {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    white-space: normal;
}

.mag-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 18px;
    color: #8a98aa;
    font-size: 0.82rem;
    line-height: 1.3;
}

.mag-meta strong {
    color: var(--charcoal);
    font-weight: 800;
}

.mag-author-badge {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--mustard);
    color: #171a16;
    font-size: 0.72rem;
    font-weight: 900;
}

/* FILTRY */
.mag-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 42px;
}

.filter-pill {
    min-height: 42px;
    padding: 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(37, 41, 31, 0.12);
    border-radius: 999px;
    background: var(--white);
    color: #4a5568;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 700;
    box-shadow: 0 5px 16px rgba(33, 39, 25, 0.045);
    transition: 0.2s ease;
}

.filter-pill:hover {
    transform: translateY(-1px);
    border-color: var(--mustard);
    color: var(--charcoal);
}

.filter-pill.active {
    background: var(--charcoal);
    color: var(--white);
    border-color: var(--charcoal);
}

/* GRID ČLÁNKŮ */
.mag-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.mag-grid-card {
    overflow: hidden;
    border: 1px solid rgba(37, 41, 31, 0.10);
    border-radius: 20px;
    background: var(--white);
    box-shadow: 0 12px 32px rgba(33, 39, 25, 0.065);
    transition:
        transform 0.24s ease,
        box-shadow 0.24s ease,
        border-color 0.24s ease;
}

.mag-grid-card:hover {
    transform: translateY(-5px);
    border-color: rgba(254, 165, 0, 0.45);
    box-shadow: 0 18px 42px rgba(33, 39, 25, 0.11);
}

.mag-card-link {
    display: block;
    height: 100%;
    color: inherit;
    text-decoration: none;
}

.mag-card-link:hover {
    color: inherit;
}

.mag-card-img {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: #eef2ec;
}

.mag-card-img img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.mag-grid-card:hover .mag-card-img img {
    transform: scale(1.04);
}

.mag-badge-small {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.mag-card-body {
    padding: 24px;
    text-align: left;
}

.mag-card-body h3 {
    margin: 0 0 12px;
    color: var(--charcoal);
    font-size: 1.3rem;
    line-height: 1.32;
    font-weight: 900;
}

.mag-card-body p {
    margin: 0 0 20px;
    color: #667085;
    font-size: 0.92rem;
    line-height: 1.6;
}

.mag-read-more {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #d98900;
    font-size: 0.88rem;
    font-weight: 900;
    text-transform: uppercase;
}

.mag-read-more i {
    transition: transform 0.2s ease;
}

.mag-grid-card:hover .mag-read-more i {
    transform: translateX(3px);
}

/* NEWSLETTER */
.mag-newsletter-box {
    margin-top: 52px;
    padding: 48px 36px;
    border-radius: 20px;
    background: var(--dark-olive);
    color: #fff;
    text-align: center;
}

.mag-newsletter-box h3 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 1.6rem;
    line-height: 1.2;
    font-weight: 900;
}

.mag-newsletter-box p {
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
}

.mag-newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 20px auto 0;
    gap: 10px;
}

.mag-newsletter-form input {
    flex: 1;
    min-width: 0;
    min-height: 48px;
    padding: 0 15px;
    border: none;
    border-radius: 10px;
}

.mag-newsletter-form button {
    min-height: 48px;
    padding: 0 24px;
    border: none;
    border-radius: 10px;
    background: var(--mustard);
    color: #171a16;
    font-weight: 800;
    cursor: pointer;
}

/* ==========================================================================
   RESPONZIVITA
   ========================================================================== */

@media (max-width: 992px) {
    .mag-card-featured {
        grid-template-columns: 1fr;
        height: auto;
    }

    .mag-featured-img,
    .mag-featured-img img {
        height: 260px;
        min-height: 0;
    }

    .mag-featured-content {
        height: auto;
        overflow: visible;
        padding: 28px 30px;
    }

    .tp-master-wrapper {
        margin: 0;
        box-shadow: none;
    }

    .tp-section-container {
        padding: 0 20px;
    }
}

@media (max-width: 992px) {
    .mag-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .tp-magazine-wrapper {
        padding: 38px 0 56px;
    }

    .mag-header {
        margin-bottom: 30px;
    }

    .mag-grid {
        grid-template-columns: 1fr;
    }

    .mag-card-img {
        height: 220px;
    }

    .mag-newsletter-form {
        flex-direction: column;
    }

    .mag-newsletter-form button {
        width: 100%;
    }
}

@media (max-width: 560px) {
    .mag-card-featured {
        height: auto;
        min-height: 0;
        border-radius: 16px;
    }

    .mag-featured-img,
    .mag-featured-img img {
        height: 210px;
        min-height: 0;
    }

    .mag-featured-content {
        padding: 22px 20px;
    }

    .mag-featured-content h2 {
        font-size: 1.5rem;
    }

    .mag-filters {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    .filter-pill {
        flex: 0 0 auto;
    }

    .mag-card-body {
        padding: 20px;
    }

    .mag-newsletter-box {
        padding: 34px 20px;
    }
}

/* ==========================================================================
   ČIŠTĚNÍ DIRECTORIST VYHLEDÁVAČE
   ========================================================================== */

.tp-search-bar-section .directorist-search-top,
.tp-search-bar-section .directorist-search-top__title,
.tp-search-bar-section .directorist-search-top__subtitle,
.tp-search-bar-section .directorist-search-header {
    display: none !important;
}

.tp-search-bar-section .directorist-listing-category-top,
.tp-search-bar-section .directorist-popular-categories {
    display: none !important;
}

.tp-search-bar-section .directorist-search-contents {
    padding: 0 !important;
    background: transparent !important;
}

/* Pevné přepsání odkazů uvnitř štítků kategorií */
.mag-badge a,
.mag-badge-small a,
.mag-card-featured .mag-badge a,
.mag-grid-card .mag-badge-small a,
.mag-badge a:visited,
.mag-badge-small a:visited,
.mag-badge a:hover,
.mag-badge-small a:hover,
.mag-badge a:focus,
.mag-badge-small a:focus {
    color: #171a16 !important;
    text-decoration: none !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

/* ==========================================================================
   ARCHIV RUBRIKY MAGAZÍNU
   ========================================================================== */

.tp-magazine-archive .mag-header {
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

.mag-archive-eyebrow {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    margin-bottom: 14px;
    padding: 0 14px;
    border-radius: 999px;
    background: #fff;
    color: #171a16;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    box-shadow: 0 8px 18px rgba(33, 39, 25, 0.08);
}

.mag-archive-description {
    max-width: 680px;
    margin: 0 auto;
    color: #718096;
    font-size: 1.02rem;
    line-height: 1.65;
}

.mag-archive-description p {
    margin: 0;
}

.mag-archive-count {
    margin-top: 14px;
    color: #8a98aa;
    font-size: 0.84rem;
    font-weight: 700;
}

.tp-magazine-archive .mag-filters {
    margin-top: -4px;
}

.tp-magazine-archive .mag-card-body h2 {
    margin: 0 0 12px;
    color: var(--charcoal);
    font-size: 1.3rem;
    line-height: 1.32;
    font-weight: 900;
}

.mag-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: auto;
}

.mag-card-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #98a2b3;
    font-size: 0.78rem;
    white-space: nowrap;
}

.mag-pagination {
    margin-top: 44px;
}

.mag-pagination .nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.mag-pagination .page-numbers {
    min-width: 42px;
    min-height: 42px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(37, 41, 31, 0.12);
    border-radius: 999px;
    background: #fff;
    color: #171a16;
    text-decoration: none;
    font-size: 0.86rem;
    font-weight: 800;
    box-shadow: 0 5px 16px rgba(33, 39, 25, 0.045);
}

.mag-pagination .page-numbers.current,
.mag-pagination .page-numbers:hover {
    border-color: var(--charcoal);
    background: var(--charcoal);
    color: #fff;
}

.mag-empty-state {
    padding: 60px 30px;
    border: 1px solid rgba(37, 41, 31, 0.10);
    border-radius: 20px;
    background: #fff;
    text-align: center;
    box-shadow: 0 14px 38px rgba(33, 39, 25, 0.06);
}

.mag-empty-state h2 {
    margin: 0 0 10px;
    color: var(--charcoal);
    font-size: 1.6rem;
    font-weight: 900;
}

.mag-empty-state p {
    margin: 0 0 24px;
    color: #718096;
}

.mag-empty-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: #fff;
    color: #d98900;
    box-shadow: 0 10px 22px rgba(254, 165, 0, 0.12);
}

.mag-empty-icon svg {
    width: 34px;
    height: 34px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

@media (max-width: 640px) {
    .mag-card-footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .mag-empty-state {
        padding: 44px 20px;
    }
}
