/* Version Update Modal - Monochrome style matching Freeform modals */

.version-update-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000010; /* Above other modals */
    padding: 20px;
    opacity: 1;
    pointer-events: auto;
    transition: opacity 0.2s ease;
}

.version-update-modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.version-update-modal {
    position: relative;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.2);
    max-width: 420px;
    width: 100%;
    overflow: hidden;
    animation: slideIn 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: center center;
    pointer-events: auto;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: scale(0.95) translateY(8px);
    }
    to { 
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.version-update-modal-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px 24px 20px;
}

.version-update-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.version-update-icon svg {
    width: 24px;
    height: 24px;
    stroke: #222;
    fill: none;
    stroke-width: 2;
    opacity: 0.7;
}

/* Animated Formas Logo in Black */
.version-update-icon.version-update-formas-logo {
    width: 56px;
    height: 56px;
    background: transparent;
    border: none;
}

.version-update-icon.version-update-formas-logo .formas-loader {
    width: 48px;
    height: 48px;
}

/* Warm orange/red version of the triangular logo - matches app theme */
.version-logo-black polygon {
    fill: #d97706 !important;
    stroke: #d97706 !important;
}

.version-update-header-info {
    flex: 1;
    min-width: 0;
}

.version-update-title {
    color: #222;
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.version-update-subtitle {
    color: rgba(0, 0, 0, 0.5);
    font-size: 13px;
    margin: 2px 0 0 0;
    font-weight: 400;
    line-height: 1.2;
}

.version-update-modal-content {
    padding: 0 24px 24px;
}



.version-info-box {
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.version-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.version-info-label {
    color: rgba(0, 0, 0, 0.5);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.version-info-value {
    color: #222;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.version-badge {
    background: rgba(0, 0, 0, 0.06);
    color: #222;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

/* Version type badges - warm accent colors matching app's orange/gold theme */
.version-badge-stable { background: rgba(34, 197, 94, 0.1); color: #16a34a; border-color: rgba(34, 197, 94, 0.2); }
.version-badge-beta { background: rgba(245, 158, 11, 0.1); color: #d97706; border-color: rgba(245, 158, 11, 0.2); }
.version-badge-alpha { background: rgba(239, 68, 68, 0.1); color: #dc2626; border-color: rgba(239, 68, 68, 0.2); }
.version-badge-preview { background: rgba(180, 83, 9, 0.1); color: #b45309; border-color: rgba(180, 83, 9, 0.2); }

/* What's New Section */
.version-whats-new {
    background: rgba(0, 0, 0, 0.02);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 20px;
}

.version-whats-new-title {
    color: #222;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

.version-whats-new-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.version-whats-new-list li {
    color: rgba(0, 0, 0, 0.7);
    font-size: 13px;
    line-height: 1.5;
    padding: 4px 0;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.version-whats-new-list li::before {
    content: "✓";
    color: #22c55e;
    font-weight: 700;
    flex-shrink: 0;
}

.version-whats-new-list li a {
    color: #d97706;
    text-decoration: underline;
    font-weight: 700;
    transition: opacity 0.2s ease;
    display: inline;
}

.version-whats-new-list li a:hover {
    opacity: 0.8;
}

.version-whats-new-list li strong {
    font-weight: 700;
    display: inline;
}

.version-update-modal-footer {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.version-update-btn {
    background: #222;
    border: none;
    color: white;
    font-size: 13px;
    font-weight: 700;
    padding: 12px 20px;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    letter-spacing: 0.3px;
    position: relative;
    z-index: 10;
    pointer-events: auto !important;
}

.version-update-btn:hover {
    background: #111;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.version-update-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.version-update-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.version-update-btn.updating {
    padding-left: 40px;
}

.version-update-btn .update-spinner {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: version-update-spin 0.8s linear infinite;
    display: none;
}

.version-update-btn.updating .update-spinner {
    display: block;
}

@keyframes version-update-spin {
    0% { transform: translateY(-50%) rotate(0deg); }
    100% { transform: translateY(-50%) rotate(360deg); }
}

.version-update-btn-secondary {
    background: rgba(0, 0, 0, 0.05);
    border: none;
    color: rgba(0, 0, 0, 0.6);
    font-size: 13px;
    font-weight: 700;
    padding: 12px 20px;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.3px;
    position: relative;
    z-index: 10;
    pointer-events: auto !important;
}

.version-update-btn-secondary:hover {
    background: rgba(0, 0, 0, 0.08);
    color: #222;
    transform: translateY(-1px);
}

.version-update-btn-secondary:active {
    transform: translateY(0);
}

.version-update-countdown {
    color: rgba(0, 0, 0, 0.4);
    font-size: 12px;
    margin-top: 12px;
    text-align: center;
    font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
    .version-update-modal {
        margin: 20px;
        max-width: 100%;
    }
    
    .version-update-modal-header {
        padding: 20px 20px 16px;
    }
    
    .version-update-modal-content {
        padding: 16px 20px 20px;
    }
    
    .version-update-icon {
        width: 40px;
        height: 40px;
    }
    
    .version-update-icon svg {
        width: 20px;
        height: 20px;
    }
    
    .version-update-title {
        font-size: 16px;
    }
    
    .version-update-modal-footer {
        flex-direction: column;
    }
    
    .version-update-btn,
    .version-update-btn-secondary {
        width: 100%;
        text-align: center;
        justify-content: center;
    }
}
