/* Reset default margins and paddings */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Basic styling for the page */
body {
  font-family: Arial, sans-serif;
  text-align: center;
  margin: 0;
  padding: 8px;
  transition: border 0.5s ease;
  border: 3px solid #ffffff;
}

#app {
  margin: 0 auto;
  max-width: 800px; /* Increased width to accommodate left alignment */
  position: relative; /* For positioning the Outline View */
}

#notification {
  font-size: 3em;
  font-weight: 500;
  margin-top: 8px;
  margin-bottom: 12px;
}

#timer {
  font-size: 4em;
  margin-bottom: 18px;
  border-radius: 10px; /* Ensured consistent rounded corners */
  transition: background-color 2s ease, color 0.3s ease; /* Smooth transition for background and text color */
}

/* Progress Bar Styles */
#progress-container {
  width: 100%;
  background-color: #ddd;
  border-radius: 25px;
  overflow: hidden;
  margin-bottom: 30px;
  position: relative;
  box-shadow: inset 0 2px 5px rgba(0,0,0,0.1); /* Inner shadow for depth */
}

/* Local Progress Bar (Cyan with 3D Effect) */
#progress-bar {
  height: 20px;
  width: 0%;
  background-color: #00bbee; /* Darker Cyan */
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3); /* 3D effect: shadow under and to the right */
  transition: width 0.3s ease, box-shadow 0.3s ease;
}

/* Buttons */
#buttons {
  margin-bottom: 20px;
}

#buttons button {
  font-size: 1.2em;
  padding: 10px 20px;
  margin: 5px;
  cursor: pointer;
  border: none;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

#buttons button:hover {
  opacity: 0.8;
}

/* Start Button Color */
#start-btn {
  background-color: #4caf50; /* Green */
  color: #fff;
}

#pause-btn {
  background-color: #f44336; /* Red */
  color: #fff;
}

#extend-btn {
  background-color: #4caf50; /* Green */
  color: #fff;
}

#end-segment-btn {
  /* Default background-color; will be overridden dynamically */
  background-color: #ff9800; /* Orange */
  color: #fff;
}

#edit-button-container {
  margin-top: 20px;
  text-align: center;
}

#edit-button-container a {
  display: inline-block;
  min-width: 76px;
  padding: 7px 18px;
  border: 1px solid #5f78ae;
  border-radius: 8px;
  background: linear-gradient(to bottom, #ffffff 0%, #edf3fb 45%, #c2d3ed 100%);
  box-shadow: 1px 1px 2px rgba(60, 74, 105, .18);
  color: #2f4778;
  font-weight: bold;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}

#edit-button-container a:hover {
  background: linear-gradient(to bottom, #ffffff 0%, #f7faff 45%, #d3e0f3 100%);
  color: #1f3562;
  text-decoration: none;
}

#restart {
  margin-top: 20px;
}

#restart button {
  font-size: 1.2em;
  padding: 10px 20px;
  cursor: pointer;
  border: none;
  border-radius: 5px;
  background-color: #555; /* Dark Gray */
  color: #fff;
  transition: background-color 0.3s ease;
}

#restart button:hover {
  opacity: 0.8;
}

/* Overall Timer Styles */
#overall-timer-container {
  position: relative;
  width: 100%;
  margin-top: 30px;
  margin-bottom: 20px;
}

#overall-timer-bar {
  position: relative;
  width: 100%;
  height: 10px;
  background-color: #ccc;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: inset 0 2px 5px rgba(0,0,0,0.1); /* Inner shadow for depth */
}

#overall-progress {
  position: absolute;
  height: 100%;
  width: 0%;
  background-color: #00bbee; /* Darker Cyan */
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3); /* 3D effect */
  transition: width 0.3s ease, box-shadow 0.3s ease;
}

.segment-marker {
  position: absolute;
  top: -5px;
  width: 2px;
  height: 20px;
  background-color: #000;
}

.hidden {
  display: none;
}

#overall-time-display {
  margin-top: 5px;
  font-size: 1.5em;
}

/* Outline View Styles */
#outline-view {
  margin-top: 30px;
  text-align: left;
  margin-left: 30%; /* Align at 30% of the container's width */
}

#segment-list {
  list-style-type: none;
  padding: 0;
}

#segment-list li {
  font-size: 1.2em;
  padding: 5px 0;
  position: relative; /* For positioning the circle */
  margin-left: 10px; /* Space for the circle */
  color: #000; /* Consistent text color */
}

/* Circle Indicator for Current Segment */
#segment-list li.current::before {
  content: '';
  position: absolute;
  left: -25px; /* Position to the left of the text */
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  background-color: var(--circle-color, #009999); /* Uses CSS variable */
  border-radius: 50%;
}

#segment-list li.current {
  font-weight: bold;
}

#segment-list li.completed {
  color: #888;
}

/* Visual indicator for timer extension */
#timer.extended { /* Solid green background */
  background-color: #4caf50;
}

/* Responsive Design */
@media (max-width: 600px) {
  #notification {
    font-size: 2em;
  }

  #timer {
    font-size: 3em;
  }

  #buttons button, #restart button {
    font-size: 1em;
    padding: 8px 16px;
  }

  #overall-time-display {
    font-size: 1.2em;
  }

  #segment-list li {
    font-size: 1em;
  }

  #outline-view {
    margin-left: 0;
    text-align: center;
  }

  #edit-button-container {
    margin-left: 0;
    text-align: center;
  }
}

/* Updated: Removed hardcoded border classes */
