/* Compact site header on computers and tablets (partials/site_header.html).
   Loaded after style.css and responsive.css, so it replaces the older,
   much taller header sizes there. Phones: see mobile-header.css.

   - Round 112px author photo (same look as on phones)
   - Smaller site name and author name
   - Small cookbook with its label (mainapp/books.py) and "Här finns den att köpa"
     always shown beside it, so the right side of the header doesn't look
     empty and the book clearly reads as a link */

@media screen and (min-width: 769px) {
  .site-header {
    padding: 1.25rem 0;
  }

  /* Seasonal string of lights along the bottom edge: leave room for it */
  .site-header:has(.holiday-lights) {
    padding-bottom: calc(1.25rem + 20px);
  }

  .left-section {
    gap: 1.75rem;
    min-width: 0;
  }

  /* --- Author photo: round, without the big frame decorations --- */
  .author-image-container {
    width: 112px;
    height: 112px;
    flex-shrink: 0;
    border-width: 3px;
    border-radius: 50%;
    box-shadow:
      0 0 0 2px var(--accent-warm),
      0 0 0 5px #ffffff,
      0 6px 16px rgba(0, 0, 0, 0.25);
  }

  .author-image-container::before,
  .author-image-container::after,
  .author-frame::before,
  .author-frame::after {
    display: none;
  }

  /* --- Name --- */
  .blog-name {
    font-size: clamp(2.2rem, 3.2vw, 2.9rem);
  }

  .blog-name::after {
    bottom: -8px;
    width: 64px;
  }

  .author-name {
    font-size: clamp(1.1rem, 1.5vw, 1.35rem);
    margin: 0.9rem 0 0;
  }

  .tagline {
    display: none;
  }

  /* --- Cookbook: small, slightly turned, caption on its left --- */
  .header-book-section {
    margin-left: 1.5rem;
  }

  .header-book {
    width: 84px;
    height: 112px;
    aspect-ratio: auto;
    transform: none;
    animation: none;
  }

  .header-book-cover {
    transform: rotateY(-14deg);
    transition: transform 0.4s ease;
  }

  a.header-book:hover .header-book-cover,
  a.header-book:focus-visible .header-book-cover {
    transform: rotateY(-4deg) translateY(-3px);
  }

  .header-book-info {
    position: absolute;
    top: 50%;
    right: calc(100% + 18px);
    bottom: auto;
    left: auto;
    transform: translateY(-50%);
    opacity: 1;
    white-space: nowrap;
    text-align: right;
  }

  .header-book-title {
    font-size: 1.05rem;
  }

  .header-book-cta {
    font-size: 0.9rem;
  }

  a.header-book:hover .header-book-cta {
    text-decoration: underline;
  }
}

@media (prefers-reduced-motion: reduce) {
  .header-book-cover {
    transition: none;
  }
}
