/* Guides Page Styles */

.guide-wrap {
    max-width: 1200px;
    margin: 0;
    padding: 0;
}

/* Back Navigation */
.guide-back-navigation {
    margin: 20px 0 10px 0;
}

.guide-back-navigation .button {
    background: #f1f1f1;
    border: 1px solid #ddd;
    color: #666;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
}

.guide-back-navigation .button:hover {
    background: #e8e8e8;
    border-color: #ccc;
    color: #333;
    text-decoration: none;
}

/* Guide Header */
.guide-header {
    background: linear-gradient(135deg, #F8991D 0%, #ff6b35 100%);
    color: white;
    padding: 30px;
    margin: 20px;
		margin-left: 0;
    border-radius: 8px;
}

.guide-header h1 {
    color: white;
    margin: 0 0 10px 0;
    font-size: 2.2em;
    font-weight: 600;
}

.guide-description {
    font-size: 1.1em;
    margin: 0 0 15px 0;
    opacity: 0.95;
}

.guide-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 0.95em;
}

.estimated-time {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 5px;
}

/* Prerequisites Section */
.guide-prerequisites {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 25px;
    margin: 20px;
		margin-left: 0;
}

.guide-prerequisites h3 {
    margin: 0 0 15px 0;
    color: #495057;
    font-size: 1.2em;
}

