diff --git a/css/styles.css b/css/styles.css index 47c5bfa..bc550b6 100644 --- a/css/styles.css +++ b/css/styles.css @@ -1,4 +1,109 @@ -/* Facebook Style — Blue social network */ +/* ======================================== + Paraguay LLC & SRL — Facebook Style + Awesome Animations + ======================================== */ + +/* ======================================== + ANIMATIONS — Motion Design System + ======================================== */ + +/* Easing curves from craft-floor: natural deceleration */ +@keyframes fadeSlideUp { + from { opacity: 0; transform: translateY(24px); } + to { opacity: 1; transform: translateY(0); } +} + +@keyframes fadeIn { + from { opacity: 0; } + to { opacity: 1; } +} + +@keyframes scaleIn { + from { opacity: 0; transform: scale(0.95); } + to { opacity: 1; transform: scale(1); } +} + +@keyframes slideDown { + from { opacity: 0; transform: translateY(-8px); } + to { opacity: 1; transform: translateY(0); } +} + +@keyframes pulse { + 0% { transform: scale(1); } + 50% { transform: scale(1.04); } + 100% { transform: scale(1); } +} + +@keyframes shimmer { + 0% { background-position: -200% 0; } + 100% { background-position: 200% 0; } +} + +@keyframes floatSlow { + 0%, 100% { transform: translateY(0); } + 50% { transform: translateY(-6px); } +} + +@keyframes heroGradientShift { + 0% { background-position: 0% 50%; } + 50% { background-position: 100% 50%; } + 100% { background-position: 0% 50%; } +} + +@keyframes ripple { + 0% { box-shadow: 0 0 0 0 rgba(24, 119, 242, 0.4); } + 100% { box-shadow: 0 0 0 12px rgba(24, 119, 242, 0); } +} + +@keyframes slideInModal { + from { opacity: 0; transform: scale(0.92) translateY(20px); } + to { opacity: 1; transform: scale(1) translateY(0); } +} + +@keyframes countPop { + 0% { transform: scale(1); } + 30% { transform: scale(1.15); color: #fff; } + 60% { transform: scale(0.95); } + 100% { transform: scale(1); } +} + +@keyframes rippleExpand { + from { width: 0; height: 0; opacity: 0.4; } + to { width: 200px; height: 200px; opacity: 0; } +} + +/* Scroll reveal visible state */ +.fade-in-section.visible { + opacity: 1 !important; + transform: translateY(0) !important; +} + +/* Reduced motion preference */ +@media (prefers-reduced-motion: reduce) { + *, *::before, *::after { + animation-duration: 0.01ms !important; + animation-iteration-count: 1 !important; + transition-duration: 0.01ms !important; + } + .fade-in-section { opacity: 1; transform: none; } +} + +/* Stagger delay classes */ +.stagger-1 { animation-delay: 0.08s !important; } +.stagger-2 { animation-delay: 0.16s !important; } +.stagger-3 { animation-delay: 0.24s !important; } +.stagger-4 { animation-delay: 0.32s !important; } + +/* Scroll reveal base state */ +.fade-in-section { + opacity: 1; + transform: none; + transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), + transform 0.5s cubic-bezier(0.16, 1, 0.3, 1); +} + +/* ======================================== + BASE + ======================================== */ *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; @@ -6,18 +111,46 @@ body { color: #1c1e21; line-height: 1.33; font-size: 15px; + overflow-x: hidden; } -/* Navigation */ +/* Custom scrollbar */ +::-webkit-scrollbar { width: 8px; } +::-webkit-scrollbar-track { background: #f0f2f5; } +::-webkit-scrollbar-thumb { background: #bdc3c7; border-radius: 4px; } +::-webkit-scrollbar-thumb:hover { background: #95a5a6; } + +/* Text selection */ +::selection { background: rgba(24, 119, 242, 0.2); color: #1c1e21; } + +/* Focus rings — design-system focus */ +:focus-visible { + outline: 2px solid #1877f2; + outline-offset: 2px; +} + +/* ======================================== + NAVIGATION + ======================================== */ .nav { - background: #fff; - box-shadow: 0 2px 4px rgba(0,0,0,0.1); + background: rgba(255,255,255,0.97); + backdrop-filter: blur(12px); + -webkit-backdrop-filter: blur(12px); + box-shadow: 0 1px 3px rgba(0,0,0,0.06); height: 56px; position: sticky; top: 0; z-index: 1000; padding: 0 16px; + transition: box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), + background 0.3s ease; } + +.nav.scrolled { + box-shadow: 0 4px 16px rgba(0,0,0,0.1); + background: rgba(255,255,255,0.99); +} + .nav-container { max-width: 1200px; margin: 0 auto; @@ -34,8 +167,20 @@ body { color: #1877f2; font-size: 24px; font-weight: 700; + transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1); } -.nav-logo { font-size: 28px; } +.nav-brand:hover { + transform: scale(1.03); +} +.nav-logo { + font-size: 28px; + transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); + display: inline-block; +} +.nav-brand:hover .nav-logo { + transform: rotate(8deg) scale(1.1); +} + .nav-menu { display: flex; gap: 8px; align-items: center; } .nav-link { color: #65676b; @@ -44,10 +189,18 @@ body { font-weight: 500; padding: 8px 16px; border-radius: 8px; - transition: background 0.2s; + transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease; + position: relative; +} +.nav-link:hover { + background: #f0f2f5; + color: #1877f2; +} +.nav-link:active { + transform: scale(0.97); } -.nav-link:hover { background: #f0f2f5; } .nav-actions { display: flex; gap: 8px; align-items: center; } + .lang-select { display: flex; gap: 4px; } .lang-btn { background: #f0f2f5; @@ -57,11 +210,20 @@ body { cursor: pointer; border-radius: 6px; font-weight: 500; + transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); + position: relative; + overflow: hidden; } .lang-btn.active { background: #e7f3ff; color: #1877f2; } -.lang-btn:hover { background: #e4e6eb; } +.lang-btn:hover { + background: #e4e6eb; + transform: translateY(-1px); +} +.lang-btn:active { transform: scale(0.96); } -/* Buttons */ +/* ======================================== + BUTTONS + ======================================== */ .btn { padding: 8px 16px; font-size: 15px; @@ -69,69 +231,149 @@ body { border-radius: 6px; cursor: pointer; text-decoration: none; - display: inline-block; + display: inline-flex; + align-items: center; + justify-content: center; + gap: 6px; border: none; - transition: background 0.2s; + transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); + position: relative; + overflow: hidden; } .btn-primary { background: #1877f2; color: #fff; } -.btn-primary:hover { background: #166fe5; } +.btn-primary:hover { + background: #166fe5; + transform: translateY(-1px); + box-shadow: 0 4px 12px rgba(24, 119, 242, 0.35); +} +.btn-primary:active { + transform: translateY(0) scale(0.98); +} .btn-outline { background: #f0f2f5; color: #1c1e21; border: none; } -.btn-outline:hover { background: #e4e6eb; } +.btn-outline:hover { + background: #e4e6eb; + transform: translateY(-1px); +} +.btn-outline:active { transform: scale(0.98); } .btn-block { display: block; width: 100%; text-align: center; } -.btn-telegram { background: #0088cc; color: #fff; } +.btn-telegram { + background: #0088cc; + color: #fff; + transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); +} +.btn-telegram:hover { + background: #0077b3; + transform: translateY(-1px); + box-shadow: 0 4px 12px rgba(0, 136, 204, 0.35); +} +.btn-telegram:active { transform: scale(0.98); } -/* Hero */ +/* ======================================== + HERO — Focal Motion + ======================================== */ .hero { - background: linear-gradient(135deg, #1877f2 0%, #42b0ff 100%); + background: linear-gradient(135deg, #1877f2 0%, #42b0ff 40%, #1877f2 70%, #0d5fc9 100%); + background-size: 300% 300%; + animation: heroGradientShift 12s ease infinite; color: #fff; text-align: center; padding: 60px 20px 40px; + position: relative; + overflow: hidden; } + +/* Subtle mesh pattern overlay */ +.hero::before { + content: ''; + position: absolute; + top: 0; left: 0; right: 0; bottom: 0; + background: radial-gradient(ellipse at 30% 20%, rgba(255,255,255,0.08) 0%, transparent 60%), + radial-gradient(ellipse at 70% 80%, rgba(255,255,255,0.05) 0%, transparent 50%); + pointer-events: none; +} + +.hero-content { position: relative; z-index: 1; } + .hero-title { font-size: 42px; font-weight: 700; margin-bottom: 12px; text-shadow: 0 2px 4px rgba(0,0,0,0.1); + /* Entrance animation — applied by JS on load */ + opacity: 0; + transform: translateY(24px); + animation: fadeSlideUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards; } + .hero-subtitle { font-size: 18px; - opacity: 0.9; + opacity: 0; + transform: translateY(24px); + animation: fadeSlideUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.25s forwards; + color: rgba(255,255,255,0.9); margin-bottom: 30px; max-width: 600px; margin-left: auto; margin-right: auto; } -.hero-stats { display: flex; justify-content: center; gap: 60px; } -.stat { text-align: center; } + +.hero-stats { + display: flex; + justify-content: center; + gap: 60px; +} + +.stat { + text-align: center; + opacity: 0; + transform: translateY(24px); + animation: fadeSlideUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards; +} +.stat:nth-child(1) { animation-delay: 0.4s; } +.stat:nth-child(2) { animation-delay: 0.55s; } +.stat:nth-child(3) { animation-delay: 0.7s; } + .stat-number { display: block; font-size: 36px; font-weight: 700; + transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); } -/* Sections */ +/* ======================================== + SECTIONS + ======================================== */ .section { background: #fff; - border-radius: 8px; + border-radius: 12px; padding: 24px; margin: 16px auto; max-width: 1200px; - box-shadow: 0 1px 2px rgba(0,0,0,0.1); + box-shadow: 0 1px 3px rgba(0,0,0,0.06); + transition: box-shadow 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); } -.section-alt { background: #fff; border-radius: 8px; padding: 24px; margin: 16px auto; max-width: 1200px; box-shadow: 0 1px 2px rgba(0,0,0,0.1); } +.section:hover { + box-shadow: 0 4px 12px rgba(0,0,0,0.08); +} + +.section-alt { background: #f7f8fa; border-radius: 12px; padding: 24px; margin: 16px auto; max-width: 1200px; box-shadow: none; } + .section-title { font-size: 20px; font-weight: 700; margin-bottom: 20px; color: #1c1e21; } + .container { max-width: 100%; } -/* About */ +/* ======================================== + ABOUT CARDS + ======================================== */ .about-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); @@ -139,16 +381,56 @@ body { } .about-card { padding: 20px; - border-radius: 8px; + border-radius: 10px; background: #f0f2f5; - transition: transform 0.2s, box-shadow 0.2s; + transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1); + cursor: default; + position: relative; + overflow: hidden; +} +/* Subtle top accent line on hover */ +.about-card::before { + content: ''; + position: absolute; + top: 0; left: 0; right: 0; + height: 3px; + background: linear-gradient(90deg, #1877f2, #42b0ff); + transform: scaleX(0); + transform-origin: left; + transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); +} +.about-card:hover::before { + transform: scaleX(1); +} +.about-card:hover { + transform: translateY(-4px); + box-shadow: 0 8px 24px rgba(0,0,0,0.1); + background: #fff; +} +.about-icon { + font-size: 2.5rem; + margin-bottom: 12px; + transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1); + display: inline-block; +} +.about-card:hover .about-icon { + transform: scale(1.15) translateY(-2px); +} +.about-card h3 { + font-size: 16px; + font-weight: 600; + color: #1c1e21; + margin-bottom: 8px; +} +.about-card p { + font-size: 14px; + color: #65676b; + line-height: 1.4; } -.about-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); } -.about-icon { font-size: 2.5rem; margin-bottom: 12px; } -.about-card h3 { font-size: 16px; font-weight: 600; color: #1c1e21; margin-bottom: 8px; } -.about-card p { font-size: 14px; color: #65676b; line-height: 1.4; } -/* Search */ +/* ======================================== + SEARCH + ======================================== */ .search-bar { display: flex; max-width: 400px; @@ -157,24 +439,42 @@ body { } .search-icon { position: absolute; - left: 12px; + left: 14px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: #65676b; + transition: color 0.2s ease; + pointer-events: none; } +.search-input:focus + .search-icon, +.search-bar:focus-within .search-icon { + color: #1877f2; +} + .search-input { width: 100%; - padding: 10px 12px 10px 36px; - border: none; - border-radius: 20px; + padding: 10px 12px 10px 38px; + border: 2px solid transparent; + border-radius: 24px; background: #f0f2f5; font-size: 15px; + transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); +} +.search-input:focus { + outline: none; + border-color: #1877f2; + background: #fff; + box-shadow: 0 0 0 4px rgba(24, 119, 242, 0.15); +} +.search-input::placeholder { + color: #9eaab5; } -.search-input:focus { outline: 2px solid #1877f2; outline-offset: 0; } -/* Members Grid */ +/* ======================================== + MEMBERS + ======================================== */ .members-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); @@ -185,33 +485,71 @@ body { align-items: center; gap: 12px; padding: 12px; - border-radius: 8px; + border-radius: 10px; background: #f0f2f5; cursor: pointer; - transition: background 0.2s; + transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); + position: relative; + overflow: hidden; } -.member-card:hover { background: #e4e6eb; } +.member-card:hover { + background: #fff; + transform: translateY(-2px); + box-shadow: 0 6px 16px rgba(0,0,0,0.08); +} +.member-card:active { transform: scale(0.98); } + +/* Subtle highlight on hover */ +.member-card::after { + content: ''; + position: absolute; + top: 0; left: 0; right: 0; bottom: 0; + background: linear-gradient(135deg, rgba(24, 119, 242, 0.05), transparent); + opacity: 0; + transition: opacity 0.25s ease; + pointer-events: none; +} +.member-card:hover::after { opacity: 1; } + .user-avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; + border: 2px solid transparent; + transition: border-color 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1); + flex-shrink: 0; +} +.member-card:hover .user-avatar { + border-color: #1877f2; + transform: scale(1.05); } .user-avatar-text { width: 48px; height: 48px; border-radius: 50%; - background: #1877f2; + background: linear-gradient(135deg, #1877f2, #42b0ff); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 600; + flex-shrink: 0; + transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1); +} +.member-card:hover .user-avatar-text { + transform: scale(1.05); +} +.member-info h4 { + font-size: 15px; + font-weight: 600; + color: #1c1e21; + margin-bottom: 2px; } -.member-info h4 { font-size: 15px; font-weight: 600; color: #1c1e21; margin-bottom: 2px; } .member-company { font-size: 13px; color: #65676b; } .member-location, .member-posts { font-size: 13px; color: #65676b; } + .rank-badge { font-size: 11px; padding: 3px 8px; @@ -220,6 +558,10 @@ body { top: -4px; right: 0; font-weight: 500; + transition: transform 0.2s ease; +} +.member-card:hover .rank-badge { + transform: scale(1.1); } .rank-badge.rank-rookie { background: #e4e6eb; color: #65676b; } .rank-badge.rank-beginner { background: #e7f3e9; color: #0a832c; } @@ -229,7 +571,9 @@ body { .rank-badge.rank-expert { background: #fff3e0; color: #e65100; } .rank-badge.rank-legend { background: #fce4ec; color: #c62828; } -/* Wiki Cards */ +/* ======================================== + WIKI CARDS + ======================================== */ .wiki-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); @@ -237,66 +581,138 @@ body { } .wiki-card { padding: 16px; - border-radius: 8px; + border-radius: 10px; background: #f0f2f5; cursor: pointer; - transition: all 0.2s; + transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); + position: relative; + overflow: hidden; border-left: 4px solid #1877f2; } -.wiki-card:hover { background: #e4e6eb; } -.wiki-card-title { font-size: 15px; font-weight: 600; color: #1c1e21; margin-bottom: 6px; } -.wiki-card-excerpt { font-size: 13px; color: #65676b; margin-bottom: 8px; } -.wiki-card-footer { display: flex; justify-content: space-between; font-size: 13px; color: #65676b; } +.wiki-card::before { + content: ''; + position: absolute; + top: 0; left: 0; right: 0; bottom: 0; + background: linear-gradient(135deg, rgba(24, 119, 242, 0.08), transparent); + opacity: 0; + transition: opacity 0.25s ease; + pointer-events: none; +} +.wiki-card:hover::before { opacity: 1; } +.wiki-card:hover { + background: #fff; + transform: translateY(-3px); + box-shadow: 0 8px 20px rgba(0,0,0,0.08); + border-left-color: #42b0ff; +} +.wiki-card:active { transform: scale(0.98); } + +.wiki-card-title { + font-size: 15px; + font-weight: 600; + color: #1c1e21; + margin-bottom: 6px; + transition: color 0.2s ease; +} +.wiki-card:hover .wiki-card-title { + color: #1877f2; +} +.wiki-card-excerpt { + font-size: 13px; + color: #65676b; + margin-bottom: 8px; +} +.wiki-card-footer { + display: flex; + justify-content: space-between; + font-size: 13px; + color: #65676b; +} .wiki-card-subtopic { color: #1877f2; } .no-results { padding: 20px; text-align: center; color: #65676b; } .loading-text { padding: 20px; text-align: center; color: #65676b; font-style: italic; } -/* Modal */ +/* ======================================== + MODALS + ======================================== */ .modal-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; - background: rgba(255,255,255,0.8); + background: rgba(0,0,0,0.4); + backdrop-filter: blur(4px); + -webkit-backdrop-filter: blur(4px); z-index: 2000; display: none; align-items: center; justify-content: center; + padding: 20px; + /* Fade in when active */ + animation: fadeIn 0.2s ease forwards; } .modal-overlay.active { display: flex; } .modal { background: #fff; - border-radius: 8px; - padding: 24px; + border-radius: 14px; + padding: 28px; max-width: 440px; width: 90%; - box-shadow: 0 8px 30px rgba(0,0,0,0.2); + box-shadow: 0 20px 60px rgba(0,0,0,0.2); position: relative; + /* Scale in animation */ + animation: slideInModal 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards; } .modal-close { position: absolute; - top: 12px; - right: 16px; - background: none; + top: 14px; + right: 18px; + background: #f0f2f5; border: none; - font-size: 24px; + width: 32px; + height: 32px; + border-radius: 50%; + font-size: 18px; cursor: pointer; color: #65676b; + display: flex; + align-items: center; + justify-content: center; + transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1); +} +.modal-close:hover { + background: #e4e6eb; + color: #1c1e21; + transform: rotate(90deg); } .login-icon { font-size: 3rem; text-align: center; margin-bottom: 16px; } -.login-hint { color: #65676b; text-align: center; margin-bottom: 20px; font-size: 15px; } +.login-hint { + color: #65676b; + text-align: center; + margin-bottom: 20px; + font-size: 15px; +} .form-group { margin-bottom: 14px; } .form-input { width: 100%; padding: 12px 14px; - border: 1px solid #dddfe2; - border-radius: 6px; + border: 2px solid #e4e6eb; + border-radius: 10px; font-size: 15px; + transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); + background: #f7f8fa; + color: #1c1e21; } -.form-input:focus { border-color: #1877f2; outline: 2px solid #1877f2; outline-offset: -2px; } +.form-input:focus { + border-color: #1877f2; + background: #fff; + box-shadow: 0 0 0 4px rgba(24, 119, 242, 0.12); + outline: none; +} +.form-input::placeholder { color: #9eaab5; } .login-step { display: none; } -.login-step.active { display: block; } +.login-step.active { display: block; animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards; } /* Profile & Detail */ .profile-username { font-size: 1.2rem; font-weight: 600; margin-bottom: 8px; } @@ -309,60 +725,102 @@ body { border-radius: 50%; margin: 0 auto 16px; overflow: hidden; + border: 3px solid #e7f3ff; } .user-detail-header { text-align: center; margin-bottom: 16px; } .user-detail-name-rank { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 8px; } .user-detail-name-rank h2 { font-size: 1.2rem; font-weight: 600; } .user-detail-fields { display: grid; gap: 10px; } -.detail-field { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #e4e6eb; } +.detail-field { + display: flex; + justify-content: space-between; + padding: 10px 0; + border-bottom: 1px solid #e4e6eb; + transition: background 0.2s ease; +} +.detail-field:hover { background: #f7f8fa; border-radius: 4px; padding-left: 4px; } .detail-label { color: #65676b; font-size: 14px; } .detail-value { color: #1c1e21; font-size: 14px; text-align: right; } .user-detail-company { color: #65676b; text-align: center; } -/* Telegram Banner */ +/* ======================================== + TELEGRAM BANNER + ======================================== */ .telegram-banner { background: #e7f3ff; padding: 16px 24px; margin: 16px auto; max-width: 1200px; - border-radius: 8px; + border-radius: 10px; display: flex; align-items: center; gap: 16px; + animation: slideDown 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards; +} +.banner-icon { + font-size: 2rem; + animation: floatSlow 3s ease-in-out infinite; } -.banner-icon { font-size: 2rem; } .banner-text strong { color: #1c1e21; } -/* Newsletter */ +/* ======================================== + NEWSLETTER + ======================================== */ .newsletter-card { text-align: center; max-width: 400px; margin: 0 auto; } .newsletter-icon { font-size: 2.5rem; margin-bottom: 16px; } .newsletter-hint { color: #65676b; margin-bottom: 16px; font-size: 15px; } -/* Footer */ +/* ======================================== + FOOTER + ======================================== */ .footer { background: #fff; - padding: 24px 16px; + padding: 32px 16px; text-align: center; border-top: 1px solid #e4e6eb; margin-top: 32px; + transition: all 0.3s ease; } -.footer-brand { margin-bottom: 12px; } -.footer-logo { font-size: 1.5rem; } +.footer-brand { margin-bottom: 16px; } +.footer-logo { font-size: 1.5rem; display: inline-block; } .footer-title { color: #1c1e21; margin-left: 10px; font-size: 14px; font-weight: 600; } -.footer-links { display: flex; justify-content: center; gap: 20px; margin-bottom: 12px; flex-wrap: wrap; } -.footer-links a { color: #65676b; text-decoration: none; font-size: 13px; } -.footer-links a:hover { text-decoration: underline; } +.footer-links { display: flex; justify-content: center; gap: 20px; margin-bottom: 16px; flex-wrap: wrap; } +.footer-links a { + color: #65676b; + text-decoration: none; + font-size: 13px; + transition: color 0.2s ease; + position: relative; +} +/* Underline slide-in effect */ +.footer-links a::after { + content: ''; + position: absolute; + bottom: -2px; + left: 0; + width: 0; + height: 1px; + background: #1877f2; + transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1); +} +.footer-links a:hover { color: #1877f2; } +.footer-links a:hover::after { width: 100%; } .footer-bottom p { color: #65676b; margin: 4px 0; font-size: 12px; } -.footer-bottom a { color: #1877f2; } +.footer-bottom a { color: #1877f2; text-decoration: none; } +.footer-bottom a:hover { text-decoration: underline; } .footer-copy { font-size: 12px; } -/* Hide/Show */ +/* ======================================== + HIDE/SHOW (i18n) + ======================================== */ .hide-en { display: none; } body[data-lang="en"] .hide-en { display: inline; } body[data-lang="en"] .hide-de { display: none; } .hidden { display: none !important; } -/* Responsive */ +/* ======================================== + RESPONSIVE + ======================================== */ @media (max-width: 768px) { .nav-menu { display: none; } .nav-menu.open { @@ -376,7 +834,8 @@ body[data-lang="en"] .hide-de { display: none; } padding: 12px; gap: 8px; border-top: 1px solid #e4e6eb; - box-shadow: 0 4px 12px rgba(0,0,0,0.1); + box-shadow: 0 8px 20px rgba(0,0,0,0.1); + animation: slideDown 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards; } .nav-toggle { display: flex; @@ -386,8 +845,17 @@ body[data-lang="en"] .hide-de { display: none; } border: none; cursor: pointer; padding: 4px; + transition: transform 0.2s ease; + } + .nav-toggle:hover { transform: rotate(5deg); } + .nav-toggle span { + display: block; + width: 20px; + height: 2px; + background: #65676b; + transition: all 0.2s ease; + border-radius: 1px; } - .nav-toggle span { display: block; width: 20px; height: 2px; background: #65676b; } .hero-title { font-size: 28px; } .hero-subtitle { font-size: 16px; } .hero-stats { gap: 30px; flex-wrap: wrap; } @@ -398,4 +866,4 @@ body[data-lang="en"] .hide-de { display: none; } } @media (min-width: 769px) { .nav-toggle { display: none; } -} \ No newline at end of file +} diff --git a/js/main.js b/js/main.js index d054f76..e4d923f 100644 --- a/js/main.js +++ b/js/main.js @@ -98,8 +98,81 @@ document.addEventListener('DOMContentLoaded', () => { openLoginModal(); }); } + + // ======================================== + // SCROLL-TRIGGERED ANIMATIONS + // ======================================== + // Fade-in sections on scroll (Intersection Observer) + initScrollReveal(); + + // Ripple effect on buttons + initRippleEffects(); }); +// ======================================== +// SCROLL REVEAL (Intersection Observer) +// ======================================== +function initScrollReveal() { + // Respect reduced motion preference + const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches; + if (prefersReducedMotion) return; + + const observerOptions = { + root: null, + rootMargin: '0px 0px -60px 0px', + threshold: 0.1 + }; + + const observer = new IntersectionObserver((entries) => { + entries.forEach(entry => { + if (entry.isIntersecting) { + entry.target.classList.add('visible'); + observer.unobserve(entry.target); // Only animate once + } + }); + }, observerOptions); + + // Observe all sections for reveal animation + document.querySelectorAll('.section, .telegram-banner, #newsletter-section').forEach(section => { + // Add initial invisible state for smooth reveal + section.style.opacity = '0'; + section.style.transform = 'translateY(20px)'; + section.style.transition = 'opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1)'; + observer.observe(section); + }); +} + +// ======================================== +// RIPPLE EFFECT ON BUTTONS +// ======================================== +function initRippleEffects() { + document.querySelectorAll('.btn, .lang-btn').forEach(btn => { + btn.addEventListener('click', function(e) { + const rect = this.getBoundingClientRect(); + const x = e.clientX - rect.left; + const y = e.clientY - rect.top; + + const ripple = document.createElement('span'); + ripple.style.cssText = ` + position: absolute; + border-radius: 50%; + background: rgba(255, 255, 255, 0.4); + width: 0; + height: 0; + left: ${x}px; + top: ${y}px; + transform: translate(-50%, -50%); + pointer-events: none; + animation: rippleExpand 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards; + `; + this.style.position = this.style.position || 'relative'; + this.style.overflow = 'hidden'; + this.appendChild(ripple); + setTimeout(() => ripple.remove(), 600); + }); + }); +} + // ======================================== // LANGUAGE // ========================================