:root {
    --primary-color: #C3F53C;
    --secondary-color: #2E6C86;
    --text-color: #333;
    --border-color: #ddd;
    --background-color: #f8f9fa;
    --white: #ffffff;
    --gray-light: #f5f5f5;
    --gray-medium: #999;
    --gray-dark: #666;
    --error-color: #dc3545;
    --success-color: #28a745;
    --border-radius: 8px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/*
.container {
    max-width: 1000px;
    width: 100%;
}
*/

/* Texto inicial */
.auth-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 20px;
}

.auth-header h1 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 32px;
    color: #2E6C86;
    margin-bottom: 10px;
    line-height: 1.2;
}

.auth-header p {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 18px;
    color: #666;
    margin: 0;
    line-height: 1.4;
}

/* Layout principal com duas colunas */
.auth-container-new {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 40px;
    padding: 40px;
    min-height: 500px;
}

/* Seções de login e cadastro */
.login-section,
.signup-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.section-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 10px;
    text-align: center;
}

/* Divisor vertical */
.vertical-divider {
    width: 1px;
    background-color: var(--border-color);
    margin: 0 20px;
}



/* Botões */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--text-color);
}

.btn-primary:hover {
    background-color: #b3e635;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: #245a73;
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
}

.btn-outline:hover {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-block {
    width: 100%;
    display: block;
}

/* Botão Google em destaque */
.btn-google-highlight {
    background-color: #4285F4;
    color: var(--white);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.btn-google-highlight:hover {
    background-color: #3367d6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.google-icon {
    flex-shrink: 0;
}

.btn-google {
    background-color: var(--white);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
}

.btn-google:hover {
    background-color: var(--gray-light);
    transform: translateY(-1px);
}

/* Formulários */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-color);
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 16px;
    font-family: inherit;
    transition: var(--transition);
    background-color: var(--white);
}

.form-control:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(46, 108, 134, 0.1);
}

.form-control::placeholder {
    color: var(--gray-medium);
}

/* Container de senha com ícone */
.password-input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-container .form-control {
    padding-right: 45px;
}

.toggle-password {
    position: absolute;
    right: 12px;
    cursor: pointer;
    user-select: none;
    font-size: 16px;
    color: var(--gray-medium);
    z-index: 2;
}

.toggle-password:hover {
    color: var(--text-color);
}

/* Links */
.forgot-password-link {
    text-align: center;
    margin-top: 15px;
}

.forgot-password-link a {
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.forgot-password-link a:hover {
    text-decoration: underline;
}

/* Separador "ou" */
.divider {
    display: flex;
    align-items: center;
    margin: 20px 0;
    color: var(--gray-medium);
    font-size: 14px;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: var(--border-color);
}

.divider::before {
    margin-right: 15px;
}

.divider::after {
    margin-left: 15px;
}

/* Links */
.link {
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.link:hover {
    text-decoration: underline;
}

.text-center {
    text-align: center;
}

.text-muted {
    color: var(--gray-medium);
    font-size: 14px;
}

/* Responsividade */
@media (max-width: 768px) {
    .auth-header {
        padding: 15px;
        margin-bottom: 30px;
    }
    
    .auth-header h1 {
        font-size: 24px;
    }
    
    .auth-header p {
        font-size: 16px;
    }
    
    .auth-container-new {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 20px;
    }
    
    .vertical-divider {
        display: none;
    }
}
    
    .login-section,
    .signup-section {
        border-bottom: 1px solid var(--border-color);
        padding-bottom: 30px;
    }
    
    .signup-section {
        border-bottom: none;
        padding-bottom: 0;
    }
}

/* Main Content Styles */
main {
    padding: 0px 0;
    min-height: calc(100vh - 300px); /* Altura mínima para manter o footer na parte inferior */
}

/* Estilos antigos removidos para evitar conflitos com o novo layout */
}

.auth-header p {
    color: #666;
    text-align: center;
    margin-bottom: 30px;
}

.tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
    border: none;
}

