/* ══════════════════════════════════════════════
   IzhFurr — style.css
   Apple-style минимализм + пушистая атмосфера 🐾
   ══════════════════════════════════════════════ */

/* ───── Переменные ───── */
:root {
    --bg:          #f2f2f7;
    --card-bg:     #ffffff;
    --text:        #1d1d1f;
    --muted:       #86868b;
    --accent:      #ff8c00;
    --accent-2:    #ff3b55;
    --green:       #34c759;
    --tg:          #0088cc;
    --vk:          #4c75a3;
    --island-bg:   rgba(12, 12, 12, 0.5);

    --r-card:      28px;
    --r-btn:       50px;
    --r-pill:      20px;

    --shadow:      0 8px 32px rgba(0, 0, 0, 0.06);
    --shadow-lg:   0 20px 56px rgba(0, 0, 0, 0.12);
    --ease:        cubic-bezier(0.22, 1, 0.36, 1);
    --t:           0.35s var(--ease);
}

/* ───── Сброс и база ───── */
html { scroll-behavior: smooth; }

*, *::before, *::after {
    margin: 0; padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display",
                 "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
    min-height: 100dvh;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 15% 40%, rgba(255, 140, 0, 0.05) 0%, transparent 100%),
        radial-gradient(ellipse 50% 40% at 85% 15%, rgba(255, 59,  85, 0.05) 0%, transparent 100%);
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 960px;
    width: 100%;
    padding: 116px 20px 72px;
    position: relative;
    z-index: 1;
}

/* ═══════════════════════════════════════
   DYNAMIC ISLAND
═══════════════════════════════════════ */
.dynamic-island {
    position: fixed;
    top: 16px;
    background: var(--island-bg);
    backdrop-filter: blur(24px) saturate(200%);
    -webkit-backdrop-filter: blur(12px) saturate(200%);
    padding: 12px 28px;
    border-radius: 50px;
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.07);
    box-shadow: 0 8px 40px rgba(0,0,0,0.28), inset 0 1px 0 rgba(255,255,255,0.06);
    transition: var(--t);
}

.dynamic-island:hover {
    transform: scale(1.04);
    box-shadow: 0 14px 50px rgba(0,0,0,0.36), inset 0 1px 0 rgba(255,255,255,0.09);
}

.dynamic-island nav {
    display: flex;
    align-items: center;
    gap: 22px;
}

.dynamic-island a {
    color: rgba(255, 255, 255, 0.88);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.01em;
    transition: color 0.2s;
    white-space: nowrap;
}

.dynamic-island a:hover { color: var(--accent); }

/* ═══════════════════════════════════════
   HERO
═══════════════════════════════════════ */
.hero {
    text-align: center;
    margin-bottom: 60px;
    padding-top: 10px;
}

.paw-container {
    position: relative;
    display: inline-block;
    margin-bottom: 28px;
}

.paw-img {
    width: 160px;
    height: 160px;
    border-radius: 44px;
    object-fit: cover;
    position: relative;
    z-index: 2;
    animation: float 7s ease-in-out infinite;
}

.paw-glow {
    position: absolute;
    inset: -16px;
    background: radial-gradient(circle, rgba(255, 140, 0, 0.3) 0%, transparent 70%);
    border-radius: 60px;
    filter: blur(24px);
    z-index: 1;
    animation: glow-pulse 7s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(-1deg); }
    50%       { transform: translateY(-14px) rotate(1deg); }
}

@keyframes glow-pulse {
    0%, 100% { opacity: 0.5; transform: scale(0.95); }
    50%       { opacity: 1;   transform: scale(1.1); }
}

.gradient-text {
    font-size: clamp(3rem, 10vw, 5rem);
    font-weight: 800;
    background: linear-gradient(135deg, #ff8c00 0%, #ff3b55 50%, #d500f9 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -3px;
    line-height: 1.05;
    margin-bottom: 16px;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--muted);
    line-height: 1.65;
    margin-bottom: 36px;
    font-weight: 400;
}

.social-links {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.social-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--r-btn);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    color: #fff;
    transition: var(--t);
}

