:root {
  --giur-primary: #2563eb;
  --giur-primary-soft: #60a5fa;
  --giur-accent: #eab308;
  --giur-border: rgba(148, 163, 184, 0.5);
  --giur-text: #e5e7eb;
  --giur-muted: #9ca3af;
  --giur-success: #22c55e;
}

* {
  box-sizing: border-box;
}



/* ========= SFONDO DINAMICO ========= */

.giur-bg {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -2;
}

/* grande gradiente in movimento */
.giur-bg-gradient {
  position: absolute;
  inset: -40%;
  background:
    radial-gradient(circle at 10% 0%, rgba(37, 99, 235, 0.8), transparent 45%),
    radial-gradient(circle at 90% 100%, rgba(234, 179, 8, 0.8), transparent 50%),
    radial-gradient(circle at 0% 100%, rgba(15, 23, 42, 0.8), #020617);
  background-size: 220% 220%;
  animation: giur-bg-flow 22s ease-in-out infinite alternate;
  filter: blur(2px);
}

/* canvas dove JS disegna le bolle */
#giur-orbs {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* griglia decorativa */
.giur-bg-grid {
  position: absolute;
  inset: -50%;
  background-image:
    linear-gradient(135deg, rgba(148, 163, 184, 0.18) 1px, transparent 1px),
    linear-gradient(315deg, rgba(30, 64, 175, 0.28) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.18;
  mix-blend-mode: soft-light;
  animation: giur-grid-move 40s linear infinite;
}

@keyframes giur-bg-flow {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(-6%, -8%, 0) scale(1.05);
  }
  100% {
    transform: translate3d(4%, 10%, 0) scale(1.03);
  }
}

@keyframes giur-grid-move {
  0% {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }
  100% {
    transform: translate3d(-60px, -40px, 0) rotate(-2deg);
  }
}

/* ========= LAYOUT / CARD ========= */

.giur-shell {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.8rem 1.2rem;
}

.giur-card {
  position: relative;
  width: 100%;
  max-width: 980px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  border-radius: 28px;
  background: radial-gradient(circle at top left,
              rgba(15, 23, 42, 0.96),
              rgba(15, 23, 42, 0.98));
  border: 1px solid var(--giur-border);
  box-shadow:
    0 34px 90px rgba(15, 23, 42, 0.95),
    0 0 0 1px rgba(15, 23, 42, 0.9);
  overflow: hidden;
  backdrop-filter: blur(22px);
  transform-origin: center;
  opacity: 0;
  animation: giur-card-in .7s ease-out forwards;
}

/* bordo glow */
.giur-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  padding: 1px;
  border-radius: inherit;
  background: conic-gradient(
    from 220deg,
    rgba(37, 99, 235, 0.0),
    rgba(37, 99, 235, 0.55),
    rgba(234, 179, 8, 0.75),
    rgba(37, 99, 235, 0.9),
    rgba(37, 99, 235, 0.0)
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  pointer-events: none;
  animation: giur-border-glow 7s ease-in-out .8s infinite alternate;
  z-index: -1;
}

@keyframes giur-card-in {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes giur-border-glow {
  0% {
    opacity: 0;
    transform: rotate(0deg);
  }
  40% {
    opacity: 0.8;
  }
  100% {
    opacity: 1;
    transform: rotate(12deg);
  }
}

/* SINISTRA: HERO */

.giur-left {
  position: relative;
  padding: 2.5rem 2.6rem 2.2rem;
  border-right: 1px solid rgba(148, 163, 184, 0.45);
  overflow: hidden;
}

.giur-left::before {
  content: "";
  position: absolute;
  inset: -25%;
  background: radial-gradient(circle at 0 0, rgba(37, 99, 235, 0.3), transparent 55%);
  opacity: .9;
  pointer-events: none;
}

.giur-mark {
  position: absolute;
  right: -4px;
  top: 10px;
  font-size: 6rem;
  opacity: .26;
  text-shadow:
    0 0 0 rgba(0,0,0,0),
    0 0 80px rgba(15, 23, 42, 1);
  pointer-events: none;
  animation: giur-mark-float 20s ease-in-out infinite alternate;
}

.giur-mark i {
  background: linear-gradient(180deg, rgba(249, 250, 251, .32), rgba(148, 163, 184, .08));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

@keyframes giur-mark-float {
  0% { transform: translate3d(0, 0, 0); opacity: .2; }
  50% { transform: translate3d(-8px, 10px, 0); opacity: .3; }
  100% { transform: translate3d(6px, -8px, 0); opacity: .24; }
}

.giur-left-inner {
  position: relative;
  z-index: 1;
}

.giur-brand-row {
  display: flex;
  align-items: center;
  gap: .9rem;
  margin-bottom: 1.6rem;
  animation: giur-stagger-up .5s ease-out .1s both;
}

.giur-logo {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, #1d4ed8, #3b82f6 40%, #93c5fd),
    radial-gradient(circle at 0 0, rgba(234, 179, 8, .9), transparent 55%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f9fafb;
  box-shadow:
    0 20px 45px rgba(37, 99, 235, 0.9),
    0 0 0 1px rgba(15, 23, 42, 0.9);
  position: relative;
  overflow: hidden;
  animation: giur-logo-pulse 4.4s ease-in-out .9s infinite;
}

.giur-logo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 0 0, rgba(255, 255, 255, .35), transparent 60%);
  mix-blend-mode: screen;
  opacity: .85;
}

.giur-logo i {
  position: relative;
  z-index: 1;
  font-size: 1.3rem;
}

@keyframes giur-logo-pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 20px 45px rgba(37, 99, 235, 0.9);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 28px 65px rgba(37, 99, 235, 1);
  }
}

