/* REM Agency Theme - CSS Main */

:root {
  --rem-blue: #4BA2FF;
  --rem-blue-deep: #2E88E8;
  --rem-blue-soft: #7FBEFF;
  --rem-blue-pale: #E6F1FF;
  --rem-dark: #010101;
  --rem-ink: #0A0A0A;
  --rem-white: #FFFFFF;
}

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

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--rem-ink);
  background-color: var(--rem-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 700;
}

/* Navigation Bar */
#theHeader,
nav.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

#theHeader.scrolled,
nav.navbar.scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
}

.navbar-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

/* Logo */
.navbar-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--rem-dark);
}

.navbar-logo svg {
  width: 28px;
  height: 28px;
  color: var(--rem-blue-deep);
  transition: color 0.3s ease;
}

.navbar-logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.navbar-logo-text strong {
  font-family: 'Montserrat', sans-serif;
  font-style: italic;
  font-weight: 600;
  font-size: 20px;
  color: var(--rem-dark);
  transition: color 0.3s ease;
}

.navbar-logo-text small {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  margin-top: 4px;
  color: rgba(10, 10, 10, 0.7);
  transition: color 0.3s ease;
}

/* Navigation Menu */
.navbar-menu {
  display: none;
  list-style: none;
}

@media (min-width: 1024px) {
  .navbar-menu {
    display: flex;
    align-items: center;
    gap: 32px;
  }
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--rem-dark);
  text-decoration: none;
  transition: color 0.3s ease;
  position: relative;
}

.nav-link:hover {
  color: var(--rem-blue-deep);
}

.nav-link.active {
  color: var(--rem-blue-deep);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-top: 12px;
  width: 288px;
  background: var(--rem-white);
  border-radius: 16px;
  box-shadow: 0 20px 25px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(-4px);
  transition: all 0.18s ease;
  pointer-events: none;
}

.nav-dropdown:hover .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.nav-dropdown-menu a {
  display: block;
  padding: 12px 20px;
  font-size: 14px;
  color: var(--rem-dark);
  text-decoration: none;
  transition: all 0.2s ease;
}

.nav-dropdown-menu a:hover {
  background: var(--rem-blue-pale);
  color: var(--rem-blue-deep);
}

.cta-button {
  padding: 8px 24px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  background: var(--rem-blue-deep);
  color: var(--rem-white);
  border: none;
  cursor: pointer;
}

.cta-button:hover {
  background: var(--rem-blue);
}

/* Mobile Menu Button */
.mobile-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  color: var(--rem-dark);
  cursor: pointer;
  border-radius: 8px;
  transition: background 0.3s ease;
}

.mobile-menu-btn:hover {
  background: rgba(46, 136, 232, 0.1);
}

@media (min-width: 1024px) {
  .mobile-menu-btn {
    display: none;
  }
}

/* Mobile Menu */
.mobile-menu {
  display: none;
  background: var(--rem-white);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  border-top: 1px solid var(--rem-blue-pale);
}

.mobile-menu.open {
  display: block;
}

.mobile-menu-list {
  list-style: none;
  padding: 16px;
}

.mobile-menu-list li {
  margin-bottom: 8px;
}

.mobile-menu-list a {
  display: block;
  padding: 12px 16px;
  border-radius: 8px;
  color: var(--rem-dark);
  text-decoration: none;
  transition: all 0.2s ease;
}

.mobile-menu-list a:hover {
  background: var(--rem-blue-pale);
  color: var(--rem-blue-deep);
}

/* Footer */
footer {
  background: var(--rem-blue);
  color: var(--rem-white);
  overflow: hidden;
  border-top: 2px solid rgba(255, 255, 255, 0.6);
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240' viewBox='0 0 240 240'><g fill='none' stroke='white' stroke-width='2' opacity='0.28' font-family='Georgia,serif' font-style='italic'><text x='0' y='80' font-size='120'>R</text><text x='100' y='170' font-size='120'>R</text><text x='0' y='260' font-size='120'>R</text></g></svg>");
  background-repeat: repeat;
  background-size: 240px 240px;
  opacity: 0.4;
  pointer-events: none;
}

.footer-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
  padding-top: 56px;
  padding-bottom: 56px;
}

