/* Mobile Responsive Enhancements */

/* Touch-friendly buttons and inputs */
@media (max-width: 768px) {
    /* Minimum touch target size (44x44px) */
    button, .bd-btn, a.bd-btn, input[type="submit"], input[type="button"] {
        min-height: 44px;
        min-width: 44px;
        padding: 12px 20px;
        font-size: 16px; /* Prevents zoom on iOS */
    }

    /* Form inputs */
    input[type="text"],
    input[type="email"],
    input[type="password"],
    input[type="number"],
    textarea,
    select {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 12px 15px;
        min-height: 44px;
    }

    /* Better spacing for mobile */
    .form-input-box-full {
        margin-bottom: 25px;
    }

    .form-option-card {
        margin-bottom: 15px;
    }

    /* Tab buttons - stack on mobile */
    .tab-btn-full {
        min-height: 50px;
        padding: 15px 20px;
        font-size: 15px;
    }

    /* Generator form wrapper */
    .bd-generator-form-wrapper-full {
        padding: 25px 20px;
    }

    /* Hero section adjustments */
    .bd-hero-area {
        padding: 60px 0 40px;
        min-height: auto;
    }

    .bd-banner-title {
        font-size: 2rem !important;
        line-height: 1.3 !important;
        margin-bottom: 1rem !important;
    }

    .bd-banner-intro {
        font-size: 1rem !important;
        margin-bottom: 1.5rem !important;
    }

    /* Floating stats - hide or reposition on mobile */
    .stat-bubble {
        position: relative !important;
        display: inline-block;
        margin: 10px;
        min-width: 100px;
    }

    /* Video preview - full width on mobile */
    .bd-hero-video-preview {
        margin-top: 30px;
    }

    /* Dropzone - better mobile experience */
    .dropzone-wrapper-simple {
        padding: 20px 15px;
        min-height: 100px;
    }

    .dropzone-simple .dz-message {
        font-size: 14px;
    }

    .dropzone-simple .dz-message i {
        font-size: 32px;
    }

    /* Cards and grids */
    .generator-tabs-nav-full {
        flex-wrap: wrap;
        gap: 10px;
    }

    .form-options-grid .row {
        margin: 0;
    }

    .form-options-grid .col-lg-5,
    .form-options-grid .col-md-6 {
        padding: 0 10px;
        margin-bottom: 15px;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    /* Container padding */
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Hero adjustments */
    .bd-banner-title {
        font-size: 1.75rem !important;
    }

    .bd-banner-button {
        flex-direction: column;
        width: 100%;
    }

    .bd-banner-button .bd-btn {
        width: 100%;
        margin-bottom: 10px;
    }

    /* Stats - single column */
    .bd-hero-stats {
        flex-direction: column;
        gap: 20px;
        width: 100%;
    }

    .stat-item {
        width: 100%;
    }

    /* Tabs - full width buttons */
    .tab-btn-full {
        width: 100%;
        margin-bottom: 10px;
    }

    /* Form elements */
    .form-input-title-full label {
        font-size: 14px;
    }

    .form-hint {
        font-size: 12px;
    }

    /* Generator header */
    .generator-header-full {
        padding: 0 10px;
    }

    .generator-title-full {
        font-size: 1.75rem !important;
    }

    .generator-description-full {
        font-size: 0.95rem !important;
    }

    /* Dropzone previews - stack vertically */
    .dropzone-simple .dz-preview {
        width: 100% !important;
        margin: 5px 0;
    }
}

/* Landscape orientation adjustments */
@media (max-width: 768px) and (orientation: landscape) {
    .bd-hero-area {
        min-height: auto;
        padding: 40px 0;
    }

    .bd-banner-title {
        font-size: 1.5rem !important;
    }
}

/* Tablet adjustments */
@media (min-width: 769px) and (max-width: 991px) {
    .bd-banner-title {
        font-size: 2.5rem !important;
    }

    .generator-tabs-nav-full {
        gap: 15px;
    }

    .tab-btn-full {
        padding: 12px 18px;
        font-size: 14px;
    }
}

/* Prevent horizontal scroll */
html, body {
    overflow-x: hidden;
    max-width: 100%;
}

/* Better text selection on mobile */
* {
    -webkit-tap-highlight-color: rgba(102, 126, 234, 0.2);
}

/* Smooth scrolling */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* Loading states for mobile */
@media (max-width: 768px) {
    .loading-shimmer {
        min-height: 200px;
    }
}

/* Dashboard mobile improvements */
@media (max-width: 768px) {
    .dashboard-sidebar {
        position: relative !important;
        margin-bottom: 20px;
    }

    .stat-card {
        margin-bottom: 15px;
    }

    .action-card {
        margin-bottom: 15px;
    }

    .generations-grid {
        grid-template-columns: 1fr !important;
    }
}

/* API Keys page mobile */
@media (max-width: 768px) {
    .api-stats {
        grid-template-columns: 1fr !important;
    }

    .api-key-card {
        padding: 20px 15px;
    }

    .api-key-card .row {
        flex-direction: column;
    }

    .api-key-card .col-lg-6 {
        width: 100%;
        margin-bottom: 15px;
    }
}

/* Template cards mobile */
@media (max-width: 768px) {
    .template-grid {
        grid-template-columns: 1fr !important;
    }
}

/* Better focus states for mobile */
@media (max-width: 768px) {
    input:focus,
    textarea:focus,
    select:focus,
    button:focus {
        outline: 2px solid rgba(102, 126, 234, 0.5);
        outline-offset: 2px;
    }
}

