Desbloquea todos los bloques y plantillas premium con All-Access desde 20 € / 3 meses, cancela cuando quieras. Consigue All-Access
Todos los bloques
Gratis Portada

Brambleby Hero

A hero block extracted from the Brambleby template, available in Tailwind CSS.

0 14
Brambleby Hero preview

Descargar el código

Licencia comercial

Descarga gratis · hasta 5 bloques al día. Ilimitado con All-Access

brambleby.html
<!DOCTYPE html>
<html lang="en">
<head>
  <script>
    window.FontAwesomeConfig = { autoReplaceSvg: 'nest' };
  </script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/js/all.min.js" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Brambleby Hero | Tailwind CSS UI Block</title>
  <meta name="description" content="A hero block extracted from the Brambleby template, available in Tailwind CSS.">
  <meta name="keywords" content="Brambleby, Tailwind CSS template, HTML website template, bakery template, biscuit shop website, cookie shop template, organic bakery, pastry shop, baking workshop booking, food and restaurant template">
  <meta name="author" content="Let's templates">
  <link rel="canonical" href="">

  <meta property="og:type" content="product">
  <meta property="og:site_name" content="Let's templates">
  <meta property="og:locale" content="en_US">
  <meta property="og:url" content="">
  <meta property="og:title" content="Brambleby | Tailwind CSS Food &amp; Restaurant Template">
  <meta property="og:description" content="A warm Tailwind CSS template for organic biscuit bakeries, with a hero slideshow, flavour tabs, a fill-your-tin builder, stockists and workshop booking.">
  <meta property="og:image" content="">
  <meta property="og:image:alt" content="Brambleby template preview">

  <meta name="twitter:card" content="summary_large_image">
  <meta name="twitter:url" content="">
  <meta name="twitter:title" content="Brambleby | Tailwind CSS Food &amp; Restaurant Template">
  <meta name="twitter:description" content="A warm Tailwind CSS template for organic biscuit bakeries, with a hero slideshow, flavour tabs, a fill-your-tin builder, stockists and workshop booking.">
  <meta name="twitter:image" content="">
  <meta name="twitter:image:alt" content="Brambleby template preview">
  <script src="https://cdn.tailwindcss.com/3.4.17"></script>
  <link rel="preconnect" href="https://fonts.googleapis.com">
  <link href="https://fonts.googleapis.com/css2?family=Caveat:wght@500;700&family=Josefin+Sans:wght@400;600;700&family=Karla:ital,wght@0,400;0,500;0,700;1,400&display=swap" rel="stylesheet">
  <script>
    tailwind.config = {
      theme: {
        extend: {
          colors: {
            apricot: { DEFAULT: '#f5c993', soft: '#f9dcb6', deep: '#eab275' },
            rust: { DEFAULT: '#9c4f2e', deep: '#7a3a1f', soft: '#c47a55' },
            cocoa: { DEFAULT: '#3f2418', soft: '#6e4a3a' },
            blush: '#f8ece7',
            oat: '#f4e6d9',
            biscuit: '#efdcc8'
          },
          fontFamily: { display: ['"Josefin Sans"', 'sans-serif'], sans: ['Karla', 'sans-serif'], script: ['Caveat', 'cursive'] },
          letterSpacing: { label: '0.18em' }
        }
      }
    }
  </script>
  <style>
    @view-transition { navigation: auto; }
    html { scroll-behavior: smooth; }
    [hidden] { display: none !important; }
    .reveal-ready [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; transition-delay: var(--reveal-delay, 0ms); }
    .reveal-ready [data-reveal].is-visible { opacity: 1; transform: none; }
    .stamp-ring { animation: spin 28s linear infinite; }
    @keyframes spin { to { transform: rotate(360deg); } }
    .slide { transition: opacity .6s ease; }
    .tin-slot img { transition: transform .3s ease; }
    @media (prefers-reduced-motion: reduce) { .stamp-ring { animation: none; } .slide { transition: none; } }
  </style>