.giur-brand-text {
  display: flex;
  flex-direction: column;
  gap: .12rem;
}

.giur-firm {
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: 1.6rem;
  letter-spacing: .03em;
  color: #f9fafb;
}

.giur-firm span {
  color: var(--giur-accent);
}

.giur-tagline {
  font-size: .82rem;
  color: var(--giur-muted);
}

.giur-tagline strong {
  color: #e5e7eb;
  font-weight: 500;
}

.giur-section-label {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .16em;
  color: var(--giur-muted);
  margin-bottom: .8rem;
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  animation: giur-stagger-up .5s ease-out .2s both;
}

.giur-section-label::before {
  content: "";
  width: 46px;
  height: 1px;
  background: linear-gradient(to right, rgba(249, 250, 251, .3), #facc15);
}

.giur-hero-title {
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: 1.6rem;
  line-height: 1.35;
  margin-bottom: .4rem;
  color: #f9fafb;
  animation: giur-stagger-up .5s ease-out .28s both;
}

.giur-hero-title span {
  color: var(--giur-accent);
}

.giur-hero-subtitle {
  font-size: .9rem;
  color: #e5e7eb;
  margin-bottom: 1.5rem;
  animation: giur-stagger-up .5s ease-out .36s both;
}

.giur-hero-subtitle em {
  color: #bfdbfe;
  font-style: normal;
}

.giur-points {
  list-style: none;
  padding: 0;
  margin: 0 0 1.6rem;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  animation: giur-stagger-up .5s ease-out .44s both;
}

.giur-points li {
  display: flex;
  gap: .6rem;
  font-size: .82rem;
  color: #dbeafe;
}

.giur-points i {
  margin-top: .08rem;
  color: var(--giur-accent);
  font-size: .8rem;
  text-shadow: 0 0 10px rgba(250, 204, 21, 0.9);
}

.giur-label-pill {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .18rem .7rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.65);
  background: rgba(15, 23, 42, 0.98);
  color: var(--giur-muted);
  font-size: .74rem;
  animation: giur-stagger-up .5s ease-out .52s both;
}

.giur-label-pill i {
  color: var(--giur-success);
  font-size: .85rem;
}

/* DESTRA: FORM */

.giur-right {
  position: relative;
  padding: 2.5rem 2.4rem 2.1rem;
  background:
    radial-gradient(circle at 100% 0%, rgba(37, 99, 235, 0.26), transparent 50%),
    radial-gradient(circle at 0 100%, rgba(15, 23, 42, 0.95), #020617);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.giur-form-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
  animation: giur-stagger-up .5s ease-out .2s both;
}

.giur-form-title {
  font-size: .86rem;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--giur-muted);
}

.giur-form-badge {
  font-size: .72rem;
  padding: .24rem .65rem;
  border-radius: 999px;
  border: 1px solid rgba(234, 179, 8, .8);
  background: linear-gradient(135deg, rgba(234, 179, 8, .18), rgba(234, 179, 8, .06));
  color: #facc15;
  display: inline-flex;
  align-items: center;
  gap: .38rem;
}

.giur-form-badge i {
  font-size: .78rem;
}

.giur-errors {
  margin-bottom: .9rem;
  animation: giur-stagger-up .5s ease-out .28s both;
}

