@charset "UTF-8";

/*!
Theme Name: Cocoon Child (R11R Redesign + PixelMplus)
Template: cocoon-master
*/

/* ==========================================================================
   1. CSS Variables & Reset
   ========================================================================== */
@font-face {
  font-family: 'PixelMplus';
  src: url('https://cdn.jsdelivr.net/npm/pixel-mplus@1.0.1/PixelMplus10-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'PixelMplus';
  src: url('https://cdn.jsdelivr.net/npm/pixel-mplus@1.0.1/PixelMplus10-Bold.ttf') format('truetype');
  font-weight: bold;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-color: #ffffff;
  --text-color: #111111;
  --text-light: #666666;
  --border-color: #e5e5e5;
  --black: #000000;
  --font-en: 'PixelMplus', 'Helvetica Neue', Arial, sans-serif;
  --font-jp: 'PixelMplus', sans-serif;
}

html {
  scroll-behavior: auto; /* Handled by JS */
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-jp);
  background-color: var(--bg-color);
  color: var(--text-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  image-rendering: pixelated;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-en);
  margin: 0;
  line-height: 1.2;
}

p {
  margin: 0 0 1.5em;
  line-height: 1.8;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

a:hover {
  opacity: 0.6;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  image-rendering: pixelated;
}

/* ==========================================================================
   2. Header & Navigation
   ========================================================================== */
.r11r-header {
  position: fixed;
  top: 0 !important;
  left: 0;
  width: 100%;
  margin: 0 !important;
  transform: none !important;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 40px;
  box-sizing: border-box;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--black);
}

/* ログイン時のWPアドミンバー（黒い上部バー）との被り防止 */
body.admin-bar .r11r-header {
  top: 32px !important;
}
@media (max-width: 782px) {
  body.admin-bar .r11r-header {
    top: 46px !important;
  }
}

.r11r-logo a {
  font-family: var(--font-en);
  font-size: 24px;
  font-weight: bold;
  letter-spacing: 1px;
}

.r11r-nav {
  display: flex;
  gap: 30px;
}

.nav-break {
  display: none;
}

.r11r-nav a {
  font-family: var(--font-en);
  font-size: 14px;
  font-weight: bold;
  text-transform: uppercase;
  position: relative;
  padding-bottom: 5px;
}

.r11r-nav a::after {
  content: "";
  position: absolute;
  bottom: 0px;
  left: 0;
  width: 0%;
  height: 3px;
  background-color: var(--black);
  transition: width 0.3s ease;
}

/* Active styles */
.r11r-nav a.active::after {
  width: 100%;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: 5px;
}
.r11r-nav .lang-switcher a {
  padding-bottom: 0;
  opacity: 0.5;
}
.r11r-nav .lang-switcher a:hover {
  opacity: 0.8;
}
.r11r-nav .lang-switcher a.active {
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 2px;
}
.r11r-nav .lang-switcher a::after {
  display: none !important;
}
.lang-switcher span.separator {
  opacity: 0.3;
  font-weight: normal;
}

/* Active styles */
.r11r-nav a.active::after,
.mobile-nav a.active::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--black);
}

/* Hover styles separately strictly for mouse capable devices to stop mobile sticky hover */
@media (hover: hover) {
  .r11r-nav a:hover::after,
  .mobile-nav a:hover::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--black);
  }
}

.hamburger-button, .nav-overlay {
  display: none !important;
}

@media (max-width: 767px) {
  .r11r-header {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
  }
  .r11r-logo {
    margin-bottom: 0;
    margin-right: 15px;
    flex-shrink: 0;
  }
  .r11r-logo a {
    font-size: 30px;
    line-height: 1.0;
    display: block;
    max-width: 150px; /* 自動で BESTIA と WORKS を2段にしてスペースを節約 */
  }
  .r11r-nav {
    gap: 8px 12px;
    flex-wrap: wrap;
    flex: 1;
    justify-content: flex-end;
    overflow-x: visible;
  }
  .nav-break {
    display: block;
    width: 100%;
    height: 0;
  }
  .r11r-nav::-webkit-scrollbar {
    display: none;
  }
  .r11r-nav a {
    font-size: 11px;
    padding-bottom: 2px;
  }
  .lang-switcher {
    order: -1;
    width: 100%;
    justify-content: flex-end;
    margin-bottom: 4px;
  }
}

/* ==========================================================================
   3. Hero Section & Marquee
   ========================================================================== */
.r11r-hero {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: 80px;
  box-sizing: border-box;
}