.tab-btn {
    color: #00597C;
    background: none;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn.active {
    font-weight: 600;
    border-bottom: 2px solid #00597C;
}

.form-group label {
    color: #00597C;
    font-weight: 500;
}

.password-input-container {
    position: relative;
}

/* Ajuste do campo de telefone para ficar em uma linha */
.phone-group {
    position: relative;
    display: flex;
    gap: 10px;
    align-items: center;
}

.phone-group .error-message:nth-of-type(1) { /* Error for DDD */
    position: absolute;
    top: 100%; /* Position below the container */
    left: 0;   /* Align with the left edge */
    width: 80px; /* Adjust width as needed to match DDD input */
  }
  
  .phone-group .error-message:nth-of-type(2) { /* Error for Telefone */
    position: absolute;
    top: 100%; /* Position below the container */
    left: 95px;  /* Adjust left offset as needed to position next to the DDD error */
    /* You might want to add a width here, depending on the desired layout */
  }

input.ddd {
    width: 70px !important;
    margin-right: 0;
}

input.fone {
    flex: 1;
}

/* Ajuste do ícone do olho */
/* Remova qualquer estilo antigo do toggle-password e substitua por este */
.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #00597C;
    background: none;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.toggle-password i {
    font-size: 18px;
    color: #00597C;
    transition: all 0.3s ease;
}

.password-input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-container input {
    padding-right: 35px;
}

/* Ajuste do botão principal e seu hover para corresponder ao profile */
.auth-container .btn-primary,
.auth-content .btn-primary,
.tab-content .btn-primary,
#login .btn-primary,
#signup .btn-primary,
.btn-primary.btn-block {
    background-color: #98D93D !important;
    border: none !important;
    padding: 12px;
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.3s ease;
    width: 100%;
    color: white !important;
}

.auth-container .btn-primary:hover,
.auth-content .btn-primary:hover,
.tab-content .btn-primary:hover,
#login .btn-primary:hover,
#signup .btn-primary:hover,
.btn-primary.btn-block:hover {
    background-color: #A8E04A !important; /* Verde mais claro no hover */
    transform: translateY(-1px);
    box-shadow: none;
    color: white !important; /* Mantém a fonte branca no hover */
}

/* Remover estilos antigos do botão que possam interferir */
.auth-container .btn-primary:active,
.auth-content .btn-primary:active,
.tab-content .btn-primary:active,
#login .btn-primary:active,
#signup .btn-primary:active,
.btn-primary.btn-block:active {
    background-color: #7AB82D !important;
    transform: scale(0.98);
    color: white !important;
}

.forgot-password a {
    color: #00597C;
    text-decoration: none;
    font-size: 12px;
}

.divider {
    text-align: center;
    margin: 20px 0;
    color: #666;
}

/* Ajustes para os inputs */
.form-control, input[type="text"], input[type="email"], input[type="password"], select {
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 10px;
    width: 100%;
    transition: border-color 0.3s ease;
    flex-wrap: wrap;
}

.form-control:focus, input:focus, select:focus {
    border-color: #00597C;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 89, 124, 0.1);
}

/* Substituir o emoji do olho por um ícone mais adequado */
.toggle-password {
    font-family: "bootstrap-icons";
    content: "\F341";
}

/* Ajuste do container principal */
.auth-container {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
    max-width: 500px;
    margin: 40px auto;
}

.tab-content {
    display: block;
}

.tab-content.hidden {
    display: none;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
}

select,       
input[type="text"],
input[type="email"],
input[type="password"] {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus {
    border-color: var(--primary-color);
    outline: none;
}

input.ddd[type="text"] { /* Or the actual type if it's not text */
    width: 20%;
    margin-right: 15px;
}

input.fone[type="text"] { /* Or the actual type */
    width: 75%;

}


.forgot-password {
    text-align: right;
    margin-top: 6px;
} 


.forgot-password a:hover {
    text-decoration: underline;
}

small {
    font-size: 12px;
    color: var(--text-lighter);
    display: block;
    margin-top: 4px;
}

.checkbox {
    display: flex;
    align-items: center;
}

.checkbox input {
    margin-right: 10px;
}

.checkbox label {
    margin-bottom: 0;
    font-size: 12px;
}

.checkbox a {
    color: var(--secondary-color);
    text-decoration: none;
}

.checkbox a:hover {
    text-decoration: underline;
}

.divider {
    display: flex;
    align-items: center;
    margin: 20px 0;
    color: var(--text-lighter);
    font-size: 12px;
}

.divider::before,
.divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background-color: var(--border-color);
}

.divider span {
    padding: 0 10px;
}

/* User Profile Styles */
.user-profile {
    display: none;
    text-align: center;
    padding: 20px;
}

.user-profile.active {
    display: block;
}

.profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 15px;
    overflow: hidden;
    border: 3px solid var(--accent-color);
}

.profile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info h2 {
    color: var(--primary-color);
    margin-bottom: 5px;
}

.profile-info p {
    color: var(--text-light);
    margin-bottom: 15px;
}

.btn-logout {
    background-color: var(--gray);
    color: var(--text-dark);
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background-color: var(--border-color);
}

/* Forgot Password Styles */
.forgot-password-container {
    display: none;
    padding: 40px;
}

.forgot-password-container.active {
    display: block;
}

.back-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    font-size: 14px;
    margin-bottom: 20px;
    text-decoration: none;
}

.back-link:hover {
    text-decoration: underline;
}

.back-icon {
    margin-right: 5px;
}

.success-icon {
    font-size: 48px;
    color: var(--success-color);
    margin-bottom: 15px;
}

.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

/* Reset Password Styles */
.reset-password-container {
    display: none;
    padding: 40px;
}

.reset-password-container.active {
    display: block;
}


/* Message styles */
.message-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
    text-align: center;
    width: 80%;
    max-width: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-message {
    padding: 15px 20px;
    border-radius: 4px;
    margin-bottom: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
    color: white;
    font-weight: 500;
}

.message-success {
    background-color: var(--success-color);
}

