/* =========================================================
   PORTAIL BÉNÉVOLES — LES TAILLEURS
   ========================================================= */

:root {
  --blue: #1C2EAB;
  --red: #E40230;
  --purple: #891E82;

  --white: #FFFFFF;
  --background: #F5F6FB;

  --text: #202020;
  --text-light: #666A73;
  --border: #DADDE8;

  --shadow: 0 18px 45px rgba(20, 28, 80, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Titillium Web", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(228, 2, 48, 0.08), transparent 30%),
    radial-gradient(circle at bottom left, rgba(28, 46, 171, 0.12), transparent 35%),
    var(--background);
}

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

.login-card {
  width: 100%;
  max-width: 920px;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(28, 46, 171, 0.08);
}

.brand {
  background: var(--blue);
  text-align: center;
  padding: 24px 28px 18px;
  border-bottom: 7px solid var(--red);
}

.brand-logo {
  width: 100%;
  max-width: 520px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.brand p {
  margin: 22px 0 0;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 2.6rem;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--white);
}

.login-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 6px;
}

.login-actions .primary-button,
.login-actions .secondary-button {
  margin: 0;
}

#login-form {
  padding: 30px 44px 0;
}

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

.form-group label {
  display: block;
  margin-bottom: 10px;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--blue);
}

.form-group input {
  width: 100%;
  padding: 20px 22px;
  font-family: "Titillium Web", Arial, sans-serif;
  font-size: 1.15rem;
  color: var(--text);
  background: var(--white);
  border: 2px solid var(--border);
  border-radius: 18px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:hover {
  border-color: rgba(28, 46, 171, 0.45);
}

.form-group input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(28, 46, 171, 0.11);
}

.field-help {
  margin: 12px 4px 0;
  font-size: 1rem;
  line-height: 1.45;
  color: var(--text-light);
}

.password-wrapper {
  position: relative;
}

.password-wrapper input {
  padding-right: 58px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 0;
  box-shadow: none;
  font-size: 1.25rem;
  cursor: pointer;
}

.password-toggle:hover {
  background: rgba(28, 46, 171, 0.06);
  border-radius: 50%;
}

.password-toggle:focus-visible {
  outline: 3px solid rgba(228, 2, 48, 0.40);
  outline-offset: 2px;
}

button {
  font-family: "Macho", "Titillium Web", sans-serif;
}

.primary-button,
.secondary-button {
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 15px 18px;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.primary-button {
  background: var(--red);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(228, 2, 48, 0.24);
}

.primary-button:hover {
  background: #C80029;
  box-shadow: 0 10px 24px rgba(228, 2, 48, 0.30);
}

.secondary-button {
  background: var(--blue);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(28, 46, 171, 0.20);
}

.secondary-button:hover {
  background: #14248C;
  box-shadow: 0 10px 24px rgba(28, 46, 171, 0.25);
}

.primary-button:active,
.secondary-button:active {
  transform: scale(0.98);
}

.login-links {
  text-align: center;
  padding: 18px 44px 0;
}

.login-links a {
  color: var(--blue);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s ease;
}

.login-links a:hover {
  color: var(--red);
  text-decoration: underline;
}

.form-error {
  margin: 8px 2px 0;
  color: var(--red);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.3;
}

.form-error:empty {
  display: none;
}

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid rgba(228, 2, 48, 0.45);
  outline-offset: 3px;
}

.dashboard-page {
  margin: 0;
  min-height: 100vh;
  font-family: "Titillium Web", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(228, 2, 48, 0.06), transparent 30%),
    radial-gradient(circle at bottom left, rgba(28, 46, 171, 0.10), transparent 35%),
    var(--background);
}

.dashboard-header {
  background: var(--blue);
  border-bottom: 7px solid var(--red);
}

.dashboard-header-inner {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 20px;
}

.dashboard-logo {
  display: block;
  width: 100%;
  max-width: 260px;
  height: auto;
}

.dashboard-title {
  min-width: 0;
  text-align: center;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--white);
  white-space: nowrap;
}

.logout-button {
  width: auto;
  min-width: 0;
  padding: 9px 16px;
  border: 2px solid var(--white);
  border-radius: 10px;
  background: transparent;
  color: var(--white);
  font-size: 0.95rem;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
}

