.timeout-concept-card {
    border-radius: 8px;
    margin-bottom: 20px;
    overflow: hidden;
    border: 1px solid #dee2e6;
    transition: transform 0.3s, box-shadow 0.3s;
}

.timeout-concept-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.timeout-card-header {
    padding: 15px;
    color: white;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.timeout-card-content {
    padding: 20px;
    background-color: white;
}

.timeout-basics { background-color: #4299e1; }
.timeout-types { background-color: #48bb78; }
.timeout-exceptions { background-color: #ed8936; }
.timeout-strategies { background-color: #9f7aea; }
.timeout-advanced { background-color: #f56565; }
.timeout-best { background-color: #38b2ac; }

.timeout-visualization {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #4a6ee0;
}

.timeout-flow {
    position: relative;
    padding: 20px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 8px;
    margin: 20px 0;
}

.flow-step {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px;
    background-color: white;
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.step-number {
    width: 30px;
    height: 30px;
    background-color: #4a6ee0;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 15px;
    flex-shrink: 0;
}

.timeout-example {
    background-color: #e8f4fd;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #1890ff;
}

.timeout-table {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.timeout-table th {
    background-color: #4a6ee0;
    color: white;
}

.comparison-container {
    display: flex;
    gap: 20px;
    margin: 20px 0;
}

.comparison-column {
    flex: 1;
    background-color: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
}

.column-header {
    padding: 10px 15px;
    background-color: #e9ecef;
    font-weight: bold;
    border-bottom: 1px solid #dee2e6;
}

.column-content {
    padding: 15px;
}

@media (max-width: 768px) {
    .comparison-container {
        flex-direction: column;
    }
}

.note-box {
    background-color: #e8f4fd;
    border-left: 4px solid #1890ff;
    padding: 15px;
    border-radius: 5px;
    margin: 15px 0;
}

.warning-box {
    background-color: #fff8e1;
    border-left: 4px solid #ffb300;
    padding: 15px;
    border-radius: 5px;
    margin: 15px 0;
}

.tip-box {
    background-color: #f0fff4;
    border-left: 4px solid #38a169;
    padding: 15px;
    border-radius: 5px;
    margin: 15px 0;
}

.timeout-preview {
    background-color: #2d3748;
    color: #e2e8f0;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    font-family: 'Courier New', monospace;
    overflow-x: auto;
}

.timeout-line {
    display: flex;
    margin: 5px 0;
}

.timeout-label {
    color: #81e6d9;
    min-width: 150px;
}

.timeout-separator {
    margin: 0 10px;
    color: #718096;
}

.timeout-value {
    color: #f7fafc;
    flex-grow: 1;
}

.timeout-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: bold;
    margin-right: 5px;
    background-color: #4299e1;
    color: white;
}

.connect-badge { background-color: #48bb78; }
.read-badge { background-color: #ed8936; }

.timeout-diagram {
    text-align: center;
    margin: 20px 0;
}

.diagram-container {
    display: inline-block;
    padding: 20px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.timeline {
    position: relative;
    width: 100%;
    height: 120px;
    margin: 20px 0;
}

.timeline-line {
    position: absolute;
    top: 60px;
    left: 10%;
    width: 80%;
    height: 2px;
    background-color: #4a6ee0;
}

.timeline-event {
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: white;
    border: 3px solid #4a6ee0;
    top: 52px;
}

.timeline-label {
    position: absolute;
    top: 85px;
    text-align: center;
    font-size: 0.8em;
    color: #666;
}

.timeline-connect {
    left: 10%;
}

.timeline-connected {
    left: 30%;
}

.timeline-read {
    left: 50%;
}

.timeline-complete {
    left: 90%;
}

.connection-phase {
    position: absolute;
    top: 30px;
    height: 30px;
    background-color: #e8f4fd;
    border-radius: 4px;
    border: 1px solid #1890ff;
}

.read-phase {
    position: absolute;
    top: 30px;
    height: 30px;
    background-color: #f0fff4;
    border-radius: 4px;
    border: 1px solid #38a169;
}

.timeout-indicator {
    position: absolute;
    top: 70px;
    height: 10px;
    background-color: #f56565;
    border-radius: 2px;
}
