/* Imposta l'altezza dell'html e del body */

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  background-color: #d9d9d9;
  font-family: 'UniversLTPro-55Roman', sans-serif;
  box-sizing: border-box
  /* touch-action: none; */
}

/* Main section con altezza adattata */
.main {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100vh;
}

.shortcuts {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: 300px;
  background: #ffffff;
  padding: 20px;
  overflow-y: auto;
  box-shadow: 4px 0 5px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
  z-index: 99999;
  transform: translateX(0);
}

.shortcuts.hidden {
  transform: translateX(-100%);
}

.shortcuts-toggle {
  padding: 8px 16px;
  background: #FF0000;
  color: white;
  border: none;
  border-radius: 1000px;
  cursor: pointer;
  width: 100%;
}

.shortcuts-toggle-open {
  padding: 8px 16px;
  background: #0057FF;
  color: white;
  border: none;
  border-radius: 1000px;
  cursor: pointer;
}

#closeShortcuts {
  margin-bottom: 20px;
  width: 100%;
}

#openShortcuts {
  position: fixed;
  left: 20px;
  top: 20px;
  z-index: 90;
  padding: 8px 16px;
  background: #0057FF;
  color: white;
  border: none;
  border-radius: 1000px;
  cursor: pointer;
  display: none;
}

/* Show open button whenever shortcuts are hidden, regardless of viewport */
.shortcuts.hidden + #openShortcuts {
  display: block !important;
}

.canvas-container {
  margin-left: 320px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  height: 100%;
}

.canvas-wrapper {
  transform: scale(1);
  transform-origin: center center;
}

.canvas-container {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

@media (max-width: 740px) {
  #canvas-container canvas {
    /* width: 390px !important; */
    /* height: 487.5px !important; */
    width: 100%;
    height: 100vh;
  }
  
  .canvas-container {
    margin-left: 0;
  }

  /* Mobile shortcuts panel */
  .shortcuts {
    width: 100%;
    max-width: 300px;
    background: #ffffff;
    transform: translateX(-100%);
  }

  /* When shortcuts is visible on mobile */
  .shortcuts:not(.hidden) {
    transform: translateX(0);
  }

  /* Add overlay behind the panel */
  .shortcuts:not(.hidden) ~ .overlay {
    content: '';
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100;
  }
}

@media (min-width: 901px) {
  .shortcuts {
    transform: translateX(0);
  }

  .canvas-container {
    margin-left: 320px;
  }
}

.shortcuts h2 {
  margin-bottom: 24px;
  font-weight: bold;
  color: #050505;
  font-size: 20px;
}

.shortcuts ul {
  list-style: none;
  padding: 0;
}

.shortcuts ul li {
  margin-bottom: 12px;
  font-size: 12px; /* Dimensione del testo */
  line-height: 14px; /* Altezza della linea */
  color: #6E6E6E; /* Colore del testo */
  letter-spacing: -0.04em; /* Spaziatura tra lettere del -4% */
}

.shortcuts ul li strong {
  font-size: 14px; /* Dimensione del testo */
  line-height: 14px; /* Altezza della linea */
  color: #050505; /* Colore del testo */
  letter-spacing: -0.04em; /* Spaziatura tra lettere del -4% */
}


.download-btn {
  background-color: #050505;
  color: white;
  border: none;
  padding: 12px 24px;
  cursor: pointer;
  font-size: 16px;
  border-radius: 1000px;
  transition: background-color 0.3s;
  font-family: 'UniversLTPro-55Roman', sans-serif;
  margin-top: auto; /* Ensures the button stays at the bottom */
}

.download-btn:hover {
  background-color: #ffbb00;
}

.variant-btn {
  border-radius: 5px;
  border: 0.5 solid #050505;
  color: #050505; /* Testo bianco */
  padding: 12px 24px; /* Spaziatura interna */
  cursor: pointer; /* Cambia il cursore al passaggio del mouse */
  font-size: 12px; /* Dimensione del font */
  transition: background-color 0.3s; /* Transizione per il colore di sfondo */
  font-family: 'DM Mono'; /* Font specificato */
  margin: 5px; /* Margine per separare i pulsanti */
}

