/* design-system/components/timer.css */

/* Невелика анімація паріння для картинки над таймером */
@keyframes timer-float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

.timer-character {
    display: flex;
    justify-content: center;
    margin-bottom: var(--space-md);
    animation: timer-float 3s ease-in-out infinite;
}

.timer-character__image {
    width: 60vw;
    max-width: 320px;
    height: auto;
    display: block;
    margin: 0 auto;
    /* повністю прибираємо будь-які візуальні ефекти контейнера */
    box-shadow: none;
    border: none;
    background: transparent;
    transition: none;
}

.timer-character__image--idle {
    transform: none;
    box-shadow: none;
}

.timer-character__image--running {
    transform: none;
    box-shadow: none;
}

.timer-character__image--ready {
    transform: none;
    box-shadow: none;
}

.timer-character__image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

/* Деактивація "довгого натискання" (touch-callout) для таймер-картинки */
#timer-character-image,
#timer-character-image img,
#timer-character-emoji {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    tap-highlight-color: transparent;
}

/* Компактний блок збору + календар (адаптація під новий проєкт) */
.compact-farming-ui {
    display: flex;
    gap: 4px;
    width: 100%;
    max-width: 420px;
    padding: 0;
    margin: 20px auto 0;
    position: relative;
    z-index: 2;
}

.compact-farming {
    position: relative;
    flex: 1;
    height: 72px;
    background: rgba(26, 31, 43, 0.8);
    border-radius: 20px 4px 4px 20px;
    cursor: pointer;
    overflow: hidden;
    transition: background 0.3s ease;
}

.compact-farming.is-collect {
    background: rgba(26, 31, 43, 0.9);
}

.compact-progress {
    position: absolute;
    inset: 0;
    width: 0%;
    background: rgba(255, 255, 255, 0.03);
    transition: width 1s linear;
    z-index: 1;
    pointer-events: none;
}

.compact-farming-content {
    position: relative;
    height: 100%;
    z-index: 2;
}

.compact-center-text {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3;
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    gap: 8px;
    flex-wrap: wrap;
}

.compact-center-text.is-visible {
    display: flex;
}

.compact-center-text-label {
    display: inline-block;
}

.compact-duration-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(52, 112, 185, 0.3);
    border: 1px solid rgba(52, 112, 185, 0.5);
    border-radius: 8px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 600;
    color: #60a5fa;
    white-space: nowrap;
    min-width: 40px;
}

.compact-farm-info {
    position: absolute;
    inset: 0;
    padding: 10px 14px;
    display: none;
    grid-template-rows: auto 1fr;
    z-index: 3;
}

.compact-farm-info.is-active {
    display: grid;
}

.compact-farm-title {
    font-size: 11px;
    color: #9ca3af;
    letter-spacing: 0.6px;
    position: relative;
    z-index: 4;
}

.compact-farm-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    position: relative;
    z-index: 4;
}

.compact-timer {
    font-size: 13px;
    color: #9ca3af;
    position: relative;
    z-index: 4;
}

.compact-amount {
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    position: relative;
    z-index: 4;
}

.compact-amount-value {
    display: inline-block;
}

.compact-reward {
    width: 72px;
    height: 72px;
    background: #3470b9;
    border-radius: 4px 20px 20px 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    cursor: pointer;
    transition: background 0.3s ease;
    text-decoration: none;
    position: relative;
}

.compact-reward:hover {
    background: #2a5a96;
}

.compact-reward--pressed {
    transform: scale(0.95);
    background: #2a5a96;
}

.timer-character-emoji {
    display: none;
}

.spinner--page {
    margin: 50px auto;
}

.icon-calendar {
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.compact-reward-badge {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: #fb7185;
    box-shadow:
        0 0 0 3px rgba(15, 23, 42, 0.35),
        0 0 18px rgba(251, 113, 133, 0.75);
    animation: compact-badge-pulse 1.4s ease-in-out infinite;
}

@keyframes compact-badge-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.25); opacity: 0.85; }
}


