/* Responsive overrides for ActingDriversTrichy
   Loaded after style.css to provide additional mobile-first tweaks
*/


/* Container paddings */
@media (max-width: 1200px) {
    .container { padding-left: 2rem; padding-right: 2rem; }
}

@media (max-width: 992px) {
    .container { padding-left: 1.25rem; padding-right: 1.25rem; }
}

@media (max-width: 768px) {
    .container { padding-left: 1rem; padding-right: 1rem; }

    /* Navbar */
    .nav-toggle { display: flex; }
    .nav-links { 
        display: none; 
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        flex-direction: column;
        background: #fff;
        padding: 1rem 0;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        z-index: 999;
    }
    .nav-links.open { display: flex; }
    .nav-links li { padding: 0.5rem 1rem; }
    .nav-links a { display: block; padding: 0.5rem 0; }

    /* Hero */
    .hero { 
        padding: 80px 1rem 40px;
        min-height: auto;
    }
    .hero-inner { 
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 1rem 0 2rem;
        align-items: stretch;
    }
    .hero-content { 
        padding: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    .hero-image { display: none !important; }
    .hero-title { 
        font-size: clamp(1.4rem, 7vw, 2rem);
        margin-bottom: 1rem;
    }
    .hero-badge { font-size: 0.75rem; padding: 0.35rem 0.85rem; margin-bottom: 1rem; }
    .hero-subtitle { 
        font-size: 0.95rem;
        max-width: 100%;
        margin-bottom: 1.5rem;
    }
    .hero-actions { 
        flex-direction: column;
        gap: 0.75rem;
        margin-bottom: 1.5rem;
    }
    .hero-actions .btn { 
        width: 100%;
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }
    .hero-stats {
        flex-wrap: wrap;
        gap: 1rem;
        justify-content: flex-start;
    }
    .stat { flex-direction: row; gap: 0.5rem; }
    .stat-num { font-size: 1.2rem; }
    .stat-label { font-size: 0.7rem; }
    .stat-divider { display: none; }

    /* Sections */
    .section { padding: 1.25rem 0; }

    /* Cards & grids */
    .services-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
    .hiw-steps { flex-direction: column; gap: 1rem; }

    /* Forms */
    .form-row { grid-template-columns: 1fr; }
    .modal { max-width: 96%; padding: 1rem; }

    /* Footer */
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }

    /* Testimonials */
    .testimonials-layout {
        display: grid;
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .testimonials-right {
        display: none;
    }
}

/* Tablet landscape - medium optimization (769px to 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
    .container { padding-left: 1.5rem; padding-right: 1.5rem; }
    
    .hero {
        padding: 80px 1.5rem 60px;
        min-height: auto;
    }
    
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 2rem 0 2rem;
    }
    
    .hero-image { display: none; }
    
    .hero-title {
        font-size: clamp(1.6rem, 5vw, 2.2rem);
        margin-bottom: 1rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
        max-width: 100%;
    }
    
    .hero-actions {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.75rem;
    }
    
    .hero-stats {
        flex-direction: row;
        gap: 1rem;
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    html { font-size: 15px; }
    .logo { font-size: 1.15rem; }
    .navbar .nav-inner { height: 60px; }
    
    /* Hero section mobile optimizations */
    .hero { 
        padding-top: 60px;
        padding-bottom: 30px;
        min-height: auto;
    }
    .hero-title { 
        font-size: clamp(1.3rem, 8vw, 1.8rem);
        margin-bottom: 0.8rem;
    }
    .hero-badge { 
        font-size: 0.7rem;
        padding: 0.3rem 0.7rem;
        margin-bottom: 0.8rem;
    }
    .hero-subtitle {
        font-size: 0.9rem;
        margin-bottom: 1.25rem;
        line-height: 1.6;
    }
    .hero-actions { 
        flex-direction: column;
        gap: 0.6rem;
        margin-bottom: 1.25rem;
    }
    .hero-actions .btn { 
        width: 100%;
        padding: 0.7rem 1rem;
        font-size: 0.9rem;
    }
    .hero-stats {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }
    .stat { 
        flex-direction: row;
        gap: 0.4rem;
        align-items: center;
    }
    .stat-num { font-size: 1.1rem; }
    .stat-label { font-size: 0.65rem; }
    .hero-inner { padding: 0 0 1.5rem; }

    .btn { padding: .55rem .9rem; font-size: .86rem; }
    .btn-lg { padding: .7rem 1.2rem; }

    .footer { padding: 1.5rem 0 0; }
    .footer-grid { grid-template-columns: 1fr; }

    .bookings-table th, .bookings-table td { padding: .5rem .5rem; font-size: .82rem; }

    .side-menu { display: none; }

    /* Dashboard responsive */
    .dashboard-stats { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
    .dashboard-layout { grid-template-columns: 1fr; }
    .profile-card { display: block; width: 100%; max-width: 100%; margin-bottom: 1rem; }
    .dashboard-main { width: 100%; }
}

/* Tablet landscape (900px - 1200px) */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: minmax(0, 1fr) minmax(300px, 1fr);
        gap: 2rem;
    }
    .container { max-width: 95%; }
}

/* Tablet portrait (600px - 900px) */
@media (max-width: 896px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .hero-image { display: none !important; }
}

/* Utility tweaks */
@media (pointer: coarse) {
    .btn:hover { transform: none; }
}

