/* Global */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background: linear-gradient(to bottom, #b6efff, #91d3ff);
  color: #FFF1D6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
}

a { text-decoration: none; color: inherit; }

header {
  background: linear-gradient(
    to bottom, 
    rgba(0,0,0,0.7) 0%,   /* solid black at the top */
    rgba(0,0,0,0.3) 70%,  /* fading in the middle */
    rgba(0,0,0,0) 100%     /* fully transparent at the bottom */
  );
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  flex-wrap: wrap;
  position: sticky; /* keeps header visible on scroll */
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  flex-wrap: wrap;
}

header .logo { font-size: 1.8rem; font-weight: bold; }

nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

nav ul li a {
  padding: 5px 10px;
  border-radius: 5px;
  transition: 0.2s;
}

nav ul li a:hover {
  background: rgba(255,255,255,0.2);
}

main { flex: 1; padding: 20px; text-align: center; }

footer {
  background-color: #333;
  color: white;
  text-align: center;
  padding: 10px 0;
}

/* Boxes */
.box, .calculator { 
  background: rgba(0,0,0,0.6);
  padding: 20px;
  border-radius: 10px;
  max-width: 500px;
  margin: 20px auto;
  text-align: center;
}

.portfolio-table {
  width: 90%;           /* Limit the table width */
  max-width: 1000px;    /* Prevent it from stretching too wide on large screens */
  margin: 20px auto;    /* Center the table */
  border-collapse: collapse;
  background: rgba(0,0,0,0.5); /* Optional semi-transparent background */
  border-radius: 10px;
  overflow: hidden;
}

.portfolio-table th,
.portfolio-table td {
  padding: 10px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0);
}

.portfolio-table img, .portfolio-table video {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 6px;
}

@media (max-width: 900px) {
  .portfolio-table img, .portfolio-table video {
    width: 150px;
    height: 150px;
  }
}

@media (max-width: 600px) {
  .portfolio-table {
    width: 95%;
  }
  .portfolio-table img, .portfolio-table video {
    width: 100px;
    height: 100px;
  }
  .portfolio-table td, .portfolio-table th {
    padding: 5px;
    font-size: 14px;
  }
}

.about-img { width: 100%; max-width: 200px; border-radius: 6px; margin: 10px 0; }

.contact-table { width: 100%; margin-top: 10px; }
.contact-table td { padding: 10px; }

/* Calculator Inputs */
input[type="checkbox"], select, button {
  margin: 5px 0;
  padding: 8px;
  border-radius: 5px;
  border: none;
}

/* Responsive tweaks */
@media (max-width: 600px) {
  nav ul { flex-direction: column; gap: 10px; text-align: center; }
  header { justify-content: center; gap: 10px; }
  .portfolio-item img { height: 150px; }
}

.video-hero {
  position: relative;
  height: 100vh;
  overflow: hidden;
}

#bg-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  z-index: 0;
  transform: translate(-50%, -50%);
  object-fit: cover;
}

/* Overlay text styling */
.video-overlay {
  position: relative;
  z-index: 1;
  text-align: center;
  color: white;
  top: 50%;
  transform: translateY(-50%);
  padding: 0 1rem;
}

.video-overlay h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.video-overlay p {
  font-size: 1.25rem;
  font-weight: 300;
}

/* Add a dark overlay for readability */
.video-hero::after {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.4);
  z-index: 0;
}