/*
Theme Name: first
Theme URI: https://example.com/
Author: Akiho
Description: Stitch design based WordPress theme for Lumiere Journal styles.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 7.4
Text Domain: stitch-lumiere
*/

/*
 * Base styles shared across the theme.
 * Layout utilities live in assets/utilities.css.
 */

:root {
  --new-journal-font: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Zen Maru Gothic", "Yu Gothic", "Meiryo", "Noto Sans JP", sans-serif;
  --new-journal-en-font: "Plus Jakarta Sans", "Noto Sans JP", sans-serif;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: var(--new-journal-font);
}

img {
  max-width: 100%;
  height: auto;
}

.comments-area .comment {
  list-style: none;
}

.comments-area .comment-body {
  border: 1px solid rgba(238, 43, 91, 0.12);
  border-radius: 0.75rem;
  padding: 1rem;
  background: #fff;
}

.comments-area .comment-meta {
  margin-bottom: 0.5rem;
  font-size: 0.75rem;
}

.comments-area .reply a,
.comments-area .comment-metadata a {
  color: #ee2b5b;
}

.js-like-toggle.is-liked {
  background-color: #2d4a3e !important;
}

.profile-avatar-image {
  object-position: 44% 82%;
}

.serif-title,
.site-header h1.serif-title a,
footer h2.serif-title a {
  font-family: var(--new-journal-font) !important;
  letter-spacing: 0.005em;
  font-weight: 700;
}

/* Keep English UI text in the same font as "New Journal". */
.site-header nav a,
footer nav a,
.site-header input[type="search"],
.site-header input[type="search"]::placeholder,
.uppercase,
.tracking-widest,
.comment-reply-link,
.page-numbers,
.wp-block-button__link,
.en-ui {
  font-family: var(--new-journal-en-font) !important;
}

.site-header .header-inner > .flex.items-center.gap-10 {
  flex: 1 1 auto;
  min-width: 0;
  gap: 0.45rem !important;
  flex-direction: column;
  align-items: flex-start;
}

.site-header .header-inner > .flex.items-center.gap-10 > .flex.items-center.gap-3 {
  min-width: 0;
}

.site-header h1.serif-title {
  min-width: 0;
  max-width: none;
  margin: 0;
}

.site-header h1.serif-title a {
  display: inline-flex;
  flex-direction: row;
  align-items: baseline;
  gap: 0.22rem;
  line-height: 1.1;
  white-space: nowrap;
}

footer h2.serif-title a {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.1;
  white-space: normal;
}

.site-brand-main {
  display: block;
}

.site-brand-main-top,
.site-brand-main-bottom {
  display: inline;
}

.site-brand-sub {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.56em;
  line-height: 1.2;
  font-weight: 600;
  opacity: 0.88;
}

.site-header .site-brand-sub {
  display: inline;
  margin-top: 0;
  font-size: 0.58em;
  line-height: 1.18;
}

.site-header nav.hidden.items-center.gap-8 {
  display: flex !important;
}

.site-header nav.hidden.items-center.gap-8 a {
  font-size: 0.82rem !important;
}

.category-list-card .category-list-thumb {
  width: min(100%, 24rem) !important;
  min-width: min(100%, 24rem) !important;
  aspect-ratio: 16 / 9 !important;
  max-height: none !important;
}

@media (min-width: 1024px) {
  .site-header nav.hidden.items-center.gap-8 {
    gap: 1.25rem !important;
  }
}

