/* ========================================== */
/*              GAZETA KUCYKON                */
/*                  CSS                       */
/* ========================================== */


@font-face {
    font-family: 'IMFePIsc29P';
    src: url('resources/font/IMFePIsc29P.ttf') format('truetype');
}
@font-face {
    font-family: 'IMFePIit29P';
    src: url('resources/font/IMFePIit29P.ttf') format('truetype');
}
@font-face {
    font-family: 'IMFePIrm29P';
    src: url('resources/font/IMFePIrm29P.ttf') format('truetype');
}

@import url('https://fonts.googleapis.com/css2?family=IM+Fell+English:ital@0;1&family=IM+Fell+English+SC&family=UnifrakturMaguntia&family=Merriweather:ital,wght@0,400;0,700;1,400&family=Crimson+Text:ital,wght@0,400;0,600;1,400&display=swap');
@import url('https://fonts.googleapis.com/css2?family=UnifrakturMaguntia&display=swap');


/* GLOBALNE USTAWIENIA */
/* GLOBALNE USTAWIENIA */
:root {
    --color-dark: #28241D;
    --color-paper: #E8DDCE;
    --color-bg-page: #E8DDCE; /* Tło strony takie jak tło obrazka */
    --color-bg-newspaper: #E8DDCE; /* Jasne tło gazety */
    --font-main: 'IMFePIrm29P', serif;
    --font-title: 'UnifrakturMaguntia', serif;
    --border-decorative: 2px solid var(--color-dark);
}

* {
    box-sizing: border-box;
}

body {
    background: var(--color-bg-page);
    font-family: var(--font-main);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 5px;
    overflow: auto;
    font-size: 25px;
}

/* Tło tylko dla podstron artykułów */
body.article-page {
    background: var(--color-bg-page) url('img/title_blur._hp.png') no-repeat center center;
    background-size: 20%;
    background-size: cover;
    background-attachment: fixed;
}

/* Globalny filtr dla wszystkich obrazków */
img {
    filter: sepia(0.15) contrast(1.02) brightness(0.98);
    border: 2px solid #000; /* czarna ramka dookoła wszystkich obrazków */
}

/* ========================================== */
/*          KONTENER GAZETY                   */
/* ========================================== */

.newspaper-container {
    max-width: 2100px;
    width: 100%;
    margin: 40px;
    padding: clamp(0.3rem, 1vw, 0.5rem) 30px;
    position: relative;
    overflow: visible;

    /* Tło i tekstura */
    background-color: var(--color-bg-newspaper);
    background-image:
        radial-gradient(ellipse at 15% 85%, rgba(130, 110, 80, 0.12) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(181, 163, 131, 0.1) 0%, transparent 70%),
        radial-gradient(ellipse at center, rgba(0, 0, 0, 0.05) 0%, rgba(0, 0, 0, 0.25) 100%);
    background-blend-mode: multiply, multiply, normal;

    /* Obramowanie */
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-left: 1px solid rgba(255, 255, 255, 0.15);

    /* Efekty - subtelne cienie dla jasnego tła */
    box-shadow:
        5px 8px 15px rgba(0, 0, 0, 0.15),
        -2px -2px 8px rgba(0, 0, 0, 0.08),
        0 10px 10px -5px rgba(0, 0, 0, 0.12);
    filter: sepia(0.15) contrast(1.02) brightness(0.98);
}

.newspaper-container::before,
.newspaper-container::after {
    content: "";
    position: absolute;
    pointer-events: none;
}

.newspaper-container::after {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    bottom: 0;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, transparent 50%, rgba(0, 0, 0, 0.1) 50%, rgba(0, 0, 0, 0.2) 60%, transparent 60%);
    transform: translateY(2px);
    z-index: 3;
}

.newspaper-container::before {
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.2) 5%, transparent 40%);
    z-index: 2;
    transform: perspective(300px) rotateX(15deg);
    transform-origin: bottom center;
    mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%), 
                linear-gradient(to top, transparent 0%, black 10%, white 90%, transparent 100%);
    mask-composite: intersect;
    filter: drop-shadow(0px -10px 15px rgba(0, 0, 0, 0.3));
}

/* ========================================== */
/*          MENU NAWIGACYJNE                  */
/* ========================================== */

.newspaper-menu {
    border-bottom: 2px double var(--color-dark);
    padding: 0.5rem 0 0.3rem 0;
    margin: 0.8rem 0;
    text-align: center;
    background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.03) 20%, rgba(0, 0, 0, 0.03) 80%, transparent 100%);
}

.newspaper-menu h3 {
    font-family: var(--font-title);
    font-size: 1.2rem;
    margin: 0 0 0.4rem 0;
    font-weight: normal;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--color-dark);
}

.newspaper-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.65rem;
    font-family: 'Courier New', Courier, monospace;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-weight: 600;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.4s ease, opacity 0.3s ease;
}

.newspaper-menu.mobile-expanded ul {
    max-height: 500px;
    opacity: 1;
}

.newspaper-menu.mobile-collapsed ul {
    max-height: 0;
    opacity: 0;
}

