﻿/* Estilos específicos para la página Crear Plugin FacturaScripts */
/* Mantiene consistencia con el tema azul de FacturaScripts */

.tutorial-article {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.article-header {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid #ecf0f1;
}

.article-title {
    font-size: 2.5rem;
    color: #2c5aa0;
    margin-bottom: 1rem;
    font-weight: 300;
}

.article-subtitle {
    font-size: 1.2rem;
    color: #7f8c8d;
}

.content-section {
    margin-bottom: 3rem;
}

.content-section h2 {
    color: #2c5aa0;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #ecf0f1;
}

.content-section h3 {
    color: #2c5aa0;
    font-size: 1.3rem;
    margin: 1.5rem 0 1rem 0;
}

.content-section h4 {
    color: #2c5aa0;
    font-size: 1.1rem;
    margin: 1.5rem 0 1rem 0;
}

.content-section p {
    line-height: 1.7;
    margin-bottom: 1rem;
    color: #555;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.feature-item {
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid #2c5aa0;
}

.feature-item h3 {
    color: #2c5aa0;
    margin-top: 0;
    margin-bottom: 1rem;
}

.feature-item ul {
    margin: 0;
    padding-left: 1rem;
}

.feature-item li {
    margin-bottom: 0.5rem;
    line-height: 1.5;
    font-size: 0.9rem;
}

.steps {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.step {
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid #2c5aa0;
}

.step h3 {
    color: #2c5aa0;
    margin-top: 0;
}

.content-section ul {
    margin: 1rem 0;
    padding-left: 2rem;
}

.content-section li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.directory-structure {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 1.5rem;
    border-radius: 6px;
    margin: 1rem 0;
    overflow-x: auto;
}

.directory-structure pre {
    margin: 0;
    font-family: 'Courier New', monospace;
    line-height: 1.4;
}

.code-example {
    border: 1px solid #e1e8ed;
    border-radius: 6px;
    padding: 1.5rem;
    margin: 1rem 0;
    overflow-x: auto;
    position: relative;
}

.code-example pre {
    margin: 0;
    white-space: pre-wrap;
}

.code-example code {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    color: #2c3e50;
    line-height: 1.5;
    background: transparent;
    font-size: 0.9rem;
    display: block;
}

.copy-code-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #2c5aa0;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.copy-code-btn:hover {
    opacity: 1;
}

.expandable-box {
    margin-top: 1rem;
    border: 1px solid #e1e8ed;
    border-radius: 6px;
    overflow: hidden;
}

.expand-button {
    width: 100%;
    background: #2c5aa0;
    color: white;
    border: none;
    padding: 1rem 1.5rem;
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.expand-button:hover {
    background: #1e3d72;
}

.arrow {
    transition: transform 0.3s ease;
    font-size: 0.8rem;
}

.expandable-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.expandable-content.expanded {
    max-height: 5000px;
}

.expandable-content-inner {
    padding: 1.5rem;
}

.expandable-box.expanded .arrow {
    transform: rotate(180deg);
}

.expandable-box.expanded .expand-button {
    background: #1e3d72;
}

.troubleshooting {
    background: #f0f7ff;
    padding: 2rem;
    border-radius: 8px;
    border-left: 4px solid #2c5aa0;
}

.problems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.problem {
    padding: 1.5rem;
    border-radius: 6px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border: 1px solid #e1e8ed;
}

.problem h3 {
    color: #2c5aa0;
    margin-top: 0;
}

.best-practices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.practice-item {
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid #2c5aa0;
}

.practice-item h3 {
    color: #2c5aa0;
    margin-top: 0;
    margin-bottom: 1rem;
}

.practice-item ul {
    margin: 0;
    padding-left: 1rem;
}

.practice-item li {
    margin-bottom: 0.5rem;
    line-height: 1.5;
    font-size: 0.9rem;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.resource-item {
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid #2c5aa0;
}

.resource-item h3 {
    color: #2c5aa0;
    margin-top: 0;
    margin-bottom: 1rem;
}

.resource-item ul {
    margin: 0;
    padding-left: 1rem;
}

.resource-item li {
    margin-bottom: 0.5rem;
}

.content-section a {
    color: #2c5aa0;
    text-decoration: none;
    font-weight: 500;
}

.content-section a:hover {
    text-decoration: underline;
    color: #1e3d72;
}

/* Resaltado de sintaxis para código PHP */
.php-tag { color: #e74c3c; font-weight: bold; }
.php-keyword { color: #9b59b6; font-weight: bold; }
.php-comment { color: #27ae60; font-style: italic; }
.php-string { color: #e67e22; }
.php-variable { color: #3498db; }
.php-function { color: #2980b9; }
.php-class { color: #8e44ad; }

/* Animaciones para elementos interactivos */
.feature-item, .step, .practice-item, .resource-item {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover, .step:hover, .practice-item:hover, .resource-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 90, 160, 0.15);
}

/* Estilo para bloques de código largos */
.code-example pre {
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Mejora la legibilidad del código */
.code-example code {
    tab-size: 4;
    -moz-tab-size: 4;
}