/* ========================================================================
   SMG TIMELINE PROCESS WIDGET - MODERN CLEAN DESIGN
   Einfache Timeline für Praxisbeispiele und Wochenverlauf
   ======================================================================== */

.smg-timeline-process-widget {
    padding: 6rem 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    position: relative;
    overflow: hidden;
}

.smg-timeline-process-widget::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 25% 25%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(220, 38, 38, 0.03) 0%, transparent 50%);
    z-index: 1;
}

.smg-timeline-process-widget > * {
    position: relative;
    z-index: 2;
}

/* ========================================================================
   HEADER SECTION
   ======================================================================== */

.smg-timeline-header {
    text-align: center;
    margin-bottom: 4rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 2rem;
}

.smg-timeline-title {
    font-family: var(--font-secondary);
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #1e293b 0%, #3b82f6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.smg-timeline-subtitle {
    font-size: 1.3rem;
    color: #64748b;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.6;
}

/* ========================================================================
   TIMELINE CONTAINER - VERTICAL LAYOUT
   ======================================================================== */

.smg-timeline-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
}

/* Central Timeline Line */
.smg-timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, 
        transparent 0%, 
        rgba(59, 130, 246, 0.3) 10%, 
        rgba(220, 38, 38, 0.4) 50%, 
        rgba(59, 130, 246, 0.3) 90%, 
        transparent 100%
    );
    border-radius: 2px;
    transform: translateX(-50%);
    z-index: 1;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

/* Timeline Items */
.smg-timeline-items {
    position: relative;
    z-index: 2;
}

.smg-timeline-item {
    position: relative;
    margin-bottom: 4rem;
    display: flex;
    align-items: center;
    opacity: 0;
    transform: translateY(30px);
    animation: timeline-fade-in 0.8s ease-out forwards;
    animation-delay: calc(var(--item-index, 0) * 0.2s);
}

.smg-timeline-item[data-index="0"] { --item-index: 0; }
.smg-timeline-item[data-index="1"] { --item-index: 1; }
.smg-timeline-item[data-index="2"] { --item-index: 2; }
.smg-timeline-item[data-index="3"] { --item-index: 3; }
.smg-timeline-item[data-index="4"] { --item-index: 4; }