.prerequisites-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.prerequisite-item {
    display: flex;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.prerequisite-item:last-child {
    border-bottom: none;
}

.prerequisite-status {
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 12px;
    font-size: 0.9em;
}

.prerequisite-met .prerequisite-status {
    background: #28a745;
    color: white;
}

.prerequisite-not-met .prerequisite-status {
    background: #dc3545;
    color: white;
}

.prerequisite-text {
    flex: 1;
    line-height: 1.5;
}

.prerequisite-action {
    margin-top: 5px;
    padding: 8px 12px;
    background: #e3f2fd;
    border-radius: 4px;
    font-size: 0.9em;
}

.prerequisite-action a {
    color: #1976d2;
    text-decoration: none;
}

.prerequisite-action a:hover {
    text-decoration: underline;
}

/* Guide Content */
.guide-content {
    margin: 30px 0;
}

.guide-section {
    margin: 40px 0;
    padding: 0 20px;
}

.guide-section h2 {
    color: #2c3e50;
    font-size: 1.8em;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 3px solid #F8991D;
}

.guide-section h3 {
    color: #34495e;
    font-size: 1.4em;
    margin: 25px 0 15px 0;
}

.guide-section h4 {
    color: #5a6c7d;
    font-size: 1.2em;
    margin: 20px 0 10px 0;
}

.guide-section p {
    line-height: 1.7;
    margin: 15px 0;
    color: #555;
}

/* Section Content */
.section-content {
    padding: 0;
    margin: 0;
}

/* Feature Section */
.feature-section {
    margin: 20px 0;
    padding: 0;
}

.feature-section ul {
    margin: 15px 0;
}

/* Concept Comparison Grid */
.concept-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.concept-item {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #F8991D;
}

.concept-item h4 {
    margin: 0 0 10px 0;
    color: #2c3e50;
}

.concept-item p {
    margin: 0;
    font-size: 0.95em;
    line-height: 1.6;
}

/* Concept Cards */
.concept-card {
    background: #ffffff;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.concept-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.concept-card h4,
.concept-card h5 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 1.1em;
    font-weight: 600;
}

.concept-card p {
    margin: 0 0 15px 0;
    font-size: 0.95em;
    line-height: 1.6;
    color: #555;
}

.concept-card ul {
    margin: 0;
    padding-left: 20px;
    list-style-type: disc;
}

.concept-card ul li {
    margin-bottom: 8px;
    font-size: 0.9em;
    line-height: 1.5;
    color: #666;
}

/* Concept Card Variants */
.concept-card.supported {
    border-left: 4px solid #28a745;
    background: linear-gradient(135deg, #f8fff9 0%, #e8f5e8 100%);
}

.concept-card.supported h5 {
    color: #28a745;
}

.concept-card.partial {
    border-left: 4px solid #ffc107;
    background: linear-gradient(135deg, #fffdf5 0%, #fff3cd 100%);
}

.concept-card.partial h5 {
    color: #856404;
}

/* Feature Lists */
.feature-list {
    list-style: none !important;
    padding: 0;
    margin: 20px 0;
}

.feature-list li {
    list-style: none !important;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
    position: relative;
    padding-left: 25px;
}

.feature-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #28a745;
    font-weight: bold;
}

.feature-list li:last-child {
    border-bottom: none;
}

/* Step Lists */
.step-list {
    counter-reset: step-counter;
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.step-list li {
    counter-increment: step-counter;
    padding: 15px 0 15px 50px;
    position: relative;
    border-bottom: 1px solid #e9ecef;
}

.step-list li:before {
    content: counter(step-counter);
    position: absolute;
    left: 0;
    top: 15px;
    background: #F8991D;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9em;
}

.step-list li:last-child {
    border-bottom: none;
}

/* Tip Boxes */
.tip-box {
    background: #e8f5e8;
    border: 1px solid #c3e6c3;
    border-radius: 8px;
    padding: 20px;
    margin: 25px 0;
    position: relative;
}

.tip-box h4 {
    margin: 0 0 10px 0;
    color: #155724;
    display: flex;
    align-items: center;
}

.tip-box h4:before {
    content: "💡";
    margin-right: 8px;
}

.tip-box p {
    margin: 0;
    color: #155724;
}

/* Roles Grid */
.roles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.role-item {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.role-item h4 {
    margin: 0 0 10px 0;
    color: #F8991D;
    font-size: 1.1em;
}

.role-item p {
    margin: 0;
    font-size: 0.9em;
    color: #6c757d;
}

.role-item h5 {
    margin: 15px 0 8px 0;
    color: #2c3e50;
    font-size: 0.9em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.role-item ul {
    text-align: left;
    margin: 8px 0 0 0;
    padding-left: 20px;
    list-style-type: disc;
}

.role-item ul li {
    margin: 5px 0;
    font-size: 0.85em;
    color: #555;
    line-height: 1.4;
}

/* Resources Grid */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.resource-item {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
}

.resource-item h4 {
    margin: 0 0 10px 0;
    color: #2c3e50;
    font-size: 1.1em;
}

.resource-item p {
    margin: 0;
    font-size: 0.9em;
    line-height: 1.6;
    color: #555;
}

/* Pro Feature Callout */
.guide-pro-callout {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
    padding: 30px;
    margin: 40px 0;
    position: relative;
    overflow: hidden;
}

.pro-callout-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.pro-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: bold;
    margin-right: 15px;
    letter-spacing: 1px;
}

.pro-callout-header h3 {
    margin: 0;
    color: white;
    font-size: 1.3em;
}

.guide-pro-callout p {
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.6;
    margin: 15px 0;
}

.pro-features-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.pro-features-list li {
    padding: 8px 0;
    position: relative;
    padding-left: 25px;
    color: rgba(255, 255, 255, 0.9);
}

.pro-features-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #4caf50;
    font-weight: bold;
}

.pro-upgrade-button {
    display: inline-block;
    background: white;
    color: #667eea;
    padding: 12px 25px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.pro-upgrade-button:hover {
    background: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Pro Installed Status */
.pro-installed-status {
    display: flex;
    align-items: center;
    margin-top: 15px;
    padding: 12px 20px;
    background: rgba(76, 175, 80, 0.2);
    border-radius: 6px;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.pro-checkmark {
    color: #4caf50;
    font-size: 1.2em;
    font-weight: bold;
    margin-right: 10px;
}

.pro-installed-text {
    color: rgba(255, 255, 255, 0.95);
    font-weight: 500;
}

/* Connection Setup */
.guide-connection-setup {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 25px;
    margin: 25px 0;
}

.guide-connection-setup h3 {
    margin: 0 0 15px 0;
    color: #495057;
}

.guide-connection-setup p {
    margin: 0 0 20px 0;
    color: #6c757d;
}

/* Navigation */
.guide-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 50px 0 30px 0;
    padding: 20px 0;
    border-top: 2px solid #e9ecef;
}

.guide-navigation .button {
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.guide-navigation .button:hover {
    text-decoration: none;
    transform: translateY(-2px);
}

/* Guides List Page */
.guides-list {
    margin: 30px 0;
}

.guides-category {
    margin: 40px 0;
}

.guides-category h2 {
    color: #2c3e50;
    font-size: 1.8em;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 3px solid #F8991D;
}

.guides-category > p {
    color: #6c757d;
    margin: 0 0 25px 0;
    font-size: 1.05em;
}

.guides-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin: 25px 0;
}

.guide-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.guide-card:hover {
    border-color: #F8991D;
    box-shadow: 0 8px 25px rgba(248, 153, 29, 0.15);
    text-decoration: none;
    color: inherit;
    transform: translateY(-3px);
}

.guide-card h3 {
    margin: 0 0 12px 0;
    color: #2c3e50;
    font-size: 1.2em;
    line-height: 1.3;
}

.guide-card p {
    margin: 0 0 15px 0;
    color: #6c757d;
    line-height: 1.6;
    font-size: 0.95em;
}

.guide-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85em;
    color: #868e96;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e9ecef;
}

.guide-prerequisites-count {
    display: flex;
    align-items: center;
}

.guide-prerequisites-count:before {
    content: "📋";
    margin-right: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .guide-header {
        padding: 20px;
        margin: 10px 0;
    }

    .guide-header h1 {
        font-size: 1.8em;
    }

    .guide-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .concept-comparison,
    .roles-grid,
    .resources-grid {
        grid-template-columns: 1fr;
    }

    .guide-navigation {
        flex-direction: column;
        gap: 15px;
    }

    .guides-grid {
        grid-template-columns: 1fr;
    }

    .guide-section {
        padding: 0 10px;
    }
}

@media (max-width: 480px) {
    .guide-header h1 {
        font-size: 1.5em;
    }

    .guide-section h2 {
        font-size: 1.5em;
    }

    .guide-section h3 {
        font-size: 1.2em;
    }
}

/* Reading Progress Bar */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(248, 153, 29, 0.2);
    z-index: 9999;
}

.reading-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #F8991D, #ff6b35);
    width: 0%;
    transition: width 0.3s ease;
}

/* Notification System */
.guide-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 6px;
    color: white;
    font-weight: 500;
    z-index: 10000;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.guide-notification.show {
    transform: translateX(0);
}

.guide-notification-success {
    background: #28a745;
}

.guide-notification-error {
    background: #dc3545;
}

.guide-notification-info {
    background: #17a2b8;
}

/* Hover Effects */
.hover-effect {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* Additional Guide Specific Styles */
.guide-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 5px;
}

.guides-additional-info {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 2px solid #e9ecef;
}

/* Displaying Custom Data on the Frontend Guide Styles */

/* Post Type Selector Styles */
.post-type-selector {
    margin: 20px 0;
    padding: 20px;
    background: #f8f9fa;
    border: 1px solid #e1e5e9;
    border-radius: 8px;
}

.post-type-selector label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #1e1e1e;
}

.post-type-selector select {
    margin-bottom: 15px;
}

#post-type-quick-links {
    animation: fadeInUp 0.3s ease-in-out;
}

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

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.button-group .button {
    flex: 1;
    text-align: center;
    min-width: 180px;
}

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

    .button-group .button {
        width: 100%;
    }
}

