:root {
	--color-black: #000000;
	--color-white: #ffffff;
	--color-gray: #f5f5f5;
	--color-dark-gray: #333333;
	--max-width: 1200px;
	--transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { height: 100%; height: 100dvh; height: -webkit-fill-available; }
body { min-height: 100vh; min-height: 100dvh; min-height: -webkit-fill-available; font-family: 'Montserrat', sans-serif; line-height: 1.6; color: var(--color-black); background: var(--color-white); display: flex; flex-direction: column; }
main { flex: 1; }
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

.loading-spinner { width: 40px; height: 40px; border: 4px solid var(--color-gray); border-top-color: var(--color-black); border-radius: 50%; animation: spin 1s linear infinite; margin: 2rem auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.lazy-image { background: var(--color-gray); min-height: 250px; }

@media (max-width: 768px) {
	.nav-toggle { display: flex !important; }
	.nav-menu { display: none; }
	.nav-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.5); opacity: 0; visibility: hidden; transition: opacity 0.3s ease; z-index: 1400; }
	.nav-overlay.active { opacity: 1; visibility: visible; }
	.nav-menu { position: fixed; top: 0; right: -100%; height: 100%; width: 80%; flex-direction: column; background: var(--color-white); text-align: center; transition: right 0.3s ease; box-shadow: -10px 0 27px rgba(0, 0, 0, 0.1); padding: 4rem 2rem; display: flex; justify-content: flex-start; align-items: center; gap: 2rem; z-index: 1501; }
	.nav-menu.active { right: 0; display: flex; }
	.nav-close { position: absolute; top: 1rem; right: 1rem; background: none; border: none; font-size: 2rem; cursor: pointer; color: var(--color-black); display: block; }
	.hero-title { font-size: 2rem; }
	.gallery-grid { grid-template-columns: 1fr; }
	.image-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 6px; padding: 1.5rem 0; }
	.footer-content { flex-direction: column; text-align: center; }
	.footer-info { text-align: center; }
	.modal-content { flex-direction: column; }
	.modal-sidebar { width: 100%; height: auto; border-left: none; border-top: 1px solid rgba(255, 255, 255, 0.1); padding: 15px 20px; padding-bottom: calc(15px + 80px); order: 2; }
	.modal-image-container { padding: 60px 10px 10px 10px; order: 1; }
	.modal-nav { font-size: 1.2rem; width: 40px; height: 40px; }
	.modal-next { right: 20px; }
	.modal-close { top: 10px; right: 10px; font-size: 1.5rem; width: 40px; height: 40px; }
	.gallery-overlay { transform: translateY(0) !important; }
	.gallery-item:hover .gallery-overlay { transform: translateY(0) !important; }
}

@media (max-width: 480px) {
	.image-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 4px; padding: 1rem 0; }
	.modal-sidebar { padding: 12px 15px; padding-bottom: calc(12px + 80px); }
	.modal-image-container { padding: 50px 5px 5px 5px; }
	.btn-modal { padding: 10px 15px; font-size: 0.8rem; }
}

@media (min-width: 769px) {
	.nav-toggle { display: none !important; }
	.nav-menu { display: flex !important; }
	.nav-close { display: none !important; }
	.nav-overlay { display: none !important; }
	.logo a { font-size: 1.4rem; }
}

@media (min-width: 1200px) {
	.image-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
}

@media (max-width: 768px) {
	.logo a { font-size: 1.0rem; }
}
