/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&display=swap');

/* Root Variables */
:root {
  --color-dark-navy: #1a1a2e;
  --color-dark-secondary: #2c2c44;
  --color-purple-dark: #4a3676;
  --color-purple-primary: #8b6cc2;
  --color-purple-light: #a68cd6;
  --color-purple-text: #d8b9ff;
  --color-white: #ffffff;
  --color-gray-light: #d8d8d8;
  --color-purple-medium: #b0a0d8;
  --color-gray-excerpt: #e0e0e0;
  --color-shadow-purple: rgba(139, 108, 194, 0.3);
  --color-shadow-purple-light: rgba(139, 108, 194, 0.2);
  --color-shadow-purple-medium: rgba(139, 108, 194, 0.4);
  --color-shadow-purple-heavy: rgba(139, 108, 194, 0.5);
  --color-text-color: #e6d5ff;
}

/* Global Styles */
body {
  font-family: 'Poppins', sans-serif;
  background-color: var(--color-white);
  margin: 0;
  background-repeat: no-repeat;
  background-size: cover;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.02em;
  margin-bottom: 1rem;
}

a {
  text-decoration: none;
  color: var(--color-text-color);
}

a:hover {
  color: var(--color-white);
}

main {
  padding: 2rem;
}

/* Header */
header {
  background: linear-gradient(90deg, #2a1a4a, #4a3676);
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 3px solid var(--color-purple-primary);
  box-shadow: 0 4px 10px var(--color-shadow-purple);
  height: 120.5px;
}

header h1 {
  font-size: 3rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--color-purple-text);
  text-shadow: 0 0 10px #6b4e9e;
}

.logoimg {
  height: 90px;
  margin-left: 150px;
}

.navigation-links {
  margin-right: 150px;
}

.pfp {
  height: 50px;
  width: 50px;
  object-fit: cover;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: middle;
}

/* Navigation */
nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  padding: 0;
  margin: 0;
}

nav a {
  color: var(--color-text-color);
  font-size: 1.1rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: background 0.3s, color 0.3s;
  position: relative;
}

nav a::after {
  content: '';
  display: block;
  height: 3px;
  background: #9b59b6;
  transition: width 0.3s;
  width: 0;
  position: absolute;
  bottom: 0;
  left: 0;
}

nav a:hover:not(.dropbtn) {
  color: var(--color-white);
}

nav a:hover::after {
  width: 100%;
}

/* Dropdown */
.profile-dropdown {
  position: relative;
}

.profile-trigger {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  color: var(--color-white);
  font-size: 1rem;
  gap: 0.5rem;
}

.dropdown-menu li a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--color-white);
}

.dropdown-menu li a:hover {
  background-color: #32284a;
}

.dropdown {
  float: left;
  overflow: hidden;
}

.dropdown .dropbtn {
  font-size: 1.1rem;
  border: none;
  padding: 10px 5px;
  color: var(--color-text-color);
  background-color: inherit;
  margin: 0;
  transition: background-color 0.2s ease;
}

.dropdown:hover .dropbtn {
  color: var(--color-white);
}

.dropdown-content {
  display: none;
  position: absolute;
  background-color: #f9f9f9;
  min-width: 130px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  z-index: 10;
}

.dropdown-content a {
  color: black;
  padding: 12px 16px;
  display: block;
  text-align: left;
}

.dropdown-content a:hover {
  background-color: #ddd;
}

.dropdown:hover .dropdown-content {
  display: block;
}

.dropdown #userNameNav {
  all: unset;
  color: var(--color-text-color);
  cursor: pointer;
}

.dropdown #userNameNav:hover {
  background: none;
}

#userNameNav:hover::after {
  content: none;
}

/* Search */
#searchBar {
  padding: 0.5rem;
  font-size: 1.5rem;
  border-radius: 5px;
  border: none;
  background-color: transparent;
  color: var(--color-white);
}

.search-img {
  height: 30px;
}

