/* Version 3 - Components Styles */

/* Custom Modal Dialog */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.modal-overlay.show {
    opacity: 1;
}

.modal-dialog {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem 2rem;
    max-width: 480px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
}

.modal-overlay.show .modal-dialog {
    transform: scale(1) translateY(0);
}

.modal-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
}

.modal-dialog.success .modal-icon {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.modal-dialog.error .modal-icon {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.modal-dialog.info .modal-icon {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    color: white;
}

.modal-content {
    text-align: center;
    margin-bottom: 2rem;
}

.modal-content p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1rem;
    margin: 0;
}

.modal-close {
    display: block;
    width: 100%;
    padding: 0.875rem 2rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.modal-close:active {
    transform: translateY(0);
}

@media (max-width: 480px) {
    .modal-dialog {
        padding: 2rem 1.5rem 1.5rem;
    }
    
    .modal-icon {
        width: 56px;
        height: 56px;
        font-size: 1.75rem;
    }
}

/* Contact Section */
.contact-section {
    background-color: var(--bg-light);
}

.contact-box {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 3rem;
    box-shadow: var(--shadow-md);
}

.contact-intro {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
}

.contact-info-panel {
    background: var(--bg-gray);
    border-radius: var(--radius-md);
    padding: 2rem;
}

.contact-info-panel h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.info-item {
    margin-bottom: 2rem;
}

.info-item:last-child {
    margin-bottom: 0;
}

.info-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.info-value {
    color: var(--text-secondary);
    line-height: 1.7;
}

.info-value a {
    color: var(--primary-color);
    text-decoration: none;
}

.info-value a:hover {
    text-decoration: underline;
}

/* Contact Form */
.contact-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-field {
    display: flex;
    flex-direction: column;
}

.form-field.full-width {
    grid-column: span 2;
}

.form-field label {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    color: var(--text-primary);
    transition: var(--transition);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 18%, transparent);
}

.form-field textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form button[type="submit"] {
    grid-column: span 2;
    margin-top: 1rem;
}

/* Story Boards Section */
.storyboards-section {
    background-color: var(--bg-white);
}

.storyboards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.storyboard-item {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
}

.storyboard-item:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.storyboard-thumb {
    height: 200px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.storyboard-placeholder {
    font-size: 4rem;
    opacity: 0.6;
}

.storyboard-info {
    padding: 1.5rem;
}

.storyboard-info h4 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.storyboard-info p {
    color: var(--text-secondary);
    line-height: 1.6;
}

.storyboard-item.wide {
    grid-column: span 2;
}

/* Responsive Storyboard Grid */
@media (max-width: 768px) {
    .storyboards-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .storyboard-item.wide {
        grid-column: span 1;
    }
    
    .storyboard-thumb {
        height: 180px;
    }
    
    .storyboard-info {
        padding: 1rem;
    }
    
    .storyboard-info h4 {
        font-size: 1rem;
    }
}

/* Footer */
.footer {
    background-color: var(--secondary-color);
    color: white;
    padding: 3rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-brand .logo {
    margin-bottom: 1rem;
}

.footer-brand .logo-text strong,
.footer-brand .logo-text span {
    color: white;
}

.footer-tagline {
    color: rgba(255, 255, 255, 0.7);
    max-width: 400px;
    line-height: 1.6;
}

.footer-legal {
    text-align: right;
}

.footer-legal p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
}

/* Az Út Carousel */
.azut-section {
    padding: 4rem 0;
}

/* Process / Infographic Section */
.process-section {
    padding: 4.5rem 0;
    background: linear-gradient(180deg, var(--bg-white) 0%, var(--bg-light) 100%);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

/* Onboarding / Bevezetés Section */
.onboarding-section {
    padding: 5rem 0;
    background-color: var(--bg-white);
    border-top: 1px solid var(--border-color);
}

    /* Larger screens: two-column features for the featured module */
    @media (min-width: 769px) {
        .module-card.featured .module-features {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 0.25rem 0.75rem;
        }

        .module-card.featured .module-features li {
            padding-left: 1.75rem;
        }

        .module-card.featured .module-features li::before {
            left: 0;
            top: 0.25rem;
        }
    }

.onboarding-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.onboarding-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.onboarding-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.onboarding-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.onboarding-head h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
}

.onboarding-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: color-mix(in srgb, var(--primary-color) 12%, transparent);
    color: var(--primary-color);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

.onboarding-desc {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.25rem;
}

.onboarding-steps {
    margin: 0;
    padding-left: 1.25rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.onboarding-steps li {
    padding: 0.25rem 0;
}

.onboarding-actions {
    margin-top: 1.5rem;
}

.onboarding-actions .btn {
    width: 100%;
}

.onboarding-note {
    margin-top: 2rem;
    background: var(--bg-gray);
    border-left: 4px solid var(--primary-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    display: flex;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 768px) {
    .onboarding-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* References Section */
.references-section {
    padding: 4.5rem 0;
    background-color: color-mix(in srgb, white 12%, transparent);
    border-top: 1px solid var(--border-color);
}

.references-panel {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.reference-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1rem;
    max-width: 980px;
    width: 100%;
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.reference-card img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

@media (max-width: 768px) {
    .references-section { padding: 3rem 0; }
    .reference-card { padding: 0.75rem; }
}

.process-card {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.process-visual {
    width: 100%;
    max-width: 1100px;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
}

.process-visual img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

@media (max-width: 767px) {
    .process-section { padding: 2.5rem 0; }
    .process-visual { max-width: 100%; }
}

.azut-carousel {
    position: relative;
    margin-top: 2rem;
}

.carousel-viewport {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.45s cubic-bezier(.2,.9,.2,1);
    will-change: transform;
}

.azut-carousel .slide {
    flex: 0 0 auto;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg-gray);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.3s, filter 0.3s, opacity 0.3s;
    position: relative;
    height: 420px;
    max-height: 60vh;
    opacity: 1;
    z-index: 1;
}

.azut-carousel .slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #f8f9fa;
}

.azut-carousel .slide.prev,
.azut-carousel .slide.next {
    opacity: 0.45;
    filter: blur(1.5px) grayscale(30%);
    z-index: 0;
    box-shadow: none;
}

.azut-carousel .slide.current {
    opacity: 1;
    filter: none;
    z-index: 2;
    box-shadow: 0 6px 32px 0 rgba(0,0,0,0.10);
}

@media (min-width: 1100px) {
    .azut-carousel .slide { width: 72%; height: 480px; }
}

@media (min-width: 768px) and (max-width: 1099px) {
    .azut-carousel .slide { width: 92%; height: 420px; }
}

@media (max-width: 767px) {
    .azut-carousel .slide { width: 100%; height: 260px; }
    .carousel-btn { display: none; }
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity 180ms ease, transform 180ms ease;
}

.carousel-btn.prev { left: 12px; }
.carousel-btn.next { right: 12px; }

.azut-carousel:hover .carousel-btn {
    opacity: 1;
}

.carousel-btn:active { transform: translateY(-50%) scale(0.98); }

/* Responsive sizes (show partial slides if space) */
@media (min-width: 1100px) {
    .azut-carousel .slide { width: 72%; }
}

@media (min-width: 768px) and (max-width: 1099px) {
    .azut-carousel .slide { width: 92%; }
}

@media (max-width: 767px) {
    .azut-carousel .slide { width: 100%; }
    .carousel-btn { display: none; }
}

/* small visual tweak for section intro */
.azut-section .section-lead { max-width: 820px; margin: 0 auto; }