</head>
<body class="bg-oat font-sans text-cocoa antialiased">
<!-- block:start hero -->
    <section id="hero" class="relative overflow-hidden bg-apricot" data-slider aria-roledescription="carousel" aria-label="This season at Brambleby">
      <div class="relative mx-auto grid min-h-[620px] max-w-7xl px-5 pb-20 pt-8 md:px-10">
          <div class="slide col-start-1 row-start-1 grid items-center gap-10 lg:grid-cols-[minmax(0,1.15fr)_minmax(0,0.85fr)] " data-slide  role="group" aria-roledescription="slide" aria-label="1 of 2">
            <div class="relative z-10">
              <p class="font-script text-3xl text-rust">Wild little treats</p>
              <h1 class="mt-3 font-display text-5xl font-bold uppercase leading-[0.95] text-white drop-shadow-[0_2px_0_rgba(156,79,46,0.35)] md:text-7xl lg:text-[5.5rem]">Biscuits with a wild streak</h1>
              <p class="mt-6 max-w-lg text-lg text-cocoa-soft">Rye, hazelnut and dark chocolate, rolled by hand in our forest-edge kitchen and baked in small trays every morning.</p>
              <div class="mt-9 flex flex-wrap items-center gap-4">
                <a href="menu.html" class="border-2 border-white px-7 py-3 font-display text-sm font-semibold uppercase tracking-label text-white hover:bg-white hover:text-rust">Taste the range</a>
                <a href="stockists.html" class="font-display text-sm font-semibold uppercase tracking-label text-cocoa underline decoration-rust decoration-2 underline-offset-8">Find a stockist</a>
              </div>
            </div>
            <div class="relative mx-auto w-full max-w-[460px]">
              <div class="absolute inset-6 translate-x-8 translate-y-10 rounded-full bg-rust/25 blur-2xl" aria-hidden="true"></div>
              <img src="https://images.unsplash.com/photo-1597733153203-a54d0fbc47de?auto=format&amp;fit=crop&amp;w=900&amp;q=80" alt="A single chocolate rye biscuit with a few crumbs beside it" class="relative aspect-square w-full rounded-full object-cover shadow-[24px_32px_0_rgba(156,79,46,0.18)]">
              <div class="absolute -left-4 -top-4 hidden h-32 w-32 md:block" aria-hidden="true">
                <svg viewBox="0 0 120 120" class="stamp-ring h-full w-full text-rust">
                  <defs><path id="stamp-path-0" d="M60 60 m-46 0 a46 46 0 1 1 92 0 a46 46 0 1 1 -92 0"></path></defs>
                  <circle cx="60" cy="60" r="58" fill="#f8ece7"></circle>
                  <text font-family="Josefin Sans" font-size="10.5" font-weight="700" letter-spacing="3" fill="currentColor"><textPath href="#stamp-path-0">ORGANIC · BAKED BY HAND · SMALL BATCH ·</textPath></text>
                </svg>
                <span class="absolute inset-0 grid place-items-center font-script text-3xl font-bold text-rust">B.</span>
              </div>
            </div>
          </div>
          <div class="slide col-start-1 row-start-1 grid items-center gap-10 lg:grid-cols-[minmax(0,1.15fr)_minmax(0,0.85fr)] pointer-events-none opacity-0" data-slide aria-hidden="true" role="group" aria-roledescription="slide" aria-label="2 of 2">
            <div class="relative z-10">
              <p class="font-script text-3xl text-rust">New this autumn</p>
              <h2 class="mt-3 font-display text-5xl font-bold uppercase leading-[0.95] text-white drop-shadow-[0_2px_0_rgba(156,79,46,0.35)] md:text-7xl lg:text-[5.5rem]">Honey, thyme and a little salt</h2>
              <p class="mt-6 max-w-lg text-lg text-cocoa-soft">Our autumn tin pairs heather honey with lemon thyme sablés. Twelve biscuits, two flavours, one very good afternoon.</p>
              <div class="mt-9 flex flex-wrap items-center gap-4">
                <a href="reservations.html" class="border-2 border-white px-7 py-3 font-display text-sm font-semibold uppercase tracking-label text-white hover:bg-white hover:text-rust">Bake it with us</a>
                <a href="stockists.html" class="font-display text-sm font-semibold uppercase tracking-label text-cocoa underline decoration-rust decoration-2 underline-offset-8">Find a stockist</a>
              </div>
            </div>
            <div class="relative mx-auto w-full max-w-[460px]">
              <div class="absolute inset-6 translate-x-8 translate-y-10 rounded-full bg-rust/25 blur-2xl" aria-hidden="true"></div>
              <img src="https://images.unsplash.com/photo-1548365328-8c6db3220e4c?auto=format&amp;fit=crop&amp;w=900&amp;q=80" alt="Stack of golden biscuits next to a glass of milk" class="relative aspect-square w-full rounded-full object-cover shadow-[24px_32px_0_rgba(156,79,46,0.18)]">
              <div class="absolute -left-4 -top-4 hidden h-32 w-32 md:block" aria-hidden="true">
                <svg viewBox="0 0 120 120" class="stamp-ring h-full w-full text-rust">
                  <defs><path id="stamp-path-1" d="M60 60 m-46 0 a46 46 0 1 1 92 0 a46 46 0 1 1 -92 0"></path></defs>
                  <circle cx="60" cy="60" r="58" fill="#f8ece7"></circle>
                  <text font-family="Josefin Sans" font-size="10.5" font-weight="700" letter-spacing="3" fill="currentColor"><textPath href="#stamp-path-1">ORGANIC · BAKED BY HAND · SMALL BATCH ·</textPath></text>
                </svg>
                <span class="absolute inset-0 grid place-items-center font-script text-3xl font-bold text-rust">B.</span>
              </div>
            </div>
          </div>
      </div>
      <button type="button" data-slide-prev aria-label="Previous slide" class="absolute left-2 top-1/2 z-20 hidden h-12 w-12 -translate-y-1/2 place-items-center text-3xl text-white hover:text-rust md:grid"><i class="fa-solid fa-chevron-left" aria-hidden="true"></i></button>
      <button type="button" data-slide-next aria-label="Next slide" class="absolute right-2 top-1/2 z-20 hidden h-12 w-12 -translate-y-1/2 place-items-center text-3xl text-white hover:text-rust md:grid"><i class="fa-solid fa-chevron-right" aria-hidden="true"></i></button>
      <div class="absolute bottom-7 left-1/2 z-20 flex -translate-x-1/2 gap-3">
          <button type="button" data-slide-dot aria-label="Show slide 1" aria-current="true" class="h-3 w-3 rounded-full border-2 border-white bg-white"></button>
          <button type="button" data-slide-dot aria-label="Show slide 2" aria-current="false" class="h-3 w-3 rounded-full border-2 border-white bg-transparent"></button>
      </div>
    </section>
    <!-- block:end hero -->
