/**
 * Right Foundation Academy - Responsive Styles
 * Mobile-first responsive design breakpoints
 */

/* ==================== BREAKPOINTS ==================== */
/*
 * Mobile: < 768px
 * Tablet: 768px - 991px
 * Desktop: 992px - 1199px
 * Large Desktop: >= 1200px
 */

/* ==================== TABLET (768px and up) ==================== */

@media (max-width: 991px) {
    
    /* Typography */
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.75rem; }
    
    /* Container */
    .container {
        padding: 0 1.25rem;
    }
    
    /* Section Spacing */
    .section {
        padding: 4rem 0;
    }
    
    .section-lg {
        padding: 5rem 0;
    }
    
    /* Hero */
    .hero {
        min-height: 60vh;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-description {
        font-size: 1.125rem;
    }
    
    /* Footer Grid */
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    /* Newsletter */
    .newsletter-wrapper {
        flex-direction: column;
        text-align: center;
    }
    
    .newsletter-content {
        justify-content: center;
    }
    
    /* Statistics */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Cards */
    .card-img {
        height: 200px;
    }
}

/* ==================== MOBILE (767px and below) ==================== */

@media (max-width: 767px) {
    
    /* Typography */
    html {
        font-size: 15px;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
    h4 { font-size: 1.25rem; }
    h5 { font-size: 1.125rem; }
    h6 { font-size: 1rem; }
    
    /* Container */
    .container {
        padding: 0 1rem;
    }
    
    /* Section Spacing */
    .section {
        padding: 3rem 0;
    }
    
    .section-sm {
        padding: 2rem 0;
    }
    
    .section-lg {
        padding: 4rem 0;
    }
    
    /* Section Header */
    .section-header {
        margin-bottom: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .section-description {
        font-size: 1rem;
    }
    
    /* ==================== NAVIGATION ==================== */
    
    .navbar-wrapper {
        padding: 0.75rem 0;
    }
    
    /* Hide desktop menu */
    .navbar-menu {
        display: none;
    }
    
    /* Logo */
    .logo-img {
        width: 50px;
        height: 50px;
    }
    
    .logo-title {
        font-size: 1rem;
    }
    
    .logo-tagline {
        font-size: 0.65rem;
    }
    
    /* Navbar Actions */
    .navbar-actions .btn {
        display: none;
    }
    
    .navbar-actions .btn-admission {
        display: flex;
        padding: 0.625rem 1rem;
        font-size: 0.85rem;
    }
    
    .navbar-actions .btn-admission span {
        display: none;
    }
    
    .navbar-actions .btn-admission i {
        margin: 0;
    }
    
    /* Show mobile menu toggle */
    .mobile-menu-toggle {
        display: flex;
    }
    
    /* ==================== HERO ==================== */
    
    .hero {
        min-height: 70vh;
        padding: 3rem 0;
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* ==================== BUTTONS ==================== */
    
    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .btn-lg {
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .btn-sm {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
    
    /* ==================== GRID SYSTEM ==================== */
    
    .row {
        margin: 0 -0.5rem;
    }
    
    .col,
    [class*="col-"] {
        width: 100%;
        padding: 0 0.5rem;
        margin-bottom: 1rem;
    }
    
    /* ==================== CARDS ==================== */
    
    .card {
        margin-bottom: 1.5rem;
    }
    
    .card-img {
        height: 180px;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    .card-title {
        font-size: 1.25rem;
    }
    
    /* ==================== STATISTICS ==================== */
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .stat-card {
        padding: 1.5rem;
    }
    
    .stat-icon {
        font-size: 2.5rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    /* ==================== FOOTER ==================== */
    
    .footer-main {
        padding: 3rem 0 1.5rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-col {
        text-align: center;
    }
    
    .footer-logo {
        justify-content: center;
    }
    
    .footer-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-social {
        justify-content: center;
    }
    
    .footer-menu {
        text-align: center;
    }
    
    .footer-menu a {
        justify-content: center;
    }
    
    .contact-info {
        text-align: left;
    }
    
    .footer-newsletter {
        padding: 2rem 0;
    }
    
    .newsletter-icon {
        font-size: 2.5rem;
    }
    
    .newsletter-text h3 {
        font-size: 1.25rem;
    }
    
    .newsletter-text p {
        font-size: 0.9rem;
    }
    
    .newsletter-form-wrapper {
        width: 100%;
    }
    
    .form-group-inline {
        flex-direction: column;
    }
    
    .form-group-inline .btn {
        width: 100%;
        border-radius: 8px !important;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
    
    .footer-bottom-links {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .separator {
        display: none;
    }
    
    /* ==================== FORMS ==================== */
    
    .form-group {
        margin-bottom: 1.25rem;
    }
    
    .form-control {
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }
    
    /* ==================== ANNOUNCEMENT BAR ==================== */
    
    .announcement-bar {
        padding: 0.625rem 0;
        font-size: 0.85rem;
    }
    
    .announcement-text {
        font-size: 0.85rem;
    }
    
    .announcement-content i {
        display: none;
    }
    
    /* ==================== BACK TO TOP ==================== */
    
    .back-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 45px;
        height: 45px;
    }
    
    /* ==================== TABLES ==================== */
    
    table {
        font-size: 0.9rem;
    }
    
    /* Make tables scroll horizontally on mobile */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    /* ==================== MODALS ==================== */
    
    .modal-alert-container,
    .modal-confirm-container {
        max-width: 90%;
        padding: 1.5rem;
    }
    
    .modal-alert-icon,
    .modal-confirm-icon {
        font-size: 3rem;
    }
    
    .modal-alert-title,
    .modal-confirm-title {
        font-size: 1.25rem;
    }
    
    /* ==================== BREADCRUMBS ==================== */
    
    .breadcrumb {
        font-size: 0.85rem;
        flex-wrap: wrap;
    }
    
    /* ==================== PAGINATION ==================== */
    
    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .pagination-item {
        font-size: 0.9rem;
        padding: 0.5rem 0.75rem;
    }
    
    /* ==================== GALLERY ==================== */
    
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    /* ==================== TESTIMONIALS ==================== */
    
    .testimonial-card {
        padding: 1.5rem;
    }
    
    /* ==================== TIMELINE ==================== */
    
    .timeline {
        padding-left: 0;
    }
    
    .timeline-item {
        padding-left: 2rem;
    }
    
    /* ==================== UTILITY CLASSES ==================== */
    
    .mobile-hide {
        display: none !important;
    }
    
    .mobile-show {
        display: block !important;
    }
    
    .mobile-text-center {
        text-align: center !important;
    }
    
    .mobile-text-left {
        text-align: left !important;
    }
    
    .mobile-full-width {
        width: 100% !important;
    }
    
    /* ==================== SPACING UTILITIES ==================== */
    
    .mb-mobile-1 { margin-bottom: 0.5rem !important; }
    .mb-mobile-2 { margin-bottom: 1rem !important; }
    .mb-mobile-3 { margin-bottom: 1.5rem !important; }
    .mb-mobile-4 { margin-bottom: 2rem !important; }
    
    .mt-mobile-1 { margin-top: 0.5rem !important; }
    .mt-mobile-2 { margin-top: 1rem !important; }
    .mt-mobile-3 { margin-top: 1.5rem !important; }
    .mt-mobile-4 { margin-top: 2rem !important; }
    
    .p-mobile-1 { padding: 0.5rem !important; }
    .p-mobile-2 { padding: 1rem !important; }
    .p-mobile-3 { padding: 1.5rem !important; }
    .p-mobile-4 { padding: 2rem !important; }
}

/* ==================== SMALL MOBILE (480px and below) ==================== */

@media (max-width: 480px) {
    
    html {
        font-size: 14px;
    }
    
    .logo-img {
        width: 45px;
        height: 45px;
    }
    
    .logo-title {
        font-size: 0.9rem;
    }
    
    .logo-tagline {
        font-size: 0.6rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .btn {
        font-size: 0.9rem;
        padding: 0.625rem 1.25rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .footer-logo-img {
        width: 50px;
        height: 50px;
    }
}

/* ==================== LARGE DESKTOP (1200px and up) ==================== */

@media (min-width: 1200px) {
    
    .container {
        max-width: 1200px;
    }
    
    .section {
        padding: 6rem 0;
    }
    
    .section-lg {
        padding: 8rem 0;
    }
    
    .hero {
        min-height: 85vh;
    }
}

/* ==================== PRINT STYLES ==================== */

@media print {
    
    .navbar,
    .announcement-bar,
    .footer,
    .back-to-top,
    .mobile-menu-overlay,
    .btn,
    button {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        color: #000;
        background: #fff;
    }
    
    a {
        color: #000;
        text-decoration: underline;
    }
    
    .section {
        page-break-inside: avoid;
    }
    
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        page-break-inside: avoid;
    }
}

/* ==================== LANDSCAPE ORIENTATION ==================== */

@media (max-height: 500px) and (orientation: landscape) {
    
    .hero {
        min-height: 100vh;
    }
    
    .modal-alert-container,
    .modal-confirm-container {
        max-height: 90vh;
        overflow-y: auto;
    }
}

/* ==================== BOOTSTRAP-COMPATIBLE GRID COLUMNS ==================== */
/* col-md-* active on 768px+, col-lg-* active on 992px+ */

.col-12 { width: 100%; }

/* Default (mobile-first): all cols full width */
.col-md-1,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,
.col-md-7,.col-md-8,.col-md-9,.col-md-10,.col-md-11,.col-md-12,
.col-lg-1,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,
.col-lg-7,.col-lg-8,.col-lg-9,.col-lg-10,.col-lg-11,.col-lg-12 {
    width: 100%;
    padding: 0 0.75rem;
    box-sizing: border-box;
}

.row { display: flex; flex-wrap: wrap; margin: 0 -0.75rem; }
.row > [class*="col-"] { padding: 0 0.75rem; }

/* md: ≥ 768px */
@media (min-width: 768px) {
  .col-md-1  { width: 8.333%; }
  .col-md-2  { width: 16.666%; }
  .col-md-3  { width: 25%; }
  .col-md-4  { width: 33.333%; }
  .col-md-5  { width: 41.666%; }
  .col-md-6  { width: 50%; }
  .col-md-7  { width: 58.333%; }
  .col-md-8  { width: 66.666%; }
  .col-md-9  { width: 75%; }
  .col-md-10 { width: 83.333%; }
  .col-md-11 { width: 91.666%; }
  .col-md-12 { width: 100%; }
}

/* lg: ≥ 992px */
@media (min-width: 992px) {
  .col-lg-1  { width: 8.333%; }
  .col-lg-2  { width: 16.666%; }
  .col-lg-3  { width: 25%; }
  .col-lg-4  { width: 33.333%; }
  .col-lg-5  { width: 41.666%; }
  .col-lg-6  { width: 50%; }
  .col-lg-7  { width: 58.333%; }
  .col-lg-8  { width: 66.666%; }
  .col-lg-9  { width: 75%; }
  .col-lg-10 { width: 83.333%; }
  .col-lg-11 { width: 91.666%; }
  .col-lg-12 { width: 100%; }
}

/* Utility helpers */
.mx-auto { margin-left: auto; margin-right: auto; }
.d-flex { display: flex; }
.justify-center { justify-content: center; }
.align-center { align-items: center; }
.gap-3 { gap: 1rem; }
.flex-wrap { flex-wrap: wrap; }
.h-100 { height: 100%; }
.w-100 { width: 100%; }
.text-center { text-align: center; }
.mt-3 { margin-top: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 0.5rem; }
.font-weight-bold { font-weight: 700; }
