/**
 * Raven Tools - Frontend Form Styles
 * Styles for form rendering on the frontend
 */

.raven-form-container {
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

/* For forms inside hero sections - prevents overflow */
.hero-form .raven-form-container {
    width: 100%;
    overflow: hidden;
}

.raven-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    max-width: 100%;
    box-sizing: border-box;
}

.raven-form-field {
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    min-width: 0;
    flex-shrink: 1;
}

.raven-form-field.width-full {
    flex: 0 0 100%;
    max-width: 100%;
}

.raven-form-field.width-half {
    flex: 0 0 calc(50% - 7.5px);
    max-width: calc(50% - 7.5px);
}

.raven-form-field.width-third {
    flex: 0 0 calc(33.333% - 10px);
    max-width: calc(33.333% - 10px);
}

@media (max-width: 768px) {
    .raven-form-field.width-half,
    .raven-form-field.width-third {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.raven-form-field label {
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    color: #333;
}

.raven-form-field label.hidden-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

.raven-form-field .required {
    color: #dc3232;
    margin-left: 2px;
}

.raven-form--hide-asterisks .raven-form-field .required {
    display: none;
}

.raven-input,
.raven-textarea,
.raven-select {
    padding: 11px 15px;
    border: 1px solid #d5d5d5;
    border-radius: var(--border-radius, 3px) !important;
    font-size: 13px;
    font-family: var(--main-font, inherit);
    font-weight: 500;
    background-color: #ffffff;
    color: #666;
    transition: border-color 0.3s ease, background-color 0.3s ease;
    box-sizing: border-box;
    min-width: 0;
    flex: 1;
}

.raven-input:focus,
.raven-textarea:focus,
.raven-select:focus {
    outline: none;
    border-color: #999;
    background-color: #fff;
}

.raven-input::placeholder,
.raven-textarea::placeholder {
    color: #999;
}

.raven-textarea {
    resize: vertical;
    min-height: 120px;
}

.raven-radio-group,
.raven-checkbox-group {
    border: none;
    padding: 0;
    margin: 14px 0 6px 0;
}

.raven-radio-group legend,
.raven-checkbox-group legend {
    font-weight: 600;
    margin-bottom: 20px;
    padding: 0;
    color: #333;
}

.raven-radio-label,
.raven-checkbox-label {
    display: block;
    margin-bottom: 8px;
    font-weight: normal !important;
    color: #666;
}

.raven-radio,
.raven-checkbox {
    margin-right: 6px;
}

.raven-form-button {
    flex: 0 0 100%;
    margin-top: 5px;
}

.raven-form-submit {
    background: var(--highlight-color, #2d7a4f) !important;
    color: #fff !important;
    padding: 15px 25px;
    width: fit-content;
    border-radius: var(--border-radius, 3px) !important;
    text-decoration: none;
    display: flex;
    justify-content: center;
    font-size: 16px;
    line-height: 16px;
    text-transform: uppercase;
    transition: all .15s ease-in !important;
    text-align: center;
    box-shadow: 0 3px 6px 0 rgb(0 0 0 / 10%) !important;
    cursor: pointer;
    letter-spacing: 1px;
    font-weight: 700 !important;
    border: none !important;
    text-shadow: 2px 2px 1px rgba(0,0,0,0.12);
    font-family: var(--accent-font, inherit);
    position: relative;
    overflow: hidden;
}

/* Shimmer effect - exactly like theme */
.raven-form-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.2) 0%,
        rgba(255, 255, 255, 0.6) 50%,
        rgba(255, 255, 255, 0.2) 100%
    );
    transform: skewX(-20deg);
    pointer-events: none;
}

/* Trigger shimmer on hover */
.raven-form-submit:hover::before {
    animation: shimmer 500ms forwards;
}

@keyframes shimmer {
    0% {
        left: -75%;
    }
    100% {
        left: 125%;
    }
}

.raven-form-submit:hover {
    transform: translateY(-2.4px);
    background: var(--highlight-color, #2d7a4f) !important;
    opacity: 1 !important;
}

.raven-form-submit:disabled {
    background: #999 !important;
    cursor: not-allowed;
    opacity: 0.6;
}

.raven-form-submit.raven-button-full-width {
    width: 100%;
}

.raven-form-submit.raven-button-full-width {
    width: 100%;
}

.raven-form-message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: var(--border-radius, 3px) !important;
    flex: 0 0 100%;
}

.raven-form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.raven-form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}