/* tools/small-text.css */

/* Contenedor principal centrado */
.small-text-main {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

/* --- ÁREA DE TEXTO (INPUT) --- */
.input-container {
    position: relative;
    margin-bottom: 40px;
}

.big-textarea {
    width: 100%;
    height: 120px;
    padding: 20px;
    font-size: 1.2rem;
    font-family: var(--font-family);
    color: white; /* Texto blanco brillante */
    background-color: #111; /* Fondo muy oscuro */
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    resize: none; /* Evitar que el usuario rompa el diseño */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.big-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 20px rgba(0, 124, 240, 0.2);
    background-color: #161616;
}

.char-count {
    position: absolute;
    bottom: 15px;
    right: 20px;
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(0,0,0,0.5);
    padding: 2px 8px;
    border-radius: 4px;
    pointer-events: none;
}

/* --- TÍTULO SECCIÓN --- */
.small-text-main h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- GRILLA DE RESULTADOS --- */
.results-grid {
    display: grid;
    /* Crear columnas automáticamente según el espacio */
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

/* --- TARJETA DE ESTILO --- */
.style-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md);
    padding: 20px;
    display: flex;
    justify-content: space-between; /* Texto a la izq, botón a la der */
    align-items: center;
    transition: transform 0.2s ease, border-color 0.2s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.style-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary-color);
    background-color: #222; /* Ligeramente más claro al hover */
}

.style-info {
    flex-grow: 1;
    overflow: hidden;
    margin-right: 15px;
}

.style-name {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.style-output {
    display: block;
    font-size: 1.3rem; /* Texto resultante grande */
    color: white;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    /* Fuente segura para símbolos Unicode */
    font-family: "Segoe UI Symbol", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
    min-height: 1.5rem; /* Evita que colapse si está vacío */
}

/* --- BOTÓN COPIAR --- */
.copy-btn-icon {
    background: linear-gradient(135deg, #333, #444);
    border: 1px solid #555;
    color: white;
    width: 45px;
    height: 45px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.2s ease;
    flex-shrink: 0; /* No encogerse */
}

.copy-btn-icon:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 0 10px var(--primary-color);
    transform: scale(1.05);
}

.copy-btn-icon:active {
    transform: scale(0.95);
}

.copy-btn-icon.copied {
    background: #28a745;
    border-color: #28a745;
}

/* Responsividad para móviles */
@media (max-width: 600px) {
    .results-grid {
        grid-template-columns: 1fr; /* Una sola columna en móvil */
    }
    
    .big-textarea {
        font-size: 1rem;
    }
    
    .style-output {
        font-size: 1.1rem;
    }
}