/* Reset browser to default */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Basic style of page */
body {
  background-color: #F5E6D3; /* Light tan */
  color: black; /* Text color */
  font-family: Arial, Helvetica, sans-serif; /* Font for the page */
  margin: 0;
  padding: 0;
  line-height: 1.6;
}

/* Intended to center the content and preventing larger screeen to stretch */
.container {
   max-width: 800px;
   margin: 0 auto;
}

/* Styling for the header */
header {
  text-align: center;
  margin-bottom: 40px;
  background-color: white;
}

/* Flex box styling for Navigation */
nav ul {
	list-style-type: none; /* Removes the bullets*/
  padding: 10px 20px;
  border-radius: 5px; /* makes the borders rounded */
  justify-content: center;
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

nav li{
  background-color: white;
  padding: 10px 20px;
  border-radius: 5px;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  cursor: pointer;
}

/* Removes the blue from the links from the nav*/
nav a {
	text-decoration: none;
  color: inherit;  
}

/* Gives a hover feature to the Navigation */
nav li:hover {
  background-color: #e0e0e0;
}

/* Styling for the smaller secondary navigation  */

.nav-2 ul {
  gap: 8px; /* smaller space between the buttons */
  padding: 5px 10px; /* smaller padding around the whole menu */
}

.nav-2 li {
  padding: 5px 12px; /* Had to shrink padding inside the buttons */
  font-size: 12px; /* Smaller text size */
  font-weight: normal; /* Makes the text less bulky compared to the main nav */
  border-radius: 4px; /*  Smaller rounded corners */
  background-color: #e8d8c3; /* Little darker tan to separate it from the white main nav */
}

/* Hover effect for the smaller buttons */
.nav-2 li:hover {
  background-color: #e0e0e0; /* Uses first navs #e0e0e0 color */
  color: white;
}

/* Styling for the sections: Done with white boxes with white shadow */
section {
  background-color: white;
  padding: 30px;
  margin-bottom: 25px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);

}

/* Styling for section headings */

h2 {
  margin-top: 0;
  border-bottom: 2px solid #F5E6D3; /* Adds a nice line under the h2 */
  padding-bottom: 10px;
  text-align: center; /* Centered all h2 */

}

/* Styling for the clickable image / modul like feature */
.image-1, .image-2 {
  width: 400px;
  max-width: 100%;
  display: block;
  margin: 20px auto;
  cursor: pointer;
  border-radius: 10px;
  transition: transform 0.3s ease;
  
}

/* Gives the image a hover effect */
/* Instead of rewritting CSS code multiple times you can group same features for your classes */
.image-1:hover, .image-2:hover {
  transform: scale(1.05);
}

/* This styling hides the checkbox */
#img1, #img2 {
  display: none;

}

/* Hides the popup by default */
.popup {
  display: none;
}

/* Shows popup when the checkbox is pressed */
#img1:checked ~ .popup,
#img2:checked ~ .popup {
  display: block;
}

/* Darkens the background of overlay */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
}

/* Creates the modal/ Modal and popup white box */
.about, .mission {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  max-width: 90%;
  background: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  z-index: 2; /* Keeps the white box on top of the dark overlay */
  max-height: 90vh;
  overflow-y: auto;
}

.charts{
  display:flex;
  justify-content:center;
  gap:50px;
  flex-wrap:wrap;
  margin:40px auto;
}

/* This CSS takes care of the styling for the charts*/
.chart-card{
    text-align:center;
}

.pie{
    width:220px;
    height:220px;
    border-radius:50%;
    margin:20px auto;
}

/* 33% vs 20% */
.stress{
    background:conic-gradient(
        #7DAA92 0% 33%,
        #F2C94C 33% 53%,
        #EAEAEA 53% 100%
    );
}

/* 48% vs 26% The values being shown*/
/* Received a bit of help from resources like chatgpt to do this */
.overwhelming{
    background:conic-gradient(
        #7DAA92 0% 48%,
        #F2C94C 48% 74%,
        #EAEAEA 74% 100%
    );
}

.legend{
    text-align:left;
}

.legend p{
    margin:8px 0;
}

.legend span{
    display:inline-block;
    width:16px;
    height:16px;
    margin-right:8px;
}

.parents{
    background:#7DAA92;
}

.adults{
    background:#F2C94C;
}

/* --- Styling for the newsletter to match the rest of the page --- */
/* --- Newsletter Form Styling --- */
form {
  max-width: 500px;
  margin: 20px auto 0; /* Centers the form inside the section */
  display: flex;
  flex-direction: column;
  text-align: left; /* Keeps labels aligned to the left */
}

form label {
  font-weight: bold;
  margin-bottom: 8px;
  margin-top: 15px;
  color: #333;
}

form input[type="text"],
form input[type="email"] {
  padding: 12px;
  border: 2px solid #F5E6D3; /* Matches your h2 underline */
  border-radius: 5px; /* Matches your nav buttons */
  font-size: 16px;
  font-family: inherit;
  transition: border-color 0.3s ease;
}

/* Highlights the box in your chart's green color when clicked/typing */
form input[type="text"]:focus,
form input[type="email"]:focus {
  outline: none;
  border-color: #7DAA92; 
}

form input[type="submit"] {
  margin-top: 25px;
  background-color: #F5E6D3; /* Uses the tan from your page charts */
  color: white;
  border: none;
  padding: 15px 20px;
  border-radius: 5px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: background-color 0.3s ease, transform 0.3s ease;
}

/* Gives the button a hover effect similar to your sections */
form input[type="submit"]:hover {
  background-color: #FCF3E6; /* Slightly lighter off tan/white */
  transform: translateY(-2px); 
}

/* Styling for the close button for the modals "responsive"*/
.close-btn {
  display: inline-block;
  margin-top: 15px;
  padding: 6px 13px;
  background-color: #f5e6d3;
  color: black;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bolder;
  text-align: center;
  
}

.close-btn:hover {
  background-color: #e0d2c0;
}

figcaption {
 text-align: center; 
}

.home-p {
  text-align: center;
  color: red;
}

.chart-p {
   text-align: center; 

}
.home-title {
  text-align: center;
}