<script>
    document.querySelectorAll('[data-menu-toggle]').forEach((button) => {
      const menu = document.getElementById(button.getAttribute('aria-controls'));
      if (!menu) return;
      button.addEventListener('click', () => {
        const open = button.getAttribute('aria-expanded') === 'true';
        button.setAttribute('aria-expanded', String(!open));
        menu.classList.toggle('hidden', open);
      });
    });

    (() => {
      const items = document.querySelectorAll('[data-reveal]');
      const skip = navigator.webdriver || !('IntersectionObserver' in window) || matchMedia('(prefers-reduced-motion: reduce)').matches;
      if (!items.length || skip) return;
      document.documentElement.classList.add('reveal-ready');
      const observer = new IntersectionObserver((entries) => {
        entries.forEach((entry) => {
          if (!entry.isIntersecting) return;
          entry.target.classList.add('is-visible');
          observer.unobserve(entry.target);
        });
      }, { rootMargin: '0px 0px -10% 0px' });
      items.forEach((item) => observer.observe(item));
    })();

    document.querySelectorAll('[data-slider]').forEach((slider) => {
      const slides = [...slider.querySelectorAll('[data-slide]')];
      const dots = [...slider.querySelectorAll('[data-slide-dot]')];
      let current = 0;
      const show = (index) => {
        current = (index + slides.length) % slides.length;
        slides.forEach((slide, i) => {
          const active = i === current;
          slide.classList.toggle('opacity-0', !active);
          slide.classList.toggle('pointer-events-none', !active);
          slide.setAttribute('aria-hidden', String(!active));
        });
        dots.forEach((dot, i) => {
          dot.setAttribute('aria-current', String(i === current));
          dot.classList.toggle('bg-white', i === current);
          dot.classList.toggle('bg-transparent', i !== current);
        });
      };
      slider.querySelector('[data-slide-prev]')?.addEventListener('click', () => show(current - 1));
      slider.querySelector('[data-slide-next]')?.addEventListener('click', () => show(current + 1));
      dots.forEach((dot, i) => dot.addEventListener('click', () => show(i)));
    });

    document.querySelectorAll('[data-tabs]').forEach((list) => {
      const tabs = [...list.querySelectorAll('[data-tab]')];
      const select = (tab) => {
        tabs.forEach((other) => {
          const active = other === tab;
          other.setAttribute('aria-selected', String(active));
          other.tabIndex = active ? 0 : -1;
          document.getElementById(other.getAttribute('aria-controls')).hidden = !active;
        });
      };
      tabs.forEach((tab, index) => {
        tab.addEventListener('click', () => select(tab));
        tab.addEventListener('keydown', (event) => {
          if (!['ArrowRight', 'ArrowLeft'].includes(event.key)) return;
          const next = tabs[(index + (event.key === 'ArrowRight' ? 1 : -1) + tabs.length) % tabs.length];
          select(next);
          next.focus();
        });
      });
    });

    document.querySelectorAll('[data-tin]').forEach((root) => {
      const slots = [...root.querySelectorAll('[data-tin-slot]')];
      const options = [...root.querySelectorAll('[data-tin-add]')];
      const note = root.querySelector('[data-tin-note]');
      const order = root.querySelector('[data-tin-order]');
      const tin = [];
      const render = () => {
        slots.forEach((slot, i) => {
          const item = tin[i];
          slot.innerHTML = item ? `<img src="${item.img}" alt="" class="aspect-square w-full rounded-full object-cover">` : '';
          slot.disabled = !item;
          slot.setAttribute('aria-label', item ? `Remove ${item.name}` : 'Empty space');
          slot.classList.toggle('border-dashed', !item);
        });
        const total = 4 + tin.reduce((sum, item) => sum + item.price, 0);
        root.querySelector('[data-tin-count]').textContent = tin.length;
        root.querySelector('[data-tin-total]').textContent = total.toFixed(2);
        note.hidden = tin.length < slots.length;
        order.classList.toggle('opacity-50', !tin.length);
      };
      const add = (button) => {
        if (tin.length >= slots.length) { note.hidden = false; return; }
        tin.push({ name: button.dataset.name, price: Number(button.dataset.price), img: button.dataset.img });
        render();
      };
      options.forEach((button) => button.addEventListener('click', () => add(button)));
      slots.forEach((slot, i) => slot.addEventListener('click', () => { tin.splice(i, 1); render(); }));
      root.querySelector('[data-tin-random]').addEventListener('click', () => {
        tin.length = 0;
        slots.forEach(() => add(options[Math.floor(Math.random() * options.length)]));
      });
      ['rye', 'rye', 'oat', 'honey', 'hazel', 'choc', 'oat'].forEach((key) => add(root.querySelector(`[data-tin-add="${key}"]`)));
    });

    document.querySelectorAll('[data-like]').forEach((button) => {
      button.addEventListener('click', () => {
        const liked = button.getAttribute('aria-pressed') === 'true';
        const count = button.querySelector('[data-like-count]');
        button.setAttribute('aria-pressed', String(!liked));
        count.textContent = Number(count.textContent) + (liked ? -1 : 1);
      });
    });

    document.querySelectorAll('[data-success-form]').forEach((form) => {
      form.addEventListener('submit', (event) => {
        event.preventDefault();
        if (!form.reportValidity()) return;
        form.querySelector('[data-success]').hidden = false;
        form.reset();
      });
    });
  </script>
<!-- Optional credit — delete this block if you prefer a clean footer -->
<p class="lt-built-with" style="margin:0;padding:12px 16px;text-align:center;font:500 11px/1.4 system-ui,-apple-system,sans-serif;color:#9ca3af;">Built with <a href="https://letstemplates.com" style="color:#059669;text-decoration:none;">Let's templates</a></p>
</body>
</html>

De esta plantilla

Brambleby screenshot Premium

Comida y restaurantes

Brambleby

Acceso ilimitado a todos los productos

Desbloquea toda la biblioteca de plantillas y bloques premium. Se renueva automáticamente, cancela cuando quieras.

20 € / 3 meses o 60 € / año
Conseguir acceso ilimitado