/* Mobile Responsive Styles */

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    gap: 5px;
    z-index: 1001;
}
.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text);
    border-radius: 3px;
    transition: all 0.3s ease;
}
.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}
.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}
.menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}
.menu-overlay.active {
    display: block;
    opacity: 1;
    pointer-events: auto;
}

/* Mobile Responsive - Tablet and below */
@media (max-width: 768px) {
    body {
        position: relative;
        overflow-x: hidden;
    }
    
    nav { 
        padding: 12px 20px; 
        flex-wrap: nowrap;
        position: relative;
        z-index: 1000;
    }
    nav.scrolled {
        padding: 8px 20px;
    }
    .nav-left {
        gap: 10px;
    }
    .logo-img { 
        height: 45px; 
    }
    nav h1 {
        font-size: 1.2rem;
    }
    .mobile-menu-toggle {
        display: flex;
    }
    nav ul.nav-menu { 
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: white;
        flex-direction: column;
        padding: 80px 20px 20px;
        box-shadow: -5px 0 20px rgba(0,0,0,0.1);
        transition: right 0.3s ease;
        z-index: 1000;
        gap: 0;
        margin: 0;
        overflow-y: auto;
    }
    nav ul.nav-menu.active {
        right: 0;
    }
    .menu-overlay {
        display: none;
    }
    .menu-overlay.active {
        display: block;
    }
    nav ul.nav-menu li {
        width: 100%;
        margin-bottom: 10px;
    }
    nav ul.nav-menu li a { 
        padding: 15px 20px; 
        font-size: 1rem;
        width: 100%;
        text-align: left;
        border-radius: 10px;
    }
    
    /* Hero - Reduced height for mobile */
    .hero {
        min-height: 25vh;
        padding: 20px 15px;
    }
    .bounce {
        font-size: 1.5rem;
    }
    .hero-content h1 {
        font-size: 1.5rem !important;
    }
    .hero-content p {
        font-size: 0.9rem;
    }
    
    /* Sections */
    .info, .video-tour, .gallery-section, .checklist-section, .faq-section, .contact-section {
        padding: 40px 15px;
    }
    .info {
        padding-left: 15px;
        padding-right: 15px;
    }
    .info h2, .video-tour h2, .gallery-section h2, .checklist-section h2, .faq-section h2, .contact-section h2 {
        font-size: 1.5rem;
    }
    
    /* Cards */
    .cards {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
        padding: 0;
        width: 100%;
        margin: 30px 0 0 0;
        box-sizing: border-box;
    }
    .card {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        margin: 0;
        box-sizing: border-box;
        flex: 1 1 100%;
        border-radius: 15px;
    }
    
    /* Video */
    .video-tour {
        padding: 25px 15px !important;
    }
    
    .video-wrapper {
        padding: 5px !important;
    }
    
    .video-container {
        border-radius: 15px;
        border-width: 2px;
        max-width: 100% !important;
        margin: 10px auto !important;
    }
    
    .video-tour h2 {
        font-size: 1.3rem !important;
        margin-bottom: 15px !important;
    }
    
    /* Gallery Slideshow for Mobile */
    .gallery-wrapper {
        position: relative;
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }
    .polaroid-container {
        position: relative;
        width: 100%;
        overflow: hidden;
        display: block;
        min-height: 200px;
    }
    .polaroid {
        width: 100%;
        display: none !important;
        margin: 0 auto;
        transform: none !important;
        transition: opacity 0.5s ease-in-out;
        opacity: 0;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
    }
    .polaroid.active {
        display: block !important;
        opacity: 1;
        position: relative;
    }
    .polaroid img {
        width: 100%;
        max-width: 280px;
        height: 180px;
        object-fit: cover;
        border-radius: 20px;
        display: block;
        margin: 0 auto;
        cursor: pointer;
        transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    }
    .polaroid img:active {
        transform: scale(1.05);
    }
    .photo-placeholder {
        width: 100% !important;
        max-width: 280px !important;
        height: 180px !important;
        margin: 0 auto !important;
    }
    /* Hide image modal on mobile */
    .image-modal {
        display: none !important;
    }
    .image-modal.active {
        display: none !important;
    }
    .polaroid img {
        cursor: default !important;
        pointer-events: none !important;
    }
    .polaroid img:active {
        transform: none !important;
    }
    
    /* About Page Mobile Styles */
    .about-container h2,
    .owner-container h2 {
        font-size: 1.8rem !important;
    }
    
    .about-content,
    .owner-content {
        padding: 25px 30px !important;
    }
    
    .about-text p,
    .owner-text p {
        padding: 0 10px !important;
    }
    
    .owner-content {
        flex-direction: column !important;
        text-align: center !important;
    }
    
    .owner-image-wrapper {
        margin: 0 auto 30px !important;
    }
    
    .owner-placeholder {
        width: 150px !important;
        height: 150px !important;
    }
    
    .owner-text {
        text-align: left !important;
    }
    
    /* Teachers Gallery Grid for Mobile */
    .teachers-gallery-wrapper {
        max-width: 100% !important;
        padding: 0 15px !important;
    }
    
    .teachers-gallery {
        gap: 15px !important;
        padding: 15px 0 !important;
        min-height: auto !important;
        flex-wrap: wrap !important;
    }
    
    .teacher-card {
        width: calc(50% - 7.5px) !important;
        min-width: 150px !important;
    }
    
    .teacher-card img,
    .teacher-placeholder {
        width: 100% !important;
        height: 200px !important;
        min-width: 100% !important;
        min-height: 200px !important;
        max-width: 100% !important;
        max-height: 200px !important;
    }
    
    .teacher-name-input {
        font-size: 0.95rem !important;
        padding: 12px !important;
    }
    
    .about-text p,
    .owner-text p {
        font-size: 1rem !important;
    }
    
    .teachers-intro {
        font-size: 1rem !important;
        padding: 0 10px !important;
    }
    .gallery-nav {
        display: flex !important;
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        background: rgba(255, 255, 255, 0.9);
        border: none;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        font-size: 2rem;
        cursor: pointer;
        z-index: 10;
        align-items: center;
        justify-content: center;
        box-shadow: 0 2px 10px rgba(0,0,0,0.2);
        transition: all 0.3s ease;
        color: var(--text);
        font-weight: bold;
        line-height: 1;
    }
    .gallery-nav:active {
        background: var(--secondary);
        color: white;
        transform: translateY(-50%) scale(1.1);
    }
    .gallery-prev {
        left: 10px;
    }
    .gallery-next {
        right: 10px;
    }
    .gallery-dots {
        display: flex !important;
        justify-content: center;
        gap: 10px;
        margin-top: 20px;
    }
    .dot {
        width: 12px;
        height: 12px;
        border-radius: 50%;
        background: #ccc;
        cursor: pointer;
        transition: all 0.3s ease;
    }
    .dot.active {
        background: var(--secondary);
        transform: scale(1.2);
    }
    
    /* Checklist */
    .checklist-card {
        padding: 20px;
        margin: 0 10px;
    }
    
    /* Contact */
    .contact-section {
        position: relative;
        z-index: 1;
    }
    .contact-container {
        flex-direction: column;
        gap: 20px;
        padding: 0 10px;
        width: 100%;
        max-width: 100%;
        position: relative;
        z-index: 1;
    }
    .contact-card {
        width: 100%;
        max-width: 100%;
        min-width: auto;
        padding: 25px 20px;
        margin: 0;
        box-sizing: border-box;
        position: relative;
        z-index: 1;
        touch-action: manipulation;
    }
    .contact-card h3 {
        font-size: 1.3rem;
        margin-bottom: 15px;
    }
    .contact-card p {
        font-size: 0.95rem;
        line-height: 1.6;
        margin: 8px 0;
    }
    .contact-icon {
        font-size: 2.5rem;
        margin-bottom: 15px;
    }
    .contact-section {
        padding: 40px 15px !important;
    }
    
    /* Questionnaire */
    .questionnaire-section {
        padding: 40px 15px;
        position: relative;
        z-index: 1;
    }
    .questionnaire-container {
        padding: 25px 20px;
        margin: 0 10px;
        position: relative;
        z-index: 1;
    }
    .questionnaire-intro {
        font-size: 1rem;
    }
    .form-group {
        margin-bottom: 20px;
        position: relative;
        z-index: 1;
    }
    .form-group label {
        font-size: 0.95rem;
    }
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 10px 12px;
        font-size: 0.95rem;
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
        position: relative;
        z-index: 1;
        touch-action: manipulation;
    }
    .form-group select {
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-position: right 12px center;
        padding-right: 35px;
    }
    .questionnaire-form {
        position: relative;
        z-index: 1;
    }
    .questionnaire-form .btn {
        padding: 12px 25px;
        font-size: 1rem;
        position: relative;
        z-index: 1;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }
    .form-section-title {
        font-size: 1.2rem;
        margin: 25px 0 15px 0;
    }
    
    /* Loading Animation Mobile */
    .loading-message {
        padding: 40px 15px;
    }
    .loading-animation {
        gap: 20px;
        min-height: 100px;
    }
    .bouncing-ball {
        font-size: 3rem;
    }
    .loading-message h3 {
        font-size: 1.5rem;
    }
    .loading-message p {
        font-size: 1rem;
    }
    
    /* Success Message Mobile */
    .success-message {
        padding: 30px 15px;
    }
    .success-icon {
        width: 60px;
        height: 60px;
        font-size: 2.5rem;
    }
    .success-message h3 {
        font-size: 1.5rem;
    }
    .success-message p {
        font-size: 1rem;
    }
    
    /* Contact Cards */
    .contact-section {
        position: relative;
        z-index: 1;
    }
    .contact-card {
        position: relative;
        z-index: 1;
        touch-action: manipulation;
    }
    .contact-link {
        position: relative;
        z-index: 1;
        touch-action: manipulation;
    }
    .contact-link {
        font-size: 1.1rem;
        word-break: break-all;
    }
    
    /* Footer */
    .main-footer {
        padding: 30px 20px;
    }
    .footer-logo-img {
        height: 60px;
    }
    .main-footer p {
        font-size: 0.9rem;
    }
    
    /* Fixed Buttons */
    .fixed-buttons {
        bottom: 15px;
        right: 15px;
        gap: 12px;
    }
    #rocketBtn {
        font-size: 2rem;
        width: 50px;
        height: 50px;
    }
    .whatsapp-btn {
        width: 50px;
        height: 50px;
    }
    .whatsapp-btn svg {
        width: 24px;
        height: 24px;
    }
    
    /* Testimonials Carousel Mobile Styles */
    .testimonials-section {
        padding: 40px 15px !important;
    }
    .testimonials-wrapper {
        max-width: 100% !important;
    }
    .testimonials-nav {
        display: flex !important;
        width: 40px !important;
        height: 40px !important;
        font-size: 2rem !important;
    }
    .testimonials-prev {
        left: 10px !important;
    }
    .testimonials-next {
        right: 10px !important;
    }
    .testimonials-dots {
        display: flex !important;
        margin-top: 15px !important;
    }
    .testimonials-container {
        min-height: 250px !important;
    }
    .testimonial-card {
        padding: 20px !important;
    }
    .testimonial-text {
        font-size: 1rem !important;
    }
    .testimonial-author {
        font-size: 0.9rem !important;
    }
    
    /* Programs Page Mobile Styles */
    .programs-section {
        padding: 40px 15px !important;
    }
    .program-container {
        padding: 0;
        gap: 30px;
    }
    .program-card {
        padding: 25px 20px !important;
        margin: 0;
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }
    .program-icon {
        font-size: 3rem;
        margin-bottom: 15px;
    }
    .program-card h2 {
        font-size: 1.5rem !important;
    }
    .program-age {
        font-size: 1rem !important;
    }
    .program-content {
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }
    .program-content h3 {
        font-size: 1.2rem !important;
        margin-top: 20px;
        margin-bottom: 12px;
    }
    .program-content p {
        font-size: 1rem !important;
        line-height: 1.6;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    .program-features {
        margin: 15px 0 !important;
        padding: 0 !important;
        width: 100%;
        box-sizing: border-box;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 8px !important;
        list-style: none !important;
    }
    .program-features li {
        padding: 10px 12px 10px 30px !important;
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%) !important;
        border-radius: 8px !important;
        border-left: 3px solid var(--secondary) !important;
        position: relative !important;
        margin: 0 !important;
        color: #555 !important;
    }
    .program-features li:before {
        content: "✓" !important;
        position: absolute !important;
        left: 12px !important;
        color: var(--secondary) !important;
        font-weight: bold !important;
        font-size: 0.9rem !important;
    }
    .schedule {
        padding: 15px !important;
        margin-top: 15px;
        box-sizing: border-box;
        width: 100%;
    }
    .schedule p {
        font-size: 0.9rem !important;
        margin: 6px 0;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    .schedule p strong {
        display: block;
        margin-bottom: 4px;
    }
    
    /* Montessori Method Section Mobile */
    .montessori-method-section {
        padding: 40px 15px !important;
    }
    .montessori-method-section h2 {
        font-size: 1.5rem !important;
    }
    .method-container {
        gap: 20px;
    }
    .method-card {
        padding: 20px !important;
    }
    .method-card h3 {
        font-size: 1.1rem !important;
    }
    .method-card p {
        font-size: 0.95rem !important;
    }
}

