.fastpix-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #dcdcde;
    padding: 18px 28px 18px 28px;
    background: #f6f7f7;
    font-family: var(--wp-admin--font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif);
}
.fastpix-modal-title { font-size: 1.3em; font-weight: 600; color: #1d2327; }
.fastpix-modal-close { background: none; border: none; font-size: 2em; cursor: pointer; color: #757575; }
.fastpix-modal-close:hover { color: #000; }
.fastpix-modal-body { padding: 28px 28px 24px 28px; font-family: inherit; }
.fastpix-modal-columns { display: flex; gap: 40px; }
.fastpix-modal-left { flex: 2; }
.fastpix-modal-right { flex: 1; padding-left: 18px; }
.fastpix-modal-right input[type='text'],
.fastpix-modal-right textarea { width: 100%; margin-bottom: 18px; font-family: inherit; font-size: 14px; border: 1px solid #dcdcde; border-radius: 2px; padding: 8px 10px; background: #fff; color: #1d2327; }
.fastpix-modal-right label { font-weight: 500; color: #1d2327; margin-bottom: 6px; display: block; }
.fastpix-video-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background: #000;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    margin-bottom: 18px;
}
.fastpix-video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 4px;
}
#TB_window {
    max-width: 800px !important;
    width: 90% !important;
    height: auto !important;
    margin: 0 auto;
    font-family: inherit;
}
#TB_ajaxContent {
    width: 100% !important;
    height: auto !important;
    padding: 0 !important;
    overflow: hidden !important;
    font-family: inherit;
}
#TB_title {
    background: #f6f7f7;
    border-bottom: 1px solid #dcdcde;
    padding: 10px 15px;
    height: auto !important;
    font-family: inherit;
}
#TB_closeWindowButton {
    top: 10px !important;
    right: 10px !important;
    background: none !important;
    border: none !important;
    color: #757575 !important;
    font-size: 20px !important;
    line-height: 1 !important;
    padding: 0 !important;
    cursor: pointer !important;
}
#TB_closeWindowButton:hover {
    color: #000 !important;
}
.fastpix-video-meta { font-size: 13px; color: #50575e; margin-bottom: 22px; }
.fastpix-video-meta div { margin-bottom: 10px; }
.fastpix-modal-right form > div { margin-bottom: 18px; }
@media screen and (max-width: 782px) {
    #TB_window {
        width: 95% !important;
    }
    .fastpix-modal-columns { flex-direction: column; gap: 0; }
    .fastpix-modal-left, .fastpix-modal-right { width: 100%; padding-left: 0; }
    .fastpix-video-container { padding-top: 75%; }
}
#fastpix-video-shortcode {
    width: 100%;
    min-width: 0;
    overflow-x: auto;
    white-space: nowrap;
    font-family: monospace;
    font-size: 13px;
    background: #f9f9f9;
    cursor: pointer;
}
.fastpix-modal-save:hover { background: #135e96; }
.fastpix-modal-save-bottom-container {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    padding: 0 28px 24px 28px;
    box-sizing: border-box;
}
.fastpix-modal-save-bottom {
    margin-top: 0;
}
.fastpix-modal-section-label {
    font-weight: 600;
    font-size: 16px;
    color: #1d2327;
    margin-bottom: 10px;
    letter-spacing: 0.01em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
.fastpix-renditions-card {
    background: #f8f9fa;
    border: 1px solid #e5e7eb;
    border-radius: 5px;
    padding: 16px 18px;
    margin-bottom: 28px;
}
.fastpix-renditions-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 600;
    color: #1d2327;
    margin-bottom: 12px;
    font-family: inherit;
}
.fastpix-mp4-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.fastpix-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
    font-family: inherit;
}
.fastpix-download-btn.primary {
    color: #2271b1;
}
.fastpix-download-btn.primary:hover {
    color: #135e96;
    text-decoration: underline;
}
.fastpix-download-btn.secondary {
    color: #50575e;
}
.fastpix-download-btn.secondary:hover {
    color: #2271b1;
    text-decoration: underline;
}
.fastpix-download-btn .icon {
    font-size: 14px;
    line-height: 1;
}
.fastpix-no-renditions {
    margin: 8px 0 0 0;
    padding: 10px 14px;
    border-left: 4px solid #d1d5db;
    background: #f4f6fa;
    color: #666;
    font-style: italic;
    border-radius: 4px;
    font-family: inherit;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Subtitle Modal Styles */
.fastpix-subtitle-modal {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    z-index: 10;
    border-radius: 8px;
    overflow: hidden;
}

.fastpix-subtitle-modal-container {
    height: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

.fastpix-subtitle-modal-header {
    flex-shrink: 0;
    padding: 24px 32px 16px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #dcdcde;
}

.fastpix-subtitle-modal-title {
    margin: 0;
    font-size: 1.3em;
    color: #1d2327;
}

.fastpix-subtitle-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #757575;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.fastpix-subtitle-modal-close:hover {
    background-color: #f0f0f1;
}

.fastpix-subtitle-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 32px;
}

.fastpix-subtitle-form-group {
    margin-bottom: 20px;
}

.fastpix-subtitle-form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #1d2327;
}

.fastpix-subtitle-form-select,
.fastpix-subtitle-form-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    color: #1d2327;
    transition: border-color 0.2s;
}

.fastpix-subtitle-form-select:focus,
.fastpix-subtitle-form-input:focus {
    border-color: #2271b1;
    outline: none;
    box-shadow: 0 0 0 1px #2271b1;
}

.fastpix-subtitle-form-select option:disabled {
    color: #757575;
}

.fastpix-subtitle-url-wrapper {
    display: none;
    margin-bottom: 20px;
}

.fastpix-subtitle-url-help {
    margin: 8px 0 0 0;
    font-size: 12px;
    color: #666;
}

.fastpix-subtitle-modal-footer {
    flex-shrink: 0;
    padding: 16px 32px 24px 32px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    border-top: 1px solid #dcdcde;
    background: #f9f9f9;
}

.fastpix-subtitle-cancel-btn {
    padding: 8px 16px;
    border: 1px solid #dcdcde;
    background: #fff;
    color: #1d2327;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.fastpix-subtitle-cancel-btn:hover {
    background: #f0f0f1;
}

.fastpix-subtitle-add-btn {
    padding: 8px 16px;
    background: #2271b1;
    color: #fff;
    border: 1px solid #2271b1;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.fastpix-subtitle-add-btn:hover {
    background: #135e96;
    border-color: #135e96;
}

.fastpix-subtitle-add-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Success Message Styles */
.fastpix-subtitle-success-msg {
    margin: 16px 0;
    padding: 12px 16px;
    background: #d1e7dd;
    border: 1px solid #badbcc;
    border-radius: 6px;
    color: #0f5132;
    font-size: 14px;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.fastpix-subtitle-success-msg .dashicons {
    color: #198754;
    margin-right: 8px;
    font-size: 16px;
}

/* Processing Row Styles */
.fastpix-subtitle-processing-row {
    background: #f8f9fa;
}

.fastpix-subtitle-processing-row td {
    padding: 8px 6px;
}

.fastpix-subtitle-processing-id {
    font-size: 12px;
    color: #666;
}

.fastpix-subtitle-processing-status {
    color: #2271b1;
    font-size: 12px;
}

.fastpix-subtitle-processing-icon {
    text-align: right;
}

.fastpix-subtitle-processing-icon .dashicons {
    animation: spin 1s linear infinite;
    color: #2271b1;
    font-size: 16px;
}
