/* Mobile First Responsive Design */

/* Base styles for mobile devices */
@media screen and (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    header .container {
        flex-direction: column;
        padding: 1rem;
    }

    .logo h1 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    nav ul {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }



    .hero p {
        font-size: 1rem;
    }

    .features .container,
    .services .container {
        grid-template-columns: 1fr;
    }

    .contact-content .container {
        grid-template-columns: 1fr;
    }

    .contact-form {
        margin-top: 2rem;
    }

    .about-text h2 {
        font-size: 1.8rem;
    }

    .feature-box,
    .service-box {
        padding: 1.5rem;
    }
}

/* Tablet styles */
@media screen and (min-width: 769px) and (max-width: 1024px) {


    .features .container,
    .services .container {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-content .container {
        grid-template-columns: 1fr;
    }

    .contact-form {
        margin-top: 2rem;
    }
}

/* Desktop styles */
@media screen and (min-width: 1025px) {


    .features .container {
        grid-template-columns: repeat(3, 1fr);
    }

    .services .container {
        grid-template-columns: repeat(3, 1fr);
    }

    .contact-content .container {
        grid-template-columns: 1fr 1fr;
    }

    .contact-form {
        margin-top: 0;
    }
}

/* Extra small devices (phones, 600px and down) */
@media only screen and (max-width: 600px) {


    .hero p {
        font-size: 1rem;
    }

    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .feature-box,
    .service-box {
        padding: 1rem;
    }

    .feature-box h3,
    .service-box h3 {
        font-size: 1.3rem;
    }

    .about-text h2 {
        font-size: 1.5rem;
    }

    .contact-item {
        padding: 1rem;
    }

    .contact-item h3 {
        font-size: 1.1rem;
    }

    .form-group input,
    .form-group textarea {
        font-size: 0.9rem;
        padding: 0.8rem;
    }
}

/* Small devices (landscape phones, 576px and up) */
@media only screen and (min-width: 576px) {


    .btn {
        padding: 1rem 2rem;
    }
}

/* Medium devices (tablets, 768px and up) */
@media only screen and (min-width: 768px) {


    .features .container {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large devices (desktops, 992px and up) */
@media only screen and (min-width: 992px) {

    .features .container {
        grid-template-columns: repeat(3, 1fr);
    }

    .services .container {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media only screen and (min-width: 1200px) {}

/* High DPI/Retina displays */
@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 192dpi) {

    .feature-box,
    .service-box {
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    }
}

/* Print styles */
@media print {
    header {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    .container {
        max-width: none;
        padding: 0;
    }

    .hero {
        background: none;
        color: black;
    }

    .feature-box,
    .service-box {
        box-shadow: none;
        border: 1px solid #ddd;
        margin-bottom: 1rem;
    }

    a {
        text-decoration: none;
        color: black;
    }

    /* Ensure sections are visible in print */
    .integration-wrapper,
    .feedback-section,
    .pricing-section {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }
}

/* Ensure sections are always visible on screen */
@media screen {

    .integration-wrapper,
    .feedback-section,
    .pricing-section {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
        position: relative !important;
        z-index: 2 !important;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e0e0e0;
    }

    header {
        background-color: #2d2d2d;
    }

    header .container {
        border-bottom: 1px solid #444;
    }

    nav ul li a {
        color: #e0e0e0;
    }

    nav ul li a:hover,
    nav ul li a.active {
        color: #3498db;
        background-color: #3d3d3d;
    }

    .features,
    .about-content,
    .services,
    .contact-content {
        background-color: #2d2d2d;
    }

    .feature-box,
    .service-box {
        background: #3d3d3d;
        color: #e0e0e0;
    }

    .about-text li {
        background: #3d3d3d;
        border-left-color: #3498db;
    }

    .contact-form {
        background: #3d3d3d;
    }

    .contact-item {
        background: #3d3d3d;
    }

    .form-group input,
    .form-group textarea {
        background-color: #4d4d4d;
        border-color: #666;
        color: #e0e0e0;
    }

    .form-group input:focus,
    .form-group textarea:focus {
        border-color: #3498db;
    }

    /* footer background intentionally not overridden — controlled by Tailwind */
}

/* Accessibility improvements */
@media screen {

    /* Focus styles for better accessibility */
    a:focus,
    button:focus,
    input:focus,
    textarea:focus {
        outline: 3px solid #3498db;
        outline-offset: 2px;
    }

    /* Skip link for keyboard navigation */
    .skip-link {
        position: absolute;
        top: -40px;
        left: 6px;
        background: #000;
        color: white;
        padding: 8px;
        z-index: 100;
        text-decoration: none;
    }

    .skip-link:focus {
        top: 6px;
    }
}