
<?php $attributes ??= new \Illuminate\View\ComponentAttributeBag;

$__newAttributes = [];
$__propNames = \Illuminate\View\ComponentAttributeBag::extractPropNames(([
    'rotulo' => null,
    'titulo',
    'descripcion' => null,
    // Miga de vuelta: `['ruta' => route(...), 'texto' => 'Entornos']`. Solo en pantallas
    // que cuelgan de otra —la ficha de un entorno—, no en las de primer nivel.
    'volver' => null,
    // El tono del icono. `orange` es el de Tresipunt y el de las pantallas de plataforma;
    // los demás distinguen secciones sin salirse de los tokens.
    'tono' => 'orange',
]));

foreach ($attributes->all() as $__key => $__value) {
    if (in_array($__key, $__propNames)) {
        $$__key = $$__key ?? $__value;
    } else {
        $__newAttributes[$__key] = $__value;
    }
}

$attributes = new \Illuminate\View\ComponentAttributeBag($__newAttributes);

unset($__propNames);
unset($__newAttributes);

foreach (array_filter(([
    'rotulo' => null,
    'titulo',
    'descripcion' => null,
    // Miga de vuelta: `['ruta' => route(...), 'texto' => 'Entornos']`. Solo en pantallas
    // que cuelgan de otra —la ficha de un entorno—, no en las de primer nivel.
    'volver' => null,
    // El tono del icono. `orange` es el de Tresipunt y el de las pantallas de plataforma;
    // los demás distinguen secciones sin salirse de los tokens.
    'tono' => 'orange',
]), 'is_string', ARRAY_FILTER_USE_KEY) as $__key => $__value) {
    $$__key = $$__key ?? $__value;
}

$__defined_vars = get_defined_vars();

foreach ($attributes->all() as $__key => $__value) {
    if (array_key_exists($__key, $__defined_vars)) unset($$__key);
}

unset($__defined_vars, $__key, $__value); ?>

<?php
    // Los tonos salen de los tokens del sistema de diseño: un color a mano aquí volvería a
    // ser un color que nadie sabe de dónde viene.
    $fondos = [
        'orange' => 'var(--orange-100)',
        'info' => 'var(--info-50)',
        'success' => 'var(--success-50)',
        'danger' => 'var(--danger-50)',
        'neutral' => 'var(--neutral-50)',
    ];

    $tintas = [
        'orange' => 'var(--orange-600)',
        'info' => 'var(--info-500)',
        'success' => 'var(--success-500)',
        'danger' => 'var(--danger-500)',
        'neutral' => 'var(--text-subtle)',
    ];

    $fondo = $fondos[$tono] ?? $fondos['orange'];
    $tinta = $tintas[$tono] ?? $tintas['orange'];
?>

<div style="display:flex; flex-direction:column; gap:14px;">

    <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if($volver): ?>
        <div>
            <a href="<?php echo e($volver['ruta']); ?>" wire:navigate
               class="inline-flex items-center gap-1.5 text-[13px] font-semibold" style="color:var(--text-link);">
                <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="m15 18-6-6 6-6"/></svg>
                <?php echo e($volver['texto']); ?>

            </a>
        </div>
    <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

    <section class="overflow-hidden rounded-xl border"
             style="background:var(--surface-card); border-color:var(--border-subtle);">

        <div class="flex flex-wrap items-center justify-between gap-6 px-6 py-5">
            <div class="flex min-w-0 flex-1 items-center gap-4">

                <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(isset($icono)): ?>
                    <span class="flex h-[52px] w-[52px] flex-none items-center justify-center rounded-xl"
                          style="background:<?php echo e($fondo); ?>; color:<?php echo e($tinta); ?>;">
                        <?php echo e($icono); ?>

                    </span>
                <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

                <div class="min-w-0">
                    <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if($rotulo): ?>
                        <div class="text-[10.5px] font-semibold uppercase tracking-[0.08em]" style="color:<?php echo e($tinta); ?>;">
                            <?php echo e($rotulo); ?>

                        </div>
                    <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

                    <h1 class="<?php echo e($rotulo ? 'mt-0.5' : ''); ?> min-w-0 truncate"
                        style="font-family:'Plus Jakarta Sans',sans-serif; font-size:21px; font-weight:700; letter-spacing:-0.02em; color:var(--text-strong); margin:0;">
                        <?php echo e($titulo); ?>

                    </h1>

                    
                    <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(isset($descripcion) && trim((string) $descripcion) !== ''): ?>
                        <div class="mt-1 max-w-3xl text-[13px]" style="color:var(--text-muted);">
                            <?php echo e($descripcion); ?>

                        </div>
                    <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

                    <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(isset($meta)): ?>
                        <div class="mt-1.5 flex flex-wrap items-center gap-2 text-[12.5px]" style="color:var(--text-muted);">
                            <?php echo e($meta); ?>

                        </div>
                    <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>
                </div>
            </div>

            <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(isset($acciones)): ?>
                <div class="flex flex-none flex-wrap items-center gap-2">
                    <?php echo e($acciones); ?>

                </div>
            <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>
        </div>

        
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(isset($pie)): ?>
            <div class="border-t px-6 py-4" style="border-color:var(--border-subtle);">
                <?php echo e($pie); ?>

            </div>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>
    </section>
</div>
<?php /**PATH /var/www/html/resources/views/components/cabecera.blade.php ENDPATH**/ ?>