/**
 * Frontend Styles for Volunteer Signup Manager
 */

/* Hide entry header on single signup sheet pages */
.single-signup_sheet .entry-header {
    display: none !important;
}

/* Container */
.vsm-signup-container {
    max-width: 1140px;
    margin: 2rem auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* Event Header */
.vsm-event-header {
    margin-bottom: 2rem;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
}

.vsm-event-title {
    margin: 0 0 0.5rem 0;
    font-size: 2rem;
    color: #1e293b;
}

.vsm-event-date {
    margin: 0;
    font-size: 1.1rem;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.vsm-event-date .dashicons {
    width: 20px;
    height: 20px;
    font-size: 20px;
}

/* Event Info */
.vsm-event-info {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    line-height: 1.8;
}

.vsm-event-info p {
    margin: 0 0 1rem 0;
}

.vsm-event-info p:last-child {
    margin-bottom: 0;
}

.vsm-event-info ul,
.vsm-event-info ol {
    margin: 0 0 1rem 1.5rem;
    padding: 0;
}

.vsm-event-info ul:last-child,
.vsm-event-info ol:last-child {
    margin-bottom: 0;
}

.vsm-event-info strong {
    font-weight: 600;
    color: #1e293b;
}

.vsm-event-info a {
    color: #2563eb;
    text-decoration: none !important;
}

.vsm-event-info a:hover {
    text-decoration: underline;
}

/* Jobs List */
.vsm-jobs-list h3 {
    margin: 0 0 1.5rem 0;
    font-size: 1.5rem;
    color: #1e293b;
}

/* Job Card */
.vsm-job-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    margin-bottom: 1rem;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.vsm-job-card:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.vsm-job-card.vsm-job-full {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.vsm-job-card.vsm-job-full:hover {
    border-color: #cbd5e1;
    box-shadow: none;
}

.vsm-job-info {
    flex: 1;
}

.vsm-job-title {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    color: #1e293b;
}

.vsm-job-card.vsm-job-full .vsm-job-title {
    color: #64748b;
}

.vsm-job-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    font-size: 0.95rem;
    color: #64748b;
}

.vsm-job-time,
.vsm-job-volunteers {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.vsm-job-details {
    display: flex;
    align-items: flex-start;
    gap: 0.3rem;
    flex-basis: 100%;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.9rem;
    line-height: 1.4;
}

.vsm-job-details .dashicons {
    flex-shrink: 0;
    margin-top: 2px;
}

.vsm-job-meta .dashicons {
    width: 18px;
    height: 18px;
    font-size: 18px;
}

.vsm-job-action {
    margin-left: 1rem;
}

/* Buttons */
.vsm-job-btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    color: white;
    background: #3b82f6;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vsm-job-btn:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.vsm-job-btn:active {
    transform: translateY(0);
}

.vsm-btn-disabled {
    background: #cbd5e1;
    color: #64748b;
    cursor: not-allowed;
}

.vsm-btn-disabled:hover {
    background: #cbd5e1;
    transform: none;
}

/* Signup Form */
.vsm-signup-form {
    margin-bottom: 2rem;
    padding: 2rem;
    background: white;
    border: 2px solid #3b82f6;
    border-radius: 8px;
}

.vsm-signup-form h3 {
    margin: 0 0 1.5rem 0;
    font-size: 1.5rem;
    color: #1e293b;
}

.vsm-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.vsm-form-field {
    margin-bottom: 1rem;
}

.vsm-form-field label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1e293b;
}

.vsm-form-field .required {
    color: #dc2626;
}

.vsm-form-field .optional {
    color: #64748b;
    font-weight: normal;
    font-size: 0.875rem;
}

.vsm-form-field input[type="text"],
.vsm-form-field input[type="email"],
.vsm-form-field textarea {
    width: 100%;
    padding: 0.75rem;
    font-size: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    transition: border-color 0.2s ease;
    font-family: inherit;
}

.vsm-form-field input:focus,
.vsm-form-field textarea:focus {
    outline: none;
    border-color: #3b82f6;
}

.vsm-form-field textarea {
    resize: vertical;
    min-height: 80px;
}

.vsm-unavailable-message-field {
    margin-bottom: 1rem;
}

.vsm-selected-job {
    margin: 1rem 0;
    padding: 1rem;
    background: #f0f9ff;
    border-left: 4px solid #3b82f6;
    border-radius: 4px;
    font-weight: 500;
    color: #1e293b;
}

.vsm-form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.vsm-form-actions .vsm-cancel-btn {
	width: 50%;
}

.vsm-submit-btn {
    flex: 1;
    padding: 0.75rem;
    font-size: 1rem;
    font-weight: 500;
    color: white;
    background: #10b981;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vsm-submit-btn:hover {
    background: #059669;
}

.vsm-submit-btn:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
}

.vsm-cancel-btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    color: #fff;
    background: #64748b;
    border: 2px solid #cbd5e1;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vsm-cancel-btn:hover {
    color: #fff;
    border-color: #94a3b8;
}