.newspaper-menu li {
    display: flex;
    align-items: center;
    position: relative;
    white-space: nowrap;
}

/* Kropki między elementami menu */
.newspaper-menu li:not(:last-child)::after {
    content: "•";
    margin: 0 0.5rem;
    color: var(--color-dark);
    font-weight: bold;
    font-size: 1.2em;
    position: relative;
    top: -2px;
}

.newspaper-menu a {
    color: var(--color-dark);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    border: 2px solid var(--color-dark);
    padding: 6px 12px;
    border-radius: 4px;
    display: inline-block;
}

.newspaper-menu a:hover {
    background-color: var(--color-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.nav-links a {
    font-family: var(--font-main);
    color: var(--color-dark);
    text-decoration: none;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    text-transform: uppercase;
    position: relative;
    transition: color 0.3s ease;
    margin: 0 15px; /* Zwiększony margines dla lepszego odstępu */
}

/* Kropka po każdym linku */
.nav-links a::after {
    content: "•";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: -20px; /* Pozycja kropki po prawej stronie */
    color: var(--color-dark);
}

/* Dodatkowa kropka przed pierwszym linkiem */
.nav-links a:first-child::before {
    content: "•";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: -20px; /* Pozycja kropki po lewej stronie */
    color: var(--color-dark);
}

.nav-links a:hover {
    color: #fff;
    background-color: var(--color-dark);
    text-shadow: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.page-number {
    font-style: italic;
    vertical-align: sub;
    font-size: 0.7em;
    display: none;
}

.newspaper-menu a[href*="registration"] {
    color: #000000;
    font-weight: 800;
    border: 3px double #000000;
    padding: 2px 4px;
    border-radius: 3px;
}

.newspaper-menu a[href*="registration"]:hover {
    color: #fff !important;
    background-color: var(--color-dark);
}

.newspaper-menu a[href*="registration"] .page-number {
    background: #000000;
    color: white;
    font-weight: bold;
}

.newspaper-menu a.special-article-link {
    border-style: solid;
    border-width: 2px;
}

.newspaper-menu a.special-article-link:hover {
    color: #fff;
    background-color: var(--color-dark);
}

.mobile-menu-toggle {
    display: none;
    background: #000;
    color: white;
    border: none;
    padding: 10px 15px;
    font-family: var(--font-main);
    font-size: 0.9em;
    cursor: pointer;
    border-radius: 3px;
    margin: 10px auto;
    font-weight: bold;
}

.newspaper-menu .registration-always-visible {
    display: none;
}

/* ========================================== */
/*         NAGŁÓWEK GAZETY                    */
/* ========================================== */

.newspaper-header {
    text-align: center;
    padding-bottom: 2px;
    margin-bottom: 0.2rem;
    position: relative;
    z-index: 100;
}

.header-top-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 10px;
    width: 100%;
    position: relative;
    z-index: 101;
}

.main-title {
    font-family: 'UnifrakturMaguntia', serif;
    font-size: clamp(2.5rem, 6vw, 5rem);
    margin: 0;
    font-weight: normal;
    color: var(--color-dark);
    padding: 0 20px;
    position: relative;
    z-index: 51;
    letter-spacing: 0.02em;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
    line-height: 1.1;
}

.title-with-wings {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    z-index: 50;
}

.header-decorations {
    position: relative;
    padding: 1px 0;
    height: auto;
    min-height: 70px;
    z-index: 50;
}

.weather-box,
.publisher-slogan {
    font-family: var(--font-main);
    color: var(--color-dark);
    border: var(--border-decorative);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    flex-shrink: 0;
    z-index: 102;
}

.weather-box::before,
.weather-box::after,
.publisher-slogan::before,
.publisher-slogan::after {
    content: "";
    position: absolute;
    width: 10px;
    height: 10px;
    border: var(--border-decorative);
}

.weather-box::before,
.publisher-slogan::before {
    top: -6px;
    left: -6px;
    border-right: none;
    border-bottom: none;
}

.weather-box::after,
.publisher-slogan::after {
    bottom: -6px;
    right: -6px;
    border-left: none;
    border-top: none;
}

.weather-box {
    width: clamp(50px, 8vw, 65px);
    height: clamp(50px, 8vw, 65px);
    flex-direction: column;
    font-size: clamp(0.5em, 1.2vw, 0.7em);
}

.publisher-slogan {
    font-style: italic;
    font-size: clamp(0.7em, 1.8vw, 1em);
    width: clamp(50px, 8vw, 65px);
    height: clamp(50px, 8vw, 65px);
    padding: 0;
    position: absolute;
    right: 10px;
    top: 10px;
    background-image: url('img/publisher-logo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    text-indent: -9999px;
    overflow: hidden;
}

.publication-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: var(--border-decorative);
    border-bottom: var(--border-decorative);
    padding: 2px 0;
    margin: 0.2rem 0;
    font-family: var(--font-main);
    font-size: clamp(0.7rem, 1.5vw, 0.8rem);
    font-weight: bold;
}

.publication-info p {
    margin: 0;
    color: var(--color-dark);
}

.quote-center {
    font-style: italic;
    text-align: center;
    flex-grow: 1;
    margin: 0 10px;
    color: var(--color-dark);
    font-weight: normal;
}

/* ========================================== */
/*         TREŚĆ GAZETY                       */
/* ========================================== */

.gazeta-content {
    margin: 0.2rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.main-content-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 0.3rem;
    align-items: flex-start;
}

.main-articles-container {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

.main-article {
    flex: 2;
    margin: 0;
    padding: 0.1rem 0.3rem 0.1rem 0.1rem;
}

.main-article h2 {
    font-family: var(--font-main);
    font-size: 3.2em;
    text-align: center;
    color: var(--color-dark);
    margin: 0.1rem 0;
    line-height: 0.85;
    text-transform: uppercase;
    font-weight: 900;
}

.second-article {
    width: 100%;
    padding: 0.1rem 0.3rem;
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

.second-article:last-child {
    border-bottom: none;
}

.second-article h3 {
    font-family: var(--font-main);
    font-size: 1.8em;
    margin-bottom: 0.2rem;
    margin-top: 0.1rem;
    color: var(--color-dark);
    text-transform: uppercase;
    line-height: 1.1;
    font-weight: bold;
    text-align: center;
}

.second-articles-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding-left: 10px;
}

.second-articles-decoration-top,
.second-articles-decoration-bottom {
    margin: 0;
    padding: 0;
    line-height: 0;
}

.second-articles-decoration-top {
    margin-bottom: 0.3rem;
}

.second-articles-decoration-bottom {
    margin-top: 0.3rem;
}

.second-articles-decoration-top .decoration-image,
.second-articles-decoration-bottom .decoration-image {
    width: 100%;
    height: auto;
    display: block;
    margin: 0;
    padding: 0;
}

.side-articles {
    column-count: 1;
    column-gap: 5px;
    margin: 0;
    padding: 0 0 0 0.2rem;
}

.side-article {
    padding: 0.1rem;
    margin-bottom: 0.2rem;
    break-inside: avoid;
    border-bottom: 0.5px solid #0000003d;
}

.side-article h3 {
    font-family: var(--font-main);
    font-size: 0.8em;
    margin-bottom: 0.1rem;
    color: var(--color-dark);
    text-transform: uppercase;
    line-height: 1.05;
    font-weight: bold;
}

.side-article .content {
    font-size: 0.65em;
    line-height: 1.2;
    margin-bottom: 0.1rem;
}

.bottom-articles {
    width: 100%;
    column-count: 3;
    column-gap: 17px;
    margin: 0.1rem;
    padding: 0;
}

.content {
    font-family: var(--font-main);
    line-height: 1.3;
    margin-bottom: 0.2rem;
    text-align: justify;
    color: var(--color-dark);
    font-size: 0.85em;
}

.author {
    font-family: var(--font-main);
    font-style: italic;
    text-align: right;
    font-size: 0.65em;
    color: var(--color-dark);
    margin-top: 0.1rem;
}

.read-more-btn {
    background: none;
    border: none;
    color: #0066cc;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 0.6em;
    padding: 0.2rem 0;
    margin: 0.2rem 0;
    text-decoration: underline;
    font-style: italic;
    transition: color 0.2s ease;
}

.read-more-btn:hover,
.read-more-btn:focus {
    color: #004499;
    outline: none;
}

/* Linki do artykułów */
.read-more-link {
    display: inline-block;
    color: #0066cc;
    font-family: var(--font-main);
    font-size: 0.85em;
    padding: 0.3rem 0;
    margin: 0.3rem 0;
    text-decoration: underline;
    font-style: italic;
    transition: color 0.2s ease;
}

.read-more-link:hover {
    color: #004499;
}

.article-title-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.article-title-link:hover {
    color: #0066cc;
}

/* Linki w tytułach artykułów - mają wyglądać jak zwykły tekst */
.main-article h2 a,
.second-article h3 a,
.side-article h3 a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.main-article h2 a:hover,
.second-article h3 a:hover,
.side-article h3 a:hover {
    opacity: 0.7;
}

/* Klikalne artykuły - cały artykuł jest linkiem */
.clickable-article {
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.clickable-article:hover {
    background-color: rgba(0, 102, 204, 0.02);
    transform: translateY(-1px);
}

.clickable-article:active {
    transform: translateY(0);
}

/* Style dla pełnej strony artykułu */
.article-full-content {
    line-height: 1.8;
}

.article-full-content .article-image {
    max-width: 100%;
    height: auto;
    margin: 2rem 0;
    border: 2px solid #000; /* czarna ramka w pełnym artykule */
    padding: 5px;
    background: var(--color-bg-newspaper);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.article-full-content .article-author {
    margin-top: 2rem;
    font-style: italic;
    color: #666;
    font-size: 0.9em;
}

/* ========================================== */
/*         MODAL ARTYKUŁU                     */
/* ========================================== */

.article-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.article-modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(44, 36, 22, 0.85);
    cursor: pointer;
}

.modal-content {
    position: relative;
    background: #f9f6f0;
    background-image: 
        linear-gradient(180deg, rgba(255, 248, 220, 0.8) 0%, rgba(245, 235, 210, 0.9) 50%, rgba(240, 228, 200, 0.8) 100%),
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.01) 2px, rgba(0, 0, 0, 0.01) 4px);
    max-width: 900px;
    max-height: 85vh;
    width: 90%;
    border: 4px double #2c2416;
    box-shadow: 0 0 0 1px #8b7355, 0 0 0 8px #f9f6f0, 0 0 0 12px #2c2416, 
                inset 0 0 30px rgba(139, 115, 85, 0.15), 0 20px 60px rgba(0, 0, 0, 0.6), 
                0 40px 100px rgba(0, 0, 0, 0.4);
    z-index: 10001;
    overflow-y: auto;
    overflow-x: hidden;
    filter: sepia(0.1) contrast(1.05);
    animation: unfoldNewspaper 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: #8b7355 #e8e3d5;
}

@keyframes unfoldNewspaper {
    0% { opacity: 0; transform: perspective(1000px) rotateX(-20deg) scale(0.8); }
    50% { transform: perspective(1000px) rotateX(5deg) scale(1.02); }
    100% { opacity: 1; transform: perspective(1000px) rotateX(0deg) scale(1); }
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    background: #2c2416;
    color: #f9f6f0;
    border: 2px solid #8b7355;
    font-size: 28px;
    font-weight: bold;
    font-family: 'Times New Roman', serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10002;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 2px 4px rgba(0, 0, 0, 0.4);
}

.modal-close:hover {
    background: #3d3120;
    color: #d4af37;
    border-color: #d4af37;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 4px 8px rgba(0, 0, 0, 0.5);
}

.modal-close:active {
    transform: translateY(1px);
}

.modal-content::-webkit-scrollbar {
    width: 16px;
}

.modal-content::-webkit-scrollbar-track {
    background: #e8e3d5;
    border-left: 2px solid #8b7355;
    box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.1);
}

.modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #8b7355 0%, #6d5a42 100%);
    border: 2px solid #e8e3d5;
    border-radius: 2px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #6d5a42 0%, #5a4835 100%);
}

