/**
 * CSS Global - Sistema de Locação de Vestuários v2.0
 * Estilos base que podem ser reutilizados em todas as páginas
 */

/* Variáveis CSS */
:root {
    --primary-blue: #1e3a8a;
    --primary-blue-light: #3b82f6;
    --primary-blue-dark: #1e40af;
    --secondary-gray: #f8fafc;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    --border-color: #e5e7eb;
    --bg-white: #ffffff;
    --bg-light: #f9fafb;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --border-radius: 12px;
    --sidebar-width: 280px;
    --sidebar-collapsed-width: 80px;
}

/* Reset Global */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body Base */
body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
}

/* Layout Principal */
.main-container {
    display: flex;
    min-height: 100vh;
}

/* Área de Conteúdo */
.content-area {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    background: var(--bg-light);
    min-height: 100vh;
    transition: margin-left 0.3s ease, width 0.3s ease;
}

.content-area.expanded {
    margin-left: var(--sidebar-collapsed-width) !important;
    width: calc(100% - var(--sidebar-collapsed-width)) !important;
}

/* Headers Padrão */
.page-header {
    background: white;
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.page-title h1 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-top: 0.1rem;
}

/* Content Padding */
.page-content {
    padding: 2rem;
}

/* Botões Base */
.btn-primary-custom {
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary-custom:hover {
    background: var(--primary-blue-dark);
    color: white;
    text-decoration: none;
}

/* Botão secundário personalizado */
.btn-secondary-custom {
    background-color: #6c757d;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary-custom:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Cards Base */
.card-custom {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.card-custom:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

/* Forms Base */
.form-label-custom {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    display: block;
}

.form-control-custom {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.875rem;
    transition: border-color 0.2s;
    width: 100%;
}

.form-control-custom:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    outline: none;
}

/* Grid Base */
.grid-auto {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

/* Tabelas Base */
.table-custom {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.table-custom table {
    width: 100%;
    border-collapse: collapse;
}

.table-custom th {
    background: var(--bg-light);
    padding: 1rem;
    font-weight: 600;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.875rem;
    color: var(--text-primary);
}

.table-custom td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.875rem;
}

.table-custom tr:last-child td {
    border-bottom: none;
}

.table-custom tr:hover {
    background: var(--bg-light);
}

/* Responsividade Base */
@media (max-width: 768px) {
    .content-area {
        margin-left: 0 !important;
        width: 100% !important;
        padding-top: 60px; /* Espaço para o header mobile */
    }

    .page-header {
        /* Mantém o header visível no mobile */
        padding: 1rem; /* Reduz padding no mobile */
        flex-wrap: wrap; /* Permite quebra de linha se necessário */
    }

    .page-content {
        padding: 1rem;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .grid-auto {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.w-100 { width: 100%; }
.h-100 { height: 100%; }

.d-flex { display: flex; }
.d-block { display: block; }
.d-none { display: none; }

.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }

.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }

.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }


/* ===== Alertas de Pagamento ===== */
.payment-alert {
    margin: 15px 20px;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 13px;
    animation: slideDown 0.3s ease-out;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.payment-alert-content {
   
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.payment-alert-message {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.payment-alert-message i {
    font-size: 16px;
}

.payment-alert-message strong {
    font-weight: 600;
}

.payment-alert-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    background: rgba(255,255,255,0.2);
    border-radius: 5px;
    color: inherit;
    text-decoration: none;
    font-weight: 500;
    font-size: 12px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.payment-alert-link:hover {
    background: rgba(255,255,255,0.3);
    transform: translateX(2px);
    text-decoration: none;
    color: inherit;
}

.payment-alert-link i {
    font-size: 10px;
}

/* Variações de tipo */
.payment-alert.info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.payment-alert.warning {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.payment-alert.danger {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: #333;
}

.payment-alert.danger .payment-alert-link {
    background: rgba(0,0,0,0.1);
}

.payment-alert.danger .payment-alert-link:hover {
    background: rgba(0,0,0,0.2);
}

/* Animação de entrada */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsividade */
@media (max-width: 768px) {
    .payment-alert {
        margin: 10px 15px;
        font-size: 12px;
    }
    
    .payment-alert-content {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .payment-alert-link {
        text-align: center;
        justify-content: center;
    }
}
