/*
Theme Name: Phat Nguoi
Theme URI: https://phatnguoi.vn
Description: Theme tra cứu phạt nguội giao thông
Version: 1.0
Author: PhatNguoi Team
Author URI: https://phatnguoi.vn
Text Domain: phatnguoi
*/

/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Public Sans', sans-serif;
    line-height: 1.6;
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

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

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

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Material Icons Settings */
.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
    user-select: none;
}

/* Print Styles */
@media print {
    /* Hide everything by default */
    body * {
        visibility: hidden;
    }
    
    /* Hide header, footer, and non-print elements */
    header, footer, .no-print, #violationModal {
        display: none !important;
    }
    
    /* Show only modal content when printing from modal */
    body.printing-modal * {
        visibility: hidden;
    }
    
    body.printing-modal #violationModalContent,
    body.printing-modal #violationModalContent * {
        visibility: visible;
    }
    
    body.printing-modal #violationModalContent {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        padding: 20px;
        background: white !important;
    }
    
    /* General print styles */
    .print-only {
        display: block !important;
    }
    
    * {
        background: transparent !important;
        color: black !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
    
    /* Override for specific elements that need background */
    .print-keep-bg {
        background: white !important;
    }
    
    /* Page breaks */
    .page-break {
        page-break-after: always;
    }
    
    /* Ensure proper spacing */
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Dark mode scrollbar */
.dark ::-webkit-scrollbar-track {
    background: #1a222c;
}

.dark ::-webkit-scrollbar-thumb {
    background: #444;
}

.dark ::-webkit-scrollbar-thumb:hover {
    background: #666;
}

/* Focus styles for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible {
    outline: 2px solid #137fec;
    outline-offset: 2px;
}

/* Smooth transitions */
* {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* Override WordPress defaults */
.alignleft {
    float: left;
    margin-right: 1.5em;
}

.alignright {
    float: right;
    margin-left: 1.5em;
}

.aligncenter {
    clear: both;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* WordPress Content Styles */
.prose h1 {
    color: #111418;
    font-size: 2.25rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    margin-top: 0;
}

.prose h2 {
    color: #111418;
    font-size: 1.875rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    margin-top: 3rem;
}

.prose h2:first-child {
    margin-top: 0;
}

.prose h3 {
    color: #111418;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    margin-top: 2rem;
}

.prose h4 {
    color: #111418;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    margin-top: 1.5rem;
}

.prose h5 {
    color: #111418;
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.prose h6 {
    color: #111418;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.prose p {
    color: #111418;
    line-height: 1.75;
    margin-bottom: 1rem;
}

.prose strong {
    color: #111418;
    font-weight: 700;
}

.prose ul,
.prose ol {
    color: #111418;
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.prose li {
    color: #111418;
    margin-bottom: 0.5rem;
}

.prose a {
    color: #137fec;
    text-decoration: none;
    font-weight: 500;
}

.prose a:hover {
    text-decoration: underline;
}

/* Images */
.prose img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 1.5rem auto;
    border-radius: 0.5rem;
}

.prose figure {
    max-width: 100%;
    margin: 1.5rem auto;
}

.prose figure img {
    margin: 0 auto;
}

.prose figcaption {
    color: #617589;
    font-size: 0.875rem;
    text-align: center;
    margin-top: 0.5rem;
    font-style: italic;
}

/* WordPress alignment classes */
.prose .alignleft {
    float: left;
    margin-right: 1.5rem;
    margin-bottom: 1rem;
    max-width: 50%;
}

.prose .alignright {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
    max-width: 50%;
}

.prose .aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.prose .alignwide,
.prose .alignfull {
    max-width: 100%;
}

/* Dark mode */
.dark .prose h1,
.dark .prose h2,
.dark .prose h3,
.dark .prose h4,
.dark .prose h5,
.dark .prose h6 {
    color: #ffffff;
}

.dark .prose p,
.dark .prose li,
.dark .prose ul,
.dark .prose ol {
    color: #d1d5db;
}

.dark .prose strong {
    color: #ffffff;
}

.dark .prose figcaption {
    color: #9aa2ac;
}