.giur-errors .alert {
  font-size: .78rem;
  padding: .5rem .75rem;
  border-radius: .9rem;
  margin-bottom: .3rem;
  border: 1px solid rgba(239, 68, 68, .7);
  background: linear-gradient(135deg,
    rgba(127, 29, 29, .97),
    rgba(127, 29, 29, .92)
  );
  color: #fee2e2;
  position: relative;
  overflow: hidden;
}

.giur-errors .alert::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 0 0, rgba(248, 250, 252, .24), transparent 55%);
  opacity: .75;
  pointer-events: none;
}

.giur-form {
  animation: giur-stagger-up .5s ease-out .32s both;
}

.giur-field {
  margin-bottom: 1rem;
}

.giur-label {
  font-size: .8rem;
  color: var(--giur-muted);
  margin-bottom: .25rem;
  display: flex;
  justify-content: space-between;
}

.giur-input-wrap {
  position: relative;
}

.giur-input-icon {
  position: absolute;
  left: .8rem;
  top: 50%;
  transform: translateY(-50%);
  color: #6b7280;
  font-size: .86rem;
  transition: color .18s ease, transform .18s ease;
}

.giur-input {
  width: 100%;
  border-radius: .9rem;
  border: 1px solid var(--giur-border);
  background: rgba(15, 23, 42, 0.9);
  color: var(--giur-text);
  padding: .6rem .95rem .6rem 2.4rem;
  font-size: .9rem;
  outline: none;
  transition:
    border-color .18s ease,
    box-shadow .18s ease,
    background .18s ease,
    transform .08s ease,
    filter .14s ease;
}

.giur-input::placeholder {
  color: #6b7280;
}

.giur-input:focus {
  border-color: var(--giur-primary-soft);
  box-shadow:
    0 0 0 1px rgba(59, 130, 246, .7),
    0 16px 38px rgba(15, 23, 42, 0.9);
  background: #020617;
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.giur-input:focus ~ .giur-input-icon {
  color: var(--giur-primary-soft);
  transform: translateY(-50%) translateX(1px);
}

.giur-toggle-password {
  position: absolute;
  right: .9rem;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: #6b7280;
  font-size: .86rem;
  transition: color .16s ease, transform .12s ease;
}

.giur-toggle-password:hover {
  color: var(--giur-primary-soft);
  transform: translateY(-50%) scale(1.05);
}

.giur-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .6rem;
  margin-bottom: .9rem;
  font-size: .8rem;
}

.giur-remember {
  display: flex;
  align-items: center;
  gap: .4rem;
  color: var(--giur-muted);
}

.giur-remember input[type="checkbox"] {
  width: .9rem;
  height: .9rem;
  accent-color: var(--giur-primary);
}

.giur-forgot a {
  color: #93c5fd;
  text-decoration: none;
}

.giur-forgot a:hover {
  text-decoration: underline;
}

.giur-submit {
  width: 100%;
  border: none;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--giur-primary), #0b1120);
  background-size: 180% 180%;
  background-position: 10% 0%;
  color: #f9fafb;
  font-weight: 600;
  font-size: .92rem;
  padding: .72rem 1rem;
  margin-top: .4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  cursor: pointer;
  box-shadow:
    0 18px 45px rgba(37, 99, 235, 0.8),
    0 0 0 1px rgba(15, 23, 42, 0.95);
  transition:
    transform .12s ease,
    box-shadow .12s ease,
    filter .12s ease,
    background-position .22s ease;
}

.giur-submit-icon {
  transition: transform .18s ease, opacity .16s ease;
}

.giur-submit:hover:not(.is-loading) {
  transform: translateY(-1px);
  filter: brightness(1.06);
  box-shadow:
    0 24px 60px rgba(37, 99, 235, 0.95),
    0 0 0 1px rgba(15, 23, 42, 0.95);
  background-position: 90% 100%;
}

.giur-submit:hover:not(.is-loading) .giur-submit-icon {
  transform: translateX(2px);
}

.giur-submit:active:not(.is-loading) {
  transform: translateY(0);
  box-shadow:
    0 10px 30px rgba(15, 23, 42, 0.96),
    0 0 0 1px rgba(15, 23, 42, 0.95);
}

.giur-submit.is-loading {
  cursor: wait;
  opacity: .95;
  transform: translateY(0);
}

