* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  height: 100%;
}

body {
  font-family: 'Helvetica', 'Arial', 'Sans-Serif';
  color: #333;
  line-height: 1.6;
  background-color: #fff;
}

body.has-video-background {
  color: #fff;
  background-color: transparent;
  overflow: hidden;
  height: 100vh;
}

.video-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  z-index: -1;
}

.video-background video {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  min-width: 100%;
  min-height: 100%;
  object-fit: cover;
  transform: translate(-50%, -50%) scale(1.25);
  filter: brightness(0.75);
  z-index: 0;
}

.image-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  z-index: -1;
}

.image-background img {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translate(-50%, -50%);
  filter: brightness(0.75);
  z-index: 0;
}

@media (max-width: 768px) {
  .image-background img {
    object-fit: cover;
    object-position: left center;
    width: 100%;
    height: 100%;
  }
  
  .intro-wrapper {
    padding-right: 100px;
  }
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.35);
  z-index: 1;
}

.page-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body.has-video-background .page-content {
  height: 100vh;
  overflow: hidden;
}

nav {
  position: fixed;
  top: 0;
  right: 0;
  padding: 20px;
  z-index: 100;
}

.nav-name {
  font-weight: 600;
  font-size: 1em;
  margin-bottom: 20px;
  text-align: right;
  color: #333;
}

body.has-video-background .nav-name {
  color: #fff;
}

nav ul, footer ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-end;
}

footer ul {
  flex-direction: row;
  justify-content: center;
  gap: 20px;
}

nav a {
  text-decoration: underline;
  color: #0066cc;
  font-weight: 500;
  text-transform: lowercase;
}

body.has-video-background nav a {
  color: #fff;
}

nav a:hover {
  color: #0052a3;
}

body.has-video-background nav a:hover {
  color: #e0e0e0;
}

footer {
  padding: 20px;
  border-top: 1px solid #d5d5d5;
  font-size: 0.9em;
}

body.has-video-background footer {
  border-top: 1px solid rgba(255, 255, 255, 0.3);
}

footer a {
  text-decoration: none;
  color: #666;
}

body.has-video-background footer a {
  color: #fff;
}

footer a:hover {
  color: #333;
  text-decoration: underline;
}

body.has-video-background footer a:hover {
  color: #e0e0e0;
}

.intro-wrapper {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 15vh;
}

.intro-square {
  width: 500px;
  height: 500px;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
}

.intro-content {
  padding: 30px;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.intro-content h1 {
  font-size: 18pt;
  margin-bottom: 1em;
  font-weight: 600;
}

.intro-content p {
  font-size: 1em;
  line-height: 1.6;
  margin-bottom: 1em;
  color: #333;
}

body.has-video-background .intro-content p {
  color: #fff;
}

.intro-content a {
  color: #0066cc;
  text-decoration: none;
}

body.has-video-background .intro-content a {
  color: #fff;
}

.intro-content a:hover {
  text-decoration: underline;
}

.intro-content b {
  font-weight: 600;
}

.projects-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 40px 20px 40px 20px;
}

.projects-list {
  max-width: 600px;
  width: 100%;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 40px 40px 40px 20px;
  box-shadow: none;
}

.project-item {
  margin-bottom: 30px;
}

.project-item h2 {
  font-size: 1.5em;
  font-weight: 600;
  margin-bottom: 8px;
}

.project-item h2 a {
  color: #333;
  text-decoration: none;
}

body.has-video-background .project-item h2 a {
  color: #fff;
}

.project-item h2 a:hover {
  color: #0066cc;
  text-decoration: underline;
}

body.has-video-background .project-item h2 a:hover {
  color: #e0e0e0;
}

.project-item p {
  color: #666;
  line-height: 1.6;
  margin: 0;
}

body.has-video-background .project-item p {
  color: #fff;
}

/* Content pages styling */
.content-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.content-container {
  max-width: 700px;
  width: 100%;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 40px;
  box-shadow: none;
}

.content-container h1 {
  font-size: 2em;
  font-weight: 600;
  margin-bottom: 0.5em;
  color: #333;
}

body.has-video-background .content-container h1 {
  color: #fff;
}

.content-container .subtitle {
  font-size: 1.2em;
  font-style: italic;
  margin-bottom: 1.5em;
  color: #666;
}

body.has-video-background .content-container .subtitle {
  color: #e0e0e0;
}

.content-container p {
  font-size: 1em;
  line-height: 1.8;
  margin-bottom: 1.2em;
  color: #444;
}

body.has-video-background .content-container p {
  color: #fff;
}

.content-container a {
  color: #0066cc;
  text-decoration: none;
}

body.has-video-background .content-container a {
  color: #fff;
}

.content-container blockquote {
  margin: 1.5em 0;
  padding-left: 1.5em;
  border-left: 4px solid #0066cc;
  font-style: italic;
  color: #555;
  line-height: 1.8;
}

body.has-video-background .content-container blockquote {
  border-left-color: #fff;
  color: #e0e0e0;
}

.content-container img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

body.has-video-background .content-container img {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.content-container a:hover {
  text-decoration: underline;
}

.faves-list {
  list-style: none;
  padding: 0;
}

.faves-list li {
  margin-bottom: 15px;
  font-size: 1em;
  line-height: 1.6;
}

.faves-list li a {
  color: #0066cc;
  text-decoration: none;
}

body.has-video-background .faves-list li a {
  color: #fff;
}

.faves-list li a:hover {
  color: #0052a3;
  text-decoration: underline;
}

body.has-video-background .faves-list li a:hover {
  color: #e0e0e0;
}

.poem-content {
  white-space: pre-line;
  line-height: 1.8;
  font-size: 1em;
  color: #444;
}

body.has-video-background .poem-content {
  color: #fff;
}
