@import url('https://fonts.googleapis.com/css?family=Open+Sans&display=swap');

:root {
    --bg-color: #000;
    --text-color: #fff;
    --muted-color: #aaa;
    --highlight-color: #ccc;
    --background-image: url(../img/mbr-1920x1280.jpg);
}

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Open-Sans', sans-serif
}

/* Hide scrollbar globally */
html {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

html::-webkit-scrollbar { width: 0px; background: transparent; }

/* --- Fade Overlay --- */
.transition-overlay {
  position: fixed;
  inset: 0;
  background: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
  z-index: 999;
}

body.fade-out .transition-overlay {
  opacity: 1;
  pointer-events: all;
}

/*----------------------------------------*/
/* Layout */

/* Root flex container */
.layout { display: flex; flex-direction: column; min-height: 100vh; justify-content: flex-start; }

/* Basic page wrapper layout */
.page-wrapper {
  display: grid;
  grid-template-columns: 200px 1fr; /* sidebar | content */
  min-height: calc(100vh - 60px); /* offset footer */
  width: 100%;
  background: var(--background-color);
  color: var(--text-color);
}

body {
    background-image: var(--background-image);
    background-color: #fff;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    background-attachment: scroll;
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: scroll;
}

/* Content area (everything to the right of the sidebar) */
.page-content { 
    height: 100vh;
    overflow-y: auto;
    padding-left: 1rem;
    padding: 2rem;
    box-sizing: border-box;
    justify-content: flex-start;
    flex: 1;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: scroll;
    min-height: 100vh;
}


/* Optional: add smooth scrolling */
.page-content::-webkit-scrollbar {
  width: 8px;
}

.page-content::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

/*------------------------------------*/
/* Highlight Quote */
.highlight-quote {
  display: flex;
  justify-content: left;
  padding: 4rem 0rem;
}

.highlight-quote blockquote {
  max-width: 800px;
  width: 100%;
  text-align: center;
  border-top: 1px solid #000;
  border-bottom: 1px solid #000;
  background: #000;
  color: #fff;
  font-size: 1.5rem;
  font-style: italic;
  padding: 2rem 1rem;
  margin: 0;
  line-height: 1.6;
}

/*----------------------------------------*/

/* Inner wrapper for left-aligned content */
.listing-content-inner {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* left align content */
}

.listing-content-inner h2 {
  color: #000;
  background-color: #ffffff25;
  font-size: 2rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid #fff;
  padding-bottom: 0.5rem;
  text-decoration: underline;
}

#blogheader {
    color: #000;
    font-size: 2rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #000;
    padding-bottom: 0.5rem;
}

/* ----------------------------------------- */
/* Sidebar */

.sidebar {
  grid-column: 1;
  background: #000;
  color: #fff;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid #222;
  box-sizing: border-box;
}


.sidebar .logo { font-weight: 700; font-size: 1.5rem; color: var(--text-color); text-decoration: none; }
.sidebar .logo a {
  color: var(--text-color);
  text-decoration: none;
  font-weight: bold;
  letter-spacing: 1px;
}
.logo a:hover,
.logo a:focus,
.logo a:visited {
  color: white;
  text-decoration: none;
}


.sidebar ul { list-style:none; margin: 0; padding: 0; }
.sidebar nav li { margin-bottom: 1rem; }
.sidebar nav a {
  color: #ccc;
  text-decoration: none;
  font-weight: 600;
  position: relative;
  transition: color 0.2s ease;
  display: inline-block;
}

.sidebar nav a.active::after { width: 100%; }
.sidebar nav a:hover { color: var(--text-color); text-decoration: underline;}


/* ----------------------------- */

/* Hero / Landing Page */
.hero {
    position: absolute;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    text-align: center;
    align-items: center;
    width: 100%;
    z-index: 1;

    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    padding: 2rem 3rem;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
}


.hero p { color: #fff; letter-spacing: 2px; padding-bottom: 5px; font-size: 12px; text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);}
.hero h2 { 
    color: #fff; 
    font-size: 3em; 
    word-spacing: 5px;
    letter-spacing: 5px;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero h2 span{ font-weight: 100; }

.hero h6, .learn-more {
    color: #fff;
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    background: none;
    padding: 7px 20px;
    cursor: pointer;
    display: inline-block;
    text-align: center;
    
}

.background-clip {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  z-index: -2; /* behind overlay and content */
  filter: blur(2px) brightness(0.7);
  pointer-events: none;
}

.video-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.005); /* adjustable darkness */
  z-index: -1; /* behind hero text, above video */
}

