@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap");

:root {
  --primary-color: #42200b;
  --secondary-color: #ffc135;
  --tertiary-color: #df1c1c;
  --text-dark: #212529;
  --text-light: #6c757d;
  --white: #ffffff;
  --background-color: #f8f9fa;
  --green: #28a745;
}

body {
  font-family: "Montserrat", sans-serif;
  background-color: var(--background-color);
  color: var(--text-dark);
  margin: 0;
}

main {
  max-width: 800px;
  margin: 2rem auto;
  padding: 0 1rem;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  background-color: var(--white);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  margin-bottom: 2.5rem;
}

.profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--secondary-color);
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
}

.profile-info {
  flex-grow: 1;
}

.profile-info h1 {
  margin: 0 0 0.5rem 0;
  font-size: 2rem;
  color: var(--primary-color);
}

.profile-info p {
  margin: 0;
  color: var(--text-light);
  font-size: 1.1rem;
}

.info-field {
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
}

.edit-icon {
  color: var(--text-light);
  cursor: pointer;
  transition: color 0.3s ease;
}

.edit-icon:hover {
  color: var(--primary-color);
}

.edit-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  width: 100%;
}

.edit-form input {
  flex-grow: 1;
  padding: 0.5rem;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 5px;
}

.edit-form .btn-save, .edit-form .btn-cancel {
  border: none;
  padding: 0.5rem 0.8rem;
  border-radius: 5px;
  cursor: pointer;
  color: white;
}

.btn-save { background-color: var(--green); }
.btn-cancel { background-color: var(--tertiary-color); }

/* Styles pour le groupe mot de passe avec icône */
.password-group {
    position: relative;
}

.toggle-password {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    cursor: pointer;
    color: #aaa;
}


.profile-section {
  margin-bottom: 2.5rem;
}

.profile-section h2 {
  font-size: 1.5rem;
  color: var(--primary-color);
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
}

.order-history-container {
  display: grid;
  gap: 1rem;
}

.order-card {
  background-color: var(--white);
  border-radius: 8px;
  padding: 1.5rem;
  border: 1px solid #e9ecef;
  transition: box-shadow 0.3s ease;
}

.order-card:hover {
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
}

.order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.order-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--text-dark);
}

.order-header .order-date {
  font-size: 0.9rem;
  color: var(--text-light);
}

.order-details {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.order-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
}

.order-total {
  color: var(--tertiary-color);
}

.order-status {
  background-color: var(--green);
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
}

.btn-logout {
    background-color: var(--tertiary-color);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.btn-logout:hover {
    background-color: #c81919;
}

.hidden {
    display: none !important;
}

.auth-required-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    margin: 4rem auto;
    max-width: 500px;
    background-color: var(--white);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.auth-required-container i {
    font-size: 3rem;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
}

.auth-required-container h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    border: none;
}

.btn-connect {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    margin-top: 1.5rem;
    transition: background-color 0.3s ease;
}
.btn-connect:hover {
    background-color: #2c1507;
}