/* public/css/styles.css */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #fff;
}

/* Start Screen Styles */
#start-screen {
  position: absolute;  /* Inside the visualiser-wrapper div */
  top: -20px;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("/washroom-visualiser/assets/all/start_image_blurred.jpg") no-repeat center center;
  background-size: cover;
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

#start-content {
  background: rgba(255, 255, 255, 0.5);
  padding: 0px 20px;
  border-radius: 8px;
  max-width: 600px;
  width: 90%;
  /* Stack each section vertically with spacing */
  display: flex;
  flex-direction: column;
  gap: 15px;
  box-sizing: border-box;
}

/* Main Title */
.start-title {
  font-size: 1.5rem;
  margin-bottom: 10px;
  text-align: center;
  color: #214975;
	font-family: "dinosaur", sans-serif;
font-weight: 700;
font-style: normal;
}

.popup-title {
	  color: #fff;  font-size: 1.5rem;

	font-family: "dinosaur", sans-serif;
font-weight: 700;
font-style: normal;
	margin-top:0px;
	margin-bottom:0px;
}

/* Each Start Section as a Block */
.start-section {
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid #ccc;
  padding-bottom: 15px;
}

.start-thumbnail {
  flex: 0 0 80px;
  width: 192px;
  height: 108px;
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.start-thumbnail img {
  width: 192px;
  height: 108;
}


/* Placeholder thumbnail for load project section */
.placeholder-thumbnail {
  width: 192px;
  height: 108px;
  background-color: #f0f0f0;
}

/* Details next to thumbnail */
.start-details {
  flex: 1;
  text-align: left;
}

.start-details h2 {
  font-size: 1rem;
  margin: 15px 0 5px;
  color: #214975;
	font-family: "dinosaur", sans-serif;
font-weight: 700;
font-style: normal;
}

.start-details p {
  font-size: 0.7rem;
  margin: 5px 0 15px;
  color: #606060;
	font-family: "open sans", sans-serif;
}

/* New Project Section Input Group (button to the right of the text field) */
.new-project-input {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}
.new-project-input input {
  flex: 1;
  max-width: 70%;
  padding: 8px 12px;
  font-size: 0.7rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}
.new-project-input button {
  padding: 10px 20px;
  font-size: 0.7rem;
  background-color: #214975;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
.new-project-input button:hover {
  background-color: #172d5a;
}

#newProjectThumbnail {
	position: relative;
	top:0px;
left:0px;
 width: 192px;
  height: 108px;
  object-fit:cover;
}

#restoreThumbnail 

{
		position: relative;
	top:0px;
left:0px;
 width: 192px;
  height: 108px;
  object-fit:cover;

}

/* Specific Button Styles for Other Sections */
#continueBtn {
  background-color: #bd61a4;  /* Pink */
  color: #fff;
	font-size: 0.7rem;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
#continueBtn:hover {
  background-color: #c26cab;
}

#beginBtn {
  background-color: #214975;
  color: #fff;
}
#beginBtn:hover {
  background-color: #1a3e65;
}

#loadSavedBtn {
  background-color: #e3dee4;  /* Light grey */
  color: #000;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
	font-size: 0.7rem;

}

#loadSavedBtn:hover {
  background-color: #D5CED6;
}



/* Full Screen Button Styles */
.fullscreen-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 101;
  padding: 0.5rem 1rem;
  background: #214975;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
.fullscreen-btn:hover {
  background: #172d5a;
}
/* When in full screen mode via the Fullscreen API,
   we add the 'max-size' class to ensure the inner visualiser
   does not exceed 1920 x 1080 px */
.visualiser-container.max-size {
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f4f4f9;
}
.visualiser-container.max-size .visualiser {
  max-width: 1920px;
  max-height: 1080px;
  width: 100%;
  height: 100%;
}


/* Visualiser container */
.visualiser-container {
  text-align: center;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0px;
overflow: hidden;
}

/* Visualiser area with fixed aspect ratio */
.visualiser {
  position: relative;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 15px;
}

.visualiser-images {
  position: absolute; /* Make it fill the .visualiser container */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease;
  z-index: 2;  /* Ensure it sits above the pseudo-element */
}




.visualiser::before {
  content: "";
  display: block;
  padding-top: 56.25%;
  z-index: 1;
}

@media (max-width: 768px) {
  .visualiser {
    min-height: 600px;
  }
}
.visualiser img {
  width: 100%;
  height: auto;
  position: absolute;
  top: 0;
  left: 0;
}

/* Layer images fade in on first appearance (JS sets opacity:1 once decoded).
   Subsequent colour changes keep opacity:1, so they swap instantly without re-fading. */
.overlay-image {
  opacity: 0;
  transition: opacity 0.45s ease;
}




/* Layering order */
.wall-layer           { z-index: 1; }
.floor-layer          { z-index: 2; }

/* Vanity unit */

.shadow-layer         { z-index: 5; }
.panel-layer          { z-index: 6; }
.splashback-layer     { z-index: 7; }
.top-layer            { z-index: 8; }
.mirror-layer         { z-index: 16; }