/* --------------------------------------- */
/* About */

.about h3, .about p {
    color: #000;
    background-color: #fff;
    font-weight: 500;
    display: block;
    width: fit-content;
    font-size: 1.2rem;
    padding: 0.25em 0.5em;
    line-height: 1.6;
    box-decoration-break: clone;
    -webkit-box-direction-break: clone;
    border-radius: 0.25em;
}

.about p {
  margin: 1em 0;
}

.about h3 {
  font-size: 2rem;
  font-weight: 700;
  padding: 0.3em 0.6em;
}

.about h1 {
    display: inline-block;
    font-size: 38px;
    letter-spacing: 0.5px;
    font-weight: 700;
    text-align: left;
    background-color: #000;
    color: #fff;
    padding: 0.2em 0.4em;
}

.about h6 {
    display: inline-block;
    font-size: 18px;
    letter-spacing: 0.5px;
    font-weight: 700;
    text-align: left;
    background-color: #000;
    color: #fff;
    padding: 0.2em 0.4em;
    margin: 0.5em 0;
}

.contact-link a {
  background-color: #000;
  color: #fff;
  text-decoration: none;
  text-align: left;
  padding: 0.2em 0.4em;
  transition: all 0.3s ease;
  display: inline-block;
  border: 1px solid transparent;
  border-radius: 2px; /* optional: softens corners */
}

