/* =====================================================
   SISTEMA DE GESTÃO DE PARCERIAS COM OSCs
   CSS Principal - Design Moderno e Elegante
   ===================================================== */

/* ===== VARIÁVEIS CSS ===== */
:root {
    --primary-color: #F17633;
    --secondary-color: #F2EADF;
    --text-color: #000000;
    --white-color: #FFFFFF;
    --primary-hover: #e06528;
    --secondary-hover: #e8d8c8;
    --shadow-light: rgba(241, 118, 51, 0.1);
    --shadow-medium: rgba(241, 118, 51, 0.2);
    --shadow-dark: rgba(241, 118, 51, 0.3);
    --gradient-primary: linear-gradient(135deg, #F17633 0%, #e06528 100%);
    --gradient-secondary: linear-gradient(135deg, #F2EADF 0%, #e8d8c8 100%);
    --gradient-background: linear-gradient(135deg, #F17633 0%, #f8a726 50%, #F17633 100%);
    --border-radius: 16px;
    --border-radius-lg: 24px;
    --border-radius-xl: 32px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --box-shadow-hover: 0 16px 48px rgba(241, 118, 51, 0.2);
    --box-shadow-card: 0 20px 60px rgba(0, 0, 0, 0.15);
    --box-shadow-input: 0 4px 16px rgba(0, 0, 0, 0.08);
    --box-shadow-button: 0 8px 24px rgba(241, 118, 51, 0.3);
}

/* ===== RESET E BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--gradient-background);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ===== PÁGINA DE LOGIN ===== */
.login-page {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: var(--gradient-background);
}

/* ===== BACKGROUND ANIMADO ===== */
.login-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.gradient-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(241, 118, 51, 0.9) 0%, rgba(248, 167, 38, 0.8) 100%);
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 120px;
    height: 120px;
    top: 60%;
    right: 15%;
    animation-delay: 1s;
}

.shape-3 {
    width: 60px;
    height: 60px;
    top: 80%;
    left: 20%;
    animation-delay: 2s;
}

.shape-4 {
    width: 100px;
    height: 100px;
    top: 10%;
    right: 30%;
    animation-delay: 3s;
}

.shape-5 {
    width: 70px;
    height: 70px;
    top: 40%;
    left: 5%;
    animation-delay: 4s;
}

.shape-6 {
    width: 90px;
    height: 90px;
    bottom: 20%;
    right: 5%;
    animation-delay: 5s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.7;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 1;
    }
}

/* ===== CONTAINER PRINCIPAL ===== */
.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 480px;
}

/* ===== CARD DE LOGIN ===== */
.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: var(--border-radius-xl);
    padding: 48px 40px;
    box-shadow: var(--box-shadow-card);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateY(0);
    transition: var(--transition);
}

.login-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.2);
}

/* ===== HEADER DO CARD ===== */
.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.logo-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--box-shadow-button);
    transition: var(--transition);
}

.logo-icon:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 32px rgba(241, 118, 51, 0.4);
}

.logo-icon i {
    font-size: 32px;
    color: var(--white-color);
}

.login-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-subtitle {
    font-size: 16px;
    color: #666;
    font-weight: 400;
    margin: 0;
}

/* ===== FORMULÁRIO ===== */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    position: relative;
}

.input-container {
    position: relative;
    display: flex;
    align-items: center;
    background: var(--white-color);
    border-radius: var(--border-radius);
    border: 2px solid transparent;
    box-shadow: var(--box-shadow-input);
    transition: var(--transition);
    overflow: hidden;
}

.input-container:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(241, 118, 51, 0.1);
    transform: translateY(-2px);
}

.input-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    transition: var(--transition);
}

.input-container:focus-within .input-icon {
    color: var(--primary-color);
}

.input-container input {
    flex: 1;
    height: 56px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 16px;
    color: var(--text-color);
    padding: 0 20px 0 0;
    font-weight: 500;
}

.input-container input::placeholder {
    color: #999;
    font-weight: 400;
}

.input-focus-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--gradient-primary);
    transition: var(--transition);
}

.input-container:focus-within .input-focus-border {
    width: 100%;
}

.toggle-password {
    width: 56px;
    height: 56px;
    border: none;
    background: transparent;
    color: #999;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.toggle-password:hover {
    color: var(--primary-color);
}

/* ===== OPÇÕES DO FORMULÁRIO ===== */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.checkbox-container input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #ddd;
    border-radius: 4px;
    position: relative;
    transition: var(--transition);
    background: var(--white-color);
}

.checkbox-container input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkbox-container input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--white-color);
    font-size: 12px;
    font-weight: bold;
}

.checkbox-label {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.forgot-password:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* ===== BOTÕES ===== */
.login-btn, .register-btn {
    position: relative;
    width: 100%;
    height: 56px;
    border: none;
    border-radius: var(--border-radius);
    background: var(--gradient-primary);
    color: var(--white-color);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    box-shadow: var(--box-shadow-button);
    transition: var(--transition);
    overflow: hidden;
}

.login-btn:hover, .register-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(241, 118, 51, 0.4);
}

.login-btn:active, .register-btn:active {
    transform: translateY(0);
}

.btn-text {
    transition: var(--transition);
}

.btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
}

.login-btn.loading .btn-text,
.register-btn.loading .btn-text {
    opacity: 0;
}

.login-btn.loading .btn-icon,
.register-btn.loading .btn-icon {
    opacity: 0;
}