@keyframes timeline-fade-in {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Alternating Layout */
.smg-timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.smg-timeline-item:nth-child(even) .smg-timeline-content {
    text-align: right;
    padding-right: 0;
    padding-left: 3rem;
}

.smg-timeline-item:nth-child(odd) .smg-timeline-content {
    text-align: left;
    padding-left: 0;
    padding-right: 3rem;
}

/* Timeline Point & Icon */
.smg-timeline-point {
    position: relative;
    z-index: 5;
    flex-shrink: 0;
}

.smg-timeline-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 4px solid #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: #3b82f6;
    box-shadow: 
        0 8px 32px rgba(59, 130, 246, 0.2),
        0 0 0 8px rgba(59, 130, 246, 0.1);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.smg-timeline-icon::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 50%;
    background: linear-gradient(45deg, #3b82f6, transparent, #dc2626);
    z-index: -1;
    opacity: 0;
    animation: icon-glow 3s ease-in-out infinite;
}

@keyframes icon-glow {
    0%, 100% { opacity: 0; transform: rotate(0deg); }
    50% { opacity: 0.6; transform: rotate(180deg); }
}

.smg-timeline-item:hover .smg-timeline-icon {
    transform: scale(1.1);
    box-shadow: 
        0 12px 40px rgba(59, 130, 246, 0.3),
        0 0 0 12px rgba(59, 130, 246, 0.15);
}

/* Highlighted Items */
.smg-timeline-item.highlighted .smg-timeline-icon {
    border-color: #dc2626;
    color: #dc2626;
    background: linear-gradient(135deg, #fef2f2 0%, #ffffff 100%);
    box-shadow: 
        0 8px 32px rgba(220, 38, 38, 0.2),
        0 0 0 8px rgba(220, 38, 38, 0.1);
    animation: highlighted-pulse 2s ease-in-out infinite;
}

@keyframes highlighted-pulse {
    0%, 100% { 
        box-shadow: 
            0 8px 32px rgba(220, 38, 38, 0.2),
            0 0 0 8px rgba(220, 38, 38, 0.1);
    }
    50% { 
        box-shadow: 
            0 12px 40px rgba(220, 38, 38, 0.3),
            0 0 0 12px rgba(220, 38, 38, 0.2);
    }
}

.smg-timeline-item.highlighted .smg-timeline-icon::before {
    background: linear-gradient(45deg, #dc2626, transparent, #f97316);
}

/* Timeline Content */
.smg-timeline-content {
    flex: 1;
    max-width: 350px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(20px);
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.smg-timeline-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6 0%, #dc2626 100%);
    border-radius: 20px 20px 0 0;
}

.smg-timeline-item.highlighted .smg-timeline-content::before {
    background: linear-gradient(90deg, #dc2626 0%, #f97316 100%);
    box-shadow: 0 0 20px rgba(220, 38, 38, 0.3);
}

.smg-timeline-item:hover .smg-timeline-content {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Meta Information */
.smg-timeline-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.smg-timeline-day {
    font-weight: 800;
    color: #1e293b;
    font-size: 1.1rem;
    letter-spacing: -0.01em;
}

.smg-timeline-time {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.smg-timeline-item.highlighted .smg-timeline-time {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border-color: rgba(220, 38, 38, 0.2);
}

/* Content Text */
.smg-timeline-item-title {
    font-family: var(--font-secondary);
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1rem;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.smg-timeline-description {
    color: #64748b;
    line-height: 1.6;
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
}

/* ========================================================================
   HORIZONTAL LAYOUT VARIANT
   ======================================================================== */

.smg-timeline-process-widget.layout-horizontal .smg-timeline-container {
    max-width: 1400px;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-line {
    display: none;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-items {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    overflow-x: auto;
    padding-bottom: 1rem;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-item {
    flex-direction: column;
    text-align: center;
    min-width: 300px;
    margin-bottom: 0;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-item:nth-child(even) {
    flex-direction: column;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-content {
    text-align: center;
    padding: 2rem;
    margin-top: 2rem;
    max-width: none;
}

.smg-timeline-process-widget.layout-horizontal .smg-timeline-item:nth-child(even) .smg-timeline-content,
.smg-timeline-process-widget.layout-horizontal .smg-timeline-item:nth-child(odd) .smg-timeline-content {
    padding-left: 2rem;
    padding-right: 2rem;
}

/* ========================================================================
   CARDS LAYOUT VARIANT
   ======================================================================== */

.smg-timeline-process-widget.layout-cards .smg-timeline-line {
    display: none;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    align-items: stretch;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-item {
    flex-direction: column;
    margin-bottom: 0;
    text-align: center;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-item:nth-child(even) {
    flex-direction: column;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-content {
    text-align: center;
    margin-top: 1.5rem;
    max-width: none;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-description {
    flex: 1;
}

.smg-timeline-process-widget.layout-cards .smg-timeline-item:nth-child(even) .smg-timeline-content,
.smg-timeline-process-widget.layout-cards .smg-timeline-item:nth-child(odd) .smg-timeline-content {
    padding-left: 2.5rem;
    padding-right: 2.5rem;
}

/* ========================================================================
   COLOR SCHEME VARIANTS
   ======================================================================== */

/* Dark Scheme */
.smg-timeline-process-widget.scheme-dark {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-title {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-subtitle {
    color: #94a3b8;
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-content {
    background: rgba(15, 23, 42, 0.8);
    border-color: rgba(255, 255, 255, 0.1);
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-item-title {
    color: #f1f5f9;
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-description {
    color: #94a3b8;
}

.smg-timeline-process-widget.scheme-dark .smg-timeline-day {
    color: #f1f5f9;
}

/* Colorful Scheme */
.smg-timeline-process-widget.scheme-colorful .smg-timeline-item:nth-child(1) .smg-timeline-icon {
    border-color: #dc2626;
    color: #dc2626;
}

.smg-timeline-process-widget.scheme-colorful .smg-timeline-item:nth-child(2) .smg-timeline-icon {
    border-color: #16a34a;
    color: #16a34a;
}

.smg-timeline-process-widget.scheme-colorful .smg-timeline-item:nth-child(3) .smg-timeline-icon {
    border-color: #d97706;
    color: #d97706;
}

.smg-timeline-process-widget.scheme-colorful .smg-timeline-item:nth-child(4) .smg-timeline-icon {
    border-color: #7c3aed;
    color: #7c3aed;
}

/* ========================================================================
   RESPONSIVE DESIGN
   ======================================================================== */

@media (max-width: 768px) {
    .smg-timeline-process-widget {
        padding: 4rem 0;
    }

    .smg-timeline-header {
        margin-bottom: 3rem;
        padding: 0 1rem;
    }

    .smg-timeline-container {
        padding: 0 1rem;
    }

    /* Mobile: Stack all items vertically */
    .smg-timeline-item {
        flex-direction: column !important;
        text-align: center;
        margin-bottom: 3rem;
    }

    .smg-timeline-item:nth-child(even) .smg-timeline-content,
    .smg-timeline-item:nth-child(odd) .smg-timeline-content {
        text-align: center;
        padding: 2rem;
        margin-top: 1.5rem;
        max-width: none;
        padding-left: 2rem;
        padding-right: 2rem;
    }

    .smg-timeline-icon {
        width: 60px;
        height: 60px;
        font-size: 1.4rem;
    }

    .smg-timeline-line {
        display: none;
    }

    /* Horizontal layout becomes single column on mobile */
    .smg-timeline-process-widget.layout-horizontal .smg-timeline-items {
        flex-direction: column;
        align-items: center;
    }

    .smg-timeline-process-widget.layout-horizontal .smg-timeline-item {
        min-width: auto;
        width: 100%;
        max-width: 400px;
    }

    /* Cards layout remains grid but single column */
    .smg-timeline-process-widget.layout-cards .smg-timeline-items {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 480px) {
    .smg-timeline-content {
        padding: 1.5rem;
    }

    .smg-timeline-item-title {
        font-size: 1.2rem;
    }

    .smg-timeline-meta {
        flex-direction: column;
        gap: 0.5rem;
        align-items: center;
    }
}