/* =============================================
   Localmoms Zürichsee – Custom Styles
   Supplements Tailwind CSS
   ============================================= */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=DM+Sans:wght@300;400;500&family=Dancing+Script:wght@600&display=swap');

/* ---- Smooth scrolling ---- */
html {
  scroll-behavior: smooth;
}

/* ---- Base typography ---- */
body {
  font-family: 'DM Sans', system-ui, sans-serif;
  background-color: #FDFCF9;
  color: #2D2419;
  -webkit-font-smoothing: antialiased;
}

/* ---- Serif utility ---- */
.font-serif {
  font-family: 'Playfair Display', Georgia, serif;
}

.font-script {
  font-family: 'Dancing Script', cursive;
}

/* ---- Nav default: white + glass on scroll ---- */
#navbar {
  background: white !important;
  transition: box-shadow 0.3s ease, background 0.3s ease;
  z-index: 9999 !important;
  position: fixed !important;
}

#navbar.nav-scrolled {
  background: rgba(255, 255, 255, 0.95) !important;
  box-shadow: 0 1px 24px rgba(45, 36, 25, 0.08);
}

/* ---- Hero section ---- */
.hero-pattern {
  background-image:
    radial-gradient(circle at 20% 80%, rgba(232, 99, 73, 0.06) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(232, 99, 73, 0.04) 0%, transparent 50%);
}

/* ---- Post card hover ---- */
.post-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(45, 36, 25, 0.1);
}

.post-card img {
  transition: transform 0.4s ease;
}

.post-card:hover img {
  transform: scale(1.04);
}

/* ---- Category badge ---- */
.category-badge {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ---- Logo circle ---- */
.logo-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1.5px solid #2D2419;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

/* ---- Divider ornament ---- */
.ornament {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: #C4956A;
}

.ornament::before,
.ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.4;
}

/* ---- Instagram embed scroll fix (mobile) ---- */
.instagram-embed-wrapper {
  -webkit-overflow-scrolling: auto;
}
.instagram-embed-wrapper iframe {
  pointer-events: auto;
  touch-action: pan-y;
}

/* ---- Mobile menu button ---- */
#menu-btn {
  position: relative;
  z-index: 51;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* ---- Mobile menu (fullscreen overlay) ---- */
#mobile-menu {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100% !important;
  height: 100% !important;
  background: #FDFCF9 !important;
  padding-top: 5rem !important;
  overflow-y: auto !important;
  z-index: 49 !important;
}

#mobile-menu a.mobile-nav-link {
  display: flex !important;
  align-items: center !important;
  gap: 1rem !important;
  padding: 1.25rem 1.75rem !important;
  font-family: 'Playfair Display', Georgia, serif !important;
  font-size: 1.375rem !important;
  font-weight: 500 !important;
  letter-spacing: -0.01em;
  color: #2D2419 !important;
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.06) !important;
  transition: background 0.15s ease;
}

#mobile-menu a.mobile-nav-link svg {
  width: 24px !important;
  height: 24px !important;
  flex-shrink: 0 !important;
  opacity: 0.5;
}

#mobile-menu a.mobile-nav-link.active svg {
  opacity: 1;
}

#mobile-menu a.mobile-nav-link:active {
  background: rgba(232, 99, 73, 0.08);
}

#mobile-menu a.mobile-nav-link.active {
  color: #E86349 !important;
}