.vsm-form-message {
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 6px;
    display: none;
}

.vsm-form-message.vsm-success {
    display: block;
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.vsm-form-message.vsm-error {
    display: block;
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #dc2626;
}

/* Responsive */
@media (max-width: 640px) {
    .vsm-signup-container {
        margin: 1rem;
    }
    
    .vsm-event-header {
        padding: 1.5rem;
    }
    
    .vsm-event-title {
        font-size: 1.5rem;
    }
    
    .vsm-job-card {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .vsm-job-action {
        margin-left: 0;
        margin-top: 1rem;
        width: 100%;
    }
    
    .vsm-job-btn {
        width: 100%;
    }
    
    .vsm-form-row {
        grid-template-columns: 1fr;
    }
    
    .vsm-form-actions {
        flex-direction: column;
    }
}

/* Cancel Box Styles */
.vsm-cancel-box {
    max-width: 500px;
    margin: 2rem auto;
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.vsm-cancel-box-header {
    background: #f8f9fa;
    padding: 2rem;
    text-align: center;
    border-bottom: 2px solid #e2e8f0;
}

.vsm-cancel-box-header h2 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #1e293b;
}

.vsm-cancel-box-header p {
    margin: 0;
    color: #64748b;
}

.vsm-cancel-success .vsm-success-header {
    background: #d1fae5;
    border-bottom-color: #10b981;
}

.vsm-cancel-success .vsm-success-header h2 {
    color: #065f46;
}

.vsm-cancel-success .vsm-success-header p {
    color: #047857;
}

.vsm-success-icon,
.vsm-info-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.vsm-success-icon {
    background: #d1fae5;
    border: 2px solid #10b981;
}

.vsm-success-icon svg {
    width: 30px;
    height: 30px;
    stroke: #10b981;
}

.vsm-info-icon {
    background: #f0f9ff;
    border: 2px solid #3b82f6;
}

.vsm-info-icon svg {
    width: 30px;
    height: 30px;
    stroke: #3b82f6;
}

.vsm-cancel-box-body {
    padding: 2rem;
}

.vsm-cancel-box-body h4 {
    margin: 0 0 1rem 0;
    font-size: 1rem;
    color: #1e293b;
    text-align: center;
}

.vsm-signup-details {
    background: #f8f9fa;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.vsm-signup-details h4 {
    margin: 0 0 1rem 0;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.5px;
    text-align: left;
}

.vsm-detail-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid #e2e8f0;
}

.vsm-detail-row:last-child {
    border-bottom: none;
}

.vsm-detail-label {
    color: #64748b;
    font-size: 0.9rem;
}

.vsm-detail-value {
    font-weight: 500;
    color: #1e293b;
}

.vsm-cancel-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.vsm-cancel-btn {
    display: block;
    width: 100%;
    padding: 0.875rem 1.25rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none !important;
    text-align: center;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.vsm-cancel-btn-red {
    background: #dc2626;
    color: #fff;
}

.vsm-cancel-btn-red:hover {
    background: #b91c1c;
    color: #fff;
}

.vsm-cancel-btn-primary {
    background: #3b82f6;
    color: #fff;
}

.vsm-cancel-btn-primary:hover {
    background: #2563eb;
    color: #fff;
}

.vsm-cancel-btn-outline {
    background: #fff;
    color: #1e293b;
    border: 2px solid #e2e8f0;
}

.vsm-cancel-btn-outline:hover {
    background: #f8f9fa;
    border-color: #cbd5e1;
    color: #1e293b;
}

.vsm-cancel-note {
    margin-top: 1.5rem;
    padding: 1rem;
    background: #f0f9ff;
    border-left: 4px solid #3b82f6;
    border-radius: 4px;
    font-size: 0.9rem;
    color: #1e293b;
}

/* Action Buttons (Select a Role + I'm Not Available) */
.vsm-action-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.vsm-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 500;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none !important;
    min-width: 180px;
}

.vsm-action-btn-primary {
    color: #fff;
    background: #3b82f6;
    border: 2px solid #3b82f6;
}

.vsm-action-btn-primary:hover {
    color: #fff !important;
    background: #2563eb;
    border-color: #2563eb;
}

.vsm-action-btn-secondary {
    color: #dc2626;
    background: #fff;
    border: 2px solid #dc2626;
}

.vsm-action-btn-secondary:hover {
    color: #fff !important;
    background: #dc2626;
}

/* Responsive: stack buttons on small screens */
@media (max-width: 480px) {
    .vsm-action-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .vsm-action-btn {
        min-width: 100%;
    }
}

.vsm-edit-btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    text-decoration: none !important;
    transition: all 0.2s ease;
}


.vsm-edit-container {
	margin: 0 auto;
    max-width: 1140px;
	text-align: right;
}

.vsm-edit-btn:hover {
    color: #fff;
    background: #2e3261;
    border-color: #2e3261;
}