.modal-article {
    padding: 50px 60px;
    position: relative;
}

.modal-article::before,
.modal-article::after {
    content: '✦';
    position: absolute;
    font-size: 20px;
    color: #8b7355;
    opacity: 0.5;
}

.modal-article::before {
    top: 30px;
    left: 30px;
}

.modal-article::after {
    top: 30px;
    right: 30px;
}

.modal-article h2 {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 2.2em;
    font-weight: 600;
    margin: 10px 0 25px;
    color: #2c2416;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 3px;
    border-bottom: 3px double #2c2416;
    padding-bottom: 20px;
    position: relative;
}

.modal-article h2::before,
.modal-article h2::after {
    content: '◆';
    position: absolute;
    bottom: -10px;
    font-size: 16px;
    color: #8b7355;
}

.modal-article h2::before {
    left: 50%;
    transform: translateX(-30px);
}

.modal-article h2::after {
    left: 50%;
    transform: translateX(14px);
}

.modal-text {
    font-family: 'Merriweather', Georgia, 'Times New Roman', serif;
    font-size: 1.05em;
    line-height: 1.8;
    margin-bottom: 25px;
    text-align: justify;
    color: #2c2416;
    text-indent: 2em;
    hyphens: auto;
}

.modal-text:first-of-type::first-letter {
    font-size: 3.5em;
    font-family: 'Crimson Text', Georgia, serif;
    font-weight: 600;
    float: left;
    line-height: 0.85;
    margin: 0.05em 0.1em 0 0;
    color: #2c2416;
}

