.page-hero { padding: 8rem 0 4rem; background-color: var(--primary-color); color: white; text-align: center; }
.page-title { font-size: 3rem; font-weight: 700; margin-bottom: 1rem; }
.page-subtitle { font-size: 1.2rem; opacity: 0.9; letter-spacing: 0.2em; }
.works-intro { text-align: center; max-width: 800px; margin: 0 auto 4rem; }
.works-intro h2 { font-size: 2rem; margin-bottom: 1.5rem; color: var(--primary-color); }
.works-intro p { font-size: 1.1rem; color: var(--secondary-color); line-height: 1.9; }
.works-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 2rem; }
.work-card { background: white; border-radius: 10px; overflow: hidden; box-shadow: 0 5px 20px rgba(0,0,0,0.1); transition: var(--transition); cursor: pointer; }
.work-card:hover { transform: translateY(-10px); box-shadow: 0 10px 30px rgba(0,0,0,0.15); }
.work-image-wrapper { width: 100%; height: 250px; overflow: hidden; position: relative; }
.work-image { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.work-card:hover .work-image { transform: scale(1.1); }
.work-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.8rem; opacity: 0; transition: opacity 0.3s ease; }
.work-card:hover .work-overlay { opacity: 1; }
.view-icon { color: white; font-size: 1.1rem; padding: 0.8rem 1.5rem; background: rgba(255,255,255,0.2); border-radius: 5px; }
.image-count { color: white; font-size: 0.9rem; background: rgba(0,0,0,0.5); padding: 0.4rem 1rem; border-radius: 20px; }
.work-info { padding: 1.5rem; }
.work-info h3 { font-size: 1.3rem; margin-bottom: 0.8rem; color: var(--primary-color); }
.work-category { display: inline-block; padding: 0.3rem 1rem; background: var(--dark-gray); color: white; border-radius: 15px; font-size: 0.85rem; margin-bottom: 0.5rem; }
.work-location { display: inline-block; padding: 0.3rem 1rem; background: var(--light-gray); color: var(--secondary-color); border-radius: 15px; font-size: 0.85rem; margin-left: 0.5rem; margin-bottom: 0.5rem; }
.work-price { font-size: 1.1rem; font-weight: 600; color: var(--primary-color); margin-bottom: 0.8rem; }
.work-description { color: var(--secondary-color); line-height: 1.7; font-size: 0.95rem; }

/* Modal Styles */
.works-modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 10000; }
.works-modal.active { display: flex; align-items: center; justify-content: center; }
.modal-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); }
.modal-content { position: relative; width: 900px; max-width: 90%; background: white; border-radius: 10px; overflow: hidden; z-index: 1; }
.modal-close { position: absolute; top: 1rem; right: 1rem; width: 40px; height: 40px; background: var(--primary-color); color: white; border: none; border-radius: 50%; font-size: 1.5rem; cursor: pointer; z-index: 10; display: flex; align-items: center; justify-content: center; }
.modal-slider { display: flex; align-items: center; justify-content: center; padding: 1rem; }
.slider-container { width: 800px; height: 500px; display: flex; align-items: center; justify-content: center; }
.slider-container img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.slider-prev, .slider-next { background: var(--dark-gray); color: white; border: none; width: 40px; height: 40px; border-radius: 50%; font-size: 1.2rem; cursor: pointer; margin: 0 1rem; }
.slider-prev:hover, .slider-next:hover { background: var(--primary-color); }
.slider-dots { display: flex; justify-content: center; gap: 0.5rem; padding: 1rem; }
.slider-dots .dot { width: 10px; height: 10px; background: var(--border-color); border-radius: 50%; cursor: pointer; }
.slider-dots .dot.active { background: var(--primary-color); }
.modal-info { padding: 1.5rem; text-align: center; border-top: 1px solid var(--border-color); }
.modal-info h3 { font-size: 1.3rem; color: var(--primary-color); margin-bottom: 0.5rem; }
.modal-info p { color: var(--secondary-color); }

@media (max-width: 768px) {
  .page-hero { padding: 6rem 0 3rem; }
  .page-title { font-size: 2.2rem; }
  .works-gallery { grid-template-columns: 1fr; }
  
  /* SP版モーダル - フルスクリーン没入型デザイン */
  .modal-content { 
    max-width: 100%; 
    width: 100%; 
    max-height: 100%; 
    height: 100%; 
    border-radius: 0;
    display: flex;
    flex-direction: column;
    background: #000;
  }
  
  .modal-slider { 
    flex: 1;
    padding: 0; 
    position: relative; 
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
  }
  
  .slider-container { 
    width: 100%;
    height: auto;
    max-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .slider-container img { 
    max-height: 70vh;
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
  }
  
  /* ナビゲーションボタン - 左右にスワイプ感を表現 */
  .slider-prev, .slider-next { 
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px; 
    height: 44px; 
    font-size: 1.2rem; 
    margin: 0;
    z-index: 5;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
  }
  .slider-prev:hover, .slider-next:hover {
    background: rgba(255, 255, 255, 0.3);
  }
  .slider-prev { left: 12px; }
  .slider-next { right: 12px; }
  
  /* 閉じるボタン - 右上に目立つが邪魔にならない配置 */
  .modal-close { 
    position: fixed;
    top: 12px; 
    right: 12px; 
    width: 44px; 
    height: 44px; 
    font-size: 1.4rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    z-index: 100;
  }
  
  /* ドットインジケーター - 中央下部にエレガントに配置 */
  .slider-dots { 
    padding: 16px;
    background: transparent;
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
  }
  .slider-dots .dot {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
  }
  .slider-dots .dot.active {
    background: #fff;
    transform: scale(1.2);
  }
  
  /* 情報エリア - コンパクトで読みやすく */
  .modal-info { 
    padding: 16px 20px;
    text-align: center;
    background: linear-gradient(to top, rgba(0,0,0,0.95), rgba(0,0,0,0.85));
    border-top: none;
  }
  .modal-info h3 { 
    font-size: 1rem;
    color: #fff;
    margin-bottom: 4px;
    font-weight: 600;
  }
  .modal-info p { 
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
  }
}
