/* Info Center button styling */
.info-center-container {
    margin-right: 15px;
}

.btn-info-center {
    position: relative;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: #fff;
    padding: 10px 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.btn-info-center:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

.btn-info-center:active {
    transform: translateY(0);
}

.info-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: #ff4757;
    color: #fff;
    border-radius: 50%;
    width: 12px;
    height: 12px;
    font-size: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: info-badge-pulse 2s infinite;
}

@keyframes info-badge-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* Modal layout */
#info-center-modal .modal-content.info-center-content {
    max-width: 980px;
    width: min(96%, 980px);
    max-height: 84vh;
    padding: 24px 28px 24px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, rgba(248, 250, 255, 0.92) 0%, rgba(255, 255, 255, 0.98) 100%);
    box-shadow: 0 32px 68px rgba(15, 23, 42, 0.18);
}

.info-center-content h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    color: #1f2937;
    font-size: 1.45rem;
}

.info-tabs {
    display: inline-flex;
    gap: 8px;
    padding: 6px;
    background: rgba(79, 70, 229, 0.05);
    border-radius: 12px;
    margin-bottom: 16px;
    align-self: flex-start;
}

.info-tab {
    border: none;
    background: transparent;
    color: #475569;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 6px 18px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.24s ease;
}

.info-tab:hover:not(.is-active) {
    color: #312e81;
    background: rgba(79, 70, 229, 0.08);
}

.info-tab.is-active {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: #fff;
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.28);
}

.info-panels {
    flex: 1 1 auto;
    width: 100%;
}

.info-panel {
    display: none;
    height: 100%;
}

.info-panel.is-active {
    display: block;
}

.info-feed,
.info-guides {
    max-height: 65vh;
    overflow-y: auto;
    padding: 18px 20px 24px;
    background: linear-gradient(180deg, rgba(245, 246, 255, 0.7) 0%, rgba(255, 255, 255, 0.95) 100%);
    border-radius: 18px;
}

.info-feed__placeholder,
.info-feed__noscript {
    font-size: 13px;
    color: #6b7280;
    padding: 12px 0;
    text-align: center;
}

/* Timeline layout */
.timeline-entry {
    display: grid;
    grid-template-columns: 140px 32px 1fr;
    column-gap: 20px;
    align-items: flex-start;
    margin-bottom: 26px;
}

.timeline-entry:last-child {
    margin-bottom: 0;
}

.timeline-time {
    text-align: right;
    font-size: 13px;
    color: #64748b;
    line-height: 1.4;
    padding-top: 4px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.timeline-date {
    font-weight: 600;
    color: #1f2937;
}

.timeline-relative {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    padding: 2px 10px;
    font-size: 11px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.18);
    color: rgba(30, 41, 59, 0.72);
}

.timeline-node {
    position: relative;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid rgba(79, 70, 229, 0.55);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
    margin-top: 6px;
}

.timeline-entry[data-pinned="true"] .timeline-dot {
    border-color: #f59e0b;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.18);
}

.timeline-line {
    flex: 1;
    width: 2px;
    margin-top: 6px;
    background: linear-gradient(180deg, rgba(148, 163, 184, 0.28) 0%, rgba(148, 163, 184, 0.08) 100%);
}

.timeline-entry:last-child .timeline-line {
    display: none;
}

.timeline-card {
    background: #fff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 18px;
    padding: 18px 20px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
    color: #1f2937;
    transition: box-shadow 0.24s ease, transform 0.24s ease;
}

.timeline-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 26px 48px rgba(15, 23, 42, 0.16);
}

.timeline-card__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.timeline-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: #111827;
}

.timeline-tag {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 999px;
}