.social-pill.telegram {
    background: var(--tg);
    box-shadow: 0 8px 24px rgba(0, 136, 204, 0.28);
}
.social-pill.telegram:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 14px 36px rgba(0, 136, 204, 0.42);
}

.social-pill.vkontakte {
    background: var(--vk);
    box-shadow: 0 8px 24px rgba(76, 117, 163, 0.28);
}
.social-pill.vkontakte:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 14px 36px rgba(76, 117, 163, 0.42);
}

/* ═══════════════════════════════════════
   BENTO GRID
═══════════════════════════════════════ */
.bento-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 72px;
}

.span-2 { grid-column: span 2; }

.bento-card {
    background: var(--card-bg);
    border-radius: var(--r-card);
    padding: 32px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(0, 0, 0, 0.04);
    transition: transform var(--t), box-shadow var(--t);
}

.bento-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.bento-card h2 {
    font-size: 1.45rem;
    font-weight: 700;
}

.badge {
    background: #f2f2f7;
    color: var(--muted);
    padding: 5px 14px;
    border-radius: var(--r-pill);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.bento-card > p {
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 22px;
}

.server-features {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 22px;
}

.feature-pill {
    background: #f2f2f7;
    color: var(--text);
    padding: 6px 14px;
    border-radius: var(--r-pill);
    font-size: 0.83rem;
    font-weight: 600;
}

.ip-block {
    display: flex;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 24px;
    align-items: center;
    gap: 12px;
    background: #f8f8fc;
    border: 2px solid #ebebf0;
    padding: 14px 22px;
    border-radius: 18px;
    cursor: pointer;
    user-select: none;
    transition: var(--t);
}

.ip-block:hover {
    border-color: var(--accent);
    background: #fff8f0;
    transform: scale(1.02);
}

.ip-block:active { transform: scale(0.97); }

.ip-label {
    color: var(--muted);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

#ip-text {
    font-family: 'SF Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 1.1rem;
    font-weight: 700;
}

.copy-icon { font-size: 1.1rem; }

.buttons {
    display: flex;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    gap: 12px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 13px 26px;
    border-radius: var(--r-btn);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
    transition: var(--t);
}

.btn-sm { padding: 10px 20px; font-size: 0.88rem; }

.btn-primary {
    background: var(--text);
    color: #fff;
}
.btn-primary:hover {
    background: var(--accent);
    box-shadow: 0 8px 28px rgba(255, 140, 0, 0.35);
    transform: translateY(-2px);
}

.btn-secondary {
    background: #f2f2f7;
    color: var(--text);
}
.btn-secondary:hover {
    background: #e5e5ea;
    transform: translateY(-2px);
}

/* ═══════════════════════════════════════
   WHITELIST BUTTON
═══════════════════════════════════════ */
.whitelist-action {
    display: flex;
    justify-content: center;
    margin-bottom: 24px;
    width: 100%;
}

.btn-whitelist {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
    padding: 16px 32px;
    border-radius: 26px;
    text-decoration: none;
    color: #fff;
    overflow: hidden;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
    box-shadow: 0 12px 32px rgba(255, 60, 85, 0.35);
}

.btn-whitelist:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 18px 48px rgba(255, 60, 85, 0.5);
}

.whitelist-icon {
    font-size: 2.2rem;
    z-index: 2;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
}

.whitelist-text {
    display: flex;
    flex-direction: column;
    z-index: 2;
    text-align: left;
}

.whitelist-title {
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.whitelist-subtitle {
    font-size: 0.9rem;
    font-weight: 600;
    opacity: 0.92;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.whitelist-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.25) 0%, transparent 50%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: pulseGlow 3s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    0% { transform: translate(-50%, -50%) scale(0.95); opacity: 0.6; }
    100% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
}

.stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 16px;
}

.stat-item {
    background: #f8f8fc;
    border-radius: 18px;
    padding: 18px 12px;
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.1;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--muted);
    margin-top: 5px;
}

.schedule {
    display: flex;
    flex-direction: column;
    gap: 9px;
    margin: 16px 0;
}