/* Mobile Responsive - Small phones */
@media (max-width: 480px) {
    nav h1 {
        font-size: 1rem;
    }
    .logo-img {
        height: 40px;
    }
    .nav-left {
        gap: 8px;
    }
    
    /* Hero - Even smaller height for small phones */
    .hero {
        min-height: 20vh;
        padding: 15px 10px;
    }
    .bounce {
        font-size: 1.3rem;
    }
    .hero-content h1 {
        font-size: 1.3rem !important;
    }
    .hero-content p {
        font-size: 0.85rem;
    }
    
    .hero-with-image .hero-content h1 {
        font-size: 1.3rem !important;
    }
    
    .hero-with-image .hero-content p {
        font-size: 0.85rem !important;
    }
    
    .info h2, .video-tour h2, .gallery-section h2, .checklist-section h2, .faq-section h2, .contact-section h2 {
        font-size: 1.3rem;
    }
    
    .btn {
        padding: 12px 25px;
        font-size: 0.9rem;
    }
    
    /* Contact - Small phones */
    .contact-container {
        padding: 0 5px;
    }
    .contact-card {
        padding: 20px 15px;
    }
    .contact-card h3 {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    .contact-card p {
        font-size: 0.85rem;
        margin: 6px 0;
    }
    .contact-icon {
        font-size: 2rem;
        margin-bottom: 12px;
    }
    .contact-link {
        font-size: 1rem;
        word-break: break-all;
    }
    
    /* Documents Section Mobile Styles */
    .documents-section {
        padding: 40px 15px !important;
    }
    .documents-container {
        flex-direction: column !important;
        gap: 20px !important;
        padding: 0 !important;
    }
    .document-list {
        padding: 20px 15px !important;
        margin: 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .document-list h3 {
        font-size: 1.2rem !important;
        margin-bottom: 15px !important;
    }
    .document-list ul {
        list-style: none !important;
        padding: 0 !important;
        margin: 0 !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
    .document-list li {
        padding: 10px 12px 10px 30px !important;
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%) !important;
        border-radius: 8px !important;
        border-left: 3px solid var(--secondary) !important;
        margin: 0 !important;
        color: #555 !important;
        position: relative !important;
    }
    .document-list li:before {
        content: "✓" !important;
        position: absolute !important;
        left: 12px !important;
        color: var(--secondary) !important;
        font-weight: bold !important;
        font-size: 0.9rem !important;
    }
    
    /* Programs Page - Small phones */
    .program-card {
        padding: 20px 15px !important;
    }
    .program-card h2 {
        font-size: 1.3rem !important;
    }
    .program-content h3 {
        font-size: 1.1rem !important;
    }
    .program-content p {
        font-size: 0.95rem !important;
    }
    .program-features li {
        font-size: 0.85rem !important;
        padding: 8px 10px 8px 28px !important;
    }
    .program-features li:before {
        left: 10px !important;
        font-size: 0.85rem !important;
    }
    .schedule p {
        font-size: 0.85rem !important;
    }
    
    /* Resources Page - Small phones */
    .resource-card {
        padding: 18px 12px !important;
    }
    .resource-card h3 {
        font-size: 1.1rem !important;
    }
    .resource-card p {
        font-size: 0.9rem !important;
    }
    .tip-card {
        padding: 18px 12px !important;
    }
    .tip-card h3 {
        font-size: 1rem !important;
    }
    .tip-card p {
        font-size: 0.9rem !important;
    }
    .montessori-resource-card {
        padding: 18px 12px !important;
    }
    .montessori-resource-card h3 {
        font-size: 1.1rem !important;
    }
    .montessori-resource-card p {
        font-size: 0.9rem !important;
    }
    .montessori-resource-card li {
        font-size: 0.85rem !important;
        padding: 8px 10px 8px 28px !important;
    }
    .montessori-resource-card li:before {
        left: 10px !important;
        font-size: 0.85rem !important;
    }
    
    /* Documents Section - Small phones */
    .document-list {
        padding: 18px 12px !important;
    }
    .document-list h3 {
        font-size: 1.1rem !important;
        margin-bottom: 12px !important;
    }
    .document-list li {
        font-size: 0.85rem !important;
        padding: 8px 10px 8px 28px !important;
    }
    .document-list li:before {
        left: 10px !important;
        font-size: 0.85rem !important;
    }
    
    /* Resources Page Mobile Styles */
    .resources-section {
        padding: 40px 15px !important;
    }
    .resources-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    .resource-card {
        padding: 20px 15px !important;
    }
    .resource-card h3 {
        font-size: 1.2rem !important;
    }
    .resource-card p {
        font-size: 0.95rem !important;
    }
    .resource-icon {
        font-size: 2.5rem !important;
    }
    
    /* Parenting Tips Section Mobile */
    .parenting-tips-section {
        padding: 40px 15px !important;
    }
    .tips-container {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    .tip-card {
        padding: 20px 15px !important;
    }
    .tip-card h3 {
        font-size: 1.1rem !important;
    }
    .tip-card p {
        font-size: 0.95rem !important;
    }
    
    /* Montessori Resources Section Mobile */
    .montessori-resources-section {
        padding: 40px 15px !important;
    }
    .montessori-resources-container {
        grid-template-columns: 1fr !important;
        gap: 25px !important;
    }
    .montessori-resource-card {
        padding: 20px 15px !important;
    }
    .montessori-resource-card h3 {
        font-size: 1.2rem !important;
        margin-bottom: 12px !important;
    }
    .montessori-resource-card p {
        font-size: 0.95rem !important;
        margin-bottom: 15px !important;
    }
    .montessori-resource-card ul {
        list-style: none !important;
        padding: 0 !important;
        margin: 0 !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
    .montessori-resource-card li {
        padding: 10px 12px 10px 30px !important;
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%) !important;
        border-radius: 8px !important;
        border-left: 3px solid var(--secondary) !important;
        margin: 0 !important;
        color: #555 !important;
        position: relative !important;
    }
    .montessori-resource-card li:before {
        content: "✓" !important;
        position: absolute !important;
        left: 12px !important;
        color: var(--secondary) !important;
        font-weight: bold !important;
        font-size: 0.9rem !important;
    }
}