.modal-author {
    font-family: 'Merriweather', Georgia, serif;
    font-style: italic;
    text-align: right;
    font-size: 1em;
    color: #2c2416;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #8b7355;
}

.modal-author::before {
    content: '— ';
}

.modal-back-btn {
    display: block;
    width: calc(100% - 120px);
    margin: 30px 60px 50px;
    padding: 18px 40px;
    background: #2c2416;
    color: #f9f6f0;
    border: 3px double #8b7355;
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.15em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 4px 8px rgba(0, 0, 0, 0.3);
}

.modal-back-btn:hover {
    background: #3d3120;
    color: #d4af37;
    border-color: #d4af37;
    transform: translateY(-2px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 6px 16px rgba(0, 0, 0, 0.4);
}

.modal-back-btn:active {
    transform: translateY(0);
}

/* ========================================== */
/*         EFEKT ROZMYCIA                     */
/* ========================================== */

.blurred-article h3,
.blurred-article .author {
    filter: blur(4px);
}

.blurred-article .content {
    user-select: none;
    filter: blur(4px);
    pointer-events: none;
}

.blurred-article .content::selection {
    background: transparent;
}

/* ========================================== */
/*         OBRAZEK W ARTYKULE                 */
/* ========================================== */

.article-image-wrapper {
    float: left;
    margin: 0 1.5rem 1rem 0;
    max-width: 400px;
    width: 45%;
}

.article-image {
    width: 100%;
    height: auto;
    display: block;
    /* filter: grayscale(1) sepia(0.5) contrast(1.15) brightness(0.9); */
    transition: none; /* usuń animację hover */
    border: 2px solid #000; /* czarna ramka */
}

/* ========================================== */
/*         SEKCJA CUTOUT                      */
/* ========================================== */

.cutout-section {
    flex: 1;
    padding-left: 20px;
    font-family: 'Courier New', Courier, monospace;
}

.cutout-border {
    border: 2px dashed var(--color-dark);
    padding: 15px;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.stamp-box {
    border: 2px solid var(--color-dark);
    padding: 5px 10px;
    text-align: center;
    margin-bottom: 15px;
    display: inline-block;
}

.stamp-title {
    font-weight: bold;
    font-size: 1.2em;
    margin: 0;
    letter-spacing: 1px;
}

.stamp-subtitle {
    margin: 0;
    font-size: 0.9em;
}

.cutout-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
}

.cutout-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9em;
}

