:root {
  --muco-blue: #0b3d91;
  --muco-blue-deep: #071a3d;
  --muco-yellow: #f5c518;
  --muco-red: #c8102e;
  --muco-ink: #12141a;
  --muco-muted: #5c6470;
  --muco-paper: #f4f1eb;
  --muco-white: #ffffff;
  --font-display: "Syne", sans-serif;
  --font-body: "Manrope", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body.muco-welcome {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--muco-ink);
  background: var(--muco-paper);
  -webkit-font-smoothing: antialiased;
}

.muco-welcome a {
  color: inherit;
  text-decoration: none;
}

/* —— Hero —— */
.muco-hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 55% at 15% 20%, rgba(245, 197, 24, 0.22), transparent 55%),
    radial-gradient(ellipse 50% 45% at 85% 15%, rgba(200, 16, 46, 0.2), transparent 50%),
    radial-gradient(ellipse 60% 50% at 60% 90%, rgba(11, 61, 145, 0.45), transparent 55%),
    linear-gradient(155deg, #050e24 0%, var(--muco-blue-deep) 42%, #0a2f73 100%);
  color: var(--muco-white);
}

.muco-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.35;
  pointer-events: none;
}

.muco-hero__brand,
.muco-hero__auth {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(1.5rem, 4vw, 3.5rem);
}

.muco-hero__brand {
  padding-left: clamp(1.75rem, 6vw, 5rem);
  animation: muco-rise 0.9s ease-out both;
}

.muco-hero__auth {
  animation: muco-rise 0.9s ease-out 0.15s both;
  align-items: stretch;
}

.muco-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  margin: 0 0 1.75rem;
}

.muco-logo-wrap {
  max-width: min(320px, 88%);
  margin-bottom: 1.5rem;
  padding: 1.1rem 1.25rem 0.9rem;
  /* Light plate so logo panels & text stay crisp on navy */
  background: #ffffff;
  border-radius: 1.35rem;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.2),
    0 18px 40px rgba(0, 0, 0, 0.35);
}

.muco-logo-wrap img {
  display: block;
  width: 100%;
  height: auto;
}

.muco-brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
  line-height: 1.1;
}

.muco-tagline {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muco-yellow);
  margin: 0 0 1.25rem;
  max-width: 28rem;
  line-height: 1.45;
}

.muco-lead {
  font-size: 1.05rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
  margin: 0;
  max-width: 26rem;
}

.muco-scroll-hint {
  margin-top: 2.5rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.45);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.2s ease;
}

.muco-scroll-hint:hover {
  color: var(--muco-yellow);
}

.muco-scroll-hint span {
  display: inline-block;
  animation: muco-bounce 1.6s ease-in-out infinite;
}

/* —— Login panel —— */
.muco-login {
  background: rgba(255, 255, 255, 0.97);
  color: var(--muco-ink);
  border-radius: 1.25rem;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  width: min(100%, 400px);
  margin-left: auto;
  margin-right: clamp(0.5rem, 2vw, 2rem);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 24px 60px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
}

.muco-login__title {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
}

.muco-login__sub {
  font-size: 0.9rem;
  color: var(--muco-muted);
  margin: 0 0 1.5rem;
}

.muco-field {
  margin-bottom: 1rem;
}

.muco-field label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--muco-ink);
}

.muco-field__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
}

.muco-field__row a {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muco-blue);
}

.muco-field__row a:hover {
  color: var(--muco-red);
}

.muco-field input[type="text"],
.muco-field input[type="password"] {
  width: 100%;
  height: 2.85rem;
  padding: 0 0.9rem;
  border: 1px solid #d5d8de;
  border-radius: 0.65rem;
  font: inherit;
  font-size: 0.95rem;
  background: #fafbfc;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.muco-field input:focus {
  outline: none;
  border-color: var(--muco-blue);
  box-shadow: 0 0 0 3px rgba(11, 61, 145, 0.15);
  background: #fff;
}

.muco-field--error input {
  border-color: var(--muco-red);
}

.muco-error {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
  color: var(--muco-red);
  font-weight: 600;
}

.muco-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  margin: 0.25rem 0 1.25rem;
  color: var(--muco-muted);
}

.muco-check input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--muco-blue);
}

.muco-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 2.95rem;
  border: none;
  border-radius: 0.75rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  background: linear-gradient(135deg, var(--muco-blue) 0%, #0a2f73 55%, #091f4d 100%);
  color: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  box-shadow: 0 10px 24px rgba(11, 61, 145, 0.35);
}

