/* Utility Classes and Shared Patterns */

/* Gradients */
.gradient-blue {
    background: linear-gradient(135deg, #0066cc 0%, #0052a3 100%);
}

.gradient-blue-text {
    background: linear-gradient(135deg, #0066cc 0%, #0052a3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Shadows and Effects */
.shadow-subtle {
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.shadow-soft {
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.08);
}

.shadow-elevated {
    box-shadow: 0 4px 8px rgba(0, 102, 204, 0.15);
}

/* Spacing Utilities */
.gap-sm { gap: 0.5rem; }
.gap-md { gap: 1rem; }
.gap-lg { gap: 1.5rem; }

/* Transitions */
.transition-fast {
    transition: all 0.2s ease;
}

.transition-smooth {
    transition: all 0.3s ease;
}

.transition-hover {
    transition: background-color 0.2s ease, transform 0.2s ease;
}

/* Display Utilities */
.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.flex-column {
    display: flex;
    flex-direction: column;
}

/* Text Utilities */
.text-truncate-lines-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.text-truncate-lines-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.font-system {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

/* States */
.is-loading {
    opacity: 0.6;
    pointer-events: none;
}

.is-disabled {
    opacity: 0.5;
    pointer-events: none;
}

.is-active {
    background-color: var(--accent-blue);
    color: white !important;
}

/* Animation Utilities */
.animate-slide-down {
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Focus States */
.focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 2px;
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible,
button:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 2px;
}

/* Responsive Utilities */
@media (max-width: 767px) {
    .hide-mobile {
        display: none !important;
    }
    
    .text-center-mobile {
        text-align: center;
    }
}

@media (min-width: 768px) {
    .hide-desktop {
        display: none !important;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Form Utilities */
.form-group-compact {
    margin-bottom: 1rem;
}

.input-icon-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
}

.input-icon-wrapper .icon {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--text-light);
}