.marquee-container {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  transform: translateY(-50%);
  white-space: nowrap;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.marquee-content {
  display: inline-block;
  animation: marquee 40s linear infinite;
  font-family: var(--font-en);
  font-size: clamp(60px, 12vw, 150px);
  font-weight: bold;
  color: rgba(0,0,0,0.03);
  text-transform: uppercase;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.hero-center-content {
  position: relative;
  z-index: 1;
  text-align: center;
  width: 95%;
  max-width: 1000px;
  margin-top: -5vh; /* 画面に対して上にシフト */
}

.hero-center-content .main-title {
  font-size: clamp(40px, 8vw, 80px);
  font-weight: bold;
  line-height: 1.1;
  margin-bottom: 20px;
  letter-spacing: 2px;
}

.hero-catchphrase {
  margin-top: 20px;
}

.hero-catchphrase .catchphrase-main-jp {
  font-size: clamp(20px, 4vw, 32px);
  font-weight: bold;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.hero-catchphrase .catchphrase-main {
  font-family: var(--font-en);
  font-size: clamp(18px, 3.5vw, 28px);
  font-weight: bold;
  letter-spacing: 3px;
  margin-bottom: 8px;
}

.hero-catchphrase .catchphrase-sub {
  font-family: var(--font-en);
  font-size: clamp(10px, 2vw, 14px);
  letter-spacing: 2px;
  color: #333;
}

/* Option C: Boxed GIF Frame in Hero */
.hero-gif-frame {
  width: 100%;
  max-width: 880px;
  aspect-ratio: 16/9;
  border: 4px solid var(--black);
  margin: 0 auto 40px;
  position: relative;
  overflow: hidden;
  box-shadow: 12px 12px 0 var(--black);
  background: #000;
}

.hero-gif-frame .background-gif {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('images/background.gif');
  background-size: cover;
  background-position: center;
  image-rendering: pixelated;
  /* subtle animation so it feels alive */
  animation: pulse 10s infinite alternate;
}

@keyframes pulse {
  0% { transform: scale(1); }
  100% { transform: scale(1.05); }
}

.scroll-down {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-en);
  font-size: 12px;
  font-weight: bold;
  letter-spacing: 2px;
  animation: bounce 2s infinite;
  z-index: 2;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
  40% { transform: translateX(-50%) translateY(-10px); }
  60% { transform: translateX(-50%) translateY(-5px); }
}

/* ==========================================================================
   4. Sections Shared Styles
   ========================================================================== */
.r11r-section {
  padding: 120px 5%;
}

.section-container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  margin-bottom: 80px;
  border-bottom: 4px solid var(--black);
  padding-bottom: 20px;
}

.section-title {
  font-size: clamp(30px, 6vw, 60px);
  font-weight: bold;
  line-height: 1;
  margin-bottom: 10px;
}

.section-subtitle {
  font-family: var(--font-en);
  font-size: 16px;
  font-weight: bold;
  color: var(--text-light);
  letter-spacing: 2px;
}

.section-header.dark {
  border-bottom: 4px solid var(--bg-color);
}

.section-header.dark .section-title,
.section-header.dark .section-subtitle {
  color: var(--bg-color);
}

/* ==========================================================================
   5. About Section
   ========================================================================== */
.about-content {
  display: flex;
  flex-direction: column;
  gap: 40px;
  align-items: center;
  text-align: center;
}

@media (min-width: 900px) {
  .about-content {
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
    gap: 60px;
  }
}

.about-image-wrapper {
  flex: 0 0 auto;
  width: 100%;
  max-width: 200px;
  border: 4px solid var(--black);
  box-shadow: 10px 10px 0 var(--black);
  padding: 10px;
  background: var(--bg-color);
  box-sizing: border-box;
}

@media (min-width: 900px) {
  .about-image-wrapper {
    flex: 0 0 250px;
    max-width: 250px;
    box-shadow: 12px 12px 0 var(--black);
  }
}

.about-avatar {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  image-rendering: pixelated;
  border: 2px solid var(--black);
}

.about-text-wrapper {
  flex: 1;
  padding-top: 20px;
}

.about-name {
  font-size: 40px;
  font-weight: bold;
  margin-bottom: 10px;
}

.about-role {
  font-size: 16px;
  font-weight: bold;
  color: var(--black);
  margin-bottom: 30px;
  display: inline-block;
  background: #eee;
  padding: 5px 15px;
  border: 2px solid var(--black);
}

.about-desc {
  font-size: 16px;
  line-height: 2;
  color: var(--black);
}

.about-socials {
  display: flex;
  gap: 20px;
  margin-top: 40px;
}

.about-social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background: var(--black);
  color: var(--bg-color);
  border: 4px solid var(--black);
  transition: all 0.3s ease;
}

.about-social-icon:hover {
  background: var(--bg-color);
  color: var(--black);
}