/* Cubicles system */

.duct-shadows-layer   { z-index: 3; }
.duct-panels-layer    { z-index: 4; }
.division-layer       { z-index: 9; }
.cubicle-doors-layer  { z-index: 10; }
.pilasters-layer      { z-index: 11; }

/*Urinal system */

.urinal-shadows-layer { z-index: 13; }
.urinal-panel-layer   { z-index: 14; }
.urinal-privacy-layer { z-index: 15; }

/*Radiator*/

.radiator-layer       { z-index: 12; }




/* Image map overlay */
.visualiser-map {
  position: absolute;
  top: 0; 
  left: 0;
  width: 100%;
  height: auto;
  z-index: 100;
	opacity: 0;
	
}

#mapContainer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease;
  pointer-events: auto;
  z-index: 101; /* or an appropriate value so it sits above the background */
}


/* Popup Modal */



.popup-close {
  background: none;
  border: none;
  font-size: 1rem;
  cursor: pointer;
}

.popup-apply {
  background: #bd60a6;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 0.5rem 1rem;
  cursor: pointer;
}
.popup-apply:hover {
  background: #B44B9A;
}

.popup-modal {
  display: none;
  position: absolute;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 6px;
  box-shadow: 0 8px 15px rgba(0,0,0,0.2);
  z-index: 200;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.popup-header {
  flex-shrink: 0;
  background: #bd60a6;
  border-bottom: 1px solid #ccc;
  padding: 10px 20px;
  cursor: move;
}
.popup-footer {
  flex-shrink: 0;
  border-top: 1px solid #ccc;
  background: #204975;
  padding: 10px 20px;
  text-align: right;
}
.popup-content {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
}


/* Hidden controls container */
#allControls {
  display: none;
  flex-wrap: wrap;
  gap: 1rem;
  max-width: 1400px;
  margin: 2rem auto;
}
.control-block {
  flex: 1 1 220px;
}
.control-block label {
  display: block;
  margin-bottom: 0.25rem;
  font-weight: bold;
}
.control-block select {
  width: 100%;
  padding: 0.4rem;
  font-size: 1rem;
  box-sizing: border-box;
}

/* Slider container that holds the arrow buttons and scrolling area */
.swatch-slider-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Arrow button styles (unchanged) */
.swatch-arrow {
  border: none;
  background: #ccc;
  color: #333;
  font-size: 1.2rem;
  width: 30px;
  height: 30px;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
	margin-bottom:20px;
}
.swatch-arrow:hover {
  background: #bbb;
}

/* Outer container that scrolls horizontally */
.swatch-strip-outer {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* for smooth scrolling on iOS */
  width: 260px;  /* adjust this as needed */
	  scrollbar-width: none; /* For Firefox */

}

/* Inner container with flex layout and scroll snap */
.swatch-strip {
  display: flex;
  gap: 8px;
  scroll-snap-type: x mandatory;
}


.swatch-strip-outer::-webkit-scrollbar {
  display: none; /* For Chrome, Safari, and Opera */
}



.swatch-strip-outer {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
  width: 260px; /* or whatever width you require */
  scrollbar-width: none; /* For Firefox */
	margin-bottom:20px;

}

.swatch-strip-outer::-webkit-scrollbar {
  display: none; /* For Chrome, Safari, and Opera */
}


/* Each thumbnail-swatch as a tile that shows the background image */
.thumbnail-swatch {
  scroll-snap-align: start;
  flex: 0 0 auto;  /* Prevent shrinking */
  width: 50px;
  height: 50px;
  border-radius: 15px;
	border: 1px solid #cfcfcf;
  background-size: 100px 100px;
  background-position: center;
  background-repeat: no-repeat;
  cursor: pointer;
  /* Optional: add some margin if needed */
  margin-right: 8px;
}

.thumbnail-swatch:hover {
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
  border-color: #999;
}


/* Visualiser menu bar */
.visualiser-menu-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 0.5rem;
  background-color: #214975;
  display: flex;
  justify-content: center;
  gap: 1rem;
  z-index: 9999;
  box-shadow: 0 -2px 6px rgba(0,0,0,0.15);
}
.menu-btn {
  background: #e3dee4;
  color: #214975;
  border: none;
  border-radius: 4px;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s;
}
.menu-btn:hover {
  background: #fff;
}
.menu-btn:active {
  background: #111;
}
.export-btn {
  background: #bd60a6;
  color: #fff;
}

.export-btn:hover {
  background: #AE4895;
  color: #fff;
}

.colour-tooltip {
  position: absolute;
  display: none;
  background: #fff;       /* White background */
  color: #000;           /* Dark text */
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: bold;
  pointer-events: none;
  z-index: 9999;
  box-shadow: 0 0 2px rgba(0,0,0,0.3);
}

.thumbnail-swatch.selected {
  border: 2px solid #000; /* Or your preferred style */
}