/* Screenshot and Video Placeholder Styles */
.screenshot-placeholder,
.video-placeholder {
    margin: 20px 0;
    padding: 40px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.screenshot-placeholder::before,
.video-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.05)"/><circle cx="50" cy="10" r="0.5" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.screenshot-note,
.video-note {
    position: relative;
    z-index: 1;
}

.screenshot-placeholder {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.video-placeholder {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.screenshot-note strong,
.video-note strong {
    display: block;
    font-size: 1.2em;
    margin-bottom: 8px;
}

/* Step Instructions Styles */
.step-instructions {
    margin: 15px 0;
    padding: 20px;
    background: #fff;
    border-left: 4px solid #2196F3;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.step-instructions ol {
    margin: 0;
    padding-left: 20px;
}

.step-instructions li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.step-instructions li strong {
    color: #1565C0;
}

.step-instructions code {
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'SFMono-Regular', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
    font-size: 0.9em;
}

/* Toggle Steps Button */
.toggle-steps-btn {
    margin-top: 10px;
    padding: 8px 16px;
    background: #f0f0f1;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    color: #1d2327;
    transition: all 0.2s ease;
}

.toggle-steps-btn:hover {
    background: #e0e0e0;
    border-color: #8c8f94;
}

/* Concept Cards Enhancements for frontend guide */
.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card {
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card h4 {
    display: flex;
    align-items: center;
    gap: 8px;
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card ul,
.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card ol {
    margin-top: 10px;
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card ul li,
.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-card ol li {
    margin-bottom: 4px;
}

/* Feature Section Enhancements */
.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .feature-section {
    margin: 20px 0;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 6px;
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .feature-section h4 {
    margin-top: 0;
    color: #1e1e1e;
}

.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .feature-section ul,
.guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .feature-section ol {
    margin-bottom: 0;
}

/* Resources Grid */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.resource-item {
    padding: 20px;
    background: #fff;
    border: 1px solid #e1e5e9;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.resource-item:hover {
    border-color: #2196F3;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.1);
}

.resource-item h4 {
    margin-top: 0;
    color: #1565C0;
}

.resource-item ul {
    margin-top: 10px;
    margin-bottom: 0;
}

/* Navigation Enhancements */
.guide-navigation a.active {
    background: #2196F3;
    color: white;
}

/* Responsive Improvements for frontend guide */
@media (max-width: 768px) {
    .resources-grid {
        grid-template-columns: 1fr;
    }

    .guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .concept-comparison {
        grid-template-columns: 1fr;
    }

    .step-instructions {
        padding: 15px;
    }

    .screenshot-placeholder,
    .video-placeholder {
        padding: 30px 15px;
    }
}

/* Dark mode support (if theme supports it) */
@media (prefers-color-scheme: dark) {
    .step-instructions {
        background: #2c3e50;
        color: #ecf0f1;
        border-left-color: #3498db;
    }

    .guide-wrap[data-guide-slug="power-platform-to-wordpress-frontend"] .feature-section {
        background: #34495e;
        color: #ecf0f1;
    }

    .resource-item {
        background: #2c3e50;
        border-color: #34495e;
        color: #ecf0f1;
    }
}

/* ====================================
   Data Flow Diagram Styles
   ==================================== */

.data-flow-diagram {
    margin: 30px 0;
    padding: 30px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    border: 1px solid #dee2e6;
    overflow-x: auto;
}

.data-flow-container {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    position: relative;
}

.flow-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border: 2px solid #e9ecef;
    transition: none;
    position: relative;
    min-width: 180px;
    max-width: 220px;
    flex: 0 0 auto;
    margin-bottom: 20px;
}

.flow-step.focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

.flow-step-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 12px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    position: relative;
    /* Fallback text for accessibility and debugging */
    font-size: 24px;
    font-weight: bold;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

/* Fallback content for each service */
.flow-step.dataverse .flow-step-icon::before {
    content: 'DV';
    position: absolute;
    z-index: 1;
}

.flow-step.power-automate .flow-step-icon::before {
    content: 'PA';
    position: absolute;
    z-index: 1;
}

.flow-step.wp-core .flow-step-icon::before {
    content: 'WP';
    position: absolute;
    z-index: 1;
}

.flow-step.acf .flow-step-icon::before {
    content: 'ACF';
    position: absolute;
    z-index: 1;
    font-size: 18px;
}

.flow-step.frontend .flow-step-icon::before {
    content: 'UI';
    position: absolute;
    z-index: 1;
}

/* Service-specific icon styles with branded colors and authentic logos */
.flow-step.dataverse .flow-step-icon {
    background: linear-gradient(135deg, #0078d4 0%, #106ebe 100%);
    background-image: url('../../images/guides/microsoft-dataverse-logo.svg');
    background-size: 45px 45px;
    background-repeat: no-repeat;
    background-position: center;
}

.flow-step.power-automate .flow-step-icon {
    background: linear-gradient(135deg, #F8991D 0%, #ff6b35 100%);
    background-image: url('../../images/guides/power-automate-logo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.flow-step.wp-core .flow-step-icon {
    background: linear-gradient(135deg, #21759b 0%, #1e6a8f 100%);
    background-image: url('../../images/guides/wordpress-logo.png');
    background-size: 45px 45px;
    background-repeat: no-repeat;
    background-position: center;
}

.flow-step.acf .flow-step-icon {
    background: linear-gradient(135deg, #00d4aa 0%, #00b894 100%);
    background-image: url('../../images/guides/acf-logo.png');
    background-size: 50px 50px;
    background-repeat: no-repeat;
    background-position: center;
}

.flow-step.frontend .flow-step-icon {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    background-image: url('../../images/guides/frontend-logo.png');
    background-size: 45px 45px;
    background-repeat: no-repeat;
    background-position: center;
}

/* Hide fallback text when authentic logos are loaded */
.flow-step.dataverse .flow-step-icon::before,
.flow-step.wp-core .flow-step-icon::before,
.flow-step.frontend .flow-step-icon::before,
.flow-step.power-automate .flow-step-icon::before,
.flow-step.acf .flow-step-icon::before {
    opacity: 0;
}

.flow-step-title {
    font-weight: 600;
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 6px;
    line-height: 1.3;
}

.flow-step-subtitle {
    font-size: 13px;
    color: #6c757d;
    margin-bottom: 8px;
    line-height: 1.2;
}

.flow-step-description {
    font-size: 12px;
    color: #8b9497;
    line-height: 1.4;
}

/* Flow arrows - responsive design that works on all screen sizes */
.flow-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin: 0 -2px; /* Negative margin to make arrows touch the boxes */
    position: relative;
    height: auto;
    align-self: center; /* Align with the center of the flow step */
}

.flow-arrow::before {
    content: '';
    width: 44px; /* Slightly longer to ensure touching */
    height: 3px;
    background: linear-gradient(90deg, #007cba 0%, #005a87 100%);
    border-radius: 2px;
}

.flow-arrow::after {
    content: '';
    position: absolute;
    right: -2px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid #005a87;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}

/* Bidirectional arrows - simple and clean */
.flow-arrow-bidirectional {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin: 0 -2px;
    height: auto;
    align-self: center;
}

.flow-arrow-bidirectional .left-arrow {
    width: 0;
    height: 0;
    border-right: 8px solid #007cba;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}

.flow-arrow-bidirectional .arrow-line {
    width: 44px;
    height: 3px;
    background: linear-gradient(90deg, #007cba 0%, #005a87 100%);
    border-radius: 2px;
}

.flow-arrow-bidirectional .right-arrow {
    width: 0;
    height: 0;
    border-left: 8px solid #005a87;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}

/* On mobile when items wrap, show curved/turn arrows */
@media (max-width: 768px) {
    .data-flow-container {
        flex-direction: column;
        align-items: center;
    }

    .flow-arrow {
        width: 40px;
        height: 40px;
        margin: 10px auto;
        transform: rotate(90deg);
        align-self: center;
    }

    .flow-arrow::before {
        width: 30px;
        height: 3px;
        background: linear-gradient(90deg, #007cba 0%, #005a87 100%);
    }

    .flow-arrow::after {
        right: -2px;
        top: 50%;
        transform: translateY(-50%);
        border-left: 8px solid #005a87;
        border-top: 4px solid transparent;
        border-bottom: 4px solid transparent;
    }

    /* Mobile bidirectional arrows */
    .flow-arrow-bidirectional {
        width: 40px;
        height: 40px;
        margin: 10px auto;
        transform: rotate(90deg);
        align-self: center;
    }

    .flow-arrow-bidirectional .left-arrow {
        border-right: 8px solid #007cba;
        border-top: 4px solid transparent;
        border-bottom: 4px solid transparent;
    }

    .flow-arrow-bidirectional .arrow-line {
        width: 30px;
        height: 3px;
    }

    .flow-arrow-bidirectional .right-arrow {
        border-left: 8px solid #005a87;
        border-top: 4px solid transparent;
        border-bottom: 4px solid transparent;
    }
}

/* Animation effects */
.data-flow-diagram.animate .flow-step {
    opacity: 0;
    transform: translateY(20px);
    animation: slideInUp 0.6s ease forwards;
}

.data-flow-diagram.animate .flow-step:nth-child(1) { animation-delay: 0.1s; }
.data-flow-diagram.animate .flow-step:nth-child(2) { animation-delay: 0.2s; }
.data-flow-diagram.animate .flow-step:nth-child(3) { animation-delay: 0.3s; }
.data-flow-diagram.animate .flow-step:nth-child(4) { animation-delay: 0.4s; }
.data-flow-diagram.animate .flow-step:nth-child(5) { animation-delay: 0.5s; }

@keyframes slideInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Responsive design for data flow diagrams */
@media (max-width: 1024px) {
    .data-flow-container {
        min-width: 700px;
    }

    .flow-step {
        min-width: 140px;
        padding: 15px;
    }

    .flow-step-icon {
        width: 56px;
        height: 56px;
    }

    .flow-step-title {
        font-size: 14px;
    }

    .flow-arrow {
        width: 50px;
    }
}

@media (max-width: 768px) {
    .data-flow-diagram {
        padding: 20px 15px;
    }

    .data-flow-container {
        min-width: 600px;
    }

    .flow-step {
        min-width: 120px;
        padding: 12px;
    }

    .flow-step-icon {
        width: 48px;
        height: 48px;
    }

    .flow-step-title {
        font-size: 13px;
    }

    .flow-step-subtitle {
        font-size: 12px;
    }

    .flow-step-description {
        font-size: 11px;
    }

    .flow-arrow {
        width: 40px;
        margin: 0 8px;
    }

    .flow-arrow:after {
        font-size: 9px;
        padding: 1px 4px;
    }
}

/* Print styles for data flow diagrams */
@media print {
    .data-flow-diagram {
        background: white !important;
        box-shadow: none !important;
        border: 1px solid #ccc !important;
    }

    .flow-step {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }

    .flow-arrow:after {
        display: none;
    }
}

/* Dark mode support for data flow diagrams */
@media (prefers-color-scheme: dark) {
    .data-flow-diagram {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
        border-color: #34495e;
    }

    .flow-step {
        background: #34495e;
        border-color: #2c3e50;
        color: #ecf0f1;
    }

    .flow-step-title {
        color: #ecf0f1;
    }

    .flow-step-subtitle {
        color: #bdc3c7;
    }

    .flow-step-description {
        color: #95a5a6;
    }
}