.cutout-list li {
    margin-bottom: 5px;
}

.image-placeholder {
    border: 2px solid var(--color-dark);
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.8em;
    color: #555;
    padding: 10px;
}

.cutout-corner {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 0 80px 80px;
    border-color: transparent transparent var(--color-paper) transparent;
}

.cutout-corner::before {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 113px;
    height: 2px;
    background: var(--color-dark);
    transform-origin: bottom right;
    transform: rotate(-45deg) translate(-33px, -1px);
    border: 2px dashed var(--color-dark) 0 0;
}

.cutout-corner span {
    position: absolute;
    bottom: 15px;
    right: 5px;
    transform: rotate(-45deg);
    font-weight: bold;
    font-size: 1em;
}

/* ========================================== */
/*         PRZEŁĄCZNIK JĘZYKÓW                */
/* ========================================== */

.language-box {
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 2px;
    background: rgba(0, 0, 0, 0.05);
    padding: 8px 15px;
    border: 2px solid #2c2416;
    border-radius: 3px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 2px 4px rgba(0, 0, 0, 0.3);
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10000;
    min-width: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lang-link {
    color: #2c2416;
    text-decoration: none;
    padding: 4px 8px;
    transition: all 0.3s ease;
    font-weight: bold;
    cursor: pointer;
}

.lang-link:hover {
    color: #8b7355;
    text-shadow: 0 0 3px rgba(139, 115, 85, 0.5);
    background: rgba(139, 115, 85, 0.1);
}

.lang-link.active {
    color: #d4af37;
    text-shadow: 0 0 5px rgba(212, 175, 55, 0.4);
    background: rgba(212, 175, 55, 0.1);
    border-bottom: 2px solid #d4af37;
}

.lang-separator {
    color: #8b7355;
    margin: 0 5px;
    opacity: 0.6;
}

/* ========================================== */
/*         PRZYCISK POWROTU                   */
/* ========================================== */

.back-link {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 10001;
    display: inline-block;
    padding: 15px 20px;
    background: #fff;
    color: #000;
    text-decoration: none;
    border: 5px double #000;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.back-link:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

/* ========================================== */
/*         STYLOWANIE PODSTRON                */
/* ========================================== */

.subpage-container {
    max-width: 900px;
    margin: 40px auto;
    padding: 40px;
    background: var(--color-bg-newspaper);
    border: var(--border-decorative);
    font-family: var(--font-main);
    box-shadow: 
        5px 8px 15px rgba(0, 0, 0, 0.15),
        -2px -2px 8px rgba(0, 0, 0, 0.08);
}

.subpage-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: var(--border-decorative);
}

.subpage-header h1 {
    font-family: var(--font-title);
    font-size: 2.5rem;
    margin: 0;
    color: var(--color-dark);
}

.subpage-content {
    line-height: 1.6;
    color: var(--color-dark);
}

.subpage-content h3 {
    font-family: var(--font-main);
    font-size: 1.5rem;
    margin: 20px 0 10px;
    font-weight: bold;
}

.subpage-content ul, .subpage-content ol {
    margin: 15px 0;
    padding-left: 30px;
}

.subpage-content li {
    margin: 8px 0;
}

.language-switcher {
    text-align: center;
    margin-bottom: 20px;
}

.language-switcher a {
    margin: 0 10px;
    text-decoration: none;
    color: var(--color-dark);
    font-weight: bold;
    padding: 5px 10px;
    border: 1px solid var(--color-dark);
    border-radius: 3px;
}

.language-switcher a.active {
    background: var(--color-dark);
    color: white;
}

.language-switcher a:hover {
    background: #444;
    color: white;
}

/* ========================================== */
/*         RESPONSIVE DESIGN                  */
/* ========================================== */

@media screen and (min-width: 769px) {
    .mobile-menu-toggle { display: none !important; }
    .newspaper-menu ul {
        display: flex !important;
        flex-wrap: wrap !important;
        max-height: none !important;
        opacity: 1 !important;
        overflow: visible !important;
        justify-content: center !important;
        gap: 0.5rem 1rem !important;
        padding: 10px 0 !important;
        font-size: 1.4rem !important;
    }
    .newspaper-menu.mobile-collapsed ul,
    .newspaper-menu.mobile-expanded ul {
        display: flex !important;
        max-height: none !important;
        opacity: 1 !important;
    }
    .newspaper-menu .registration-always-visible { display: none !important; }
    .newspaper-menu ul li:first-child { display: flex !important; }
    .newspaper-menu a { font-size: 1rem !important; }
}

@media (min-width: 1800px) {
    .bottom-articles { column-count: 7; }
    .side-articles { column-count: 2; }
}

@media (min-width: 1600px) and (max-width: 1799px) {
    .bottom-articles { column-count: 6; }
    .side-articles { column-count: 2; }
}

@media (min-width: 1400px) and (max-width: 1599px) {
    .bottom-articles { column-count: 5; }
}

@media (min-width: 1024px) and (max-width: 1399px) {
    .bottom-articles { column-count: 4; }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .bottom-articles { column-count: 3; }
}

@media (max-width: 1200px) {
    body { padding: 5px clamp(20px, 5vw, 40px); }
    .newspaper-container { max-width: 100%; margin: 0 auto; }
    .side-articles { column-count: 2; column-gap: 12px; }
    .bottom-articles { column-count: 3; }
    .header-top-row { flex-direction: column; align-items: center; gap: 10px; }
    .language-box {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        order: -1;
        font-size: 13px;
        padding: 6px 12px;
        letter-spacing: 1.5px;
        margin-bottom: 10px;
    }
    .back-link { top: 15px; left: 15px; padding: 10px 20px; font-size: 0.9rem; }
}

@media (max-width: 767px) {
    .bottom-articles { column-count: 2; }
    .newspaper-container::before {
        height: 60px;
        transform: perspective(200px) rotateX(10deg);
        filter: drop-shadow(0px -5px 10px rgba(0, 0, 0, 0.25));
    }
    .newspaper-container::after { width: 50px; height: 50px; }
}

@media (max-width: 768px) {
    .mobile-menu-toggle { display: block; }
    .newspaper-menu ul { flex-direction: column; align-items: center; gap: 0.5rem; }
    .newspaper-menu.mobile-collapsed ul { max-height: 0; opacity: 0; padding: 0; }
    .newspaper-menu.mobile-expanded ul {
        display: flex;
        max-height: 500px;
        opacity: 1;
        padding: 10px 0;
    }
    .newspaper-menu.mobile-expanded ul::-webkit-scrollbar { display: none; }
    .newspaper-menu .registration-always-visible {
        display: block;
        margin-bottom: 10px;
        text-align: center;
    }
    .newspaper-menu .registration-always-visible a {
        color: #000000 !important;
        font-weight: 800;
        border: 3px double #000000;
        padding: 2px 4px;
        border-radius: 3px;
    }
    .newspaper-menu ul li:first-child { display: none; }
    .newspaper-menu li { white-space: normal; text-align: center; width: 100%; }
    .newspaper-menu li:not(:last-child)::after { display: none; }
    .publisher-slogan, .weather-box { display: none; }
    
    body { padding: 5px clamp(15px, 4vw, 30px); }
    .newspaper-container { padding: clamp(0.5rem, 4vw, 1rem) 10px; }
    .header-decorations { min-height: 20px; margin-bottom: 1rem; }
    .main-title { text-align: center; padding: 0 10px; margin: 0; }
    .publication-info { flex-direction: column; gap: 0.2rem; text-align: center; }
    .quote-center { margin: 0; }
    .gazeta-content, .main-content-row, .main-articles-container { flex-direction: column; gap: 0; }
    .main-content-row { display: flex; }
    .main-article { margin: 0.3rem; padding: 0.3rem; }
    .second-article { padding-left: 0; }
    .side-articles { column-count: 1; margin: 0.2rem; padding-left: 0; }
    .bottom-articles { column-count: 1; margin: 0.2rem; }
    .article-image-wrapper { float: none; margin: 1rem 0; max-width: 100%; width: 100%; }
    .pegasus-wing { display: none; }
    .title-with-wings { padding: 10px 0; }
    
    .language-box {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        order: -1;
        font-size: 12px;
        padding: 6px 10px;
        letter-spacing: 1px;
        margin-bottom: 15px;
        border: 1px solid #2c2416;
    }
    .lang-link { padding: 3px 6px; font-size: 12px; }
    .lang-separator { margin: 0 3px; }
    .back-link { top: 10px; left: 10px; padding: 10px 16px; font-size: 0.85rem; }
    
    .modal-content {
        width: 95%;
        max-height: 90vh;
        border-width: 3px;
        box-shadow: 0 0 0 1px #8b7355, 0 0 0 6px #f9f6f0, 0 0 0 9px #2c2416, 
                    inset 0 0 20px rgba(139, 115, 85, 0.15), 0 15px 40px rgba(0, 0, 0, 0.6);
    }
    .modal-content::-webkit-scrollbar { width: 12px; }
    .modal-article { padding: 35px 25px; }
    .modal-article::before, .modal-article::after { font-size: 16px; top: 20px; }
    .modal-article::before { left: 15px; }
    .modal-article::after { right: 15px; }
    .modal-article h2 { font-size: 1.6em; letter-spacing: 1px; }
    .modal-text { font-size: 0.95em; text-indent: 1.5em; }
    .modal-text:first-of-type::first-letter { font-size: 2.8em; }
    .modal-close { width: 38px; height: 38px; font-size: 24px; top: 15px; right: 15px; }
    .modal-back-btn { width: calc(100% - 50px); margin: 20px 25px 35px; padding: 15px 25px; font-size: 1em; letter-spacing: 1px; }
    .subpage-container { margin: 80px 15px 20px; }
}

@media (max-width: 480px) {
    .newspaper-menu ul { padding: 0 15px; gap: 0.8rem; font-size: 1.4rem; }
    .newspaper-menu li:not(:last-child)::after { margin: 0 0.6rem; font-size: 1.6rem; }
    .newspaper-container { padding: 0.5rem; }
    .main-title { font-size: clamp(1.5rem, 6vw, 3rem); padding: 0 20px; }
    .main-article h2 { font-size: clamp(2rem, 8vw, 4rem); }
    .side-article { padding: 0.2rem 0.1rem; }
    .header-decorations { min-height: 20px; }
    
    .language-box {
        position: relative !important;
        font-size: 11px;
        padding: 5px 8px;
        letter-spacing: 0.5px;
        margin-bottom: 10px;
    }
    .lang-link { padding: 2px 4px; font-size: 11px; }
    .lang-separator { margin: 0 2px; }
    .back-link { top: 8px; left: 8px; padding: 8px 12px; font-size: 0.8rem; }
    
    .modal-article { padding: 25px 18px; }
    .modal-article h2 { font-size: 1.3em; letter-spacing: 0.5px; padding-bottom: 15px; }
    .modal-text { font-size: 0.9em; text-indent: 1em; line-height: 1.6; }
    .modal-text:first-of-type::first-letter { font-size: 2.5em; }
    .modal-close { width: 35px; height: 35px; font-size: 22px; top: 12px; right: 12px; }
    .modal-back-btn { width: calc(100% - 36px); margin: 15px 18px 25px; padding: 12px 20px; font-size: 0.9em; }
    .subpage-container { margin: 70px 10px 20px; }
}

/* ========================================== */
/*   STYLIZACJA ARTICLE.PHP I PODSTRON       */
/* ========================================== */

/* Kontener artykułu - stylizowany jak gazeta */
.article-page-container,
.subpage-container {
    max-width: 2100px;
    width: calc(100% - 300px);
    margin: 40px auto;
    padding: clamp(0.3rem, 1vw, 0.5rem) 30px;
    position: relative;
    overflow: visible;

    /* Tło i tekstura jak w głównej gazecie */
    background-color: var(--color-bg-newspaper);
    background-image:
        radial-gradient(ellipse at 15% 85%, rgba(130, 110, 80, 0.12) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(181, 163, 131, 0.1) 0%, transparent 70%),
        radial-gradient(ellipse at center, rgba(0, 0, 0, 0.05) 0%, rgba(0, 0, 0, 0.25) 100%);
    background-blend-mode: multiply, multiply, normal;

    /* Obramowanie */
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-left: 1px solid rgba(255, 255, 255, 0.15);

    /* Efekty - jak w głównej gazecie */
    box-shadow:
        5px 8px 15px rgba(0, 0, 0, 0.15),
        -2px -2px 8px rgba(0, 0, 0, 0.08),
        0 10px 10px -5px rgba(0, 0, 0, 0.12);
    filter: sepia(0.15) contrast(1.02) brightness(0.98);
}

/* Efekty before/after dla article-page-container */
.article-page-container::before {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.2) 5%, transparent 40%);
    z-index: 2;
    transform: perspective(300px) rotateX(15deg);
    transform-origin: bottom center;
    mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%), 
                linear-gradient(to top, transparent 0%, black 10%, white 90%, transparent 100%);
    mask-composite: intersect;
    filter: drop-shadow(0px -10px 15px rgba(0, 0, 0, 0.3));
    pointer-events: none;
}