.about-social-icon svg {
  width: 30px;
  height: 30px;
  fill: currentColor;
}

.about-social-icon.bsky-icon {
  color: #1185fe;
  border-color: #1185fe;
}

.about-social-icon.bsky-icon:hover {
  background: #1185fe;
  color: var(--bg-color);
}

/* Swup SPA Transitions */
.transition-fade {
  transition: opacity 0.4s ease-in-out, transform 0.4s ease-in-out;
  opacity: 1;
  transform: translateY(0);
}
html.is-animating .transition-fade {
  opacity: 0;
  transform: translateY(10px);
}
html.is-leaving .transition-fade {
  opacity: 0;
  transform: translateY(-10px);
}

/* Contact Form 7 必須マーク非表示設定 */
.CF7_req {
  display: none !important;
}

/* Global Language Switcher Support */
html.lang-en-active .lang-jp { display: none !important; }
html:not(.lang-en-active) .lang-en { display: none !important; }

/* ==========================================================================
   6. Works / Gallery Section
   ========================================================================== */
.bg-black {
  background-color: var(--black);
  color: var(--bg-color);
}

.bg-black .section-subtitle {
  color: #ccc;
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 40px;
  margin-bottom: 60px;
}

.work-item {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1/1;
  background: #1a1a1a;
  border: 4px solid var(--bg-color);
  transition: transform 0.3s ease;
}

.work-item:hover {
  transform: translateY(-5px);
  box-shadow: 8px 8px 0 var(--bg-color);
}

.work-item-hidden {
  display: none;
}

.work-image {
  width: 100%;
  height: 100%;
  position: relative;
}

.work-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.work-item:hover .work-image img {
  transform: scale(1.05);
  filter: brightness(0.6);
}

.work-hover {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  opacity: 0;
  box-sizing: border-box;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.work-item:hover .work-hover {
  opacity: 1;
}

.work-title {
  color: #fff;
  font-size: 20px;
  margin-bottom: 5px;
  text-shadow: 2px 2px 0 #000;
}

.work-cat {
  color: #fff;
  font-family: var(--font-en);
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 15px;
  text-shadow: 2px 2px 0 #000;
}

/* Button */
.center-btn {
  text-align: center;
}

.r11r-button {
  display: inline-block;
  padding: 15px 40px;
  border: 4px solid var(--bg-color);
  background: var(--black);
  color: var(--bg-color);
  font-family: var(--font-en);
  font-size: 16px;
  font-weight: bold;
  letter-spacing: 2px;
  transition: all 0.3s ease;
  box-shadow: 6px 6px 0 var(--bg-color);
}

.r11r-button.dark {
  border-color: var(--black);
  background: var(--bg-color);
  color: var(--black);
  box-shadow: 6px 6px 0 var(--black);
}

.r11r-button:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--bg-color);
}

.r11r-button.dark:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--black);
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   7. Contact Form
   ========================================================================== */
.contact-wrapper {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px;
  border: 4px solid var(--black);
  box-shadow: 15px 15px 0 var(--black);
}

.contact-lead {
  font-size: 18px;
  margin-bottom: 15px;
  text-align: center;
  font-weight: bold;
}

.wpcf7-form br,
.wpcf7-form p:empty {
  display: none !important;
}

.wpcf7-form p {
  display: flex !important;
  flex-direction: column !important;
  margin-bottom: 15px;
  font-weight: bold;
}

.wpcf7-form p:last-of-type {
  margin-bottom: 0 !important;
}

.wpcf7-form table, 
.wpcf7-form tbody, 
.wpcf7-form tr, 
.wpcf7-form th, 
.wpcf7-form td {
  display: block !important;
  width: 100% !important;
  border: none !important;
  padding: 0 !important;
}

.wpcf7-form th {
  padding-bottom: 5px !important;
  text-align: left !important;
}

.wpcf7-form td {
  padding-bottom: 25px !important;
}

.wpcf7-form-control-wrap {
  display: block;
  margin-top: 4px;
}

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea {
  display: block;
  width: 100%;
  background: var(--bg-color);
  border: 4px solid var(--black);
  padding: 15px;
  font-size: 16px;
  font-family: var(--font-jp);
  transition: background 0.3s ease;
  box-sizing: border-box;
}

/* Prominent decoration for REQUIRED fields */
.wpcf7 input[aria-required="true"],
.wpcf7 textarea[aria-required="true"] {
  border-left: 12px solid #e60012;
  background-color: #fffcfc;
}

.wpcf7 input:focus,
.wpcf7 textarea:focus {
  outline: none;
  background: #f4f4f4;
}

