/* ==========================================================================
   CK Soluções - Responsive Stylesheet
   ========================================================================== */

/* --------------------------------------------------------------------------
   Large Desktop (1400px+)
   -------------------------------------------------------------------------- */
@media (min-width: 1400px) {
    :root {
        --container-max: 1320px;
    }
    
    .hero-title {
        font-size: 5rem;
    }
}

/* --------------------------------------------------------------------------
   Desktop (1200px - 1399px)
   -------------------------------------------------------------------------- */
@media (max-width: 1399px) {
    :root {
        --container-max: 1140px;
    }
}

/* --------------------------------------------------------------------------
   Laptop (992px - 1199px)
   -------------------------------------------------------------------------- */
@media (max-width: 1199px) {
    :root {
        --container-max: 960px;
        --space-5xl: 6rem;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
    
    .section-title {
        font-size: 2.25rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .contact-container {
        grid-template-columns: 1fr 1.2fr;
        gap: var(--space-2xl);
    }
}

/* --------------------------------------------------------------------------
   Tablet (768px - 991px)
   -------------------------------------------------------------------------- */
@media (max-width: 991px) {
    :root {
        --container-max: 720px;
        --space-5xl: 5rem;
        --space-4xl: 4rem;
    }
    
    /* Typography adjustments */
    .hero-title {
        font-size: 3rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.125rem;
    }
    
    /* Navigation */
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--color-primary);
        flex-direction: column;
        align-items: flex-start;
        padding: 100px var(--space-xl) var(--space-xl);
        gap: var(--space-lg);
        transition: right 0.3s ease;
        border-left: 1px solid var(--border-color);
        z-index: var(--z-dropdown);
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    .nav-link {
        font-size: var(--fs-lg);
        padding: var(--space-sm) 0;
    }
    
    .nav-cta {
        margin-top: var(--space-lg);
    }
    
    .hamburger {
        display: flex;
        z-index: calc(var(--z-dropdown) + 1);
    }
    
    /* Hero */
    .hero-buttons {
        flex-direction: column;
        gap: var(--space-md);
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .scroll-indicator {
        display: none;
    }
    
    /* About */
    .about-features {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Factory */
    .factory-process {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Stats */
    .stats-container {
        gap: var(--space-2xl);
    }
    
    .stat-number {
        font-size: 3.5rem;
    }
    
    /* Services */
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Audience */
    .audience-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Benefits */
    .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Cases */
    .case-card {
        flex: 0 0 280px;
    }
    
    /* Contact */
    .contact-container {
        grid-template-columns: 1fr;
        gap: var(--space-2xl);
    }
    
    .contact-info {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-md);
    }
    
    .contact-card {
        flex-direction: column;
        text-align: center;
        padding: var(--space-lg);
    }
    
    .contact-card a {
        flex-direction: column;
        text-align: center;
    }
    
    /* Footer */
    .footer-content {
        flex-direction: column;
        gap: var(--space-xl);
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: var(--space-lg);
    }
}

/* --------------------------------------------------------------------------
   Mobile Large (576px - 767px)
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
    :root {
        --container-padding: 1rem;
        --space-5xl: 4rem;
        --space-4xl: 3rem;
        --space-3xl: 2.5rem;
    }
    
    /* Typography */
    .hero-title {
        font-size: 2.25rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .section-subtitle {
        font-size: var(--fs-base);
    }
    
    /* Section header */
    .section-header {
        margin-bottom: var(--space-2xl);
    }
    
    /* Hero */
    .hero {
        min-height: 100vh;
        padding-top: 100px;
    }
    
    .hero-badge {
        font-size: var(--fs-xs);
        padding: var(--space-xs) var(--space-md);
    }
    
    .hero-subtitle {
        font-size: var(--fs-base);
    }
    
    /* About */
    .about-text p {
        font-size: var(--fs-base);
    }
    
    .about-features {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
    }
    
    .feature-card {
        padding: var(--space-lg);
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
    }
    
    .feature-card h3 {
        font-size: var(--fs-base);
    }
    
    /* Factory */
    .factory-process {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .process-step {
        padding: var(--space-lg);
    }
    
    /* Stats */
    .stats-container {
        flex-direction: column;
        gap: var(--space-lg);
    }
    
    .stat-card {
        padding: var(--space-xl);
    }
    
    .stat-number {
        font-size: 3rem;
    }
    
    /* Problems */
    .problems-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
    }
    
    .problem-item {
        padding: var(--space-lg);
    }
    
    .problem-item h3 {
        font-size: var(--fs-base);
    }
    
    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .service-card {
        padding: var(--space-xl);
    }
    
    /* Audience */
    .audience-grid {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .audience-card {
        padding: var(--space-lg);
    }
    
    /* Differentials */
    .differential-item {
        padding: var(--space-lg);
    }
    
    .differential-text h3 {
        font-size: var(--fs-base);
    }
    
    /* Benefits */
    .benefits-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
    }
    
    .benefit-card {
        padding: var(--space-lg);
    }
    
    .benefit-card svg {
        width: 36px;
        height: 36px;
    }
    
    .benefit-card h3 {
        font-size: var(--fs-base);
    }
    
    /* Cases */
    .case-card {
        flex: 0 0 260px;
        padding: var(--space-lg);
    }
    
    .cases-cta h3 {
        font-size: var(--fs-xl);
    }
    
    /* CTA */
    .cta-content h2 {
        font-size: var(--fs-2xl);
    }
    
    .cta-content p {
        font-size: var(--fs-base);
    }
    
    /* Contact */
    .contact-info {
        grid-template-columns: 1fr;
    }
    
    .contact-card {
        flex-direction: row;
        text-align: left;
    }
    
    .contact-card a {
        flex-direction: row;
        text-align: left;
    }
    
    .contact-form {
        padding: var(--space-xl);
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

/* --------------------------------------------------------------------------
   Mobile Small (up to 575px)
   -------------------------------------------------------------------------- */
@media (max-width: 575px) {
    :root {
        --container-padding: 1rem;
        --space-5xl: 3rem;
        --space-4xl: 2.5rem;
    }
    
    /* Typography */
    .hero-title {
        font-size: 1.875rem;
        line-height: 1.3;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    /* Navigation */
    .nav-menu {
        width: 100%;
        right: -100%;
    }
    
    .logo {
        font-size: var(--fs-lg);
    }
    
    /* Hero */
    .hero {
        padding: 80px 0 40px;
    }
    
    .hero-content {
        padding: var(--space-xl) 0;
    }
    
    .hero-buttons .btn {
        width: 100%;
        padding: var(--space-md) var(--space-lg);
    }
    
    /* About */
    .about-features {
        grid-template-columns: 1fr;
    }
    
    /* Problems */
    .problems-grid {
        grid-template-columns: 1fr;
    }
    
    /* Benefits */
    .benefits-grid {
        grid-template-columns: 1fr;
    }
    
    /* Cases */
    .case-card {
        flex: 0 0 calc(100vw - 3rem);
    }
    
    .cases-nav {
        display: none;
    }
    
    /* CTA */
    .cta-section {
        padding: var(--space-3xl) 0;
    }
    
    .cta-content h2 {
        font-size: var(--fs-xl);
    }
    
    /* Contact */
    .contact-form {
        padding: var(--space-lg);
    }
    
    .form-group input,
    .form-group textarea {
        padding: var(--space-sm) var(--space-md);
    }
    
    .btn-full {
        padding: var(--space-md);
    }
    
    /* Footer */
    .footer-links {
        flex-direction: column;
        gap: var(--space-md);
    }
}

/* --------------------------------------------------------------------------
   Extra Small (up to 375px)
   -------------------------------------------------------------------------- */
@media (max-width: 375px) {
    .hero-title {
        font-size: 1.625rem;
    }
    
    .section-title {
        font-size: 1.375rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    .stat-symbol {
        font-size: 1.5rem;
    }
}

/* --------------------------------------------------------------------------
   Landscape Mobile
   -------------------------------------------------------------------------- */
@media (max-width: 991px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 100px 0 60px;
    }
    
    .scroll-indicator {
        display: none;
    }
}

/* --------------------------------------------------------------------------
   High DPI / Retina Displays
   -------------------------------------------------------------------------- */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Crisp borders on retina */
    .feature-card,
    .service-card,
    .audience-card,
    .benefit-card,
    .case-card,
    .differential-item,
    .contact-card,
    .contact-form {
        border-width: 0.5px;
    }
}

/* --------------------------------------------------------------------------
   Print Styles
   -------------------------------------------------------------------------- */
@media print {
    .header,
    .loading-screen,
    .scroll-indicator,
    .hamburger,
    .cases-nav,
    .cta-section,
    .contact-form {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .section {
        padding: 2rem 0;
        page-break-inside: avoid;
    }
    
    .hero {
        min-height: auto;
        padding: 2rem 0;
    }
    
    * {
        color: black !important;
        background: white !important;
        box-shadow: none !important;
    }
}

/* --------------------------------------------------------------------------
   Touch Device Optimizations
   -------------------------------------------------------------------------- */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn {
        min-height: 48px;
    }
    
    .nav-link {
        padding: var(--space-md) 0;
    }
    
    /* Remove hover effects that don't work on touch */
    .feature-card:hover,
    .service-card:hover,
    .audience-card:hover,
    .benefit-card:hover,
    .case-card:hover,
    .differential-item:hover {
        transform: none;
    }
    
    /* Increase form element sizes */
    .form-group input,
    .form-group textarea {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: var(--space-md);
    }
}

/* --------------------------------------------------------------------------
   Dark Mode Preference (Already dark, but for future reference)
   -------------------------------------------------------------------------- */
@media (prefers-color-scheme: light) {
    /* Site is dark by default, but you can add light mode styles here if needed */
}
