/* Custom CSS styles for CRSS Development website */

/* Cache control headers for development */
.no-cache {
    Cache-Control: no-cache, no-store, must-revalidate;
    Pragma: no-cache;
    Expires: 0;
}

  .hyphenate{
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    overflow-wrap: break-word; /* fallback */
  }

/* Cookies Popup Styles */
.cookies-popup {
    transition: opacity 0.3s ease-in-out;
}

.cookies-flicker {
    animation: flicker 2s ease-in-out infinite;
}

@keyframes flicker {
    0%, 100% { 
        opacity: 1;
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    }
    25% { 
        opacity: 0.8;
        box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    }
    50% { 
        opacity: 1;
        box-shadow: 0 30px 60px rgba(0, 0, 0, 0.25);
        transform: translateY(-2px);
    }
    75% { 
        opacity: 0.9;
        box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    }
}

/* Cookies popup hover effects */
.cookies-popup:hover {
    animation: none !important;
}

.cookies-popup .bg-gray-800 {
    transition: all 0.3s ease;
}

.cookies-popup:hover .bg-gray-800 {
    transform: translateY(-5px);
    box-shadow: 0 35px 70px rgba(0, 0, 0, 0.3);
}

/* ANPC Compliance Buttons - Romanian Legal Requirement */
.anpc-button {
    background: #ffffff;
    border: 3px solid #2c5aa0;
    border-radius: 25px;
    padding: 12px 20px;
    text-decoration: none;
    transition: all 0.3s ease;
    max-width: 280px;
}

.anpc-button:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(44, 90, 160, 0.15);
}

.anpc-button-dual .anpc-logo-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-right: 15px;
    border-right: 2px solid #2c5aa0;
    margin-right: 15px;
    min-width: 70px;
}

.anpc-logo {
    text-align: center;
    line-height: 1;
}

.anpc-logo-text {
    display: block;
    font-size: 16px;
    font-weight: bold;
    color: #2c5aa0;
    letter-spacing: 1px;
}

.anpc-logo-subtext {
    display: block;
    font-size: 10px;
    color: #2c5aa0;
    margin-top: 2px;
    font-style: italic;
}

.anpc-content-section {
    flex: 1;
    text-align: center;
}

.anpc-single-content {
    text-align: center;
    width: 100%;
}

.anpc-title {
    font-size: 13px;
    font-weight: bold;
    color: #2c5aa0;
    line-height: 1.1;
    letter-spacing: 0.5px;
}

.anpc-button-inner {
    background: #2c5aa0;
    color: white;
    font-size: 11px;
    font-weight: bold;
    padding: 6px 20px;
    border-radius: 15px;
    margin-top: 8px;
    display: inline-block;
    letter-spacing: 0.5px;
}

.anpc-button:hover .anpc-button-inner {
    background: #1e3d73;
}

/* Desktop layout for ANPC buttons - side by side */
@media (min-width: 768px) {
    .anpc-button {
        width: 280px !important;
        min-width: 280px !important;
        max-width: 280px !important;
        height: 120px !important;
        min-height: 120px !important;
        max-height: 120px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        box-sizing: border-box !important;
    }
    
    .anpc-button:first-child {
        margin-right: 15px;
    }
    
    .space-y-3 {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0;
    }
    
    .space-y-3 > * + * {
        margin-top: 0;
    }
    
    .anpc-button-dual .flex {
        width: 100%;
        height: 100%;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }
    
    .anpc-button-dual .anpc-logo-section {
        flex-shrink: 0;
        width: auto;
        padding-right: 12px;
        margin-right: 12px;
        border-right: 2px solid #2c5aa0;
    }
    
    .anpc-button-dual .anpc-content-section {
        flex: 1;
        text-align: center;
    }
    
    .anpc-single-content {
        width: 100% !important;
        height: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
    }
}

/* Mobile layout for ANPC buttons - stacked */
@media (max-width: 767px) {
    .anpc-button {
        max-width: 100%;
        padding: 10px 15px;
    }
    
    .anpc-logo-text {
        font-size: 14px;
    }
    
    .anpc-title {
        font-size: 12px;
    }
    
    .anpc-button-inner {
        font-size: 10px;
        padding: 5px 15px;
    }
    
    .space-y-3 {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
}

/* Additional custom styles that complement Tailwind CSS */

/* Smooth scrolling for all browsers */
html {
    scroll-behavior: smooth;
}

/* Custom button hover effects */
.btn-primary {
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

/* Form focus states */
.form-input:focus {
    outline: none;
    border-color: #6b7280;
    box-shadow: 0 0 0 3px rgba(107, 114, 128, 0.1);
}

/* Loading spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #6b7280;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Custom gradient backgrounds */
.gradient-gray {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

.gradient-hero {
    background: linear-gradient(135deg, #9ca3af 0%, #6b7280 50%, #4b5563 100%);
}

/* Card hover effects */
.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Text animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Responsive typography */
@media (max-width: 640px) {
    .text-responsive-xl {
        font-size: 2rem;
        line-height: 2.5rem;
    }
}

@media (min-width: 641px) {
    .text-responsive-xl {
        font-size: 3rem;
        line-height: 1;
    }
}

/* Custom success popup styles */
.success-popup {
    background: rgba(34, 197, 94, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(34, 197, 94, 0.3);
}

/* Error message styles */
.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #dc2626;
}

/* File upload styles */
.file-upload {
    transition: all 0.3s ease;
}

.file-upload:hover {
    background-color: #f9fafb;
    border-color: #6b7280;
}

/* Progress bar */
.progress-bar {
    height: 4px;
    background-color: #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: #6b7280;
    transition: width 0.3s ease;
}

/* Mobile menu animations */
.mobile-menu-enter {
    opacity: 0;
    transform: translateY(-10px);
}

.mobile-menu-enter-active {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
}

/* Hero section specific styles */
.hero-title {
    background: linear-gradient(135deg, #1f2937 0%, #374151 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Contact form styles */
.contact-form {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Service cards */
.service-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.8) 100%);
    transition: all 0.3s ease;
}

.service-card:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.95) 100%);
    transform: translateY(-5px);
}

/* Process timeline */
.timeline-line {
    background: linear-gradient(to right, #d1d5db, #9ca3af, #6b7280, #4b5563);
}

/* Portfolio grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

@media (min-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #6b7280;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #4b5563;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus indicators for keyboard navigation */
a:focus, button:focus, input:focus, textarea:focus, select:focus {
    outline: 2px solid #6b7280;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .bg-gray-50 {
        background-color: white;
    }
    
    .text-gray-600 {
        color: black;
    }
    
    .border-gray-300 {
        border-color: black;
    }
}

/* Dark mode support (if needed in future) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here */
}

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

.clearfix::after {
    content: "";
    display: table;
    clear: both;
}

/* Performance optimizations */
.will-change-transform {
    will-change: transform;
}

.gpu-accelerated {
    transform: translateZ(0);
}

/* Form validation styles */
.invalid {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.valid {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1) !important;
}