/* create.css - Estudio tipo Word */

/* Contenedor Principal */
#word-studio-container {
    height: calc(100vh - 60px); /* Pantalla completa menos header */
    display: flex;
    flex-direction: column;
    background-color: #f3f2f1; /* Gris Office/Word */
}

/* --- 1. BARRA DE HERRAMIENTAS SUPERIOR --- */
.studio-toolbar {
    height: 60px;
    background-color: var(--color-tarjeta);
    border-bottom: 1px solid var(--color-borde);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    z-index: 10;
}

.toolbar-left, .toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toolbar-center {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    margin: 0 20px;
}

/* Botones de la barra */
.tool-btn {
    background: none; border: none; color: var(--color-suave);
    cursor: pointer; font-size: 1.1em; padding: 8px;
    transition: 0.2s;
}
.tool-btn:hover { color: var(--color-principal); }

.divider { color: var(--color-borde); margin: 0 5px; }

/* Botones de MODO (Libro vs Frase) */
.mode-btn {
    background: transparent;
    border: 1px solid transparent;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    color: var(--color-texto);
    font-size: 0.9em;
    display: flex; align-items: center; gap: 6px;
}
.mode-btn:hover { background: rgba(255,255,255,0.05); }

.mode-btn.active {
    background-color: var(--color-principal); /* Activado */
    color: #000;
    font-weight: bold;
}

/* Input de Título Central */
#post-title {
    width: 100%; max-width: 500px;
    text-align: center;
    font-weight: bold;
    font-size: 1.1em;
    border: none;
    background: transparent;
    border-bottom: 2px solid transparent;
    color: var(--color-texto);
}
#post-title:focus {
    outline: none;
    border-bottom-color: var(--color-principal);
}

/* --- 2. ÁREA DE TRABAJO (FONDO) --- */
.workspace-bg {
    flex-grow: 1;
    background-color: #cfd8dc; /* Gris azulado escritorio */
    position: relative;
    overflow-y: auto; /* Scroll aquí */
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
}

/* Configuración rápida flotante o arriba */
.quick-settings {
    margin-bottom: 20px;
    display: flex; gap: 15px;
}
.minimal-select, .minimal-input {
    background: var(--color-tarjeta);
    border: 1px solid var(--color-borde);
    padding: 8px 15px;
    border-radius: 20px;
    color: var(--color-texto);
    font-size: 0.9em;
}

/* --- 3. HOJA DE PAPEL (EL NÚCLEO) --- */
.paper-sheet {
    background-color: white;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: all 0.4s ease;
    padding: 0; /* El padding lo da el textarea */
    position: relative;
}

/* MODO LIBRO (A4 style) */
.paper-sheet.mode-book {
    width: 100%;
    max-width: 800px; /* Ancho A4 aprox */
    min-height: 1000px; /* Alto A4 aprox */
    margin-bottom: 50px;
}

/* MODO FRASE (Tarjeta Cuadrada) */
.paper-sheet.mode-quote {
    width: 500px;
    height: 500px; /* Cuadrado */
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #ffffff 0%, #f0f0f0 100%);
}

/* TEXTAREA DENTRO DEL PAPEL */
#post-content {
    width: 100%;
    height: 100%;
    border: none;
    resize: none;
    outline: none;
    background: transparent;
    color: #222; /* Texto siempre oscuro en papel blanco */
    padding: 50px; /* Margen de impresión */
    line-height: 1.8;
}

/* Estilos de Texto según modo */
.mode-book #post-content {
    font-family: 'Merriweather', serif; /* Fuente de libro */
    font-size: 1.1em;
}

.mode-quote #post-content {
    font-family: 'Caveat', cursive; /* Fuente manuscrita */
    font-size: 2.5em;
    text-align: center;
    padding: 40px;
    overflow: hidden;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .studio-toolbar { flex-wrap: wrap; height: auto; padding: 10px; gap: 10px; }
    .toolbar-center { order: 2; width: 100%; margin: 0; }
    #post-title { width: 100%; }
    
    .paper-sheet.mode-quote { width: 100%; height: 350px; }
    .paper-sheet.mode-book { min-height: 500px; }
    
    #post-content { padding: 20px; }
}