.schedule-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: #f8f8fc;
    border-radius: 14px;
    font-size: 0.92rem;
    font-weight: 500;
}

.online-row { border-left: 3px solid var(--green); }

.schedule-time {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.88rem;
    font-weight: 700;
    background: none;
    color: var(--text);
}

.server-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--r-pill);
    font-size: 0.85rem;
    font-weight: 700;
    margin-top: 4px;
    min-height: 36px;
}

.server-status-badge.online  { background: rgba(52,199,89,0.12);  color: #1a7a32; }
.server-status-badge.offline { background: rgba(255,59,48,0.10);  color: #c0201a; }

/* ═══════════════════════════════════════
   СЕКЦИЯ ЗАГОЛОВКА
═══════════════════════════════════════ */
.section-title {
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
}

.section-subtitle {
    color: var(--muted);
    font-size: 1rem;
    margin-bottom: 32px;
}

/* ═══════════════════════════════════════
   СХОДКИ
═══════════════════════════════════════ */
.meetups-section { margin-bottom: 72px; }

.meetups-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.meetup-card {
    background: var(--card-bg);
    border-radius: var(--r-card);
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid rgba(0, 0, 0, 0.04);
    transition: transform var(--t), box-shadow var(--t);
}

.meetup-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.meetup-poster {
    position: relative;
    height: 280 px;
    overflow: hidden;
}

.meetup-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s var(--ease);
}

.meetup-card:hover .meetup-poster img { transform: scale(1.06); }

.meetup-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(10px);
    color: #fff;
    padding: 5px 14px;
    border-radius: var(--r-pill);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    z-index: 2;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.8);
}

.meetup-badge.latest { background: rgba(255, 140, 0, 0.3); }

.meetup-info { padding: 24px; }

.meetup-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.3;
}

.meetup-date,
.meetup-place {
    font-size: 0.88rem;
    color: var(--muted);
    font-weight: 500;
    margin-bottom: 3px;
}

.meetup-desc {
    font-size: 0.93rem;
    color: var(--muted);
    line-height: 1.6;
    margin: 12px 0 18px;
}

.meetup-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ═══════════════════════════════════════
   ГАЛЕРЕЯ (С ПРОГРЕССИВНОЙ ЗАГРУЗКОЙ)
═══════════════════════════════════════ */
.gallery-section { margin-bottom: 40px; }

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 180px;
    gap: 12px;
}

.gallery-item {
    border-radius: 20px;
    overflow: hidden;
    transition: transform var(--t), box-shadow var(--t);
    cursor: pointer;
    background: #e0e0ea; /* Фоновый цвет на долю секунды пока картинка не появится */
}

.gallery-item.wide { grid-column: span 2; }

.gallery-item:hover {
    transform: scale(1.03);
    box-shadow: var(--shadow-lg);
    z-index: 2;
    position: relative;
}

.gallery-placeholder {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden; /* Важно, чтобы scale и blur не вылазили */
}

/* Стили для всех изображений галереи */
.gallery-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
    /* Плавный переход при снятии блюра (когда JS заменит класс и src) */
    transition: filter 0.6s var(--ease), transform 0.6s var(--ease);
    will-change: filter, transform;
}

/* Класс для первоначальной размытой картинки 128px */
.gallery-placeholder img.blurred {
    filter: blur(15px);
    transform: scale(1.1); /* Скрываем "прозрачные" края размытия за пределами блока */
}

/* ═══════════════════════════════════════
   FOOTER
═══════════════════════════════════════ */
footer {
    width: 100%;
    border-top: 1px solid rgba(0, 0, 0, 0.07);
    padding: 48px 20px;
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 960px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    text-align: center;
}

.footer-logo {
    font-size: 1.25rem;
    font-weight: 800;
}

.footer-links {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.93rem;
    font-weight: 500;
    transition: color 0.2s;
}

.footer-links a:hover { color: var(--accent); }

.footer-copy {
    color: var(--muted);
    font-size: 0.82rem;
}