.contact-link a:hover {
  background-color: #fff;
  color: #000;
  border: 1px solid #000;
  box-shadow: inset 0 0 0 100px #fff; 
  transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.about-portrait {
  flex: 0 0 850px;
  align-items: flex-start; 
  display: flex;
  justify-content: center;
}

.about-portrait img {
  width: 100%;
  max-width: 850px;
  height: auto;
  border-radius: 0.25rem;
  border: 4px solid #000;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  object-fit: cover;
  transition: transform 0.3s ease;
}

@media (max-width: 768px) {
  .about {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .about-portrait {
    margin-top: 1.5rem;
    flex: 0 0 80%;           
  }

  .about-portrait img {
    max-width: 80%;          
  }
}

/* --------------------------------------- */
/* Projects */

/* Hidden class for filtering */
.project {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.project.hidden {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transform: scale(0.95); /* optional subtle shrink */
}

.portfolio-filters {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: #000;
  color: #fff;
  border: 1px solid #fff;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
  background: #fff;
  color: #000;
}

.projects-grid .project {
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.projects-grid .project.hidden {
  opacity: 0;
  transform: scale(0.95);
  pointer-events: none; /* prevents hover while hidden */
  position: absolute;    /* avoids affecting layout while hidden */
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); 
    gap: 1.5rem;
    padding: 2rem 0;
    max-width: 1200px;
    margin: 0 auto;
    transition: all 0.3s ease;
}

/* Individual Project Styling */
.project {
    position: relative;
    background: #000;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    aspect-ratio: 1 / 1;
    cursor: pointer;
    transition: transform 0.25s ease;
}

.project .overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  color: var(--text-color);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 1rem;
}

.project img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.4s ease;
}

.project:hover {
    transform: translateY(-4px) scale(1.02);
}

.project:hover .overlay { opacity: 1; }

.project .overlay h3 {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
}

.project .overlay p {
margin-top: 0.5rem;
font-size: 0.95rem;
line-height: 1.2;
color: var(--muted);
}

.project:hover img { transform: scale(1.1); }

/* -------------------------------------*/
/* Blog Posts */

/* Recent Posts Section */
.recent-posts {
  margin-top: 4rem;
}

.recent-posts h2 {
    display: inline-block;
    font-size: 38px;
    letter-spacing: 0.5px;
    font-weight: 700;
    text-align: left;
    background-color: #000;
    color: #fff;
    padding: 0.2em 0.4em;

    font-size: 2rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #fff;
    padding-bottom: 0.5rem;
}

/* Posts Grid */
.recent-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

/* Post Card */
.post-card {
  background: #111; /* dark card background */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid #333;
  border-radius: 4px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

/* Post Thumbnail */
.post-thumbnail {
  width: 100%;
  display: block;
  object-fit: cover;
  height: 180px;
}

/* Post Content */
.post-content {
  padding: 1rem;
  color: #fff;
}

/* Post Title */
.post-title {
  margin: 0 0 0.5rem 0;
  font-size: 1.3rem;
  text-decoration: none; 
  
}

.post-title a {
  color: #fff;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.3s ease;
}

.post-title a:hover {
  border-bottom: 1px solid #fff;
  opacity: 0.8;
}

.post-excerpt {
  font-size: 1rem;
  color: #fff;
  margin: 0.75rem 0 1rem;
  line-height: 1.7;
  max-width: 60ch;
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid #e5e5e5;
  justify-content: flex-start;
  width: 100%;
  box-sizing: border-box;
}

.post-tags .tag {
  background-color: #000;
  color: #fff;
  padding: 0.4em 0.9em;
  border: 1px solid #000;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
  transition: all 0.3s ease;
}

.post-tags .tag:hover {
  background-color: #fff;
  color: #000;
  transform: translateY(-2px);
}

.post-tags .extra-count {
  background-color: #000;
  color: #fff;
  border: 1px solid #000;
  padding: 0.4em 0.9em;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.post-tags .tag:hover, 
.post-tags .extra-count:hover {
  background-color: #fff;
  color: #000;
  transform: translateY(-2px);
}



/* Post Footer */
.post-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 1rem;
  background: #000;
  font-size: 0.85rem;
  color: #aaa;
  border-top: 1px solid #333;
}

.read-more {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
}

.read-more:hover {
  text-decoration: underline;
}

/* ----------------------------- */
/* Individual Project Page Styling */

/* Project Detail Page */
.project-detail {
  max-width: 900px;
  margin: 4rem auto;
  padding: 0 2rem;
  color: #000;
  background-color: #fff;
  font-family: 'Open Sans', sans-serif;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.project-detail header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1rem;
  border-bottom: 2px solid #000;
  padding-bottom: 0.5rem;
}

.project-detail .project-image {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.project-detail .project-content {
  line-height: 1.7;
  font-size: 1.05rem;
  color: #222;
}

.project-detail .project-content h2,
.project-detail .project-content h3 {
  margin-top: 2rem;
  font-weight: 700;
  color: #000;
}

.project-detail .project-content p {
  margin: 1rem 0;
}

.project-detail .back-link {
  display: inline-block;
  margin-top: 3rem;
  color: #000;
  text-decoration: none;
  font-weight: 600;
  border: 1px solid #000;
  padding: 0.5rem 1rem;
  transition: all 0.3s ease;
}

.project-detail .back-link:hover {
  background-color: #000;
  color: #fff;
}


/* ------------------------------ */
/* Individual Post Styling */

.blogpost {
    background-color: #fff;      /* clean white background */
    color: #000;                 /* readable black text */
    max-width: 800px;            /* constrain width for readability */
    margin: 2rem auto;           /* center horizontally with spacing */
    padding: 2rem 2.5rem;        /* breathing room around content */
    border-radius: 8px;          /* subtle rounding for modern feel */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); /* soft shadow for depth */
    line-height: 1.6;            /* improve text readability */
    font-size: 1rem;
    font-weight: 400;
}


.blogpost p {
    margin-bottom: 1.2rem;       /* spacing between paragraphs */
}

.blogpost h1, .blogpost h2, .blogpost h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 700;
    color: #000;
}

.blogpost h1 {
    font-size: 2rem;
}

.blogpost h2 {
    font-size: 1.75rem;
}

.blogpost h3 {
    font-size: 1.5rem;
}

.blogpost a {
    color: #000;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.blogpost a:hover {
    color: #555; /* subtle hover effect */
}

.blogpost blockquote {
    border-left: 3px solid #000;
    padding-left: 1rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #333;
}

.blogpost img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 1.5rem 0;
    border-radius: 4px;
}

.blogpost section {
    margin-top: 1.5rem;
}

.blogpost .author-date {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 1rem;
}

/* ---------------------------------*/
/* Pagination */
.pagination {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 2rem;
}

.pagination a,
.pagination .current {
  padding: 0.5em 0.8em;
  border-radius: 0.25rem;
  text-decoration: none;
  display: inline-block;
  transition: background-color 0.2s, color 0.2s;
}

/* Unselected pages */
.pagination a {
  background-color: #000;
  color: #fff;
}

.pagination a:hover {
  background-color: #333;
}

/* Selected page */
.pagination .current {
  background-color: #fff;
  color: #000;
  font-weight: 600;
  cursor: default;
}