.wpcf7 input[type="submit"] {
  background: var(--bg-color);
  color: var(--black);
  border: 4px solid var(--black);
  padding: 20px 60px;
  font-family: var(--font-en);
  font-size: 18px;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  width: 100%;
  transition: all 0.3s ease;
  box-shadow: 6px 6px 0 var(--black);
}

.wpcf7 input[type="submit"]:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--black);
}

@media (max-width: 767px) {
  .r11r-section {
    padding: 60px 4%;
  }
  .section-title {
    font-size: 32px;
  }
  .contact-wrapper {
    padding: 20px 15px;
    box-shadow: 8px 8px 0 var(--black);
    border-width: 3px;
  }
  .contact-lead {
    font-size: 15px;
    margin-bottom: 25px;
  }
  .wpcf7 input[type="text"],
  .wpcf7 input[type="email"],
  .wpcf7 input[type="tel"],
  .wpcf7 textarea {
    padding: 10px;
    border-width: 3px;
  }
  .wpcf7 input[type="submit"] {
    padding: 15px;
    font-size: 16px;
    border-width: 3px;
    box-shadow: 4px 4px 0 var(--black);
  }
}

/* ==========================================================================
   8. Footer & Privacy Modal
   ========================================================================== */
.r11r-footer {
  padding: 60px 5%;
  border-top: 4px solid var(--black);
  text-align: center;
}

.footer-logo {
  font-family: var(--font-en);
  font-size: 32px;
  font-weight: bold;
  margin-bottom: 20px;
}

.footer-links {
  margin-bottom: 20px;
}

.footer-links a {
  font-size: 16px;
  font-weight: bold;
  text-decoration: underline;
}

.footer-copy {
  font-size: 14px;
  font-weight: bold;
}

.r11r-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(5px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.r11r-modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--bg-color);
  width: 90%;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  padding: 50px;
  position: relative;
  box-sizing: border-box;
  border: 4px solid var(--black);
  box-shadow: 15px 15px 0 var(--black);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
}

.modal-title {
  font-size: 30px;
  margin-bottom: 30px;
  border-bottom: 4px solid var(--black);
  padding-bottom: 15px;
}

/* ==========================================================================
   9. WordPress / Cocoon Default Overrides
   ========================================================================== */
.header,
#header,
.logo-header,
.logo-image,
.site-name-text,
#navi,
.global-nav,
.footer,
#footer,
.breadcrumb {
  display: none !important;
}

img[src*="BestiaWorks_001.png"] {
  display: none !important;
}

/* Hide reCAPTCHA badge */
.grecaptcha-badge {
  visibility: hidden !important;
}

/* ==========================================================================
   10. Mobile Browser Native Tap Highlight Clear
   ========================================================================== */
.r11r-nav a,
.mobile-nav a,
.nav-link {
  -webkit-tap-highlight-color: transparent !important;
}

.r11r-nav a:focus,
.mobile-nav a:focus,
.nav-link:focus,
.r11r-nav a:active,
.mobile-nav a:active,
.nav-link:active {
  background-color: transparent !important;
  outline: none !important;
}

/* ==========================================================================
   11. Adjust 100vh for Mobile Safari & Dynamic Screen Height
   ========================================================================== */
.r11r-hero {
  min-height: 100vh;
  min-height: 100dvh; /* Dynamic sizing avoids being hidden by mobile browser UI bars */
}

.scroll-down {
  bottom: max(30px, 6dvh);
}

/* ==========================================================================
   12. Modals (Privacy / KemoMap)
   ========================================================================== */
.r11r-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background-color: rgba(0, 0, 0, 0.8);
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}

.r11r-modal.active {
  display: flex !important;
}

.r11r-modal .modal-content {
  background-color: var(--white);
  padding: 30px 40px;
  border: 4px solid var(--black);
  box-shadow: 12px 12px 0 var(--black);
  max-width: 800px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
}

.r11r-modal .modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 32px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
}

.r11r-modal .modal-close:hover {
  color: #666;
}

.r11r-modal .modal-title {
  font-family: var(--font-en);
  font-size: 24px;
  margin-bottom: 20px;
  border-bottom: 3px solid var(--black);
  padding-bottom: 10px;
}

.r11r-modal .modal-body h3 {
  font-size: 16px;
  margin-top: 25px;
  margin-bottom: 10px;
  border-left: 4px solid var(--black);
  padding-left: 10px;
}

.r11r-modal .modal-body p,
.r11r-modal .modal-body ul {
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 15px;
}

.r11r-modal .modal-body ul {
  padding-left: 20px;
}

.r11r-modal .policy-date {
  margin-top: 30px;
  text-align: right;
  font-size: 14px;
  font-weight: bold;
}
