/* =====================================================
   Polonicatimes Theme — main.css
   Версия 1.0.0
   ===================================================== */

/* --- RESET & BASE --- */
*, *::before, *::after { box-sizing: border-box; }

/* --- VARIABLES --- */
:root {
    --pct-red:        #CC0000;
    --pct-red-dark:   #aa0000;
    --pct-dark:       #1a1a1a;
    --pct-tg:         #0088cc;
    --pct-radius:     6px;
    --pct-max-width:  1100px;
    --pct-sidebar-w:  290px;
    --pct-gap:        20px;
}

/* --- LAYOUT --- */
.pct-wrap {
    max-width: var(--pct-max-width);
    margin: 0 auto;
    padding: 0 16px;
}
.pct-page-wrap { padding-top: 14px; padding-bottom: 40px; }
.pct-main-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--pct-sidebar-w);
    gap: var(--pct-gap);
    margin-top: 14px;
}

/* --- TOPBAR --- */
.pct-topbar {
    background: var(--pct-red);
    color: #fff;
    font-size: 12px;
    padding: 5px 0;
}
.pct-topbar__inner { display: flex; justify-content: space-between; align-items: center; }
.pct-topbar__date  { opacity: .85; }

/* --- LANG SWITCHER --- */
.pct-lang-switcher { display: flex; gap: 7px; }
.pct-lang-btn {
    background: rgba(255,255,255,.2);
    border: none;
    color: #fff;
    font-size: 11px;
    padding: 2px 9px;
    border-radius: 3px;
    cursor: pointer;
    text-decoration: none;
    font-weight: 400;
    transition: background .15s;
}
.pct-lang-btn.active,
.pct-lang-btn:hover { background: #fff; color: var(--pct-red); font-weight: 500; }

/* --- HEADER --- */
.pct-header {
    background: #fff;
    border-bottom: 3px solid var(--pct-red);
    padding: 12px 0;
}
.pct-header .pct-wrap { display: flex; justify-content: space-between; align-items: center; }

.pct-logo {
    font-size: 26px;
    font-weight: 500;
    color: var(--pct-red);
    text-decoration: none;
    letter-spacing: -.5px;
    line-height: 1;
}
.pct-logo span,
.pct-logo b { color: #111; font-weight: 500; }
.pct-logo--footer { font-size: 20px; margin-bottom: 10px; display: inline-block; }

/* --- SEARCH --- */
.pct-search { display: flex; gap: 7px; align-items: center; }
.pct-search input {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 6px 12px;
    font-size: 13px;
    width: 190px;
    background: #f8f8f8;
    outline: none;
    transition: border-color .15s;
}
.pct-search input:focus { border-color: var(--pct-red); }
.pct-search button {
    background: var(--pct-red);
    color: #fff;
    border: none;
    padding: 6px 15px;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    transition: background .15s;
}
.pct-search button:hover { background: var(--pct-red-dark); }

/* --- NAV --- */
.pct-nav { background: #fff; border-bottom: 1px solid #eee; }
.pct-nav__inner { display: flex; overflow-x: auto; gap: 0; }
.pct-nav__item {
    font-size: 13px;
    font-weight: 500;
    padding: 10px 14px;
    color: #555;
    cursor: pointer;
    white-space: nowrap;
    border-bottom: 3px solid transparent;
    text-decoration: none;
    transition: color .15s;
    display: block;
}
.pct-nav__item:hover,
.pct-nav__item.active { color: var(--pct-red); border-bottom-color: var(--pct-red); }

/* --- BREAKING --- */
.pct-breaking { background: var(--pct-red); color: #fff; padding: 7px 0; font-size: 13px; }
.pct-breaking__inner { display: flex; align-items: center; gap: 12px; }
.pct-breaking__label {
    background: #fff;
    color: var(--pct-red);
    font-size: 11px;
    font-weight: 500;
    padding: 2px 9px;
    border-radius: 3px;
    white-space: nowrap;
}
.pct-breaking__text { color: #fff; text-decoration: none; }
.pct-breaking__text:hover { text-decoration: underline; }

/* --- AD BLOCKS --- */
.pct-ad {
    background: #f5f5f5;
    border: 1px dashed #ccc;
    text-align: center;
    border-radius: 4px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.pct-ad--leaderboard { min-height: 100px; margin-bottom: 14px; }
.pct-ad--inline      { min-height: 90px; margin: 20px 0; }
.pct-ad--medium-rect { min-height: 250px; }
.pct-ad--half-page   { min-height: 600px; }
.pct-ad__label {
    font-size: 10px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.pct-ad__size { font-size: 12px; color: #aaa; }

/* --- HERO --- */
.pct-hero {
    background: #fff;
    border-radius: var(--pct-radius);
    overflow: hidden;
    border: 1px solid #eee;
    margin-bottom: 20px;
}
.pct-hero__main {
    display: block;
    text-decoration: none;
}
.pct-hero__img {
    width: 100%;
    height: 300px;
    background: #0f2744 center/cover no-repeat;
    display: flex;
    align-items: flex-end;
}
.pct-hero__img--no-photo { background: #0f2744; }
.pct-hero__overlay {
    padding: 20px;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,.82) 0%, transparent 100%);
}
.pct-hero__title {
    color: #fff;
    font-size: 22px;
    font-weight: 500;
    line-height: 1.3;
    margin: 6px 0 5px;
}
.pct-hero__meta { color: rgba(255,255,255,.65); font-size: 12px; }

.pct-hero__secondary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: #eee;
    margin-top: 1px;
}
.pct-hero__sec-item {
    background: #fff;
    padding: 12px;
    text-decoration: none;
    display: block;
    transition: background .15s;
}
.pct-hero__sec-item:hover { background: #fafafa; }
.pct-hero__sec-cat {
    font-size: 10px;
    color: var(--pct-red);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .3px;
    margin-bottom: 4px;
}
.pct-hero__sec-title { font-size: 13px; font-weight: 500; line-height: 1.35; color: #111; }
.pct-hero__sec-meta  { font-size: 11px; color: #999; margin-top: 3px; }

/* --- CATEGORY TAG --- */
.pct-cat-tag {
    display: inline-block;
    background: var(--pct-red);
    color: #fff;
    font-size: 11px;
    font-weight: 500;
    padding: 3px 9px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: .3px;
}

/* --- CATEGORY SECTION --- */
.pct-cat-section { margin-bottom: 22px; }
.pct-cat-section__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}
.pct-cat-section__title { font-size: 16px; font-weight: 500; color: #111; white-space: nowrap; }
.pct-cat-section__line  { flex: 1; height: 2px; background: var(--pct-red); }
.pct-cat-section__more  { font-size: 12px; color: var(--pct-red); text-decoration: none; white-space: nowrap; }
.pct-cat-section__more:hover { text-decoration: underline; }
.pct-cat-section__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

/* --- CARD --- */
.pct-card {
    background: #fff;
    border-radius: var(--pct-radius);
    border: 1px solid #eee;
    overflow: hidden;
    text-decoration: none;
    display: block;
    transition: border-color .15s;
}
.pct-card:hover { border-color: #ccc; }
.pct-card:hover .pct-card__title { color: var(--pct-red); }
.pct-card__img {
    height: 130px;
    overflow: hidden;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pct-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pct-card__img-placeholder { width: 32px; height: 32px; background: #ddd; border-radius: 4px; }
.pct-card__body  { padding: 10px 12px 12px; }
.pct-card__cat   { font-size: 10px; color: var(--pct-red); font-weight: 500; text-transform: uppercase; letter-spacing: .3px; margin-bottom: 4px; }
.pct-card__title { font-size: 13px; font-weight: 500; line-height: 1.35; color: #111; transition: color .15s; }
.pct-card__meta  { font-size: 11px; color: #999; margin-top: 5px; }

/* --- SIDEBAR --- */
.pct-sidebar { display: flex; flex-direction: column; gap: 16px; }

.pct-widget {
    background: #fff;
    border-radius: var(--pct-radius);
    border: 1px solid #eee;
    overflow: hidden;
}
.pct-widget__header {
    background: var(--pct-red);
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    padding: 9px 14px;
}
.pct-widget__body { padding: 12px 14px; }
.pct-widget__body--tg { text-align: center; padding: 16px 14px; }
.pct-widget__body--tg p { font-size: 12px; color: #555; line-height: 1.55; margin: 8px 0 14px; }
.pct-widget__body--tg svg { display: inline-block; }

.pct-widget-news {
    display: flex;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
}
.pct-widget-news:last-child { border-bottom: none; padding-bottom: 0; }
.pct-widget-news__thumb {
    width: 56px;
    height: 46px;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pct-widget-news__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pct-widget-news__no-img { width: 22px; height: 22px; background: #ddd; border-radius: 3px; }
.pct-widget-news__title { font-size: 12px; font-weight: 500; line-height: 1.35; color: #111; }
.pct-widget-news__title:hover { color: var(--pct-red); }
.pct-widget-news__meta  { font-size: 11px; color: #999; margin-top: 2px; }

.pct-tg-btn {
    display: block;
    background: var(--pct-tg);
    color: #fff;
    text-decoration: none;
    padding: 9px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    transition: background .15s;
}
.pct-tg-btn:hover { background: #006fa8; color: #fff; }

/* --- ARTICLE PAGE --- */
.pct-breadcrumb {
    font-size: 12px;
    color: #999;
    padding: 10px 0;
    display: flex;
    gap: 5px;
    align-items: center;
    flex-wrap: wrap;
}
.pct-breadcrumb a { color: var(--pct-red); text-decoration: none; }
.pct-breadcrumb a:hover { text-decoration: underline; }

.pct-article {
    background: #fff;
    border-radius: var(--pct-radius);
    border: 1px solid #eee;
    padding: 26px 30px;
}
.pct-article__title {
    font-size: 28px;
    font-weight: 500;
    line-height: 1.3;
    color: #111;
    margin: 10px 0 12px;
}
.pct-article__lead {
    font-size: 16px;
    color: #555;
    line-height: 1.65;
    font-style: italic;
    margin-bottom: 16px;
}
.pct-article__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.pct-article__author { display: flex; align-items: center; gap: 10px; }
.pct-article__avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--pct-red);
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.pct-article__author-name { font-size: 13px; font-weight: 500; color: #111; }
.pct-article__date        { font-size: 11px; color: #999; }
.pct-article__read-time   { font-size: 12px; color: #999; margin-left: auto; }

.pct-share { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pct-share__btn {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 5px 12px;
    font-size: 12px;
    cursor: pointer;
    background: #fff;
    color: #555;
    text-decoration: none;
    display: inline-block;
    transition: border-color .15s, color .15s;
}
.pct-share__btn:hover { border-color: #999; color: #111; }
.pct-share__btn--tg { background: var(--pct-tg); color: #fff; border-color: var(--pct-tg); }
.pct-share__btn--tg:hover { background: #006fa8; color: #fff; }

.pct-article__hero-img {
    width: 100%;
    margin: 0 0 6px;
    border-radius: 4px;
    overflow: hidden;
}
.pct-article__hero-img img { width: 100%; height: auto; display: block; max-height: 480px; object-fit: cover; }
.pct-article__hero-img figcaption { font-size: 12px; color: #999; margin-top: 5px; margin-bottom: 18px; }

/* Article body typography */
.pct-article__body { font-size: 16px; line-height: 1.78; color: #222; }
.pct-article__body p  { margin-bottom: 18px; }
.pct-article__body h2 { font-size: 20px; font-weight: 500; color: #111; margin: 26px 0 14px; }
.pct-article__body h3 { font-size: 17px; font-weight: 500; color: #111; margin: 20px 0 10px; }
.pct-article__body ul,
.pct-article__body ol { margin: 0 0 18px 22px; }
.pct-article__body li { margin-bottom: 6px; }
.pct-article__body a  { color: var(--pct-red); }
.pct-article__body a:hover { text-decoration: underline; }
.pct-article__body blockquote {
    border-left: 3px solid var(--pct-red);
    border-radius: 0;
    padding: 12px 18px;
    background: #fafafa;
    margin: 22px 0;
    font-style: italic;
    color: #555;
    font-size: 15px;
    line-height: 1.65;
}
.pct-article__body img { max-width: 100%; height: auto; border-radius: 4px; margin: 8px 0; }

/* In-article ad (Gutenberg custom HTML block) */
.pct-article__body .pct-ad--inline { margin: 24px 0; }

/* Tags */
.pct-article__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0; }
.pct-tag {
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 4px 13px;
    font-size: 12px;
    color: #555;
    text-decoration: none;
    transition: border-color .15s, color .15s;
}
.pct-tag:hover { border-color: var(--pct-red); color: var(--pct-red); }

/* Author box */
.pct-author-box {
    display: flex;
    gap: 14px;
    background: #f8f8f8;
    border-radius: var(--pct-radius);
    padding: 16px;
    margin: 22px 0 0;
    border: 1px solid #eee;
    align-items: flex-start;
}
.pct-author-box__avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--pct-red);
    color: #fff;
    font-size: 17px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.pct-author-box__name { font-size: 14px; font-weight: 500; color: #111; margin-bottom: 4px; }
.pct-author-box__bio  { font-size: 13px; color: #666; line-height: 1.55; }

/* Related posts */
.pct-related { margin-top: 26px; }
.pct-related__title {
    font-size: 16px;
    font-weight: 500;
    color: #111;
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--pct-red);
    display: inline-block;
}
.pct-related__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

/* --- FOOTER --- */
.pct-footer { background: var(--pct-dark); color: #aaa; padding: 30px 0 16px; margin-top: 32px; }
.pct-footer__grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 22px;
    margin-bottom: 22px;
}
.pct-footer__brand p { font-size: 12px; color: #666; line-height: 1.6; margin-top: 8px; }
.pct-footer__col-title {
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 10px;
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
}
.pct-footer__link {
    font-size: 12px;
    color: #888;
    display: block;
    margin-bottom: 5px;
    text-decoration: none;
    transition: color .15s;
}
.pct-footer__link:hover { color: var(--pct-red); }
.pct-footer__bottom {
    border-top: 1px solid #333;
    padding-top: 12px;
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #555;
}

/* --- RESPONSIVE --- */
@media (max-width: 900px) {
    .pct-main-grid { grid-template-columns: 1fr; }
    .pct-sidebar   { display: none; }
    .pct-footer__grid { grid-template-columns: 1fr 1fr; }
    .pct-cat-section__grid { grid-template-columns: repeat(2, 1fr); }
    .pct-related__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .pct-hero__secondary { grid-template-columns: 1fr; }
    .pct-article { padding: 16px; }
    .pct-article__title { font-size: 22px; }
    .pct-article__meta  { gap: 10px; }
    .pct-article__read-time { margin-left: 0; }
    .pct-footer__grid { grid-template-columns: 1fr; }
    .pct-cat-section__grid { grid-template-columns: 1fr; }
    .pct-related__grid { grid-template-columns: 1fr; }
    .pct-header .pct-wrap { flex-direction: column; gap: 10px; align-items: flex-start; }
}