.login-btn.loading .btn-loading,
.register-btn.loading .btn-loading {
    display: block;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid var(--white-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== DIVISOR ===== */
.divider {
    position: relative;
    text-align: center;
    margin: 24px 0;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e0e0e0;
}

.divider-text {
    background: rgba(255, 255, 255, 0.95);
    padding: 0 16px;
    color: #666;
    font-size: 14px;
    font-weight: 500;
}

/* ===== BOTÃO GOV.BR ===== */
.gov-br-btn {
    width: 100%;
    height: 56px;
    border: 2px solid #e0e0e0;
    border-radius: var(--border-radius);
    background: var(--white-color);
    color: #333;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: var(--transition);
}

.gov-br-btn:hover {
    border-color: var(--primary-color);
    background: rgba(241, 118, 51, 0.05);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow-input);
}

.gov-icon {
    color: var(--primary-color);
    font-size: 18px;
}

/* ===== LINK DE CADASTRO ===== */
.register-link {
    text-align: center;
    margin-top: 16px;
}

.register-link p {
    color: #666;
    font-size: 14px;
    margin: 0;
}

.register-link-btn {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.register-link-btn:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* ===== MODAL DE CADASTRO ===== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.show {
    display: flex;
    animation: modalFadeIn 0.3s ease-out;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
}

.modal-content {
    position: relative;
    background: var(--white-color);
    border-radius: var(--border-radius-xl);
    padding: 0;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: var(--transition);
}

.modal.show .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 32px 40px 24px;
    border-bottom: 1px solid #f0f0f0;
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 16px;
}

.modal-icon {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white-color);
    font-size: 20px;
}

.modal-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.close-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: #f5f5f5;
    border-radius: 50%;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.close-btn:hover {
    background: #e0e0e0;
    color: var(--text-color);
    transform: rotate(90deg);
}

/* ===== FORMULÁRIO DE CADASTRO ===== */
.register-form {
    padding: 32px 40px 40px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.register-form .form-group {
    margin-bottom: 24px;
}

.register-form label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
}

/* ===== SELECT PERSONALIZADO ===== */
.select-container {
    position: relative;
    display: flex;
    align-items: center;
    background: var(--white-color);
    border-radius: var(--border-radius);
    border: 2px solid transparent;
    box-shadow: var(--box-shadow-input);
    transition: var(--transition);
    overflow: hidden;
}

.select-container:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(241, 118, 51, 0.1);
    transform: translateY(-2px);
}

.select-container select {
    flex: 1;
    height: 56px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 16px;
    color: var(--text-color);
    padding: 0 56px 0 20px;
    font-weight: 500;
    cursor: pointer;
    appearance: none;
}

.select-container select option {
    background: var(--white-color);
    color: var(--text-color);
    padding: 12px;
}

.select-arrow {
    position: absolute;
    right: 20px;
    color: #999;
    pointer-events: none;
    transition: var(--transition);
}

.select-container:focus-within .select-arrow {
    color: var(--primary-color);
    transform: rotate(180deg);
}

/* ===== NOTIFICAÇÕES ===== */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--white-color);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10000;
    transform: translateX(100%);
    transition: var(--transition);
    max-width: 400px;
    border-left: 4px solid var(--primary-color);
}

.notification.show {
    transform: translateX(0);
}

.notification-success {
    border-left-color: #4caf50;
}

.notification-error {
    border-left-color: #f44336;
}

.notification-icon {
    font-size: 20px;
}

.notification-success .notification-icon {
    color: #4caf50;
}

.notification-error .notification-icon {
    color: #f44336;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.notification-message {
    font-size: 14px;
    color: #666;
}

/* ===== ESTADOS DE ERRO ===== */
.form-group {
    position: relative;
}

.error-message {
    color: #f44336;
    font-size: 12px;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.input-container.error {
    border-color: #f44336;
    box-shadow: 0 0 0 4px rgba(244, 67, 54, 0.1);
}

/* ===== CARDS DE PARCERIAS ===== */

.partnerships-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.partnership-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.partnership-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.partnership-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e1e5e9;
}

.partnership-header h4 {
    margin: 0;
    color: #2c3e50;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.3;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-rascunho {
    background: #f8f9fa;
    color: #6c757d;
}

.status-enviada {
    background: #e3f2fd;
    color: #1976d2;
}

.status-em_analise {
    background: #fff3e0;
    color: #f57c00;
}

.status-aprovada {
    background: #e8f5e8;
    color: #388e3c;
}

.status-rejeitada {
    background: #ffebee;
    color: #d32f2f;
}

.status-cancelada {
    background: #fafafa;
    color: #757575;
}

.partnership-info {
    margin-bottom: 1.5rem;
}

.partnership-info p {
    margin: 0.5rem 0;
    color: #555;
    font-size: 0.9rem;
    line-height: 1.4;
}

.partnership-info strong {
    color: #2c3e50;
    font-weight: 600;
}

.partnership-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.partnership-actions .btn {
    flex: 1;
    min-width: 100px;
    font-size: 0.8rem;
    padding: 0.5rem 0.75rem;
}

.no-data {
    text-align: center;
    padding: 3rem 1rem;
    color: #6c757d;
    grid-column: 1 / -1;
}

.no-data i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.no-data p {
    font-size: 1.1rem;
    margin: 0;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 768px) {
    .login-card {
        padding: 32px 24px;
        margin: 20px;
    }
    
    .modal-content {
        margin: 20px;
        max-height: calc(100vh - 40px);
    }
    
    .modal-header,
    .register-form {
        padding: 24px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .login-header h1 {
        font-size: 24px;
    }
    
    .logo-icon {
        width: 64px;
        height: 64px;
    }
    
    .logo-icon i {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 24px 20px;
    }
    
    .modal-header,
    .register-form {
        padding: 20px;
    }
    
    .form-options {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
}

/* ===== ANIMAÇÕES ===== */
@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ===== SCROLLBAR PERSONALIZADA ===== */
.modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--primary-hover);
}