/* Buttons */
.loginbtn,
.signinbtn {
  background-color: rgb(147, 61, 152);
  color: var(--color-white);
}

.loginbtn:hover {
  font-weight: bold;
}

.hero-button,
.small-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--color-purple-primary);
  color: var(--color-white);
  font-size: 1rem;
  font-weight: bold;
  text-align: center;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.small-button {
  padding: 0.5rem 1rem;
  background-color: #a66eff;
}

.character-creator:hover {
  background-color: #9b5bc0;
  transform: translateY(-2px);
}

.character-creator:active {
  transform: translateY(2px);
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  background-image: url(../images/SCAG_Header.jpg);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-overlay {
  padding: 2rem;
  border-radius: 12px;
  text-align: center;
  color: #f3e8ff;
}

.hero h1 {
  font-size: 3.5rem;
  color: var(--color-white);
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  color: #e1c5f7;
}

/* Text Overlay */
.text-overlay {
  position: absolute;
  transform: translate(-50%, -50%);
  text-align: center;
  color: var(--color-white);
  left: 100px;
  top: 40px;
}

.text-overlay h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

/* Welcome Section */
.welcome {
  background-color: var(--color-purple-dark);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 0 10px #00000055;
  max-width: 900px;
  margin: 2rem auto;
  text-align: center;
}

.welcome h2 {
  font-size: 2.5rem;
  color: #fff0ff;
}

.welcome p {
  font-size: 1.2rem;
  color: #e1c5f7;
}

/* Features Section */
.features {
  background-color: var(--color-white);
  padding: 4rem 2rem;
  text-align: center;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.card {
  background-color: var(--color-purple-light);
  color: var(--color-white);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:nth-child(odd) {
  background-color: #422f5c;
}

.card h3 {
  font-size: 1.8rem;
  color: #fffeff;
}

.card p {
  font-size: 1rem;
  color: var(--color-white);
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Quick Links Section */
.quick-links {
  max-width: 1280px;
  margin: 3rem auto;
  padding: 2rem 1rem;
  position: relative;
  z-index: 1;
}

.image-link-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 1.5rem;
  position: relative;
  z-index: 1;
}

.image-link-stack {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.image-link {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.image-link:hover {
  transform: scale(1.05);
}

.image-link-small .slide-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.image-link-large .slide-image {
  width: 100%;
  height: 420px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.3s ease;
}

.image-link:hover .slide-image {
  transform: scale(1.1);
  filter: brightness(1.1);
}

.image-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
  z-index: 2;
}

.image-link:hover::before {
  left: 100%;
}

.image-link:focus {
  outline: none;
  box-shadow: 0 0 0 3px var(--color-shadow-purple-heavy);
}

/* Blog Preview Section */
.blog-preview {
  max-width: 1280px;
  margin: 3rem auto;
  padding: 2rem 1rem;
  background: var(--color-white);
  border-radius: 8px;
  position: relative;
  z-index: 1;
  border: 1px solid rgb(84, 41, 84);
}

.blog-preview-title {
  font-family: 'Poppins', sans-serif;
  color: #4e216a;
  font-size: 2.2rem;
  font-weight: 700;
  text-align: left;
  text-transform: uppercase;
  margin: 0 0 1.5rem;
  padding-left: 0.5rem;
  border-left: 4px solid var(--color-purple-primary);
}

.blog-grid {
  position: relative;
  z-index: 1;
}

.blog-container {
  width: 100%;
}

.blog-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.blog-post {
  background: var(--color-dark-secondary);
  border: 1px solid var(--color-purple-dark);
  border-radius: 6px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-post:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px var(--color-shadow-purple-medium);
}

.blog-image-container {
  position: relative;
  overflow: hidden;
}

.blog-header-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.3s ease;
}

.blog-post:hover .blog-header-image {
  transform: scale(1.05);
  filter: brightness(1.1);
}

.blog-content {
  padding: 1rem;
}

.blog-category {
  display: inline-block;
  font-family: 'Poppins', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-purple-text);
  background: var(--color-purple-dark);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

.blog-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.blog-title a {
  color: var(--color-white);
  transition: color 0.3s ease;
}

.blog-title a:hover {
  color: var(--color-purple-primary);
}

.blog-meta {
  font-family: 'Poppins', sans-serif;
  font-size: 0.85rem;
  color: var(--color-purple-medium);
  margin-bottom: 0.75rem;
}

.blog-excerpt {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  color: var(--color-gray-excerpt);
  line-height: 1.4;
  margin-bottom: 1rem;
}

.read-more {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-purple-primary);
  transition: color 0.3s ease;
}

.read-more:hover {
  color: var(--color-white);
  text-decoration: underline;
}

.no-posts {
  text-align: center;
  font-family: 'Poppins', sans-serif;
  font-size: 1.2rem;
  color: var(--color-purple-medium);
  padding: 1.5rem;
  background: var(--color-dark-secondary);
  border: 1px solid var(--color-purple-dark);
  border-radius: 6px;
  margin: 1.5rem auto;
  max-width: 500px;
}

.see-all-posts {
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-white);
  background-color: rgb(110, 57, 157);
  width: 150px;
  border-radius: 10px;
  margin: 20px auto;
  padding: 1rem;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.see-all-posts:hover {
  color: var(--color-white);
  text-shadow: 0 0 8px #6b4e9e;
}

/* Footer */
.site-footer {
  background: #1a0b24;
  color: #f8f8f8;
  padding: 1.5rem 1rem;
  font-size: 0.9rem;
  text-align: center;
  border-top: 1px solid rgba(200, 150, 255, 0.2);
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto 1rem;
  justify-content: center;
}

.footer-column {
  flex: 1;
  min-width: 150px;
  max-width: 300px;
}

.footer-tagline p {
  color: #ccc;
  line-height: 1.5;
  margin: 0.3rem 0;
  font-size: 0.85rem;
}

.footer-title {
  font-size: 1.3rem;
  color: #c084f5;
  margin-bottom: 0.6rem;
}

.footer-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-link {
  color: #f8f8f8;
  margin: 0.3rem 0;
  font-size: 0.85rem;
  transition: color 0.2s ease, transform 0.2s ease;
}

.footer-link:hover {
  color: #e0b0ff;
  transform: translateX(3px);
}

.footer-legal {
  max-width: 800px;
  margin: 0 auto;
  padding-top: 0.8rem;
  border-top: 1px solid rgba(200, 150, 255, 0.1);
}

.legal-copyright,
.legal-disclaimer {
  color: #ccc;
  font-size: 0.8rem;
  margin: 0.3rem 0;
}

.legal-disclaimer {
  font-size: 0.75rem;
  line-height: 1.4;
}

.legal-links {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.6rem;
}

.legal-button {
  color: #f8f8f8;
  background: #311a4c;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.8rem;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.legal-button:hover {
  background: #c084f5;
  color: #1a0b24;
  box-shadow: 0 0 8px rgba(200, 150, 255, 0.3);
}

/* Image Container */
.image-container {
  background-color: #f6f0ff;
  padding: 1rem;
  height: 75px;
  margin: 10px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  position: relative;
  width: 250px;
  left: 25px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.image-container:hover {
  transform: translateY(-5px);
  background-color: #a276e9;
}

.image-container img {
  width: 100px;
  height: 75px;
  position: relative;
  left: 85px;
}

.image-container h2 {
  margin-top: 50px;
  font-size: 1.5rem;
  color: black;
  position: relative;

}

.image-button-row {
  display: flex;
  justify-content: center;
  gap: 2rem; /* Increased gap for better spacing */
  max-width: 1280px;
  margin: 2rem auto;
  padding: 1rem;
  flex-wrap: wrap; /* Ensures responsiveness */
  overflow-x: auto; /* Allows scrolling if needed */
}

/* Page Wrapper */
.page-wrapper {
  position: relative;
  z-index: 1;
}

.page-wrapper::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('images/mystical-bg.png') no-repeat center/cover;
  opacity: 0.1;
  z-index: -1;
  animation: pulse 20s infinite ease-in-out;
}

@keyframes pulse {
  0%, 100% { opacity: 0.1; }
  50% { opacity: 0.15; }
}

/* Media Queries */
@media (max-width: 1000px) {

  header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 2vw 4vw;
    height: auto;
    gap: 1vw;
  }
  
    header h1 {
    font-size: 6vw;
    letter-spacing: 0.5vw;
    margin: 0;
    flex: 1 1 100%;
    text-align: center;
  }

  .logoimg {
    height: 12vw;
    margin: 0 auto;
    flex: 1 1 40%;
    margin-left: 27vw;

  }

  nav ul.navigation-links {
    display: flex;
    flex-wrap: wrap;
    gap: 2vw;
    justify-content: center;
    padding: 0;
    margin: 1vw 0;
    flex: 1 1 100%;
    margin-left: 7vw;
  }

  .dropdown .dropbtn {
  font-size: 7.5vw;
  padding: 1.5vw 3vw;
  border-radius: 8px;
  margin-top: 1px;
}

  nav ul.navigation-links {
    gap: 0.3rem;
  }

  nav a,
  .dropdown .dropbtn {
    font-size: 3.5vw;
    padding: 1.5vw 3vw;
    border-radius: 8px;
  }

  .dropbtn {
    font-size: 7.5vw;
    padding: 1.5vw 3vw;
    border-radius: 8px;
  }

  .pfp {
    height: 8vw;
    width: 8vw;
  }

  #searchBar {
    width: 90%;
    font-size: 4vw;
    padding: 1vw;
    margin-top: 1vw;
    text-align: center;
     margin-left: 17vw;
  }

  .search-img {
    display: none;
  }

  .loginbtn, .signinbtn {
    font-size: 3.5vw;
    padding: 1vw 2vw;
    white-space: nowrap;
  }

  .image-link-grid {
    grid-template-columns: 1fr;
  }

  .image-link-stack {
    flex-direction: column;
    gap: 1rem;
  }

  .image-link-small .slide-image,
  .image-link-large .slide-image {
    height: 200px;
  }

  .quick-links-title {
    font-size: 1.8rem;
  }

  .blog-list {
    grid-template-columns: 1fr;
  }

  .blog-preview-title {
    font-size: 1.8rem;
  }

  .blog-title {
    font-size: 1.3rem;
  }

  .blog-header-image {
    height: 160px;
  }

  .card h3 {
    font-size: 1.5rem;
  }

  .card p {
    font-size: 0.9rem;
  }
}

@media (max-width: 1000px) {
  .quick-links {
    padding: 1.5rem 0.75rem;
  }

  .image-link-small .slide-image,
  .image-link-large .slide-image {
    height: 180px;
  }

  .quick-links-title {
    font-size: 1.6rem;
  }

  .blog-post {
    padding: 0.75rem;
  }

  .blog-header-image {
    height: 140px;
  }

  .see-all-posts {
    font-size: 1rem;
  }

  .no-posts {
    font-size: 1rem;
    padding: 1rem;
  }

  .site-footer {
    padding: 1rem 0.5rem;
    font-size: 0.75rem;
  }

  .footer-content {
    flex-direction: column;
    gap: 1rem;
    padding: 0 1rem;
  }

  .footer-column {
    min-width: 100%;
    max-width: none;
    text-align: center;
  }

  .footer-title {
    font-size: 1rem;
  }

  .footer-tagline p,
  .footer-link,
  .legal-copyright,
  .legal-disclaimer {
    font-size: 0.7rem;
  }

  .legal-links {
    flex-direction: column;
    gap: 0.3rem;
  }

  .legal-button {
    font-size: 0.75rem;
    padding: 0.3rem 0.6rem;
  }
}