@charset "UTF-8";

/* =========================================
   RapidNews - CUSTOM EDITORIAL STYLE
   Palette: Deep Blue & Mustard Yellow
   Framework Base: Bootstrap 5.x
========================================= */

/* --- 1. CSS VARIABLES & THEME --- */
:root {
    /* Палитра */
    --w24-blue: #951717;
    --w24-blue-dark: #3b0606;
    --w24-blue-light: #6f821a;
    --w24-yellow: #a5e51a;
    --w24-yellow-hover: #c9bd15;
    
    /* Фоны и текст */
    --w24-bg-paper: #dbd8d3; /* Цвет газетной бумаги */
    --w24-bg-white: #eae5e5;
    --w24-text-main: #1c1c1b;
    --w24-text-muted: #838380;
    --w24-border: #71706e;

    /* Типографика */
    --w24-font-display: 'Playfair Display', Georgia, serif;
    --w24-font-body: 'Lora', 'Times New Roman', serif;
    --w24-font-ui: 'Inter', Helvetica, sans-serif;

    /* Отступы для кастомной сетки */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1.5rem;
    --spacing-md: 3rem;
    --spacing-lg: 5rem;
    --spacing-xl: 8rem;
}

/* --- 2. GLOBAL OVERRIDES & BOOTSTRAP TWEAKS --- */
body {
    background-color: var(--w24-bg-paper);
    color: var(--w24-text-main);
    font-family: var(--w24-font-body);
    font-size: 1.1rem;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3 {
    font-family: var(--w24-font-display);
    color: var(--w24-blue);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

a {
    color: var(--w24-blue);
    text-decoration: none;
    background-image: linear-gradient(var(--w24-yellow), var(--w24-yellow));
    background-position: 0% 100%;
    background-repeat: no-repeat;
    background-size: 0% 2px;
    transition: background-size 0.3s ease, color 0.3s ease;
}

a:hover {
    color: var(--w24-blue-dark);
    background-size: 100% 2px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

::selection {
    background-color: var(--w24-yellow);
    color: var(--w24-blue-dark);
}

/* Скрываем типичные скругления Bootstrap */
.card, .btn, .form-control, .badge {
    border-radius: 0 !important;
}

/* --- 3. CUSTOM HEADER & NAVIGATION --- */
.editorial-header {
    background-color: var(--w24-bg-paper);
    border-bottom: 2px solid var(--w24-blue);
    padding: var(--spacing-sm) 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.editorial-header .navbar-brand {
    font-family: var(--w24-font-display);
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--w24-blue);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.editorial-header .navbar-brand span {
    color: var(--w24-yellow);
}

.editorial-header .nav-link {
    font-family: var(--w24-font-ui);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--w24-text-main);
    padding: 0.5rem 1rem;
    margin: 0 0.2rem;
}

.editorial-header .nav-link:hover,
.editorial-header .nav-link.active {
    color: var(--w24-blue);
    background-color: var(--w24-yellow);
    background-image: none; /* Убираем подчеркивание для ссылок меню */
}

/* --- 4. HERO SECTIONS (MAGAZINE STYLE) --- */
.hero-magazine {
    padding: var(--spacing-lg) 0;
    border-bottom: 1px solid var(--w24-border);
    margin-bottom: var(--spacing-md);
}

.hero-magazine .category-tag {
    display: inline-block;
    font-family: var(--w24-font-ui);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--w24-yellow);
    letter-spacing: 2px;
    margin-bottom: 1rem;
    border: 1px solid var(--w24-yellow);
    padding: 0.2rem 0.8rem;
}

.hero-magazine h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    margin-bottom: 1.5rem;
}

.hero-magazine .lead-text {
    font-size: 1.3rem;
    color: var(--w24-text-muted);
    border-left: 4px solid var(--w24-yellow);
    padding-left: 1.5rem;
    margin-bottom: 2rem;
}

.hero-image-wrapper {
    position: relative;
}

.hero-image-wrapper::after {
    content: '';
    position: absolute;
    bottom: -15px;
    right: -15px;
    width: 100%;
    height: 100%;
    border: 2px solid var(--w24-blue);
    z-index: -1;
}

/* --- 5. ASYMMETRICAL GRID & CARDS --- */
.editorial-grid {
    display: flex;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: var(--spacing-xl);
}

.news-card-editorial {
    background-color: var(--w24-bg-white);
    border: none;
    border-top: 4px solid transparent;
    transition: transform 0.3s ease, border-top-color 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.news-card-editorial:hover {
    transform: translateY(-5px);
    border-top-color: var(--w24-yellow);
}

.news-card-editorial .card-img-top {
    height: 280px;
    object-fit: cover;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.news-card-editorial:hover .card-img-top {
    filter: grayscale(0%);
}

.news-card-editorial .card-body {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-card-editorial .card-title {
    font-size: 1.6rem;
    margin-bottom: 1rem;
}

.news-card-editorial .card-text {
    font-size: 1rem;
    color: var(--w24-text-muted);
    flex-grow: 1;
}

.news-meta {
    font-family: var(--w24-font-ui);
    font-size: 0.8rem;
    color: var(--w24-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--w24-border);
    padding-top: 1rem;
}

/* --- 6. LONG-READ / ARTICLE TYPOGRAPHY --- */
.article-content {
    max-width: 850px;
    margin: 0 auto;
    padding: var(--spacing-md) 0;
}

.article-content p {
    margin-bottom: 2rem;
    font-size: 1.15rem;
}

/* Буквица для начала статьи */
.drop-cap::first-letter {
    float: left;
    font-size: 6rem;
    line-height: 0.8;
    padding-top: 4px;
    padding-right: 8px;
    padding-left: 3px;
    font-family: var(--w24-font-display);
    color: var(--w24-yellow);
    font-weight: 900;
}

/* Большие выноски / Цитаты */
.pull-quote {
    font-family: var(--w24-font-display);
    font-size: 2.2rem;
    color: var(--w24-blue);
    line-height: 1.4;
    text-align: center;
    margin: var(--spacing-md) 0;
    padding: var(--spacing-sm) 0;
    border-top: 1px solid var(--w24-yellow);
    border-bottom: 1px solid var(--w24-yellow);
    font-style: italic;
}

.pull-quote span {
    display: block;
    font-family: var(--w24-font-ui);
    font-size: 0.9rem;
    font-style: normal;
    color: var(--w24-text-muted);
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Изображения внутри статей, ломающие сетку */
.article-image-breakout {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.article-image-breakout img {
    width: 100%;
    height: 60vh;
    object-fit: cover;
}

.image-caption {
    font-family: var(--w24-font-ui);
    font-size: 0.85rem;
    color: var(--w24-text-muted);
    text-align: right;
    margin-top: 0.5rem;
    padding-right: 1rem;
    border-right: 2px solid var(--w24-yellow);
}

/* --- 7. CUSTOM UI ELEMENTS (Buttons, Forms, Alerts) --- */
.btn-editorial {
    font-family: var(--w24-font-ui);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 1rem 2.5rem;
    background-color: var(--w24-blue);
    color: var(--w24-bg-white);
    border: 2px solid var(--w24-blue);
    transition: all 0.3s ease;
}

.btn-editorial:hover {
    background-color: var(--w24-yellow);
    border-color: var(--w24-yellow);
    color: var(--w24-blue-dark);
}

.btn-editorial-outline {
    background-color: transparent;
    color: var(--w24-blue);
    border: 2px solid var(--w24-blue);
}

.btn-editorial-outline:hover {
    background-color: var(--w24-blue);
    color: var(--w24-bg-white);
}

/* Формы (для страницы контактов) */
.editorial-form .form-control {
    background-color: transparent;
    border: none;
    border-bottom: 2px solid var(--w24-border);
    padding: 1rem 0;
    font-family: var(--w24-font-ui);
    font-size: 1.1rem;
    color: var(--w24-text-main);
    transition: border-color 0.3s ease;
}

.editorial-form .form-control:focus {
    box-shadow: none;
    border-bottom-color: var(--w24-yellow);
    background-color: rgba(229, 169, 26, 0.05);
}

.editorial-form label {
    font-family: var(--w24-font-ui);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--w24-blue);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0;
}

/* --- 8. FOOTER --- */
.editorial-footer {
    background-color: var(--w24-blue-dark);
    color: var(--w24-bg-paper);
    padding: var(--spacing-lg) 0 var(--spacing-sm);
    margin-top: var(--spacing-xl);
    border-top: 5px solid var(--w24-yellow);
}

.editorial-footer h5 {
    color: var(--w24-yellow);
    font-family: var(--w24-font-ui);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.editorial-footer p {
    font-family: var(--w24-font-body);
    font-size: 0.95rem;
    opacity: 0.8;
}

.editorial-footer a {
    color: var(--w24-bg-paper);
    background-image: none;
    font-family: var(--w24-font-ui);
    font-size: 0.9rem;
    opacity: 0.8;
}

.editorial-footer a:hover {
    color: var(--w24-yellow);
    opacity: 1;
}

.footer-domain-watermark {
    font-family: var(--w24-font-display);
    font-size: clamp(3rem, 10vw, 8rem);
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    line-height: 1;
    margin-top: var(--spacing-md);
    user-select: none;
}

.footer-bottom {
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-family: var(--w24-font-ui);
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

/* --- 9. UTILITIES & ANIMATIONS --- */
.bg-blue { background-color: var(--w24-blue) !important; color: white; }
.bg-yellow { background-color: var(--w24-yellow) !important; color: var(--w24-blue-dark); }
.text-blue { color: var(--w24-blue) !important; }
.text-yellow { color: var(--w24-yellow) !important; }

.fade-in-up {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}