/**
 * Platform Selector Styles
 */

/* ── Container ── */
.platform-selector {
    margin-bottom: 1rem;
}

.platform-pills {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 0;
}

.platform-pills::-webkit-scrollbar {
    display: none;
}

/* ── Pill ── */
.platform-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    min-height: 44px;
    border: 1.5px solid #E0E0E0;
    border-radius: 20px;
    background: #F5F5F5;
    color: #7A7A7A;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.platform-pill:hover {
    border-color: #ccc;
    background: #eee;
}

.platform-pill.active {
    background: #E44335;
    color: #fff;
    border-color: #E44335;
}

.platform-pill.active .platform-pill-icon svg {
    stroke: #fff;
    fill: #fff;
}

.platform-pill-icon {
    display: flex;
    align-items: center;
    line-height: 0;
}

.platform-pill-icon svg {
    width: 18px;
    height: 18px;
}

/* ── Hint line ── */
.platform-hint {
    margin: 8px 0 0;
    font-size: 0.85rem;
    color: #7A7A7A;
    line-height: 1.4;
    transition: opacity 0.2s ease;
}

/* ── Rule Popup ── */
.platform-rule-popup {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0);
    transition: background 0.2s ease, backdrop-filter 0.2s ease;
    padding: 20px;
}

.platform-rule-popup.visible {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.platform-rule-box {
    background: #fff;
    border-radius: 16px;
    padding: 32px 24px 24px;
    max-width: 340px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    transform: scale(0.9) translateY(10px);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.platform-rule-popup.visible .platform-rule-box {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.platform-rule-icon {
    margin-bottom: 12px;
}

.platform-rule-icon svg {
    width: 40px;
    height: 40px;
}

.platform-rule-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #222;
    margin: 0 0 8px;
}

.platform-rule-text {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
    margin: 0;
}

/* ── RTL ── */
html[dir="rtl"] .platform-pills {
    direction: rtl;
}

html[dir="rtl"] .platform-selector {
    direction: rtl;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .platform-pill {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
}