.message-error {
    background-color: var(--error-color);
}

.message-info {
    background-color: #2196F3;
}

/* Error message styles */
.error-message {    
    color: var(--error-color);
    font-size: 12px;
    margin-top: 5px;
    display: block;
    width: 100%;
    background-color: rgba(255, 240, 240, 0.9); /* Very light red */
    padding: 2px 4px; /* Add a little padding for better appearance */
}

.password-input-container .error-message {
    position: absolute;
    top: 100%;
    left: 0;
  } 

.ddd .error-message,
.telefone .error-message {
  position: absolute;
  top: 100%;
  left: 0;
}

input.error, select.error {
    border-color: var(--error-color);
}


/* Override CakePHP flash messages */
.message {
    position: relative;
    width: 30%;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    margin: 0 auto 30px auto;
    padding: 15px 30px;
    border-radius: 8px;
    text-align: center;
    font-size: 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    word-wrap: break-word;
    top:15px;
}

.message.success {
    background-color: rgba(40, 167, 69, 0.9);
    top:15px;
}

.message.error {
    background-color: rgba(220, 53, 69, 0.9);
    top:15px;
}

.message.warning {
    background-color: rgba(255, 193, 7, 0.9);
    top:15px;
}

.message.info {
    background-color: rgba(23, 162, 184, 0.9);
    top:15px;
}

/* Google button container */
#google-btn-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

        /* Responsive Styles */
    @media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    .message {
        width: 85%;
        margin: 0 auto 20px auto;
    }

    main {
        padding: 20px 0;
    }

    .auth-container {
        max-width: 100%;
        margin: 0 10px;
        border-radius: 6px;
    }

    .auth-content, 
    .forgot-password-container, 
    .reset-password-container {
        padding: 25px 20px;
    }

    .auth-header h1 {
        font-size: 20px;
    }

    .auth-header p {
        font-size: 13px;
    }

    .tab-btn {
        padding: 10px 5px;
        font-size: 14px;
    }

    .btn {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .message-container {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);        
        width: auto;
    }

    .message {
        padding: 10px 15px;
        font-size: 13px;
    }
}       


@media (max-width: 480px) {
    .header-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .message {
        width: 90%;
        margin: 0 auto 15px auto;
    }

    .header-right {
        margin-top: 10px;
    }

    .logo {
        margin-bottom: 5px;
    }

    .auth-content, 
    .forgot-password-container, 
    .reset-password-container {
        padding: 20px 15px;
    }

    .auth-header {
        margin-bottom: 20px;
    }

    .auth-header h1 {
        font-size: 18px;
    }

    .auth-header p {
        font-size: 12px;
    }

    .form-group {
        margin-bottom: 15px;
    }

    label {
        font-size: 13px;
    }

    input[type="text"],
    input[type="email"],
    input[type="password"] {
        padding: 10px;
        font-size: 13px;
    }

    .checkbox label {
        font-size: 11px;
    }

    .divider {
        margin: 15px 0;
    }

    .success-icon {
        font-size: 36px;
    }

    .message-container {
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);        
        width: auto;
    }


    
}
 
.password-input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.toggle-password {
    position: absolute;
    right: 10px;
    cursor: pointer;
    user-select: none;    
}

.toggle-password:hover {
    opacity: 0.8;
}

/* Add these new styles at the end of the file */

/* Improve button appearance on macOS */
.auth-container .btn-primary,
.auth-content .btn-primary,
.tab-content .btn-primary,
#login .btn-primary,
#signup .btn-primary,
.btn-primary.btn-block {
    -webkit-appearance: none;
    appearance: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.auth-container .btn-primary:active,
.auth-content .btn-primary:active,
.tab-content .btn-primary:active,
#login .btn-primary:active,
#signup .btn-primary:active,
.btn-primary.btn-block:active {
    background-color: #7AB82D !important;
    transform: scale(0.98);
    color: white !important;
}


/* Enhance password toggle visibility */

.password-input-container input[type="password"],
.password-input-container input[type="text"] {
    padding-right: 35px; /* Make space for eye icon */
}


.toggle-password {
    font-size: 18px;
    padding: 5px;
}


/* Better error states */
.error-message {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Enhance button hover states */
.auth-container .btn-primary:hover,
.auth-content .btn-primary:hover,
.tab-content .btn-primary:hover,
#login .btn-primary:hover,
#signup .btn-primary:hover,
.btn-primary.btn-block:hover {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Better mobile tap targets */
@media (max-width: 480px) {
    .btn {
        padding: 12px;
    }
    
    input, select {
        padding: 12px 10px !important;
    }
}

/* Improve form spacing */
.form-group {
    margin-bottom: 25px;
}

/* Better visual hierarchy for labels */
label {
    font-weight: 600;
    margin-bottom: 8px;
}

/* More prominent active tab */
.tab-btn.active {
    font-weight: 600;
    border-bottom-width: 3px;
}
@media (max-width: 768px) {
    .custom-alert-message {
        text-align: center;
        margin: 0 auto;
    }
}
