/* ==========================================================================
   1. 基本スタイル (Global Settings)
   ========================================================================== */
html, body {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  height: auto !important;
  max-height: none !important;
  scroll-behavior: smooth;
  width: 100% !important;
  max-width: 100vw !important;
}

* {
  box-sizing: border-box !important;
}

@media(max-width: 450px) {
  html {
    font-size: 0.9rem !important;
  }
  body {
    word-break: keep-all !important;
    overflow-wrap: break-word !important;
  }
}

/* ==========================================================================
   2. 汎用・レイアウトスタイル (Layout & Utilities)
   ========================================================================== */
.profile-container {
  width: 100%;
  max-width: 100vw;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: #f8f9fa;
  overflow-x: hidden ;
  overflow-y: auto;
  height: auto;
}
.section-accent-line {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, #007bff 60%, #00c6ff 100%);
  border-radius: 2px;
  margin: 1.2rem auto 2rem auto;
  display: block;
  position: relative;
  z-index: 2;
  box-shadow: 0 1px 6px 0 rgba(0,0,0,0.08);
}

.profile-section {
  padding: 4rem 2rem;
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

.profile-section-title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--dl-color-secondary-400);
  margin-bottom: 2.5rem;
}

.text-center {
  text-align: center;
}

/* ==========================================================================
   3. セクション別スタイル (Page Sections)
   ========================================================================== */

/* --- Hero Section --- */
.profile-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 50vh;
  width: 100%;
  max-width: 100vw;
  overflow: hidden;
  color: white;
}

.profile-hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.profile-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.75));
  z-index: 0;
}

.profile-hero-content {
  max-width: 800px;
  position: relative;
  z-index: 0;
}

.profile-hero .profile-hero-content .profile-hero-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1rem;
  color: white !important;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.profile-hero .profile-hero-content .profile-hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  font-weight: 300;
  color: white !important;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

/* --- Introduction Section --- */
.profile-intro {
  max-width: 1320px;
  margin: 0 auto;
}

.profile-intro-flex {
  display: flex;
  align-items: center;
  gap: 3rem;
}

.profile-intro-text {
  flex: 2;
  color: #000000;
}

.profile-intro-text .profile-section-title {
  color: #000000;
}

.profile-intro-text p {
  margin-bottom: 1.5rem;
  line-height: 1.8;
  color: #000000;
}

.profile-intro-image {
  flex: 1;
  text-align: center;
}

.profile-image-main {
  width: 100%;
  max-width: 300px;
  height: auto;
  border-radius: 50%;
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
  border: 5px solid white;
}

/* --- Strengths Section --- */
.profile-strengths-bg {
  background-color: #ffffff;
}

.profile-strengths-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1320px;
  margin: 0 auto;
}

.profile-strength-card {
  background-color: #f8f9fa;
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile-strength-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.profile-strength-icon {
  font-size: 2rem;
  color: #007bff;
  margin-bottom: 1rem;
}

.profile-strength-card h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--dl-color-secondary-400);
  margin-bottom: 1rem;
}

.profile-strength-card p {
  color: #000000;
  line-height: 1.6;
}

/* --- Testimonials Section --- */
.profile-testimonials-container {
  display: flex;
  justify-content: center;
  gap: 2rem;
  max-width: 1320px;
  margin: 0 auto;
}

.profile-testimonial-card {
  background-color: #ffffff;
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
  width: 45%;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.profile-testimonial-image {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 1.5rem auto;
  box-shadow: 0 5px 10px rgba(0,0,0,0.1);
}

.profile-testimonial-text {
  font-style: italic;
  color: var(--dl-color-gray-700);
  margin-bottom: 1.5rem;
}

.profile-testimonial-author {
  font-weight: 600;
  color: var(--dl-color-secondary-400);
}

/* --- Profile Details Section --- */
.profile-details-bg {
  background-color: var(--dl-color-pimary-900);
}

.profile-details-bg .profile-section-title {
  color: var(--dl-color-secondary-100);
}

.profile-details-container {
  display: flex;
  justify-content: center;
  gap: 2rem;
  max-width: 1320px;
  margin: 0 auto;
}

.profile-details-card {
  background-color: #ffffff;
  padding: 2.5rem;
  border-radius: 8px;
  width: 50%;
}

.profile-details-card h3 {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--dl-color-secondary-400);
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--dl-color-pimary-500);
  padding-bottom: 0.5rem;
}

