/* Base Styles and Variables */
:root {
  --bg-color: #1a1a1a;
  --text-color: #e0e0e0;
  --accent-color: #2196F3;
  --accent-color-hover: #1976D2; /* slightly darker blue for hover states */
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg-color);
  color: var(--text-color);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  line-height: 1.6;
}

/* Container to center content and set max width */
.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Headings and text */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-color);
  margin: 2rem 0 1rem;
  font-weight: 600;
}
h1 { font-size: 1.8em; }
h2 { font-size: 1.5em; }
h3 { font-size: 1.25em; }
p {
  margin: 1rem 0;
}
p.call-to-action {
  font-size: 1.1em;
  font-weight: 500;
}
a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s;
}
a:hover {
  text-decoration: underline;
  color: var(--accent-color-hover);
}
a:focus {
  outline: 2px dashed var(--accent-color);
  outline-offset: 4px;
}

/* Header and Navigation Bar */
header {
  background: #0f0f0f; /* very dark gray background for header */
  padding: 0.5rem 0;
}
header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo img {
  height: 40px;
  /* If no image is available, we could instead style text logo:
     font-size: 1.2em; font-weight: bold; color: var(--text-color); */
}
nav a {
  color: var(--text-color);
  margin-left: 2rem;
  font-size: 1em;
  text-decoration: none;
}
nav a:hover {
  color: var(--accent-color);
}
nav a.active {
  color: var(--accent-color);
  font-weight: 500;
}

/* Footer */
footer {
  background: #0f0f0f;
  padding: 1rem 0;
}
footer p {
  text-align: center;
  font-size: 0.9em;
  color: #aaaaaa;
  margin: 0.5rem 0;
}
footer a {
  color: var(--accent-color);
}
footer a:hover {
  color: var(--accent-color-hover);
  text-decoration: underline;
}

/* Blockquotes (for quotes on home page) */
blockquote {
  border-left: 4px solid var(--accent-color);
  margin: 1.5rem 0;
  padding: 0.5rem 1rem;
  color: #cccccc;
  font-style: italic;
}
blockquote footer {
  text-align: right;
  font-size: 0.9em;
  color: #999999;
  margin-top: 0.5rem;
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}
figure {
  text-align: center;
  margin: 2rem 0;
}
figure img {
  /* center the image in figure (block with auto margin not needed since figure text-align) */
}
figure figcaption {
  font-size: 0.9em;
  color: #aaaaaa;
  margin-top: 0.5rem;
}

/* Portfolio Items */
.portfolio-item {
  margin-bottom: 3rem;
}
.portfolio-item img {
  display: block;
  margin: 0.5rem auto 1rem;
}
.portfolio-item h2 {
  text-align: center;
  font-size: 1.3em;
  margin-bottom: 0.5rem;
}
.portfolio-item p {
  text-align: left;
}
.portfolio-item ul {
  margin: 0.5rem 0 1.5rem 1.2rem;
  /* default list-style is fine (disc), color will be same as text */
}
.portfolio-item ul li {
  margin: 0.5rem 0;
}

/* Contact Form Styles */
form {
  margin: 1.5rem 0;
}
label {
  display: block;
  margin: 0.5rem 0 0.2rem;
  font-weight: 500;
}
input[type=text], input[type=email], textarea {
  width: 100%;
  padding: 0.5rem;
  background: #2a2a2a;
  border: 1px solid #555555;
  color: var(--text-color);
  border-radius: 4px;
  font: inherit;
  transition: border-color 0.2s;
}
input::placeholder, textarea::placeholder {
  color: #888888;
}
input:focus, textarea:focus {
  outline: none;
  border-color: var(--accent-color);
}
button[type=submit], input[type=submit] {
  background: var(--accent-color);
  color: #ffffff;
  border: none;
  padding: 0.6rem 1.2rem;
  font-size: 1em;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
  margin: 0.5rem 0 1rem;
}
button[type=submit]:hover, input[type=submit]:hover {
  background: var(--accent-color-hover);
}
button[type=submit]:focus {
  outline: 2px dashed var(--accent-color);
  outline-offset: 3px;
}

/* Additional spacing or helper classes */
.contact-info {
  margin: 1.5rem 0;
  font-size: 1em;
}

/* Responsive Design: Stack nav on smaller screens */
@media (max-width: 600px) {
  header .container {
    flex-direction: column;
    align-items: center;
  }
  header nav {
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  header nav a {
    margin: 0.5rem 0;
  }
  .portfolio-item h2, .portfolio-item p {
    text-align: center;
  }
}