/* ---- Form inputs ---- */
.form-input {
  border: 1px solid #E3D9CC;
  background: #FDFCF9;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  width: 100%;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.95rem;
  color: #2D2419;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

.form-input:focus {
  border-color: #E86349;
  box-shadow: 0 0 0 3px rgba(232, 99, 73, 0.1);
}

.form-input::placeholder {
  color: #9B8F85;
}

/* ---- Skeleton loader ---- */
.skeleton {
  background: linear-gradient(90deg, #F0EAE2 25%, #E8E0D5 50%, #F0EAE2 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 0.5rem;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---- Footer gradient ---- */
.footer-bg {
  background: linear-gradient(135deg, #2D2419 0%, #3D3028 100%);
}

/* ---- Spinner ---- */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ---- Scroll fade-in ---- */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Nav links ---- */
.nav-link {
  position: relative;
  padding-bottom: 4px;
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: #E86349 !important;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: #E86349;
  border-radius: 1px;
  transition: width 0.25s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link.active {
  color: #2D2419 !important;
}

.nav-link.active::after {
  width: 100%;
  background: #2D2419;
}

/* ---- Orte Marquee ---- */
.marquee-wrapper {
  width: 100%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.marquee-track {
  display: inline-flex;
  align-items: center;
  gap: 0;
  white-space: nowrap;
  will-change: transform;
  animation: marquee-scroll 18s linear infinite;
}

.marquee-track:hover {
  animation-play-state: paused;
}

@keyframes marquee-scroll {
  0% { transform: translateX(0%); }
  100% { transform: translateX(-50%); }
}

/* ---- Instagram feed grid ---- */
.instagram-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}

@media (max-width: 640px) {
  .instagram-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---- Instagram embed styling ---- */
.instagram-embed-wrapper {
  border-radius: 16px;
  border: 1px solid #E3D9CC;
  overflow: hidden;
  position: relative;
}

.instagram-embed-wrapper::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(to bottom, transparent, #FDFCF9);
  pointer-events: none;
  z-index: 1;
}

.instagram-embed-wrapper iframe {
  width: 100%;
  border: none;
}

/* ---- Filter pill active ---- */
.filter-pill.active {
  background-color: #E86349;
  color: white;
  border-color: #E86349;
}

/* ---- Read more link ---- */
.read-more {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-weight: 500;
  color: #E86349;
  transition: gap 0.2s ease;
}

.read-more:hover {
  gap: 0.625rem;
}

/* ---- Dot Navigation ---- */
.dot-nav {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 14px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.dot-nav.visible {
  opacity: 1;
}

.dot-nav a {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d6d3d1;
  display: block;
  transition: all 0.3s ease;
  position: relative;
}

.dot-nav a:hover {
  background: #E86349;
  transform: scale(1.3);
}

.dot-nav a.active {
  background: #2D2419;
  transform: scale(1.3);
}

.dot-nav a::before {
  content: attr(data-label);
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  white-space: nowrap;
  font-size: 0.7rem;
  font-weight: 500;
  color: #78716c;
  background: white;
  padding: 4px 10px;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.dot-nav a:hover::before {
  opacity: 1;
}

@media (max-width: 768px) {
  .dot-nav { display: none; }
}

/* ---- Toast notification ---- */
.toast {
  position: fixed;
  bottom: -80px;
  left: 50%;
  transform: translateX(-50%);
  background: #2D2419;
  color: white;
  padding: 1rem 1.75rem;
  border-radius: 100px;
  font-size: 0.9rem;
  font-weight: 500;
  font-family: 'DM Sans', system-ui, sans-serif;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  box-shadow: 0 8px 32px rgba(45, 36, 25, 0.25);
  z-index: 200;
  transition: bottom 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  white-space: nowrap;
}

.toast.visible {
  bottom: 2rem;
}

.toast .toast-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #4ade80;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ---- Inline field validation ---- */
.input-error {
  border-color: #E86349 !important;
  box-shadow: 0 0 0 3px rgba(232, 99, 73, 0.1) !important;
}

.field-error-msg {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.78rem;
  color: #E86349;
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
  animation: fadeInDown 0.2s ease;
}

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

/* ---- Envelope success notification ---- */
.env-toast {
  position: fixed;
  bottom: -180px;
  left: 50%;
  transform: translateX(-50%);
  background: white;
  border-radius: 20px;
  padding: 1.25rem 1.5rem 1.25rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 20px 60px rgba(45, 36, 25, 0.14), 0 4px 12px rgba(45, 36, 25, 0.07);
  z-index: 300;
  transition: bottom 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid #F0EAE2;
  min-width: 260px;
  pointer-events: none;
}

.env-toast.visible {
  bottom: 2.5rem;
}

.env-icon-wrap {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, #FEF2F0 0%, #FDEAE4 100%);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  animation: env-float 2.8s ease-in-out infinite;
}

@keyframes env-float {
  0%,  100% { transform: translateY(0px) rotate(-4deg); }
  50%        { transform: translateY(-7px) rotate(4deg); }
}

.env-text-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: #2D2419;
  line-height: 1.2;
}

.env-text-sub {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.78rem;
  color: #a8a29e;
  margin-top: 2px;
}

/* ---- Back to Top ---- */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #2D2419;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 40;
  box-shadow: 0 4px 12px rgba(45, 36, 25, 0.15);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: #E86349;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(232, 99, 73, 0.25);
}