.footer-grid {
  display: grid;
  gap: 40px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(12, 1fr);
  }
}

.footer-section {
  grid-column: span 1;
}

@media (min-width: 768px) {
  .footer-section:nth-child(1) {
    grid-column: span 4;
  }
  .footer-section:nth-child(2) {
    grid-column: span 5;
    padding-left: 32px;
    border-left: 2px solid rgba(255, 255, 255, 0.6);
  }
  .footer-section:nth-child(3) {
    grid-column: span 3;
  }
}

.footer-logo {
  margin-bottom: 24px;
}

.footer-address {
  font-style: normal;
  margin-top: 24px;
  font-size: 12px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.footer-address a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
}

.footer-address a:hover {
  text-decoration: underline;
}

.footer-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.footer-title::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.footer-menu {
  list-style: none;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.9);
}

.footer-menu li {
  margin-bottom: 8px;
}

.footer-menu a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
}

.footer-menu a:hover {
  text-decoration: underline;
}

.footer-social {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.25);
  text-decoration: none;
  color: rgba(255, 255, 255, 1);
  font-size: 12px;
  font-weight: 500;
  backdrop-filter: blur(10px);
  transition: all 0.2s ease;
}

.footer-social:hover {
  background: rgba(255, 255, 255, 0.4);
}

.footer-social svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.footer-bottom {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 2px solid rgba(255, 255, 255, 0.6);
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
}

.footer-bottom a:hover {
  text-decoration: underline;
}

.footer-links {
  display: flex;
  gap: 20px;
}

/* Main Content */
body {
  padding-top: 100px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main,
#content {
  flex: 1;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  padding: 0 1.5rem;
}

.rem-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Piwigo content wrapper */
#theContent {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

/* Hide Piwigo menu bar and palettes */
#menubar {
  display: none !important;
}

#thePalette {
  display: none !important;
}

.header_msgs {
  display: none !important;
}

#theHeader {
  display: none !important;
}

/* Remove dark background from page title */
.titrePage {
  background-color: transparent !important;
  background: transparent !important;
  padding: 20px 0 !important;
}

/* Gallery Styles */
#content {
  padding: 40px 0;
}

.gallery {
  padding: 20px 0;
}

.gallery-item {
  transition: transform 0.3s ease, filter 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-4px);
  filter: drop-shadow(0 10px 15px rgba(46, 136, 232, 0.1));
}

/* Piwigo specific overrides */
#theContent {
  padding: 0;
}

.content {
  margin: 0;
  padding: 0;
}

/* Thumbnail gallery styling */
.thumbnails {
  list-style: none;
  padding: 0;
  margin: 0;
}

.thumbnails li {
  margin: 8px;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.thumbnails li:hover {
  box-shadow: 0 8px 16px rgba(46, 136, 232, 0.2);
}

.thumbnails a {
  display: block;
}

.thumbnails img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: 9999px;
  font-weight: 600;
  transition: all 0.3s ease;
  font-size: 14px;
  letter-spacing: 0.5px;
  border: none;
  cursor: pointer;
  text-decoration: none;
}

.btn-solid {
  background: var(--rem-blue-deep);
  color: var(--rem-white);
}

.btn-solid:hover {
  background: var(--rem-blue);
}

.btn-dark {
  background: var(--rem-dark);
  color: var(--rem-white);
}

.btn-dark:hover {
  background: #000000;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.3);
  color: var(--rem-white);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.4);
}

/* Utilities */
.text-balance {
  text-wrap: balance;
}

.section-title {
  font-size: 48px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

@media (max-width: 768px) {
  .section-title {
    font-size: 32px;
  }
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--rem-blue);
}

.section-eyebrow::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--rem-blue);
}

.divider-line {
  display: block;
  width: 1px;
  background: rgba(255, 255, 255, 0.4);
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(24px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-10px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-out both;
}

.animate-slide-up {
  animation: slideUp 0.7s ease-out both;
}

.animate-slide-down {
  animation: slideDown 0.5s ease-out both;
}

/* Print Styles */
@media print {
  #theHeader,
  nav.navbar,
  footer {
    display: none;
  }

  body {
    padding-top: 0;
  }
}