.muco-btn:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(11, 61, 145, 0.4);
}

.muco-btn:active {
  transform: translateY(0);
}

.muco-alert {
  margin-bottom: 1rem;
  padding: 0.75rem 0.9rem;
  border-radius: 0.65rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.muco-alert--error {
  background: rgba(200, 16, 46, 0.08);
  color: var(--muco-red);
  border: 1px solid rgba(200, 16, 46, 0.2);
}

.muco-alert--ok {
  background: rgba(11, 61, 145, 0.08);
  color: var(--muco-blue);
  border: 1px solid rgba(11, 61, 145, 0.2);
}

/* —— Categories —— */
.muco-rayons {
  padding: clamp(3rem, 7vw, 5.5rem) clamp(1.25rem, 5vw, 4rem);
  background:
    linear-gradient(180deg, #ebe6dc 0%, var(--muco-paper) 40%, #fff 100%);
}

.muco-rayons__head {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto 2.5rem;
  animation: muco-rise 0.7s ease-out both;
}

.muco-rayons__eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muco-blue);
  margin: 0 0 0.5rem;
}

.muco-rayons__title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  font-weight: 800;
  margin: 0 0 0.6rem;
}

.muco-rayons__sub {
  margin: 0;
  color: var(--muco-muted);
  font-size: 1rem;
  line-height: 1.5;
}

.muco-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  max-width: 1100px;
  margin: 0 auto;
}

.muco-tile {
  background: #fff;
  border-radius: 0.9rem;
  padding: 1.35rem 1rem;
  text-align: center;
  border: 1px solid rgba(18, 20, 26, 0.06);
  border-top: 4px solid var(--accent, var(--muco-blue));
  box-shadow: 0 8px 24px rgba(18, 20, 26, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: muco-rise 0.6s ease-out both;
}

.muco-tile:nth-child(1) { --accent: var(--muco-blue); animation-delay: 0.05s; }
.muco-tile:nth-child(2) { --accent: var(--muco-yellow); animation-delay: 0.1s; }
.muco-tile:nth-child(3) { --accent: var(--muco-red); animation-delay: 0.15s; }
.muco-tile:nth-child(4) { --accent: var(--muco-blue); animation-delay: 0.2s; }
.muco-tile:nth-child(5) { --accent: var(--muco-yellow); animation-delay: 0.25s; }
.muco-tile:nth-child(6) { --accent: var(--muco-red); animation-delay: 0.3s; }
.muco-tile:nth-child(7) { --accent: var(--muco-blue); animation-delay: 0.35s; }
.muco-tile:nth-child(8) { --accent: var(--muco-yellow); animation-delay: 0.4s; }

.muco-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(18, 20, 26, 0.08);
}

.muco-tile__icon {
  width: 2.75rem;
  height: 2.75rem;
  margin: 0 auto 0.85rem;
  border-radius: 0.7rem;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--accent) 12%, white);
  color: var(--accent);
}

.muco-tile__icon svg {
  width: 1.35rem;
  height: 1.35rem;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.muco-tile__name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0;
}

/* —— Footer —— */
.muco-footer {
  padding: 1.5rem clamp(1.25rem, 5vw, 4rem) 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  border-top: 1px solid rgba(18, 20, 26, 0.08);
  background: #fff;
  font-size: 0.85rem;
  color: var(--muco-muted);
}

.muco-footer strong {
  color: var(--muco-ink);
  font-family: var(--font-display);
}

.muco-footer a {
  font-weight: 700;
  color: var(--muco-blue);
}

.muco-footer a:hover {
  color: var(--muco-red);
}

@keyframes muco-rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes muco-bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(4px);
  }
}

@media (max-width: 960px) {
  .muco-hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .muco-hero__brand {
    padding-top: 2.5rem;
    padding-bottom: 1rem;
    text-align: center;
    align-items: center;
  }

  .muco-lead {
    margin-left: auto;
    margin-right: auto;
  }

  .muco-logo-wrap {
    margin-left: auto;
    margin-right: auto;
  }

  .muco-hero__auth {
    padding-top: 0.5rem;
    padding-bottom: 3rem;
  }

  .muco-login {
    margin: 0 auto;
  }

  .muco-scroll-hint {
    justify-content: center;
  }

  .muco-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  .muco-grid {
    grid-template-columns: 1fr;
  }
}