/* ═══════════════════════════════════════
   TOAST
═══════════════════════════════════════ */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: rgba(18, 18, 18, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    padding: 14px 22px;
    border-radius: 26px;
    box-shadow: 0 12px 48px rgba(0,0,0,0.32);
    z-index: 2000;
    display: flex;
    align-items: center;
    gap: 14px;
    max-width: calc(100vw - 40px);
    transition: transform 0.55s cubic-bezier(0.68, -0.55, 0.265, 1.55),
                opacity 0.4s ease;
}

.toast.hidden {
    transform: translateY(100px);
    opacity: 0;
    pointer-events: none;
}

.toast-icon { font-size: 1.6rem; flex-shrink: 0; }

.toast-content {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.toast-title    { font-weight: 700; font-size: 0.93rem; }
.toast-subtitle { font-size: 0.8rem; color: rgba(255,255,255,0.6); }

.copy-toast {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(0);
    background: var(--green);
    color: #fff;
    padding: 10px 26px;
    border-radius: var(--r-btn);
    font-size: 0.9rem;
    font-weight: 700;
    z-index: 2000;
    box-shadow: 0 8px 28px rgba(52, 199, 89, 0.42);
    transition: var(--t), opacity 0.25s;
    white-space: nowrap;
}

.copy-toast.hidden {
    transform: translateX(-50%) translateY(-24px);
    opacity: 0;
    pointer-events: none;
}

/* ═══════════════════════════════════════
   SCROLL REVEAL
═══════════════════════════════════════ */
.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.75s var(--ease), transform 0.75s var(--ease);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ═══════════════════════════════════════
   АДАПТИВНОСТЬ
═══════════════════════════════════════ */
@media (max-width: 768px) {
    .container { padding: 96px 16px 60px; }

    .dynamic-island {
        width: calc(100% - 32px);
        justify-content: center;
    }
    .dynamic-island nav  { gap: 14px; justify-content: center; }
    .dynamic-island a    { font-size: 13px; }

    .bento-grid          { grid-template-columns: 1fr; }
    .span-2              { grid-column: span 1; }

    .meetups-grid        { grid-template-columns: 1fr; }

    .gallery-grid {
        grid-template-columns: 1fr 1fr;
        grid-auto-rows: 140px;
    }
    .gallery-item.wide   { grid-column: span 2; }

    .card-header         { flex-direction: column; align-items: flex-start; }
    .bento-card          { padding: 24px; }
}

@media (max-width: 480px) {
    .gallery-grid        { grid-template-columns: 1fr; }
    .gallery-item.wide   { grid-column: span 1; }

    .social-pill         { padding: 10px 18px; font-size: 0.88rem; }
    .buttons, .meetup-buttons { flex-direction: column; }
    .btn                 { justify-content: center; }

    .footer-links        { gap: 16px; }
}

/* ═══════════════════════════════════════
   LIGHTBOX / ФОТО НА ВЕСЬ ЭКРАН
═══════════════════════════════════════ */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.35s var(--ease);
}

.lightbox.hidden {
    opacity: 0;
    pointer-events: none;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 16px;
    object-fit: contain;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    transform: scale(1);
    transition: transform 0.35s var(--ease);
}

.lightbox.hidden .lightbox-img {
    transform: scale(0.9);
}

.lightbox-close,
.lightbox-btn {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--t);
    z-index: 3001;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.lightbox-close:hover,
.lightbox-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

.lightbox-close {
    top: 24px;
    right: 32px;
    font-size: 2rem;
    width: 48px;
    height: 48px;
    line-height: 1;
    padding-bottom: 4px;
}

.lightbox-btn {
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    width: 54px;
    height: 54px;
}

.lightbox-btn:hover {
    transform: translateY(-50%) scale(1.1);
}

.lightbox-btn.prev { left: 32px; }
.lightbox-btn.next { right: 32px; }

@media (max-width: 768px) {
    .lightbox-img {
        max-width: 100vw;
        border-radius: 0;
    }
    .lightbox-btn {
        width: 44px;
        height: 44px;
    }
    .lightbox-btn.prev { left: 16px; }
    .lightbox-btn.next { right: 16px; }
    .lightbox-close {
        top: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
        font-size: 1.6rem;
    }
}