.article-page-container::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    bottom: 0;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, transparent 50%, rgba(0, 0, 0, 0.1) 50%, rgba(0, 0, 0, 0.2) 60%, transparent 60%);
    transform: translateY(2px);
    z-index: 3;
    pointer-events: none;
}

/* Nagłówek artykułu */
.article-page-header {
    text-align: center;
    padding-bottom: 20px;
    margin-bottom: 30px;
    border-bottom: var(--border-decorative);
}

.article-page-header h1 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 5vw, 4rem);
    margin: 20px 0;
    font-weight: normal;
    color: var(--color-dark);
    letter-spacing: 0.02em;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
    line-height: 1.1;
    text-transform: uppercase;
}

/* Informacje o publikacji */
.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: var(--border-decorative);
    border-bottom: var(--border-decorative);
    padding: 8px 0;
    margin: 15px 0;
    font-family: var(--font-main);
    font-size: clamp(0.7rem, 1.5vw, 0.9rem);
    font-weight: bold;
    color: var(--color-dark);
}

.article-meta p {
    margin: 0;
}

/* Treść artykułu */
.article-full-content {
    font-family: var(--font-main);
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    line-height: 1.8;
    color: var(--color-dark);
    text-align: justify;
    margin: 30px 0;
}

.article-full-content p {
    margin-bottom: 1.5rem;
    text-indent: 2em;
}

