@import url('tokens.css');

.logo-connexion {
    text-align: center;
    margin-bottom: 30px;
}

.logo-connexion img {
    max-width: 180px;
    height: auto;
    object-fit: contain;
}

.connexion-title {
    color: var(--sev-text-secondary);
    margin-top: 0;
    font-size: 1.8rem;
    margin-bottom: 25px;
}

.connexion-error {
    color: #7f1d1d;
    font-weight: 700;
    background: #ffffff;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #fecaca;
}

.connexion-form {
    text-align: center;
    margin: 0;
}

.connexion-label {
    font-weight: bold;
    color: #555;
    display: block;
    margin-bottom: 5px;
}

.connexion-label--spaced {
    margin-top: 15px;
}

.connexion-remember {
    margin-bottom: 25px;
    margin-top: 15px;
    text-align: center;
}

.connexion-remember label {
    color: var(--sev-muted);
    font-size: 0.9rem;
    font-weight: normal;
    cursor: pointer;
}

.connexion-remember input {
    margin: 0;
}

.connexion-blocked {
    background: #ffebee;
    color: #c62828;
    padding: 10px;
    border-radius: 5px;
    margin-top: 20px;
    text-align: center;
}

.connexion-divider {
    border: 0;
    border-top: 1px solid #eee;
    margin: 30px 0 20px;
}

.connexion-footer {
    font-size: 0.9rem;
    color: var(--sev-muted);
}

.connexion-footer a {
    text-decoration: none;
    color: var(--sev-link);
}

.connexion-footer a:hover,
.connexion-footer a:focus-visible {
    text-decoration: underline;
}

.connexion-footer-sep {
    color: #767676;
    margin: 0 8px;
}

.connexion-form input:focus-visible,
.connexion-form button:focus-visible,
.connexion-remember input:focus-visible,
.connexion-footer a:focus-visible {
    outline: 2px solid #1d4ed8;
    outline-offset: 2px;
}

/* Shared card tools (import/export pages) */
.tool-card {
    max-width: 600px;
}

.tool-card--wide {
    max-width: min(96vw, 1280px);
    text-align: left;
}

.carte-blanche.tool-card--wide {
    max-width: min(96vw, 1280px);
}

.wrapper-connexion--wide {
    align-items: flex-start;
    padding: 24px 16px;
}

.tool-card--narrow {
    max-width: 550px;
}

.tool-header {
    text-align: center;
    margin-bottom: 20px;
}

.tool-header img {
    max-width: 100px;
    height: auto;
}

.tool-header--small img {
    max-width: 70px;
}

.tool-title {
    font-size: 1.5rem;
    margin: 10px 0;
    color: #1e293b;
}

.tool-title--small {
    font-size: 1.3rem;
}

.tool-info-box {
    background: #e3f2fd;
    border-left: 5px solid #2196f3;
    padding: 15px;
    margin-bottom: 25px;
    font-size: 0.9rem;
    border-radius: 5px;
    text-align: left;
}

.tool-file-input {
    background: #f8f9fa;
    border: 2px dashed #ccc;
    padding: 30px;
    width: 100%;
    border-radius: 10px;
    cursor: pointer;
    margin-bottom: 20px;
    color: #666;
    text-align: center;
    box-sizing: border-box;
}

.tool-file-input:hover {
    border-color: #386918;
    background: #f1f8e9;
}

.tool-actions {
    margin-top: 30px;
    border-top: 1px solid #eee;
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tool-btn-secondary {
    width: 100%;
    background: #555;
    color: #fff;
    border: 0;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
}

.tool-link-back {
    color: #666;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9rem;
}

.export-form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.export-form-col {
    flex: 1;
    text-align: left;
}

.export-period-actions {
    text-align: left;
}

.btn-period {
    padding: 5px 12px;
    font-size: 0.8rem;
    background: #e2e8f0;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    margin-bottom: 10px;
}

.btn-period:hover {
    background: #cbd5e1;
}

.type-selector {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.type-selector div {
    flex: 1;
    position: relative;
}

.type-selector input {
    position: absolute;
    opacity: 0;
}

.type-selector label {
    display: block;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: bold;
}

.type-selector input:checked + label {
    background: #1e293b;
    color: #fff;
    border-color: #1e293b;
}

.input-group-custom {
    margin-bottom: 20px;
    text-align: left;
}

.btn-flex {
    display: flex;
    gap: 10px;
    margin-top: 25px;
}

.btn-flex button {
    flex: 1;
    padding: 15px;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    border: none;
    color: #fff;
}

.btn-download {
    background: #1e293b;
}

.btn-send {
    background: #386918;
}

.export-status {
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 14px;
    font-weight: 600;
}

.export-status-success {
    color: #166534;
    background: #dcfce7;
    border: 1px solid #bbf7d0;
}

.export-status-error {
    color: #991b1b;
    background: #fee2e2;
    border: 1px solid #fecaca;
}

/* User account page */
.account-card {
    max-width: 550px;
    text-align: left;
}

.account-header {
    text-align: center;
    margin-bottom: 30px;
}

.account-header img {
    max-width: 100px;
    height: auto;
}

.account-header h1 {
    color: #1e293b;
    font-size: 1.6rem;
    margin: 15px 0 5px;
}

.account-header p {
    color: #64748b;
    font-size: 0.9rem;
    margin: 0;
}

.account-section {
    background: #f8fafc;
    padding: 25px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    margin-bottom: 25px;
}

.account-section h3 {
    color: #334155;
    margin-top: 0;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.account-alert {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 0.9rem;
    border: 1px solid transparent;
}

.account-alert-success {
    background: #dcfce7;
    color: #166534;
    border-color: #bbf7d0;
}

.account-alert-error {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

.account-form {
    margin: 0;
}

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

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

.account-form-group label {
    font-weight: bold;
    color: #475569;
    display: block;
    margin-bottom: 5px;
}

.account-form-group input {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    box-sizing: border-box;
}

.account-password-btn {
    background: #334155;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    width: 100%;
}

.account-footer {
    border: 0;
    border-top: 1px solid #e2e8f0;
    margin: 30px 0 20px 0;
}

.account-footer-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.account-link {
    text-decoration: none;
    font-weight: bold;
    font-size: 0.95rem;
}

.account-link-dashboard {
    color: #0066cc;
}

.account-link-logout {
    color: #ef4444;
}