.giur-spinner {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 2px solid rgba(239, 246, 255, 0.3);
  border-top-color: #e5e7eb;
  animation: giur-spin .7s linear infinite;
}

@keyframes giur-spin {
  to { transform: rotate(360deg); }
}

.giur-meta {
  margin-top: 1rem;
  font-size: .79rem;
  color: var(--giur-muted);
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  align-items: center;
}

.giur-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .18rem .7rem;
  border-radius: 999px;
  font-size: .74rem;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: rgba(15, 23, 42, 0.95);
}

.giur-meta-pill i {
  color: var(--giur-success);
}


/* ===== TEMA GOLD ===== */

body.giur-theme-gold {
  --giur-primary: #facc15;
  --giur-primary-soft: #fde68a;
  --giur-accent: #fbbf24;
  --giur-border: rgba(250, 204, 21, 0.55);
}

/* sfondo più “champagne” */
body.giur-theme-gold .giur-bg-gradient {
  background:
    radial-gradient(circle at 10% 0%, rgba(250, 204, 21, 0.7), transparent 45%),
    radial-gradient(circle at 90% 100%, rgba(245, 158, 11, 0.8), transparent 50%),
    radial-gradient(circle at 0% 100%, rgba(15, 23, 42, 0.9), #020617);
}

/* card con riflessi più caldi */
body.giur-theme-gold .giur-card {
  background: radial-gradient(circle at top left,
              rgba(15, 23, 42, 0.98),
              rgba(15, 23, 42, 0.98));
}

body.giur-theme-gold .giur-card::before {
  background: conic-gradient(
    from 220deg,
    rgba(234, 179, 8, 0.0),
    rgba(234, 179, 8, 0.7),
    rgba(252, 211, 77, 0.95),
    rgba(234, 179, 8, 0.9),
    rgba(234, 179, 8, 0.0)
  );
}

/* logo più gold */
body.giur-theme-gold .giur-logo {
  background:
    linear-gradient(135deg, #b45309, #facc15 40%, #fef3c7),
    radial-gradient(circle at 0 0, rgba(252, 211, 77, .9), transparent 55%);
}

/* badge / pill con accenti oro */
body.giur-theme-gold .giur-label-pill,
body.giur-theme-gold .giur-meta-pill {
  border-color: rgba(250, 204, 21, 0.7);
}

/* pulsante login più dorato */
body.giur-theme-gold .giur-submit {
  background: linear-gradient(135deg, #facc15, #854d0e);
  box-shadow:
    0 20px 50px rgba(250, 204, 21, 0.75),
    0 0 0 1px rgba(15, 23, 42, 0.95);
}
body.giur-theme-gold .giur-submit:hover:not(.is-loading) {
  box-shadow:
    0 26px 65px rgba(250, 204, 21, 0.95),
    0 0 0 1px rgba(15, 23, 42, 0.95);
}

/* icone timeline / check più calde */
body.giur-theme-gold .giur-points i {
  color: #facc15;
  text-shadow: 0 0 10px rgba(250, 204, 21, 0.9);
}


/* ===== TOGGLE TEMA (BLUE / GOLD) ===== */
.giur-theme-toggle {
  position: fixed;
  top: 16px;
  right: 18px;
  z-index: 10;
  padding: 4px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.5);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(10px);
}

.giur-theme-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  position: relative;
}

.giur-theme-dot--blue {
  background: radial-gradient(circle, #60a5fa, #1d4ed8);
}

.giur-theme-dot--gold {
  background: radial-gradient(circle, #facc15, #b45309);
}

.giur-theme-toggle::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.95);
  pointer-events: none;
}

/* piccolo highlight sul tema attivo */
body:not(.giur-theme-gold) .giur-theme-dot--blue {
  box-shadow: 0 0 0 2px rgba(191, 219, 254, 0.9);
}

body.giur-theme-gold .giur-theme-dot--gold {
  box-shadow: 0 0 0 2px rgba(253, 224, 71, 0.9);
}



/* animazioni generiche */
@keyframes giur-stagger-up {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* RESPONSIVE */

@media (max-width: 900px) {
  .giur-card {
    max-width: 540px;
    grid-template-columns: minmax(0, 1fr);
  }
  .giur-left {
    display: none;
  }
  .giur-right {
    padding: 2.2rem 1.9rem 1.9rem;
  }
}

@media (max-width: 480px) {
  .giur-shell {
    padding: 1.4rem .9rem;
  }
  .giur-right {
    padding: 2rem 1.4rem 1.6rem;
  }
  .giur-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}