@media (max-width: 767px) {
  .site-header .header-inner {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    padding-top: 0.6rem !important;
    padding-bottom: 0.6rem !important;
  }

  .site-header h1.serif-title {
    width: 100%;
    max-width: 100%;
    font-size: 1.2rem !important;
    line-height: 1.2;
  }

  .site-header .header-inner > .flex.items-center.gap-10 {
    gap: 0.5rem !important;
    min-width: 0;
    flex: 1 1 auto;
    width: auto;
    align-items: flex-start;
  }

  .site-header nav.hidden.items-center.gap-8 {
    display: flex !important;
    flex-wrap: wrap;
    row-gap: 0.25rem;
    gap: 0.7rem !important;
  }

  .site-header .header-inner > .flex.items-center.gap-4 {
    flex: 0 0 auto;
    width: auto;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.5rem !important;
    padding-top: 0.15rem;
  }

  .site-header h1.serif-title a {
    display: flex;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.06rem;
    white-space: normal;
    line-height: 1.15;
  }

  .site-header .site-brand-main {
    white-space: normal;
  }

  .site-header .site-brand-main-top,
  .site-header .site-brand-main-bottom {
    display: inline;
  }

  .site-header .site-brand-sub {
    display: block;
    margin-top: 0.16rem;
    line-height: 1.2;
  }

  .site-header form[action][method="get"] {
    width: 2.5rem !important;
    min-width: 2.5rem !important;
    max-width: 2.5rem !important;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-left: 0.6rem !important;
    padding-right: 0.6rem !important;
    overflow: hidden;
    transition: width 0.25s ease, max-width 0.25s ease, padding 0.25s ease, box-shadow 0.25s ease;
  }

  .site-header form[action][method="get"] .material-symbols-outlined {
    font-size: 1.6rem;
    flex: 0 0 auto;
  }

  .site-header form[action][method="get"] input[type="search"] {
    font-size: 0.75rem;
    min-width: 0;
    width: 0;
    opacity: 0;
    flex: 0 0 0;
    padding-left: 0 !important;
    padding-right: 0 !important;
    transition: width 0.2s ease, opacity 0.2s ease, padding 0.2s ease;
  }

  .site-header form[action][method="get"].is-search-expanded,
  .site-header form[action][method="get"]:focus-within {
    width: min(40vw, 8.5rem) !important;
    min-width: min(40vw, 8.5rem) !important;
    max-width: min(40vw, 8.5rem) !important;
    height: 2.5rem;
    justify-content: flex-start;
    padding-left: 0.8rem !important;
    padding-right: 0.8rem !important;
  }

  .site-header form[action][method="get"].is-search-expanded input[type="search"],
  .site-header form[action][method="get"]:focus-within input[type="search"] {
    width: 100%;
    opacity: 1;
    flex: 1 1 auto;
    padding-left: 0.35rem !important;
    padding-right: 0.1rem !important;
  }

  [class*="min-h-[400px]"] {
    min-height: 220px !important;
  }

  [class*="aspect-[21/9]"] {
    aspect-ratio: 16 / 9 !important;
    max-height: 220px !important;
  }

  [class*="aspect-[16/10]"] {
    aspect-ratio: 16 / 11 !important;
    max-height: 190px !important;
  }

  [class*="aspect-[16/10]"] img,
  [class*="aspect-[21/9]"] img {
    object-fit: cover;
  }

  .journal-list-card {
    display: flex !important;
    flex-direction: row !important;
    gap: 0.75rem !important;
    align-items: stretch;
  }

  .journal-list-card .journal-list-thumb {
    width: 120px !important;
    min-width: 120px !important;
    max-height: none !important;
    height: auto !important;
    aspect-ratio: auto !important;
    align-self: stretch;
  }

  .category-list-card .category-list-thumb {
    width: 132px !important;
    min-width: 132px !important;
    max-height: none !important;
    height: auto !important;
    aspect-ratio: auto !important;
    align-self: stretch;
  }

  .journal-list-card .journal-list-thumb > a,
  .category-list-card .category-list-thumb > a {
    display: block;
    height: 100%;
  }

  .journal-list-card .journal-list-thumb > a:first-child,
  .category-list-card .category-list-thumb > a:first-child {
    display: inline-flex;
    height: auto;
  }

  .journal-list-card h4 {
    font-size: 1rem !important;
    line-height: 1.35 !important;
  }

  .journal-list-card p {
    font-size: 0.8125rem !important;
  }
}
