/*
  General Stylesheet for Nikki Jones' creative portfolio.

  This file defines a clean, modern aesthetic using a neutral colour
  palette and responsive layout. Colours and typography are defined as
  CSS variables for easy customisation. Feel free to adjust the
  variables below to better match your personal brand.
*/

/* CSS Reset */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Global variables */
:root {
  --bg-colour: #f9fafb;
  --card-colour: #ffffff;
  --text-colour: #2e2e3a;
  --heading-colour: #1f1f2e;
  --accent-colour: #ff704d;
  --secondary-colour: #4b5aea;
  --border-radius: 6px;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* fixed, subtle background image */
body::before {
  content: "";
  position: fixed;          /* fixed relative to viewport */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;              /* send behind page content */
  background-image: url("images/background.png");
  background-size: cover;   /* fill entire viewport */
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; /* keep it fixed:contentReference[oaicite:2]{index=2} */
  opacity: 0.0375;            /* adjust visibility */
  pointer-events: none;     /* ensure it doesn’t block clicks */
}


body {
  font-family: 'Montserrat', 'Poppins', sans-serif;
  color: var(--text-colour);
  background-color: var(--bg-colour);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Navigation */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  background-color: var(--card-colour);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.navbar .logo {
  font-size: 2rem;
  font-weight: 400;
  color: var(--heading-colour);
  /* Use Long Cang for the site name to give it a signature feel */
  font-family: 'Long Cang', 'Montserrat', sans-serif;
}

.navbar .nav-links {
  list-style: none;
  display: flex;
  gap: 1.25rem;
}

.navbar .nav-links a {
  text-decoration: none;
  font-weight: 500;
  color: var(--text-colour);
  transition: color 0.3s ease;
}

.navbar .nav-links a:hover {
  color: var(--accent-colour);
}

/* Hero Section */
.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 6rem 1.5rem 4rem;
  background: linear-gradient(90deg, #e8efff 0%, #fef3f2 100%);
  color: var(--heading-colour);
}

.hero h1 {
  font-size: 5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  font-family: 'Long Cang', 'Montserrat', sans-serif;
}

.hero p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  max-width: none; /* or a larger value than 600px */
}

/* Utility classes */
.btn {
  display: inline-block;
  padding: 0.65rem 1.25rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: var(--secondary-colour);
  color: #fff;
  border: none;
}

.btn-primary:hover {
  background-color: #3a48c1;
}

.btn-secondary {
  background-color: var(--accent-colour);
  color: #fff;
}

.btn-secondary:hover {
  background-color: #e85437;
}

/* Sections */
.section {
  padding: 4rem 1.5rem;
}

.section h2 {
  font-size: 3.4rem;
  font-weight: 700;
  margin-bottom: 2rem;
  color: var(--heading-colour);
  text-align: center;
  font-family: 'Long Cang', 'Poppins', sans-serif;
}

.section-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2rem;
  font-size: 1rem;
  color: var(--text-colour);
}

/* About Section */
.about-content {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
  justify-content: center;
}

.about-photo {
  width: 280px;
  height: 280px;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: var(--shadow);
  /* Add a neutral background and border so the placeholder stands out until replaced */
  background-color: #f0f0f0;
  border: 1px solid #e5e5e5;
}

.about-text {
  flex: 1 1 300px;
  max-width: 600px;
  font-size: 1rem;
}

/* Audio Grid */
.audio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.audio-item h3 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--heading-colour);
}

.audio-item iframe {
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

/* Style native audio player */
.audio-item audio {
  width: 100%;
  margin-top: 0.5rem;
}

/* Photo Grid */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.photo-grid img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  /* Provide a background colour and border so placeholders are visible */
  background-color: #f0f0f0;
  border: 1px solid #e5e5e5;
}

/* Art Grid */
.art-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.art-grid img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  background-color: #f0f0f0;
  border: 1px solid #e5e5e5;
}

/* Book Grid */
.book-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.book-item {
  background-color: var(--card-colour);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

/* View All Books link */
.view-all-books {
  text-align: center;
  margin-top: 2rem;
}

.book-cover {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
  background-color: #f0f0f0;
  border: 1px solid #e5e5e5;
}

.book-item h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--heading-colour);
}

.book-item p {
  flex-grow: 1;
  margin-bottom: 1rem;
  font-size: 0.95rem;
  color: var(--text-colour);
}

/* Contact Form */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.75rem;
  border-radius: var(--border-radius);
  border: 1px solid #dcdce6;
  font-size: 1rem;
  color: var(--text-colour);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--secondary-colour);
  box-shadow: 0 0 0 3px rgba(75, 90, 234, 0.2);
}

.contact-form button {
  align-self: flex-start;
}

/* Social Links */
.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 2rem;
}

.social-links img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  transition: transform 0.3s ease;
  background-color: #f0f0f0;
  border: 1px solid #e5e5e5;
  border-radius: var(--border-radius);
}

.social-links a:hover img {
  transform: scale(1.1);
}

/* Smaller social icons for items embedded within content */
.social-links.small {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.social-links.small img {
  width: 24px;
  height: 24px;
}

/* Copyright */
.copyright {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: #777;
}

/* Hamburger menu button (removed) */
.menu-toggle {
  display: none;
}

/* Button Group */
.button-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

/* Responsive styles */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  .navbar .nav-links {
    gap: 0.75rem;
    font-size: 0.9rem;
  }
  .about-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .about-photo {
    width: 200px;
    height: 200px;
  }

  /* Stack navigation links vertically on small screens */
  .navbar {
    flex-direction: column;
    align-items: flex-start;
  }
  .navbar .nav-links {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    margin-top: 0.5rem;
  }
  .navbar .nav-links li {
    margin: 0.25rem 0;
  }
  .navbar .nav-links a {
    display: block;
    padding: 0.25rem 0;
  }

  /* Reduce section heading size for small screens */
  .section h2 {
    font-size: 2.2rem;
  }

  /* Stack grids into single column on small screens */
  .audio-grid,
  .photo-grid,
  .art-grid,
  .book-grid {
    grid-template-columns: 1fr;
  }

  /* Make button groups vertical */
  .button-group {
    flex-direction: column;
    align-items: stretch;
  }
}

/*
  Additional mobile refinements. These rules override earlier responsive
  definitions to implement a hamburger menu, center the contact form
  submit button, and prevent call‑to‑action buttons from stretching
  across the full width on small screens.
*/
@media (max-width: 768px) {
  /* Always show navigation links on small screens and stack them */
  .navbar {
    flex-direction: column;
    align-items: flex-start;
  }
  .navbar .nav-links {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 0.75rem;
    margin-top: 0.5rem;
  }
  .navbar .nav-links li {
    margin: 0.5rem 0;
  }
  .navbar .nav-links a {
    padding: 0.5rem 0;
  }

  /* Further reduce section headings on mobile */
  .section h2 {
    font-size: 2rem;
  }

  /* Keep call‑to‑action buttons from stretching */
  .button-group {
    flex-direction: column;
    align-items: center;
  }
  .button-group .btn {
    width: auto;
    text-align: center;
  }

  /* Center the contact form submit button */
  .contact-form button {
    align-self: center;
  }
}