.article-full-content p:first-of-type::first-letter {
    font-size: 3.5em;
    font-family: 'Crimson Text', Georgia, serif;
    font-weight: 600;
    float: left;
    line-height: 0.85;
    margin: 0.05em 0.1em 0 0;
    color: var(--color-dark);
}

/* Obrazki w artykule */
.article-full-content .article-image {
    max-width: 100%;
    height: auto;
    margin: 2rem 0;
    border: 2px solid #000; /* czarna ramka w pełnym artykule */
    padding: 5px;
    background: var(--color-bg-newspaper);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Autor artykułu */
.article-full-content .article-author {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 2px solid var(--color-dark);
    font-style: italic;
    text-align: right;
    font-size: 1em;
    color: var(--color-dark);
}

.article-full-content .article-author::before {
    content: '— ';
}

/* Stylizacja dla podstron */
.subpage-header h1 {
    font-family: var(--font-title);
    font-size: clamp(2rem, 5vw, 3rem);
    margin: 0 0 20px 0;
    color: var(--color-dark);
    letter-spacing: 0.02em;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.subpage-content {
    font-family: var(--font-main);
    font-size: clamp(0.9rem, 2vw, 1.05rem);
    line-height: 1.7;
    color: var(--color-dark);
}

.subpage-content h2,
.subpage-content h3 {
    font-family: var(--font-main);
    color: var(--color-dark);
    margin: 25px 0 15px;
    font-weight: bold;
}

.subpage-content h2 {
    font-size: 1.8rem;
    border-bottom: 2px solid var(--color-dark);
    padding-bottom: 10px;
}

.subpage-content h3 {
    font-size: 1.4rem;
}

.subpage-content ul,
.subpage-content ol {
    margin: 20px 0;
    padding-left: 40px;
}

.subpage-content li {
    margin: 10px 0;
    line-height: 1.6;
}

/* Responsive dla article.php i podstron */
@media (max-width: 1024px) {
    .article-page-container,
    .subpage-container {
        width: calc(100% - 20px);
        margin: 30px auto;
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .article-page-container,
    .subpage-container {
        width: calc(100% - 20px);
        margin: 20px auto;
        padding: 15px;
    }

    .article-page-container::before {
        height: 60px;
        transform: perspective(200px) rotateX(10deg);
    }

    .article-page-container::after {
        width: 50px;
        height: 50px;
    }

    .article-page-header h1,
    .subpage-header h1 {
        font-size: clamp(1.5rem, 6vw, 2.5rem);
    }

    .article-full-content,
    .subpage-content {
        font-size: clamp(0.85rem, 2vw, 1rem);
    }

    .article-full-content p:first-of-type::first-letter {
        font-size: 2.8em;
    }

    .article-meta {
        flex-direction: column;
        gap: 5px;
        text-align: center;
        font-size: 0.8rem;
    }
    
    .subpage-content h2 {
        font-size: 1.4rem;
    }
    
    .subpage-content h3 {
        font-size: 1.2rem;
    }
    
    .subpage-content ul,
    .subpage-content ol {
        padding-left: 25px;
    }
}

@media (max-width: 480px) {
    .article-page-container,
    .subpage-container {
        width: calc(100% - 10px);
        margin: 10px auto;
        padding: 10px;
    }
    
    .article-page-container::before {
        height: 40px;
        transform: perspective(150px) rotateX(8deg);
    }

    .article-page-container::after {
        width: 40px;
        height: 40px;
    }

    .article-full-content p {
        text-indent: 1em;
    }

    .article-full-content p:first-of-type::first-letter {
        font-size: 2.5em;
    }
    
    .article-page-header h1,
    .subpage-header h1 {
        font-size: clamp(1.3rem, 7vw, 2rem);
        margin: 10px 0;
    }
    
    .article-meta {
        font-size: 0.7rem;
        padding: 6px 0;
        margin: 10px 0;
    }
    
    .subpage-content h2 {
        font-size: 1.2rem;
        margin: 20px 0 10px;
    }
    
    .subpage-content h3 {
        font-size: 1rem;
        margin: 15px 0 8px;
    }
    
    .subpage-content ul,
    .subpage-content ol {
        padding-left: 20px;
        margin: 15px 0;
    }
    
    .subpage-content li {
        margin: 8px 0;
        font-size: 0.9rem;
    }
}

.glod-link, .glod-link:visited {
    text-decoration: none;
    text-shadow: 0 0 5px #b12B34, 0 0 10px #b12B34;
    color: inherit;
}

.second_article img
{
	border: 0;
	border-radius: 1em;
	padding: 0;
}

.decoration-image
{
	display: block;
	margin-left: auto;
	margin-right: auto;
	width: 50%;
	border: 0;
	border-radius: 1em;
	padding: 0;
	margin-top: 1em;
}