/* ==========================================================================
   ANDALUZA TRANS - MODERN RESPONSIVE CORE CSS
   ========================================================================== */

:root {
    --primary: #0284c7;
    --primary-dark: #0369a1;
    --primary-light: #e0f2fe;
    --secondary: #0f172a;
    --secondary-light: #1e293b;
    --accent: #10b981;
    --accent-hover: #059669;
    --warning: #f59e0b;
    --danger: #ef4444;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --border: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --radius-sm: 0.375rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-full: 9999px;
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-dark);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* NAVBAR */
.navbar {
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: var(--shadow-sm);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 72px;
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--secondary);
    letter-spacing: -0.5px;
    text-decoration: none;
    line-height: 1;
}

.brand-logo span {
    color: var(--primary);
}

.navbar-logo-img {
    height: 44px;
    width: auto;
    max-height: 48px;
    max-width: 250px;
    object-fit: contain;
    display: block;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.brand-logo:hover .navbar-logo-img {
    opacity: 0.92;
    transform: scale(1.02);
}

.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 1.25rem;
}

.nav-link {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-main);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
    background-color: var(--primary-light);
}

.btn-nav-wa {
    background: var(--accent);
    color: #ffffff !important;
    padding: 0.55rem 1.25rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
    transition: all 0.2s ease;
}

.btn-nav-wa:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

/* Mobile Nav Toggle */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--secondary);
}

.mobile-menu-drawer {
    display: none;
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem;
    box-shadow: var(--shadow-md);
}

.mobile-menu-drawer.show {
    display: block;
}

.mobile-menu-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.mobile-menu-list a {
    display: block;
    padding: 0.6rem 0.75rem;
    font-weight: 600;
    color: var(--text-main);
    border-radius: var(--radius-sm);
}

.mobile-menu-list a:hover, .mobile-menu-list a.active {
    background: var(--primary-light);
    color: var(--primary);
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    text-align: center;
}

.btn-primary {
    background: var(--primary);
    color: #ffffff;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: #ffffff;
}

.btn-whatsapp {
    background: #25d366;
    color: #ffffff !important;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
    background: #1eb956;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.4);
}

.btn-secondary {
    background: #e2e8f0;
    color: var(--text-main);
}

.btn-secondary:hover {
    background: #cbd5e1;
}

.btn-sm {
    padding: 0.45rem 0.9rem;
    font-size: 0.85rem;
    border-radius: var(--radius-sm);
}

/* CARDS & GRIDS */
.grid {
    display: grid;
    gap: 1.5rem;
}

.grid-cols-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.card-service {
    border-top: 4px solid var(--primary);
}

/* BADGES */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    text-transform: uppercase;
}