.logout-button:hover {
  background: var(--white);
  color: var(--blue);
}

.dashboard-main {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 36px 24px 60px;
}

.dashboard-welcome {
  margin-bottom: 30px;
}

.dashboard-eyebrow,
.section-label {
  margin: 0 0 4px;
  color: var(--red);
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.dashboard-welcome h1 {
  margin: 0;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 2.4rem;
  line-height: 1.1;
  color: var(--blue);
}

.user-role {
  display: inline-block;
  margin: 10px 0 0;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(28, 46, 171, 0.08);
  color: var(--blue);
  font-size: 0.9rem;
  font-weight: 700;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 1.6rem;
  color: var(--blue);
}

.next-shift-card {
  margin-bottom: 34px;
  padding: 26px 28px;
  background: var(--white);
  border-radius: 18px;
  border-left: 7px solid var(--red);
  border-right: 7px solid var(--red);
  box-shadow: 0 10px 28px rgba(20, 28, 80, 0.09);
}

.shift-icon {
  font-size: 2rem;
}

.empty-shift {
  padding: 18px 20px;
  border-radius: 12px;
  background: #F7F8FC;
}

.empty-shift p {
  margin: 0;
  color: var(--text-light);
}

.empty-shift-title {
  margin-bottom: 5px !important;
  color: var(--text) !important;
  font-size: 1.05rem;
  font-weight: 700;
}

.dashboard-section {
  margin-top: 34px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.dashboard-card {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px;
  background: var(--white);
  border: 2px solid transparent;
  border-radius: 16px;
  color: var(--text);
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(20, 28, 80, 0.08);
  transition: transform 0.15s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.dashboard-card:hover {
  transform: translateY(-2px);
  border-color: rgba(28, 46, 171, 0.25);
  box-shadow: 0 12px 28px rgba(20, 28, 80, 0.12);
}

.dashboard-card-icon {
  flex-shrink: 0;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(28, 46, 171, 0.08);
  font-size: 1.55rem;
}

.dashboard-card-content {
  min-width: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.dashboard-card-content strong {
  color: var(--blue);
  font-size: 1.05rem;
}

.dashboard-card-content small {
  margin-top: 4px;
  color: var(--text-light);
  font-size: 0.88rem;
}

.role-banner {
  padding: 24px 26px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  border-radius: 16px;
  color: var(--white);
}

.role-banner h2 {
  margin: 2px 0 5px;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 1.5rem;
}

.role-banner p {
  margin-top: 5px;
  margin-bottom: 0;
}

.role-banner > span {
  font-size: 2.6rem;
}

.responsable-banner {
  background: var(--purple);
}

.admin-banner {
  background: var(--blue);
  border-left: 7px solid var(--red);
}

.role-banner .section-label {
  color: var(--white);
  opacity: 0.8;
}

.dashboard-message {
  margin-bottom: 24px;
  padding: 14px 18px;
  border-radius: 12px;
  font-weight: 600;
}

.dashboard-message.info {
  color: var(--blue);
  background: rgba(28, 46, 171, 0.08);
}

.dashboard-message.error {
  color: #A90022;
  background: rgba(228, 2, 48, 0.09);
  border-left: 5px solid var(--red);
}

[hidden] {
  display: none !important;
}

.subpage-header-inner {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 24px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
}

.back-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 15px;
  border: 2px solid var(--white);
  border-radius: 10px;
  color: var(--white);
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.back-button:hover {
  background: var(--white);
  color: var(--blue);
}

.subpage-main {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 30px 24px 50px;
}

.subpage-heading {
  margin-bottom: 20px;
}

.subpage-heading h1 {
  margin: 0;
  font-family: "Macho", "Titillium Web", sans-serif;
  font-size: 2.1rem;
  color: var(--blue);
}

.map-card {
  width: 100%;
  overflow: hidden;
  background: var(--white);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(20, 28, 80, 0.10);
}

.festival-map {
  display: block;
  width: 100%;
  height: 650px;
  border: 0;
}

.emergency-contact-card {
  margin-bottom: 20px;
  padding: 16px 18px;
  background: rgba(228, 2, 48, 0.08);
  border-left: 5px solid var(--red);
  border-right: 5px solid var(--red);
  border-radius: 12px;
}

.emergency-contact-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.emergency-contact-line h2 {
  margin: 0;
  font-size: 1.15rem;
  color: var(--text);
}

.emergency-phone {
  white-space: nowrap;
}

.contacts-section {
  width: 100%;
}

.contacts-message {
  padding: 14px 0;
  color: var(--text-light);
}

.contacts-error {
  color: var(--red);
  font-weight: 700;
}

.contacts-grid {
  width: 100%;
}

.contacts-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.contacts-table tr + tr th,
.contacts-table tr + tr td {
  padding-top: 18px;
}

.contacts-table th,
.contacts-table td {
  border: 0;
  vertical-align: top;
  text-align: left;
}

.contacts-subject {
  width: 34%;
  padding: 2px 28px 0 0;
  color: var(--blue);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.25;
}

.contacts-people {
  width: 66%;
  padding: 0;
}

.contact-person-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
}

.contact-person-row + .contact-person-row {
  margin-top: 12px;
}

.contact-person-name {
  color: var(--text);
  font-size: 1.02rem;
  line-height: 1.25;
}

.contact-phone {
  color: var(--blue);
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
}

.contact-phone:hover {
  color: var(--red);
  text-decoration: underline;
}

.subpage-intro {
  margin: 8px 0 0;
  color: #5d6375;
  font-size: 1rem;
}

.job-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
}

.job-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: var(--white);
  border-radius: 16px;
  border-left: 5px solid var(--blue);
  box-shadow: 0 8px 24px rgba(20, 28, 80, 0.08);
}

.job-card-icon {
  flex: 0 0 auto;
  font-size: 2rem;
}

.job-card-content {
  min-width: 0;
  flex: 1;
}

.job-card-content h2 {
  margin: 0 0 14px;
  color: var(--blue);
  font-size: 1.15rem;
}

.job-card-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  background: var(--red);
  color: var(--white);
  border-radius: 9px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 700;
}