/* ------------------------------- */
/* Contact Section */
.contact-section { background: #111; color: var(--text-color); padding: 4rem 2rem; justify-content: center; }
.contact-container { max-width: 800px; width: 100%; text-align: center; margin: 0 auto; }

/* Heading and text */
.contact-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.contact-text {
  font-size: 1.1rem;
  color: #ccc;
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* Form styling */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Input and textarea fields */
.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #ccc;
  background: #fff;        /* white background */
  color: #000;             /* black text for readability */
  font-size: 1rem;
  border-radius: 6px;
  outline: none;
  transition: border 0.3s ease, box-shadow 0.3s ease;
}

/* Focus state */
.form-group input:focus,
.form-group textarea:focus {
  border-color: #000;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
}

/* Contact Button */
.contact-button {
  background: #000;
  color: #fff;
  border: 1px solid #fff;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.contact-button:hover {
  background: #fff;
  color: #000;
  border: 1px solid #000;
}

/* ---------------------------------------- */
/* Code Blocks */

/* Code block container */
pre {
  background: #111;
  color: #fff;
  padding: 1rem 1.2rem;
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.95rem;
  line-height: 1.5;
  margin: 1.5rem 0;
  border: 1px solid #333;
}

/* Inline code (single backticks) */
code {
  background: #000;
  color: #fff;
  padding: 0.2em 0.4em;
  border-radius: 4px;
  font-family: "Courier New", monospace;
  font-size: 0.9em;
}

/* Optional: syntax highlighting colors */
.highlight .nt, /* tag names */
.highlight .kd, /* keywords */
.highlight .k,
.highlight .kn {
  color: #86c5ff;
}

.highlight .s, /* strings */
.highlight .sr {
  color: #f4b942;
}

.highlight .c { /* comments */
  color: #777;
  font-style: italic;
}


/* Copy button */
.copy-btn {
  position: absolute;
  top: 0.4rem;
  right: 0.4rem;
  background: #000;
  color: #fff;
  border: 1px solid #fff;
  padding: 0.2em 0.5em;
  font-size: 0.8rem;
  cursor: pointer;
  border-radius: 4px;
  opacity: 0.7;
  transition: opacity 0.2s ease;
  z-index: 2;
}

.copy-btn:hover {
  opacity: 1;
}


/* ---------------------------------------- */
/* Global Footer */
.site-footer {
  background-color: #000;        
  color: #fff;                   
  text-align: center;            
  padding: 1rem 2rem;            
  font-size: 0.9rem;             
  border-top: 1px solid #222;   
}


/* ---------------------------- */
/* Responsive / Mobile adjustments */

@media (max-width: 768px) {
  
  /* Layout adjustments */
  .page-wrapper {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
  }

  .sidebar {
    grid-column: 1;
    grid-row: 1;
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--text-color);
  }

  .portfolio-filters {
    gap: 0.5rem;
  }

  .filter-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
  }

  .listing-content {
    grid-column: 1;
    grid-row: 2;
    padding: 2rem;
  }

  .listing-content-inner {
    width: 100%;
  }

  /* Heading adjustments */
  .hero {
    top: 50%;
    padding: 1.5rem;
  }
  .hero p {
    font-size: 12px;
    letter-spacing: 1px;
  }
  .hero h2 {
    font-size: 2.5em;
    word-spacing: 5px;
    letter-spacing: 5px;
  }
  .hero h6, .learn-more {
    font-size: 10px;
    width: 40%;
  }

  .background-clip {
    height: auto;
    width: 100%;
    min-height: 100%;
    object-fit: cover;
  }

  /* Projects & Recent Posts Grid */
  .projects-grid, .recent-posts-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  /* Post cards adjustments */
  .post-card {
    flex-direction: column;
  }
  .post-footer {
    flex-direction: row;
    justify-content: space-between;
  }

  /* Sidebar links-grid adjustments */
  .links-grid {
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem;
  }

  /* Contact Form adjustments */
  .contact-container {
    padding: 0 1rem;
  }
  .contact-title { font-size: 2rem; }
  .contact-text { font-size: 1rem; }
  .contact-button { width: 100%; }

  .about h1 {
    font-size: 28px;
    letter-spacing: 0.3px;
    padding: 0.15em 0.35em;
  }

  .about h3,
  .about p {
    font-size: 0.95rem;
    padding: 0.15em 0.35em;
  }

  .about h6 {
    font-size: 16px;
    padding: 0.15em 0.35em;
  }

  .contact-link a {
    font-size: 1rem;
    padding: 0.15em 0.35em;
  }
}