/* Effetto al passaggio del mouse */
.variant-btn:hover {
  background-color: #ffbb00; /* Colore di sfondo al passaggio del mouse */
}

/* Canvas styling */
canvas {
  border-radius: 4px;
  background-color: #f9f9f9;
}

/* Footer section */
footer {
  display: flex;
  justify-content: center;
  padding: 15px;
}

/* About page container */
.about-container {
  padding: 48px;
  max-width: 800px;
  margin: 0 auto;
  font-family: 'UniversLTPro-55Roman', sans-serif;
  color: #050505;
}

.about-container h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 24px;
}

.about-container p {
  font-size: 16px;
  line-height: 24px;
  margin-bottom: 16px;
  color: #6E6E6E;
}

.back-btn {
  background-color: #050505;
  color: white;
  border: none;
  padding: 12px 24px;
  cursor: pointer;
  font-size: 16px;
  border-radius: 1000px;
  transition: background-color 0.3s;
  font-family: 'DM Mono';
}

.back-btn:hover {
  background-color: #ffbb00;
}

/* Add these styles for the UI components */
.ui-component {
  margin-bottom: 20px;
}

.ui-component label {
  display: block;
  margin-bottom: 16px;
  color: #323232;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}

#headline {
  font-size: 16px;
}

.ui-component input[type="text"],
.ui-component input[type="range"],
.ui-component select {
  font-size: 16px;
  width: 100%;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.ui-component input[type="range"] {
  padding: 0;
}

.cutoutButton {
  width: 100%;
  margin: 20px 0;
  margin-top: 0px;
  padding: 10px;
  background: #0057FF;
  color: white;
  border: none;
  border-radius: 1000px;
  cursor: pointer
}

.cutoutButton.active {
  background: #FF0000;
}

/* #cutoutButton:hover {
  background: #0046cc;
} */

.color-circles {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.color-circle {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.1); /* Bordo sottile semi-trasparente */
  cursor: pointer;
  padding: 0;
  transition: transform 0.2s ease;
}

.color-circle:hover {
  transform: scale(1.1);
  border-color: rgba(0, 0, 0, 0.2); /* Bordo leggermente più scuro all'hover */
}

.color-circle.active {
  transform: scale(1.2);
  border-color: rgba(0, 0, 0, 0.3); /* Bordo più scuro quando attivo */
}

.divider {
  display: flex;
  align-items: center;
  margin: 24px 0;
  padding-bottom: 8px;
  padding-top: 16px;
}

.divider-line {
  flex-grow: 1;
  height: 1px;
  background-color: #dadada;
}

.divider-text {
  padding: 0 10px;
  color: #b0b0b0;
  font-size: 12px;
  font-weight: 400;
  text-transform: uppercase;
}

.toggle-button {
  width: 100%;
  margin: 20px 0;
  margin-top: 0px;
  padding: 10px;
  background: #0057FF;
  color: white;
  border: none;
  border-radius: 1000px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.toggle-button:hover {
  background: #0046cc;
}

.toggle-button.off {
  background: #ccc;
}

.grid-toggle-circle {
  background-color: white !important;
  position: relative;
  border: 1px solid rgba(0, 0, 0, 0.2) !important;
}

.grid-toggle-circle .diagonal-line {
  position: absolute;
  width: 140%;
  height: 2px;
  background-color: #FF0000;
  top: 45%;
  left: -20%;
  transform: rotate(45deg);
  display: block;
}

.grid-toggle-circle.off .diagonal-line {
  display: block;
}

.images-sidebar {
  position: fixed;
  padding: 20px 8px;
  right: 0;
  top: 0;
  width: 350px;
  height: 100vh;
  background: #ffffff;
  z-index: 99999;
  overflow-y: auto;
  overflow-x: hidden;
  box-shadow: -4px 0 5px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
  
}

.images-sidebar.hidden {
  transform: translateX(100%);
}

.images-grid {
  position: relative;
  margin-bottom: 30px;
}

.image-preview-wrapper {
  width: calc(100%/3 - 4px);
  padding-top: 12px;
  display: inline-block;
  height: auto;
  opacity: 85%;
}

.image-preview-wrapper:nth-child(3n + 2) {
  padding-left: 6px;
  padding-right: 6px;
}

.image-preview-wrapper:hover {
  transition: 0.3s opacity;
  opacity: 1;
}

.image-preview {
  display: block;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  max-height: 180px;
}

.image-preview:hover {
  border-color: #0046cc;
}

.image-preview.active {
  border-color: #FFD400;
}

@media (max-width: 740px) {
  .images-sidebar {
    width: 100%;
    padding-left: 0px;
    padding-right: 0px;
  }
  
  .images-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.img-class { 
  width: 100%;
  height: auto;
}

/* Privacy Policy Styles */
.privacy-container {
  max-width: 800px;
  margin: 40px auto;
  padding: 20px;
  line-height: 1.6;
}

.privacy-container h1 {
  color: #0057FF;
  margin-bottom: 20px;
}

.privacy-container h2 {
  color: #323232;
  margin: 30px 0 15px;
}

.privacy-container ul {
  margin-left: 20px;
  margin-bottom: 15px;
}

/* Cookie Banner Styles */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  padding: 15px;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  z-index: 999999;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.cookie-banner.visible {
  transform: translateY(0);
}

.cookie-banner p {
  margin: 0;
  padding-right: 20px;
  font-size: 14px;
}

.cookie-buttons {
  display: flex;
  gap: 10px;
}

.cookie-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s ease;
}

.cookie-btn.accept {
  background: #0057FF;
  color: white;
}

.cookie-btn.decline {
  background: #ffffff;
  border: 1px solid #0057FF;
  color: #0057FF;
}

.download-button {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 10px 20px;
    background-color: #0057FF;
    color: white;
    border: none;
    border-radius: 1000px;
    cursor: pointer;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 8px;
    pointer-events: auto;
}


.download-button:hover {
    background-color: #0046cc;
}

.download-dialog {
    padding: 20px;
    border-radius: 4px;
    border: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    max-width: 380px;
    width: 90%;
}

.download-dialog::backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

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

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 400;
    font-size: 14px;
}

.form-group input[type="text"],
.form-group input[type="email"] {
    width: 100%;
    max-width: 330px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 1000px;
    font-size: 16px;
}

.form-group.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 16px;
}