.timeline-tag--feature { background: rgba(59, 130, 246, 0.14); color: #1d4ed8; }
.timeline-tag--experience { background: rgba(16, 185, 129, 0.14); color: #047857; }
.timeline-tag--bugfix { background: rgba(248, 113, 113, 0.14); color: #b91c1c; }
.timeline-tag--ops { background: rgba(217, 119, 6, 0.14); color: #b45309; }
.timeline-tag--maintenance { background: rgba(168, 85, 247, 0.14); color: #6d28d9; }

.timeline-pin {
    margin-left: auto;
    font-size: 12px;
    color: #7c3aed;
    background: rgba(124, 58, 237, 0.14);
    padding: 2px 10px;
    border-radius: 999px;
}

.timeline-summary {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #1f2937;
}

.timeline-summary[data-collapsed="true"] {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.timeline-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 14px;
    font-size: 13px;
    font-weight: 600;
    color: #4338ca;
    text-decoration: none;
}

.timeline-link:hover {
    text-decoration: underline;
}

.timeline-toggle {
    margin-top: 12px;
    border: none;
    background: transparent;
    color: #4f46e5;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
}

.timeline-toggle:hover {
    text-decoration: underline;
}

/* Guides */
.guide-entry {
    background: #fff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 16px;
    padding: 18px 20px;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.1);
    margin-bottom: 18px;
    transition: box-shadow 0.24s ease, transform 0.24s ease;
}

.guide-entry:last-child {
    margin-bottom: 0;
}

.guide-entry:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 44px rgba(15, 23, 42, 0.14);
}

.guide-title {
    margin: 0 0 8px;
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
}

.guide-summary {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #1f2937;
}

.guide-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #4338ca;
    text-decoration: none;
}

.guide-link:hover {
    text-decoration: underline;
}

.guide-actions {
    margin-top: 14px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.guide-action {
    border: none;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    padding: 6px 16px;
    border-radius: 999px;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(67, 56, 202, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.guide-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(67, 56, 202, 0.28);
}

.guide-action:active {
    transform: translateY(0);
}

.info-footer {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
}

/* Responsive */
@media (max-width: 992px) {
    #info-center-modal .modal-content.info-center-content {
        padding: 20px 20px 22px;
        max-height: 88vh;
    }
    .timeline-entry {
        grid-template-columns: 120px 28px 1fr;
    }
}

@media (max-width: 768px) {
    .info-tabs {
        width: 100%;
        justify-content: space-between;
    }
    .info-tab {
        flex: 1 1 0;
        text-align: center;
    }
    .info-feed,
    .info-guides {
        max-height: 66vh;
        padding: 16px;
    }
    .timeline-entry {
        position: relative;
        display: block;
        padding-left: 28px;
        margin-left: 4px;
        margin-bottom: 24px;
    }
    .timeline-entry::before {
        content: '';
        position: absolute;
        left: 4px;
        top: 6px;
        width: 10px;
        height: 10px;
        border-radius: 50%;
        background: #fff;
        border: 3px solid rgba(79, 70, 229, 0.55);
        box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
    }
    .timeline-entry::after {
        content: '';
        position: absolute;
        left: 8px;
        top: 20px;
        bottom: -24px;
        width: 2px;
        background: linear-gradient(180deg, rgba(148, 163, 184, 0.24) 0%, rgba(148, 163, 184, 0.08) 100%);
    }
    .timeline-entry:last-child::after {
        display: none;
    }
    .timeline-entry[data-pinned="true"]::before {
        border-color: #f59e0b;
        box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.18);
    }
    .timeline-node {
        display: none;
    }
    .timeline-time {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        font-size: 12px;
        color: #475569;
        margin-bottom: 8px;
    }
    .timeline-date {
        font-weight: 600;
        color: #1f2937;
    }
    .timeline-relative {
        justify-content: flex-start;
    }
    .timeline-card {
        margin: 0;
        padding: 16px 18px;
        border-radius: 16px;
    }
    .timeline-card__header {
        gap: 8px;
        margin-bottom: 8px;
    }
    .timeline-title {
        font-size: 1rem;
    }
    .timeline-summary {
        font-size: 13px;
    }
    .guide-entry {
        padding: 16px 18px;
    }
}

@media (max-width: 520px) {
    #info-center-modal .modal-content.info-center-content {
        width: 98%;
        padding: 18px 16px 20px;
    }
    .timeline-entry {
        padding-left: 26px;
    }
    .timeline-entry::before {
        left: 2px;
    }
    .timeline-entry::after {
        left: 6px;
    }
    .timeline-time {
        font-size: 11px;
    }
    .timeline-tag {
        font-size: 11px;
    }
    .timeline-pin {
        font-size: 11px;
    }
    .guide-actions {
        flex-direction: column;
        align-items: flex-start;
    }
    .guide-action,
    .guide-link {
        width: 100%;
    }
    .info-footer {
        margin-top: 16px;
    }
}