/* ---- DASHBOARD RESPONSIVE OVERRIDES ---- */
@media (max-width: 1024px) {
    .dashboard-layout {
        grid-template-columns: 1fr 280px;
        gap: 1.5rem;
    }

    .dashboard-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .dashboard-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.85rem;
        margin-bottom: 1.5rem;
    }

    .stat-card {
        padding: 1rem;
        gap: 0.75rem;
    }

    .stat-card-icon {
        font-size: 1.5rem;
    }

    .stat-card-num {
        font-size: 1.4rem;
    }

    .stat-card-label {
        font-size: 0.75rem;
    }

    .dashboard-layout {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .profile-card {
        display: block;
        order: -1;
        width: 100%;
        max-width: 100%;
        margin-bottom: 1rem;
    }

    .dashboard-main {
        width: 100%;
    }

    .card {
        padding: 1.25rem;
        margin-bottom: 1rem;
    }

    .card-title {
        font-size: 1.15rem;
        font-weight: 700;
    }

    .card-header-row {
        flex-direction: column;
        gap: 0.75rem;
    }

    .bookings-table th, .bookings-table td {
        padding: 0.6rem 0.5rem;
        font-size: 0.78rem;
    }

    .bookings-table thead {
        display: none;
    }

    .bookings-table tr {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0.65rem;
        margin-bottom: 1rem;
        padding: 0.85rem 0.85rem 0.8rem;
        background: #fff;
        border: 1px solid var(--border);
        border-radius: 14px;
    }

    .bookings-table tbody tr {
        border-bottom: none;
    }

    .bookings-table td {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 0.6rem;
        padding: 0.35rem 0;
        border: none;
    }

    .bookings-table td::before {
        content: attr(data-label);
        font-size: 0.75rem;
        font-weight: 700;
        color: var(--text-muted);
    }

    .bookings-table td:last-child {
        padding-bottom: 0;
    }

    .table-wrapper {
        border-radius: 8px;
    }

    .bookings-table {
        min-width: auto;
        width: 100%;
    }

    .form-group {
        margin-bottom: 1.25rem;
    }

    .form-control, .form-group input, .form-group textarea {
        padding: 0.7rem 0.95rem;
        font-size: 0.95rem;
        border-radius: 8px;
    }

    .profile-form button {
        width: 100%;
        padding: 0.75rem;
        margin-bottom: 0.5rem;
    }

    #bookingSearch {
        width: 100%;
        margin-bottom: 1.25rem;
        padding: 0.75rem 0.95rem;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .dashboard-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        margin-bottom: 1.5rem;
    }

    .stat-card {
        padding: 1.2rem 1rem;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 0.7rem;
    }

    .stat-card-icon {
        font-size: 2rem;
        min-width: auto;
    }

    .stat-card-info {
        flex: 1;
    }

    .stat-card-num {
        font-size: 1.5rem;
        font-weight: 700;
    }

    .stat-card-label {
        font-size: 0.8rem;
        color: var(--text-muted);
    }

    .card {
        padding: 1.25rem 1rem;
        border-radius: 12px;
        margin-bottom: 1.5rem;
    }

    .card-header-row {
        gap: 0.75rem;
        margin-bottom: 1rem;
        flex-direction: column;
    }

    .card-title {
        font-size: 1.15rem;
        font-weight: 700;
    }

    .btn-sm {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
        width: 100%;
    }

    .bookings-table th, .bookings-table td {
        padding: 0.65rem 0.5rem;
        font-size: 0.8rem;
    }

    .bookings-table thead {
        display: none;
    }

    .bookings-table tr {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0.65rem;
        margin-bottom: 1rem;
        padding: 0.85rem 0.85rem 0.8rem;
        background: #fff;
        border: 1px solid var(--border);
        border-radius: 14px;
    }

    .bookings-table tbody tr {
        border-bottom: none;
    }

    .bookings-table td {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 0.5rem;
        padding: 0.35rem 0;
        border: none;
    }

    .bookings-table td::before {
        content: attr(data-label);
        font-size: 0.75rem;
        font-weight: 700;
        color: var(--text-muted);
    }

    .bookings-table td:last-child {
        padding-bottom: 0;
    }

    .table-wrapper {
        border-radius: 8px;
        margin-bottom: 1rem;
    }

    .bookings-table {
        min-width: auto;
        width: 100%;
    }

    #bookingSearch {
        width: 100%;
        margin-bottom: 1.25rem;
        padding: 0.8rem 1rem;
        font-size: 0.95rem;
        border-radius: 8px;
    }

    .form-group {
        margin-bottom: 1.25rem;
    }

    .form-label {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
        font-weight: 600;
    }

    .form-control, .form-group input, .form-group textarea {
        padding: 0.7rem 0.9rem;
        font-size: 0.95rem;
        border-radius: 8px;
    }

    .profile-form {
        margin: 0;
    }

    .profile-form button {
        width: 100%;
        padding: 0.75rem 1.2rem;
        font-size: 0.9rem;
        margin-bottom: 0.75rem;
    }

    .empty-state {
        padding: 2.5rem 1.5rem;
        text-align: center;
    }

    .empty-icon {
        font-size: 3rem;
        margin-bottom: 1rem;
    }

    .empty-state h3 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
        font-weight: 700;
    }

    .empty-state p {
        font-size: 0.9rem;
        margin-bottom: 1.25rem;
        color: var(--text-muted);
    }

    .alert {
        padding: 1rem 1.25rem;
        font-size: 0.9rem;
        margin-bottom: 1rem;
        border-radius: 8px;
    }

    .alert ul {
        margin: 0;
        padding-left: 1.25rem;
    }

    .alert li {
        font-size: 0.85rem;
        line-height: 1.5;
        margin-bottom: 0.4rem;
    }

    .page-hero-sm {
        padding: 4rem 0 2rem;
    }

    .page-hero-content h1 {
        font-size: clamp(1.4rem, 6vw, 1.8rem);
    }

    .page-hero-content p {
        font-size: 0.9rem;
    }

    .section {
        padding: 2rem 0;
    }

    .container {
        padding: 0 1rem;
    }
}