.form-group.checkbox input[type="checkbox"] {
    margin-top: 4px;
    font-size: 16px;
}

.policy-link {
    color: #007bff;
    text-decoration: none;
}

.policy-link:hover {
    text-decoration: underline;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.form-actions button {
    padding: 8px 16px;
    border-radius: 1000px;
    cursor: pointer;
}

.cancelBtn {
    background-color: #CDC3BA;
    color: white;
    border: none;
}

#confirmDownload {
    background-color: #0057FF;
    color: white;
    border: none;
}

.cancelBtn:hover {
    background-color: #bdb4ac;
}

#confirmDownload:hover {
    background-color: #0046cc;
}

.title {
font-size: 28px;
font-weight: 900;
line-height: 32px;
}

.alternative {
  background: white;
  color: #323232;
  outline: 1px solid #0057FF;
}

.alternative:hover {
  background: rgb(240, 240, 240);
}

.secondary {
  background: #ffd400;
  color: #323232;
  /* outline: 1px solid #0057FF; */
}

.secondary:hover {
  background: #efc700;
}

.tertiary {
  background: #323232;
  color: white;
}

.tertiary:hover {
  background: #424242;
}

/* Add @font-face declaration at the top of the file */
@font-face {
  font-family: 'UniversLTPro-55Roman';
  src: url('fonts/UniversLTPro-55Roman.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
}

.baseline {
  font-size: 14px;
  text-align: center;
  background: #f7f7f7;
  /* text-transform: uppercase; */
  color: #323232;
  padding: 12px;
  margin: 0px;
  border-radius: 16px;
  border: 1px solid #d9d9d9;
}

.loading-image {
  width: 100px; /* Adjust the size as needed */
  animation: bounce 1s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
      transform: translateY(0);
  }
  40% {
      transform: translateY(-20px); /* Adjust the bounce height */
  }
  60% {
      transform: translateY(-10px); /* Adjust the bounce height */
  }
}