/* ───────────────────────────────────────────────────────────
   Site-wide styles ported from app/globals.css.
   Tailwind utilities themselves are loaded via the Play CDN
   in the layout; this file only carries CSS variables and the
   custom rules Tailwind cannot express.
   ─────────────────────────────────────────────────────────── */

:root {
    --background: #f7d397;
    --foreground: #2d2d2d;
    --heading-color: #1a1a1a;
    --footer-bg: #0f0f23;
    --menu-active: #4a90d9;
    --text-hot: #64b5f6;
    --nav-link: #90caf9;
    --btn-more: #ffd54f;
    --bg-top-image: url(img2/default/Top.webp);
    --bg-bot-image: url(img2/default/Bot.webp);
}

[data-theme="tet2026"] {
    --background: #fea4b3;
    --foreground: #171717;
    --heading-color: #171717;
    --footer-bg: #441636;
    --menu-active: #da3000;
    --text-hot: #f8587c;
    --nav-link: #003600;
    --btn-more: #fbc76e;
    --bg-top-image: url(img2/tet2026/Top.webp);
    --bg-bot-image: url(img2/tet2026/Bot.webp);
}

[data-theme="v1"] {
    --background: #f7d397;
    --foreground: #2d2d2d;
    --heading-color: #1a1a1a;
    --footer-bg: #0f0f23;
    --menu-active: #4a90d9;
    --text-hot: #64b5f6;
    --nav-link: #90caf9;
    --btn-more: #fbc76e;
    --bg-top-image: url(img2/v1/Top.webp?v=1);
    --bg-bot-image: url(img2/v1/Bot.webp?v=1);
}

body {
    background: var(--bg-top-image) center top no-repeat;
    background-size: 100% auto;
    background-color: var(--background);
    color: var(--foreground);
    font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    font-size: 15px;
    font-weight: 600;
}

body.home-bg {
    background:
        var(--bg-top-image) center top no-repeat,
        var(--bg-bot-image) center calc(100% + 150px) no-repeat;
    background-size: 100% auto, contain;
    background-color: var(--background);
}

body.top-page-active {
    background-image: none !important;
}

/* Navigation Styles */
.navbar-nav .active {
    background-image: url("img2/HeadMenu_Focus.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    width: 100px;
    height: 25px;
    line-height: 25px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.navbar-nav .active a {
    color: #fff !important;
}

/* Swiper Custom Navigation */
.swiper-button-prev,
.swiper-button-next {
    background-image: url("img/arow_b.png?v=1");
    width: 50px;
    height: 70px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.swiper-button-next {
    background-image: url("img/arow.png?v=1");
}

.swiper-button-prev::after,
.swiper-button-next::after {
    content: '';
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--heading-color);
}

h1 {
    font-size: 2.5em;
    font-weight: 700;
    line-height: 1.2;
}

h2 {
    font-size: 2em;
    font-weight: 700;
    line-height: 1.25;
}

h3 {
    font-size: 1.75em;
    font-weight: 600;
    line-height: 1.3;
}

h4 {
    font-size: 1.5em;
    font-weight: 600;
    line-height: 1.35;
}

h5 {
    font-size: 1.25em;
    font-weight: 600;
    line-height: 1.4;
}

h6 {
    font-size: 1em;
    font-weight: 600;
    line-height: 1.4;
}

/* Custom scrollbar used by /top and /event ranking lists */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.5);
}

/* News article body styling — mirrors app/[id]/[slug]/page.tsx */
.news-content {
    font-size: 15px;
    line-height: 1.8;
    word-break: break-word;
}

.news-content h1 {
    font-size: 1.85em;
    font-weight: 800;
    color: #b72600;
    margin: 2rem 0 0.75rem;
    padding-bottom: 0.4em;
    border-bottom: 3px solid #da3000;
    line-height: 1.3;
}

.news-content h2 {
    font-size: 1.5em;
    font-weight: 700;
    color: #c03000;
    margin: 1.75rem 0 0.6rem;
    padding-bottom: 0.3em;
    border-bottom: 2px solid #e8c07a;
    line-height: 1.35;
}

.news-content h3 {
    font-size: 1.25em;
    font-weight: 700;
    color: #333;
    margin: 1.5rem 0 0.5rem;
    padding-left: 0.6em;
    border-left: 4px solid #da3000;
    line-height: 1.4;
}

.news-content h4 {
    font-size: 1.1em;
    font-weight: 600;
    color: #444;
    margin: 1.25rem 0 0.4rem;
    line-height: 1.4;
}

.news-content h5 {
    font-size: 1em;
    font-weight: 600;
    color: #555;
    margin: 1rem 0 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    line-height: 1.4;
}

.news-content h6 {
    font-size: 0.9em;
    font-weight: 600;
    color: #666;
    margin: 1rem 0 0.3rem;
    font-style: italic;
    line-height: 1.4;
}

.news-content p {
    margin-bottom: 1rem;
}

.news-content a {
    color: #da3000;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.15s;
}

.news-content a:hover {
    color: #b72600;
}

.news-content img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 1.25rem auto;
    border-radius: 6px;
}

.news-content ul,
.news-content ol {
    margin: 0.75rem 0 1rem 1.5rem;
    padding: 0;
}

.news-content ul {
    list-style-type: disc;
}

.news-content ol {
    list-style-type: decimal;
}

.news-content li {
    margin-bottom: 0.35rem;
    line-height: 1.7;
}

.news-content li::marker {
    color: #da3000;
}

.news-content blockquote {
    margin: 1.25rem 0;
    padding: 0.75rem 1.25rem;
    border-left: 4px solid #da3000;
    background: #fff8e7;
    color: #555;
    font-style: italic;
    border-radius: 0 6px 6px 0;
}

.news-content blockquote p:last-child {
    margin-bottom: 0;
}

.news-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25rem 0;
    font-size: 0.95em;
}

.news-content th,
.news-content td {
    border: 1px solid #ddd;
    padding: 0.5rem 0.75rem;
    text-align: left;
}

.news-content th {
    background: #da3000;
    color: #fff;
    font-weight: 600;
}

.news-content tr:nth-child(even) {
    background: #fdf6e3;
}

.news-content code {
    background: #f5f2eb;
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: Consolas, monospace;
}

.news-content pre {
    background: #2d2d2d;
    color: #f8f8f2;
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
    margin: 1.25rem 0;
}

.news-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.news-content hr {
    border: none;
    height: 2px;
    background: linear-gradient(to right, transparent, #da3000, transparent);
    margin: 2rem 0;
}

.news-content strong {
    font-weight: 700;
    color: #222;
}

.news-content em {
    font-style: italic;
}

/* Floating widget visibility helper toggled from JS */
#floating-widget.is-visible {
    opacity: 1;
    pointer-events: auto;
}

/* sr-only utility (matches Tailwind's plugin) */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}