/* Container */
.crf-form-modern {
    background-color: #f3f5f7; /* Light grey background */
    padding: 22px;
    border-radius: 8px;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    font-family: 'Arial', sans-serif;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

@media (min-width: 1024px) {
    .crf-form-modern {
        max-width: 440px;
        margin: 0;
        margin-left: auto;
    }
}

@media (min-width: 1280px) {
    .crf-form-modern {
        max-width: 490px;
    }
}

@media (min-width: 1536px) {
    .crf-form-modern {
        max-width: 550px;
    }
}

/* Header */
.crf-header {
    text-align: center;
    margin-bottom: 30px;
}
.crf-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #000;
    margin-bottom: 10px;
}
.crf-header p {
    color: #6B7280;
    font-size: 14px;
    margin: 0;
    letter-spacing: 0.09em;
}

/* Section Titles (Icon + Text) */
.crf-section-title {
    display: flex;
    align-items: center;
    color: #6B7280; /* Dark grey-green */
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    margin-bottom: 15px;
    margin-top: 20px;
}
.crf-section-title img {
    width: 28px;
    height: 28px;
    margin-right: 10px;
}

/* Input Fields Wrapper */
.crf-input-wrapper {
    position: relative;
    margin-bottom: 15px;
}

/* The Icons inside inputs */
.crf-field-icon {
    position: absolute;
    left: 15px;
    top: 49%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    opacity: 0.5;
    z-index: 2;
}
.crf-field-icon.top-aligned {
    top: 16px;
    transform: none;
}

/* Inputs & Textarea */
.crf-input {
    width: 100%;
    padding: 15px 15px 15px 45px; /* Left padding makes room for icon */
    border: none;
    border-radius: 6px;
    background-color: #ffffff;
    font-size: 14px;
    color: #333;
    box-sizing: border-box; /* Ensures padding doesn't break width */
}
.crf-input:focus {
    outline: 2px solid #366657;
}

/* -------------------------------------
   FILE UPLOAD UI (Horizontal Layout)
   ------------------------------------- */
.crf-upload-container {
    margin-bottom: 20px;
}

.crf-upload-label {
    cursor: pointer;
    display: flex;
    align-items: center;         /* Vertically center icon and text */
    justify-content: center;     /* Horizontally center everything */
    gap: 10px;                   /* Space between icon and text */
    padding: 16px 20px;          /* Slimmer vertical padding */
    border: 2px dashed #cbd5e1;  /* Dashed border */
    border-radius: 6px;
    background-color: transparent; 
    transition: all 0.2s ease;
}

.crf-upload-label:hover {
    background-color: #f1f5f9;
    border-color: #94a3b8;
}

.crf-upload-icon {
    width: 24px;                 /* Smaller icon to match text size */
    height: auto;
    opacity: 0.5;
}

.crf-upload-text {
    color: #6a82a0;              /* Soft blue-gray color to match your screenshot */
    font-size: 15px;
    font-weight: 500;
}

.crf-file-input-hidden {
    display: none;               /* Hides the default ugly browser button */
}

/* Make the actual file input invisible but clickable over the whole area */
.crf-file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

/* Submit Button */
.crf-submit-btn {
    width: 100%;
    background-color: #366657; /* The specific dark green */
    color: white;
    border: none;
    padding: 15px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
     letter-spacing: 0.05em;
    gap: 10px;
    transition: background 0.3s;
}
.crf-submit-btn:hover {
    background-color: #2b5246;
}

/* Privacy Footer */
.crf-privacy-footer {
    text-align: center;
    margin-top: 15px;
    font-size: 12px;
    color: #666;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
}
.crf-footer-icon {
    width: 18px;
    height: 18px;
    opacity: 0.6;
    position: static; 
    transform: none;
}

/* -------------------------------------
   PREMIUM FLOATING TOAST NOTIFICATION
   ------------------------------------- */
.crf-toast-premium {
    position: fixed;
    bottom: 40px; /* Moved to the bottom of the screen */
    left: 50%;
    transform: translateX(-50%);
    z-index: 2147483647; /* Maximum possible z-index to guarantee it's on top */
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 0 5px 15px rgba(0, 0, 0, 0.05);
    min-width: 340px;
    max-width: 90%;
    overflow: hidden;
    font-family: 'Inter', 'Segoe UI', 'Arial', sans-serif;
    animation: crfToastPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    transition: opacity 0.3s ease, transform 0.3s ease;
}
.crf-toast-inner {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    gap: 14px;
}

/* Beautiful solid circle around the checkmark */
.crf-toast-icon-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #ffffff;
}

.crf-toast-icon-circle svg {
    width: 16px;
    height: 16px;
}

.crf-bg-green { background-color: #10b981; } /* Premium success green */
.crf-bg-red { background-color: #ef4444; } /* Premium error red */

/* Dark, bold, readable text */
.crf-toast-text {
    flex-grow: 1;
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
    letter-spacing: -0.01em;
}

/* Styled close button with hover effect */
.crf-toast-close-btn {
    background: #f8fafc;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #94a3b8;
    transition: all 0.2s ease;
    padding: 0;
}

.crf-toast-close-btn svg {
    width: 14px;
    height: 14px;
}

.crf-toast-close-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
}

/* Integrated Progress Bar at the very bottom */
.crf-toast-progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    animation: crfProgressShrink 5s linear forwards;
}

/* Animations */
@keyframes crfToastPop {
    0% { transform: translate(-50%, 30px) scale(0.9); opacity: 0; }
    100% { transform: translate(-50%, 0) scale(1); opacity: 1; }
}

@keyframes crfProgressShrink {
    0% { width: 100%; }
    100% { width: 0%; }
}

/* Keep the inline JS error styling */
.crf-message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    width: 100%;
    box-sizing: border-box;
}
.crf-message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #f87171;
}