/* ========================================
   SESC APEOC - Shared Utility CSS
   Most styles are inline in base.html
   ======================================== */

/* Print styles */
@media print {
    .main-header,
    .footer,
    .header-nav,
    .spinner-overlay,
    #alertModal {
        display: none !important;
    }

    body {
        background: white !important;
    }

    .card-shadow {
        box-shadow: none !important;
        border: 1px solid #ddd;
    }
}

/* Utility: Scroll to top smoothness */
html {
    scroll-behavior: smooth;
}

/* Utility: No text select on badges/buttons */
.badge, .btn {
    user-select: none;
}

/* Utility: Truncate text */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Utility: Skeleton loading */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeletonLoading 1.5s infinite;
    border-radius: 4px;
}

@keyframes skeletonLoading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Utility: Fade in animation */
.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive utilities */
@media (max-width: 576px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }

    h1 { font-size: 1.6rem; }
    h2 { font-size: 1.4rem; }
    h3 { font-size: 1.2rem; }
}

/* Accessibility: Focus visible */
:focus-visible {
    outline: 2px solid #1a5632;
    outline-offset: 2px;
}

/* Override Bootstrap form validation colors to match brand */
.was-validated .form-control:valid,
.form-control.is-valid {
    border-color: #1a5632;
}

.was-validated .form-control:valid:focus,
.form-control.is-valid:focus {
    box-shadow: 0 0 0 0.2rem rgba(26, 86, 50, 0.25);
}

.valid-feedback {
    color: #1a5632;
}