.badge-success { background: #dcfce7; color: #15803d; }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-primary { background: var(--primary-light); color: var(--primary-dark); }
.badge-neutral { background: #f1f5f9; color: #475569; }

/* FORMS */
.form-group {
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
}

.form-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 0.45rem;
}

.label-title {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.badge-required {
    font-size: 0.725rem;
    font-weight: 700;
    color: #dc2626;
    background: #fee2e2;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-full);
}

.badge-optional {
    font-size: 0.725rem;
    font-weight: 500;
    color: var(--text-muted);
    background: #f1f5f9;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-full);
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-main);
    background-color: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
    background-color: #ffffff;
}

.form-control::placeholder {
    color: #94a3b8;
    font-size: 0.9rem;
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
    line-height: 1.6;
}

.input-highlight {
    border-color: #86efac;
    background-color: #f0fdf4;
}

.input-highlight:focus {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.form-hint {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.35rem;
    line-height: 1.4;
}

.form-hint-wa {
    color: #15803d;
    font-weight: 500;
}

/* FLOATING WA BUTTON */
.floating-wa {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 99;
    background: #25d366;
    color: #ffffff;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
}

.floating-wa:hover {
    transform: scale(1.1);
    color: #ffffff;
}

/* FLOATING CS BUTTON */
.floating-cs-container {
    position: fixed;
    bottom: 95px;
    right: 25px;
    z-index: 99;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.floating-cs {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(2, 132, 199, 0.45);
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    outline: none;
    position: relative;
}

.floating-cs:hover {
    transform: scale(1.1);
    color: #ffffff;
    box-shadow: 0 6px 20px rgba(2, 132, 199, 0.55);
}

.floating-cs-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 13px;
    height: 13px;
    background: #22c55e;
    border-radius: 50%;
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.3);
}

.floating-cs-label {
    background: #0f172a;
    color: #ffffff;
    padding: 0.45rem 0.9rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
    opacity: 0;
    transform: translateX(10px);
    transition: all 0.25s ease;
    pointer-events: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
}

.floating-cs-container:hover .floating-cs-label {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

/* CS MODAL WIDGET */
.cs-modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 25px;
    box-sizing: border-box;
}

.cs-modal-backdrop.active {
    display: flex;
}

.cs-modal-card {
    background: #ffffff;
    width: 100%;
    max-width: 440px;
    max-height: calc(100vh - 40px);
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: csSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid var(--border);
}

@keyframes csSlideUp {
    from {
        opacity: 0;
        transform: translateY(25px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.cs-modal-header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: #ffffff;
    padding: 1.15rem 1.4rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cs-modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #ffffff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s;
}

.cs-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

.cs-modal-body {
    padding: 1.25rem 1.4rem;
    overflow-y: auto;
    max-height: calc(100vh - 150px);
}

/* FOOTER */
.footer {
    background: var(--secondary);
    color: #94a3b8;
    margin-top: auto;
    padding: 3.5rem 0 1.5rem;
    border-top: 1px solid #334155;
}

.footer h4 {
    color: #ffffff;
    margin-bottom: 1rem;
}

.footer a {
    color: #cbd5e1;
}

.footer a:hover {
    color: #ffffff;
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid #1e293b;
    text-align: center;
    font-size: 0.875rem;
}

/* ALERTS */
.alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.alert-success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.alert-error { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }

/* RESPONSIVE */
@media (max-width: 900px) {
    .nav-menu {
        display: none;
    }
    .mobile-toggle {
        display: block;
    }
}

@media (max-width: 640px) {
    .navbar-logo-img {
        height: 38px;
        max-width: 200px;
    }
    .grid-cols-2, .grid-cols-3, .grid-cols-4 {
        grid-template-columns: 1fr;
    }
    .hero-title {
        font-size: 2rem !important;
    }
    .section-title {
        font-size: 1.6rem !important;
    }
    .floating-cs-container {
        bottom: 85px;
        right: 18px;
    }
    .floating-wa {
        bottom: 18px;
        right: 18px;
        width: 52px;
        height: 52px;
    }
    .floating-cs {
        width: 52px;
        height: 52px;
    }
    .floating-cs-label {
        display: none;
    }
    .cs-modal-backdrop {
        padding: 0;
        align-items: flex-end;
    }
    .cs-modal-card {
        max-width: 100%;
        border-radius: 20px 20px 0 0;
        max-height: 90vh;
    }
}

/* ==========================================================================
   PAGINATION STYLES (CLEAN, MODERN & RESPONSIVE)
   ========================================================================== */
.custom-pagination-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1.25rem 0.25rem 0.5rem;
    margin-top: 1.5rem;
    font-size: 0.875rem;
    border-top: 1px solid var(--border, #e2e8f0);
}

.pagination-info {
    color: var(--text-muted, #64748b);
    font-size: 0.9rem;
}

.pagination-info strong {
    color: var(--secondary, #0f172a);
}

.pagination-list {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.page-item {
    display: inline-flex;
}

.page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 0.75rem;
    border-radius: var(--radius-sm, 0.375rem);
    border: 1px solid var(--border, #e2e8f0);
    background: #ffffff;
    color: var(--text-main, #1e293b);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.15s ease;
}

.page-link:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: var(--primary, #0284c7);
}

.page-item.active .page-link {
    background: var(--primary, #0284c7) !important;
    color: #ffffff !important;
    border-color: var(--primary, #0284c7) !important;
    box-shadow: 0 2px 4px rgba(2, 132, 199, 0.25);
}

.page-item.disabled .page-link {
    opacity: 0.45;
    cursor: not-allowed;
    background: #f8fafc;
    color: #94a3b8;
    pointer-events: none;
}

/* Fallback constraint to prevent any SVG from ever expanding */
nav[role="navigation"] svg,
.pagination svg,
svg.w-5,
svg.h-5 {
    width: 16px !important;
    height: 16px !important;
    max-width: 16px !important;
    max-height: 16px !important;
}