.profile-details-card p {
  margin-bottom: 1rem;
  line-height: 1.7;
  color: #000000;
}

/* --- Call to Action (CTA) Section --- */
.profile-cta {
  text-align: center;
  background-color: var(--dl-color-secondary-100);
}

.profile-cta-title {
  font-size: 2rem;
  font-weight: 700;
  color: #000000;
  margin-bottom: 1rem;
}

.profile-cta-text {
  color: #000000;
  font-size: 1.125rem;
  margin-bottom: 2rem;
}

.profile-cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.2rem 2.8rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: white;
  background: linear-gradient(135deg, #0066cc 0%, #004499 100%);
  border: none;
  border-radius: 50px;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 4px 15px rgba(0, 102, 204, 0.3),
    0 2px 4px rgba(0, 0, 0, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-transform: none;
  letter-spacing: 0.5px;
  min-width: 220px;
}

.profile-cta-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.profile-cta-button:hover {
  background: linear-gradient(135deg, #0078e6 0%, #0056b3 100%);
  transform: translateY(-2px) scale(1.02);
  box-shadow: 
    0 8px 25px rgba(0, 102, 204, 0.4),
    0 4px 10px rgba(0, 0, 0, 0.15);
  color: white;
  text-decoration: none;
}

.profile-cta-button:hover::before {
  left: 100%;
}

.profile-cta-button:active {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 
    0 4px 15px rgba(0, 102, 204, 0.3),
    0 2px 5px rgba(0, 0, 0, 0.1);
}

.profile-cta-button::after {
  content: '→';
  font-size: 1.2rem;
  margin-left: 0.3rem;
  transition: transform 0.3s ease;
}

.profile-cta-button:hover::after {
  transform: translateX(3px);
}

/* ==========================================================================
   4. アニメーションスタイル (Animations)
   ========================================================================== */
.fade-in-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Animation Delays --- */
.profile-strengths-container .profile-strength-card:nth-child(2) {
  transition-delay: 0.2s;
}
.profile-strengths-container .profile-strength-card:nth-child(3) {
  transition-delay: 0.4s;
}
.profile-details-container .profile-details-card:nth-child(2) {
  transition-delay: 0.2s;
}

/* ==========================================================================
   5. レスポンシブスタイル (Responsive Styles)
   ========================================================================== */

/* --- Tablets (max-width: 991px) --- */
@media(max-width: 991px) {
  .profile-section {
    padding: 3rem 1.5rem;
  }
  .profile-intro-flex {
    flex-direction: column;
  }
  .profile-intro-image {
    margin-top: 2rem;
  }
  .profile-strengths-container {
    grid-template-columns: 1fr;
  }
  .profile-testimonials-container {
    flex-direction: column;
    align-items: center;
  }
  .profile-testimonial-card {
    width: 100%;
    max-width: 500px;
  }
  .profile-details-container {
    flex-direction: column;
    align-items: center;
  }
  .profile-details-card {
    width: 100%;
    max-width: 600px;
  }
}

/* --- Large Phones (max-width: 767px) --- */
@media(max-width: 767px) {
  .profile-hero {
    height: 40vh;
  }
  .profile-hero-title {
    font-size: 2.2rem;
  }
  .profile-hero-subtitle {
    font-size: 1.1rem;
  }
  .profile-section-title {
    font-size: 1.8rem;
  }
}

/* --- Hero Text Size Adjustments by Screen Size --- */
@media(max-width: 1200px) {
  .profile-hero .profile-hero-content .profile-hero-title {
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  }
  
  .profile-hero .profile-hero-content .profile-hero-subtitle {
    font-size: clamp(0.95rem, 2vw, 1.25rem);
  }
}

@media(max-width: 768px) {
  .profile-hero .profile-hero-content .profile-hero-title {
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    line-height: 1.2;
  }
  
  .profile-hero .profile-hero-content .profile-hero-subtitle {
    font-size: clamp(0.9rem, 1.8vw, 1.1rem);
  }
}

/* --- Small Phones (max-width: 450px) --- */
@media(max-width: 450px) {
  /* Header adjustments for small screens */
  .header-header {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0.75rem 1rem !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
  }
  .header-container1,
  .header-container4 {
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
  }
  
  /* Profile page adjustments */
  .profile-container {
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
  }
  .profile-section {
    padding: 2rem 1rem !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .profile-hero {
    height: 35vh !important;
    min-height: 250px !important;
  }
  .profile-hero-content {
    padding: 0 1rem !important;
    max-width: calc(100vw - 2rem) !important;
    width: 100% !important;
  }
  .profile-hero .profile-hero-content .profile-hero-title {
    font-size: clamp(1.3rem, 2.5vw, 1.8rem) !important;
    line-height: 1.2 !important;
    margin-bottom: 0.8rem !important;
  }
  .profile-hero .profile-hero-content .profile-hero-subtitle {
    font-size: clamp(0.85rem, 1.5vw, 1rem) !important;
    line-height: 1.4 !important;
  }
  .profile-section-title {
    font-size: 1.5rem !important;
    margin-bottom: 1.5rem !important;
  }
  .profile-intro-flex {
    gap: 1.5rem !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .profile-intro-text {
    width: 100% !important;
    max-width: 100% !important;
  }
  .profile-intro-text p {
    font-size: 0.9rem !important;
    line-height: 1.6 !important;
    margin-bottom: 1rem !important;
  }
  .profile-image-main {
    max-width: 200px !important;
    width: 100% !important;
    height: auto !important;
  }
  .profile-strengths-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }
  .profile-strength-card {
    padding: 1.5rem 1rem !important;
    margin-bottom: 1rem !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .profile-strength-card h3 {
    font-size: 1.2rem !important;
    margin-bottom: 0.8rem !important;
  }
  .profile-strength-card p {
    font-size: 0.9rem !important;
    line-height: 1.5 !important;
  }
  .profile-details-card {
    padding: 1.5rem 1rem;
    margin-bottom: 1rem;
  }
  .profile-details-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
  }
  .profile-details-card p {
    font-size: 0.9rem;
    line-height: 1.6;
  }
  .profile-cta-title {
    font-size: 1.5rem;
    line-height: 1.3;
    margin-bottom: 1rem;
  }
  .profile-cta-text {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }
  .profile-cta-button {
    padding: 1rem 2rem;
    font-size: 0.95rem;
    min-width: 180px;
    max-width: 280px;
  }

  /* Universal word break for smaller screens */
  .profile-hero-title, .profile-hero-subtitle, .profile-section-title,
  .profile-intro-text p, .profile-strength-card h3, .profile-strength-card p,
  .profile-details-card h3, .profile-details-card p,
  .profile-cta-title, .profile-cta-text {
    word-break: keep-all !important;
    overflow-wrap: break-word !important;
  }
}

/* --- Extra Small Phones (max-width: 375px) --- */
@media(max-width: 375px) {
  .header-header {
    padding: 0.5rem 0.8rem !important;
  }
  .profile-section {
    padding: 1.5rem 0.8rem !important;
    overflow-x: hidden !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .profile-hero {
    height: 30vh;
    min-height: 220px;
  }
  .profile-hero-content {
    padding: 0 0.8rem;
    max-width: calc(100vw - 1.6rem);
  }
  .profile-hero-title {
    font-size: 1.6rem;
  }
  .profile-hero-subtitle {
    font-size: 0.9rem;
  }
  .profile-section-title {
    font-size: 1.3rem;
    margin-bottom: 1.2rem;
  }
  .profile-intro-flex,
  .profile-strengths-container,
  .profile-details-container {
    width: 100%;
    overflow-x: hidden;
  }
  .profile-intro-text p,
  .profile-strength-card p,
  .profile-details-card p {
    font-size: 0.85rem;
  }
  .profile-image-main {
    max-width: 180px;
  }
  .profile-strength-card,
  .profile-details-card {
    padding: 1.2rem 0.8rem;
    width: 100%;
  }
  .profile-strength-card h3 {
    font-size: 1.1rem;
  }
  .profile-details-card h3 {
    font-size: 1.2rem;
  }
  .profile-cta-title {
    font-size: 1.3rem;
  }
  .profile-cta-text {
    font-size: 0.9rem;
  }
  .profile-cta-button {
    padding: 0.9rem 1.8rem;
    font-size: 0.9rem;
    min-width: 160px;
    max-width: 250px;
  }
}