.job-card-button:hover {
  opacity: 0.9;
}

@media (max-width: 900px) {
  .login-card {
    max-width: 760px;
  }

  .brand {
    padding: 20px 22px 16px;
  }

  .brand-logo {
    max-width: 430px;
  }

  .brand p {
    font-size: 2.1rem;
    margin-top: 18px;
  }

  #login-form {
    padding: 26px 30px 0;
  }

  .login-links {
    padding: 18px 30px 0;
  }

  .dashboard-header-inner {
    grid-template-columns: 1fr auto;
    gap: 15px;
  }

  .dashboard-logo {
    max-width: 210px;
  }

  .dashboard-title {
    font-size: 1.35rem;
  }

  .dashboard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 700px) {
  .login-page {
    padding: 0;
    background: var(--white);
  }

  .login-card {
    max-width: none;
    min-height: 100vh;
    border-radius: 0;
    border: 0;
    box-shadow: none;
  }

  .brand {
    padding: 14px 16px 14px;
    border-bottom-width: 6px;
  }

  .brand-logo {
    max-width: 100%;
  }

  .brand p {
    margin-top: 16px;
    font-size: 1.95rem;
    line-height: 1.05;
    letter-spacing: 0.03em;
  }

  #login-form {
    padding: 24px 24px 0;
  }

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

  .form-group label {
    font-size: 1.15rem;
    margin-bottom: 8px;
  }

  .form-group input {
    padding: 18px 18px;
    font-size: 1.05rem;
    border-radius: 16px;
  }

  .field-help {
    font-size: 0.95rem;
    line-height: 1.4;
  }

  .login-links {
    padding: 16px 24px 0;
  }

  .dashboard-header-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding: 14px 16px;
  }

  .dashboard-logo {
    max-width: 250px;
    margin: 0 auto;
  }

  .dashboard-title {
    width: 100%;
    order: 2;
    font-size: 1.45rem;
  }

  .logout-button {
    order: 3;
    margin-top: 4px;
    padding: 8px 13px;
  }

  .dashboard-main {
    padding: 26px 18px 44px;
  }

  .dashboard-welcome h1 {
    font-size: 2rem;
  }

  .next-shift-card {
    padding: 21px 20px;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .dashboard-card {
    padding: 17px;
  }
}
