/*
 * Myo Taw News — Custom Styles
 * (Cloned from WordPress style.css)
 * Non-Tailwind styles that require custom CSS
 */

/* =========================================
   Self-hosted Padauk Font
   ========================================= */
@font-face {
    font-family: 'Padauk';
    src: url("../fonts/Padauk-Regular.ae10122af3d5.ttf") format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Padauk';
    src: url("../fonts/Padauk-Medium.ec1fc396eca5.ttf") format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Padauk';
    src: url("../fonts/Padauk-SemiBold.48b8ab6adabd.ttf") format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Padauk';
    src: url("../fonts/Padauk-Bold.3de5432a2753.ttf") format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Padauk';
    src: url("../fonts/Padauk-ExtraBold.135ae7055962.ttf") format('truetype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

/* =========================================
   Font Families
   ========================================= */
body {
    font-family: 'Padauk', sans-serif;
}

.font-serif {
    font-family: 'Merriweather', serif;
}

/* =========================================
   Custom Scrollbar (for video carousel)
   ========================================= */
.hide-scroll::-webkit-scrollbar {
    display: none;
}

.hide-scroll {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* =========================================
   Breaking News Ticker Animation
   ========================================= */
@keyframes slideUpFade {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }
    10% {
        opacity: 1;
        transform: translateY(0);
    }
    90% {
        opacity: 1;
        transform: translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateY(-10px);
    }
}

.ticker-text {
    animation: slideUpFade 4s infinite;
}

/* =========================================
   Prose (Article body text improvements)
   ========================================= */
.prose p {
    margin-bottom: 1.25rem;
    line-height: 2;
}

.prose img {
    border-radius: 0.75rem;
    margin: 1.5rem 0;
}

.prose h2,
.prose h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.prose a {
    color: #dc2626;
    text-decoration: underline;
}

.prose a:hover {
    color: #b91c1c;
}

.prose blockquote {
    border-left: 4px solid #dc2626;
    padding-left: 1rem;
    font-style: italic;
    color: #6b7280;
    margin: 1.5rem 0;
}

/* =========================================
   Line Clamp (for truncating text)
   ========================================= */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* =========================================
   Responsive Video Embeds
   ========================================= */
.responsive-object iframe {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 16/9 !important;
    border-radius: 0.5rem;
}

/* =========================================
   Animations
   ========================================= */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-down {
    animation: fadeInDown 0.4s ease-out;
}

/* =========================================
   Wagtail Admin Overrides (for Myanmar font)
   ========================================= */
.richtext-editor,
.w-field__input textarea,
.w-field__input input {
    font-family: 'Padauk', sans-serif !important;
}

/* =========================================
   Mobile-First Responsive Enhancements
   ========================================= */
/* Prevent horizontal overflow */
body {
    overflow-x: hidden;
}
img {
    max-width: 100%;
    height: auto;
}

/* Better touch targets on mobile */
@media (max-width: 767px) {
    .prose p {
        font-size: 1rem;
        line-height: 2;
    }
    /* Card grid: 1 col on small screens */
    .grid-cols-1 {
        grid-template-columns: 1fr;
    }
    /* Gallery slider: larger swipe target */
    .gallery-slider {
        border-radius: 0.5rem;
    }
    .gallery-btn {
        width: 36px;
        height: 36px;
    }
    /* Footer: stack columns */
    footer .grid {
        gap: 2rem;
    }
    /* Pagination spacing */
    nav .px-4 {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Focus visible for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #dc2626;
    outline-offset: 2px;
    border-radius: 2px;
}

