/* Film Upload Form — styled to match CF7 Styler / Divi contact form */

.gj-film-upload-wrap {
    max-width: 100%;
    margin: 0 auto;
    padding: 30px;
    background: transparent;
    border-radius: 6px;
}

.gj-film-upload-closed {
    max-width: 600px;
    margin: 2em auto;
    padding: 30px;
    text-align: center;
    background: #eeeeee;
    border-radius: 6px;
}

.gj-film-challenge-name {
    margin-bottom: 1.5em;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.6);
    border-left: 4px solid #36b8f5;
    border-radius: 4px;
    font-size: 1em;
    color: #666666;
}

/* Grid layout matching CF7 Styler dcs_row / dcs_col */
.gj-row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -8px;
}

.gj-col-half {
    flex: 0 0 50%;
    max-width: 50%;
    padding: 0 8px;
    margin-bottom: 16px;
    box-sizing: border-box;
}

.gj-col-full {
    flex: 0 0 100%;
    max-width: 100%;
    padding: 0 8px;
    margin-bottom: 16px;
    box-sizing: border-box;
}

/* Fields — match CF7 Styler settings */
.gj-film-upload-form input[type="text"],
.gj-film-upload-form input[type="email"],
.gj-film-upload-form input[type="tel"],
.gj-film-upload-form textarea {
    width: 100%;
    padding: 12px 16px;
    background: #e8e8e8;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
    line-height: 1.7em;
    color: #666666;
    box-sizing: border-box;
    transition: box-shadow 0.2s;
}

.gj-film-upload-form textarea {
    resize: vertical;
    min-height: 120px;
}

.gj-film-upload-form input::placeholder,
.gj-film-upload-form textarea::placeholder {
    color: #999999;
    line-height: 1.7em;
}

.gj-film-upload-form input:focus,
.gj-film-upload-form textarea:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(248, 76, 70, 0.3);
}

/* File drop zone */
.gj-file-drop {
    padding: 40px 20px;
    background: #ffffff;
    border: 2px dashed #cccccc;
    border-radius: 4px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.gj-file-drop:hover,
.gj-file-drop.gj-drag-over {
    border-color: #36b8f5;
    background: #fff8f8;
}

.gj-file-drop p {
    margin: 0 0 10px;
    color: #999999;
    font-size: 14px;
}

.gj-file-hint {
    font-size: 12px;
    color: #999999 !important;
    margin-top: 10px !important;
}

.gj-file-browse {
    padding: 10px 24px;
    background: #36b8f5;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    -webkit-appearance: none;
    min-height: 44px;
    transition: background 0.2s;
}

.gj-file-browse:hover {
    background: #2aa0d9;
}

.gj-file-input {
    position: absolute;
    left: -9999px;
    opacity: 0;
}

/* Selected file */
.gj-file-selected {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: #ffffff;
    border: 1px solid #36b8f5;
    border-radius: 4px;
}

.gj-file-name {
    flex: 1;
    font-weight: 600;
    color: #666666;
    word-break: break-all;
}

.gj-file-size {
    color: #999999;
    white-space: nowrap;
}

.gj-file-remove {
    background: none;
    border: none;
    font-size: 1.4em;
    color: #36b8f5;
    cursor: pointer;
    padding: 4px 8px;
    line-height: 1;
    min-width: 44px;
    min-height: 44px;
}

/* Progress bar */
.gj-progress-wrap {
    margin: 0 8px 16px;
}

.gj-progress-bar {
    height: 12px;
    background: #dddddd;
    border-radius: 6px;
    overflow: hidden;
}

.gj-progress-fill {
    height: 100%;
    width: 0;
    background: #36b8f5;
    border-radius: 6px;
    transition: width 0.3s ease;
}

.gj-progress-text {
    margin-top: 0.5em;
    font-size: 13px;
    color: #999999;
    text-align: center;
}

/* Messages */
.gj-message {
    padding: 12px 16px;
    border-radius: 4px;
    margin: 0 8px 16px;
    font-size: 14px;
}

.gj-message-error {
    background: #fff0f0;
    border: 1px solid #36b8f5;
    color: #8b1a1c;
}

.gj-message-info {
    background: #f0f7fc;
    border: 1px solid #2271b1;
    color: #135e96;
}

/* Submit button — right-aligned, matching CF7 Styler */
.gj-submit-row {
    justify-content: flex-end;
}

.gj-submit {
    display: inline-block;
    padding: 12px 32px;
    background: #36b8f5;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    -webkit-appearance: none;
    min-height: 44px;
    transition: background 0.2s;
}

.gj-submit:hover {
    background: #2aa0d9;
}

.gj-submit:disabled {
    background: #cccccc;
    cursor: not-allowed;
}

/* Success */
.gj-success {
    text-align: center;
    padding: 40px 20px;
    background: #f0faf0;
    border: 1px solid #5cb85c;
    border-radius: 4px;
}

.gj-success h3 {
    color: #2d6a2e;
    margin-bottom: 0.5em;
}

/* Responsive */
@media (max-width: 768px) {
    .gj-col-half {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .gj-film-upload-wrap {
        padding: 20px 15px;
    }

    .gj-submit {
        width: 100%;
    }
}
