/* 
  ===========================================================
  File: style.css
  Author: Joshua Dornfeldt
  Description: CSS for styling the personal portfolio site,
               including layout, colors, and responsive design.
  ===========================================================
*/

/* General Styles */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background-color: #f4f4f9;
  color: #333;
}

/* Header 
   - Green background and white text to stand out
*/
header {
  background-color: #4CAF50;
  color: #fff;
  padding: 20px 0;
  text-align: center;
}

/* 
  Sticky Navigation Bar:
  - Sticks to top on scroll
  - White background for contrast
  - Subtle box-shadow for visual separation
*/
nav {
  position: sticky;
  top: 0;
  z-index: 999; /* Ensures that the nav stays above other elements */
  background-color: #fff;
  padding: 10px 0;
  margin: 0;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

nav a {
  margin: 0 10px;
  text-decoration: none;
  color: #4CAF50;
  font-weight: bold;
}

nav a:hover {
  text-decoration: underline;
}

/* Container for consistent max-width and centering */
.container {
  width: 80%;
  margin: 0 auto;
}

/* Section Styles 
   - White background, rounded corners, subtle box shadow
*/
section {
  margin: 40px 0;
  padding: 20px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* About Section Layout
   - Flex container for headshot and a bio side by side on larger screens
*/
.about-container {
  display: flex;
  flex-wrap: wrap; 
  gap: 2rem;       
  align-items: center;
}

.about-headshot img {
  max-width: 200px; /* Controls the headshot size */
  border-radius: 50%; /* To display a circular image */
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.about-bio {
  flex: 1;
  min-width: 250px;
}

.about-bio p {
  margin-bottom: 1rem;
}

/* Project Links
   - Green button style for the "View GitHub Repository" links
*/
.project a {
  display: inline-block;
  margin-top: 5px;
  padding: 10px 15px;
  color: #fff;
  background-color: #4CAF50;
  text-decoration: none;
  border-radius: 5px;
}

.project a:hover {
  background-color: #45a049;
}

/* Footer 
   - Dark background, white text for contrast
*/
footer {
  text-align: center;
  padding: 10px 0;
  background-color: #333;
  color: #fff;
}

/* Scroll-to-Top Button 
   - Circular arrow for returning to top of the page
   - Hidden by default, and will appear after scrolling down
*/
#scroll-top {
  position: fixed;
  bottom: 20px;
  right: 20px;

  width: 40px;
  height: 40px;
  border-radius: 50%;

  font-size: 20px;
  font-weight: bold;
  line-height: 40px;
  text-align: center;

  background-color: #4CAF50;
  color: #fff;
  border: none;
  cursor: pointer;
  display: none;

  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

#scroll-top:hover {
  background-color: #45a049;
}

/* Modal
   - Hidden overlay that appears for project details or expansions
*/
.modal {
  display: none;
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto; 
  background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background-color: #fff;
  margin: 15% auto;
  padding: 20px;
  border-radius: 8px;
  width: 80%;
  max-width: 500px;
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* Project Dates
   - Italicized style for timeline under each project title
*/
.project-dates {
  font-style: italic;
  color: #666;
  margin-bottom: 1rem;
}

.coming-soon {
  background-color: #999;      
  opacity: 0.7;           
}

.coming-soon:hover {
  background-color: #999; 
}
