/*
Theme Name: Furusato Nanae
Theme URI: https://furusato-nanae.jp/
Author: Nanae Town Development Team
Author URI: https://nanae.jp/
Description: 北海道七飯町ふるさと納税特設サイト。Hokkaido Nanae Town Furusato Tax Official Theme. レスポンシブ対応、最新のWeb標準に準拠した美しいデザイン。
Version: 1.0.2
License: GPL v2 or later
Text Domain: furusato-nanae
Domain Path: /languages
Requires at least: 5.0
Tested up to: 6.3
Requires PHP: 7.4
Tags: custom-theme, responsive, furusato-tax, nanae-town
*/

/* 
 * メインのスタイルは assets/css/responsive-styles.css に記載
 * このファイルはWordPressテーマ認識用
 */

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'メイリオ', 'Meiryo', sans-serif;;
    overflow-x: hidden;
    width: 100%;
}

/* WordPress Core Styles */
.alignnone {
    margin: 5px 20px 20px 0;
}

.aligncenter,
div.aligncenter {
    display: block;
    margin: 5px auto 5px auto;
}

.alignright {
    float:right;
    margin: 5px 0 20px 20px;
}

.alignleft {
    float: left;
    margin: 5px 20px 20px 0;
}

a img.alignright {
    float: right;
    margin: 5px 0 20px 20px;
}

a img.alignnone {
    margin: 5px 20px 20px 0;
}

a img.alignleft {
    float: left;
    margin: 5px 20px 20px 0;
}

a img.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.wp-caption {
    background: var(--bg-white);
    border: 1px solid var(--bg-gray);
    max-width: 96%;
    padding: 5px 3px 10px;
    text-align: center;
}

.wp-caption.alignnone {
    margin: 5px 20px 20px 0;
}

.wp-caption.alignleft {
    margin: 5px 20px 20px 0;
}

.wp-caption.alignright {
    margin: 5px 0 20px 20px;
}

.wp-caption img {
    border: 0 none;
    height: auto;
    margin: 0;
    max-width: 98.5%;
    padding: 0;
    width: auto;
}

.wp-caption p.wp-caption-text {
    font-size: 11px;
    line-height: 17px;
    margin: 0;
    padding: 0 4px 5px;
}

/* Screen Reader Text */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

/* Stitch Effect for All Sections (excluding Hero) */
.SecPickup,
.SecCategory,
.SecPortalsite,
.SecShowcase,
.SecProducer,
.SecYokotsu,
.SecTown,
.SecInfo,
.SecBanner,
.SecDonors,
.SecFaq,
.SecUsage {
    position: relative;
}

.SecPickup .Back,
.SecCategory .Back,
.SecPortalsite .Back,
.SecShowcase .Back,
.SecProducer .Back,
.SecYokotsu .Back,
.SecTown .Back,
.SecInfo .Back,
.SecBanner .Back,
.SecDonors .Back,
.SecFaq .Back,
.SecUsage .Back {
    position: relative;
}

/* Stitch Top and Bottom Elements - Responsive Stitch Design */
/* 仕様: 1920px時 - 幅1pt、線分4pt、間隔6pt */
/* レスポンシブ: ブラウザ幅に比例して縮小 */
.SecPickup .stitch-top,
.SecPickup .stitch-bottom,
.SecCategory .stitch-top,
.SecCategory .stitch-bottom,
.SecPortalsite .stitch-top,
.SecPortalsite .stitch-bottom,
.SecShowcase .stitch-top,
.SecShowcase .stitch-bottom,
.SecProducer .stitch-top,
.SecProducer .stitch-bottom,
.SecYokotsu .stitch-top,
.SecYokotsu .stitch-bottom,
.SecTown .stitch-top,
.SecTown .stitch-bottom,
.SecInfo .stitch-top,
.SecInfo .stitch-bottom,
.SecBanner .stitch-top,
.SecBanner .stitch-bottom,
.SecDonors .stitch-top,
.SecDonors .stitch-bottom,
.SecFaq .stitch-top,
.SecFaq .stitch-bottom,
.SecUsage .stitch-top,
.SecUsage .stitch-bottom,
.FooterMain .stitch-top,
.FooterMain .stitch-bottom,
.FooterNavBack .stitch-top,
.FooterNavBack .stitch-bottom {
    position: absolute;
    left: 0;
    right: 0;
    background-image: linear-gradient(
        to right,
        #C3BA9B 0%,
        #C3BA9B 40%,  /* 4pt/10pt = 40% */
        transparent 40%,
        transparent 100%
    );
    /* 1920px時: 13px (10pt), 比率計算: 13/1920 = 0.677vw */
    /* clampで最小値と最大値を設定 */
    background-size: clamp(6.5px, 0.677vw, 13px) clamp(0.5px, 0.052vw, 1px);
    background-repeat: repeat-x;
    height: clamp(0.5px, 0.052vw, 1px);
    z-index: 10;
}

/* Stitch Top Position */
.SecPickup .stitch-top,
.SecCategory .stitch-top,
.SecPortalsite .stitch-top,
.SecShowcase .stitch-top,
.SecProducer .stitch-top,
.SecYokotsu .stitch-top,
.SecTown .stitch-top,
.SecInfo .stitch-top,
.SecBanner .stitch-top,
.SecDonors .stitch-top,
.SecFaq .stitch-top,
.SecUsage .stitch-top {
    top: 16px;
    background-position: top;
}

.FooterMain .stitch-top,
.FooterNavBack .stitch-top {
    top: 16px;
    background-position: top;
    background-image: linear-gradient(
        to right,
        #64a5dd 0%,
        #64a5dd 40%,  /* 4pt/10pt = 40% */
        transparent 40%,
        transparent 100%
    );
}

/* Stitch Bottom Position */
.SecPickup .stitch-bottom,
.SecPortalsite .stitch-bottom,
.SecShowcase .stitch-bottom,
.SecProducer .stitch-bottom,
.SecYokotsu .stitch-bottom,
.SecTown .stitch-bottom,
.SecInfo .stitch-bottom,
.SecBanner .stitch-bottom,
.SecDonors .stitch-bottom,
.SecFaq .stitch-bottom,
.SecUsage .stitch-bottom {
    bottom: 16px;
}

.FooterMain .stitch-bottom,
.FooterNavBack .stitch-bottom {
    bottom: 16px;
    background-image: linear-gradient(
        to right,
        #64a5dd 0%,
        #64a5dd 40%,  /* 4pt/10pt = 40% */
        transparent 40%,
        transparent 100%
    );
}

.SecCategory .stitch-bottom {
    bottom: 16px;
}

/* Border Stitch Effect for Specific Elements */
.HeroBtnBox,
.CategoryBox,
.YokotsuBoxBack,
.TownWrap,
.BannerBtn,
.FooterMain {
    position: relative;
}

/* Single element stitch border with rounded corners */
.HeroBtnBox::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 6px;
    right: 6px;
    bottom: 6px;
    border: 2px dashed #C3BA9B;
    border-radius: 5px;
    pointer-events: none;
    z-index: 10;
}

.CategoryBox::after {
    content: '';
    position: absolute;
    top: 0.79vw;
    left: 0.79vw;
    right: 0.79vw;
    bottom: 0.79vw;
    border: 2px dashed #fff;
    border-radius: inherit;
    opacity: 0.5;
    pointer-events: none;
    z-index: 10;
}

.TownWrap::after {
    content: '';
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    bottom: 15px;
    border: 2px dashed #C3BA9B;
    border-radius: clamp(15px, 1.56vw, 30px);
    pointer-events: none;
    z-index: 10;
}

.BannerBtn::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 6px;
    right: 6px;
    bottom: 6px;
    border: 1px dashed #d13a25;
    border-radius: inherit;
    pointer-events: none;
    z-index: 10;
}

/* FooterMain stitch effects removed - using stitch-top and stitch-bottom elements */


.screen-reader-text:focus {
    background-color: var(--bg-light-gray);
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 14px;
    font-size: 0.875rem;
    font-weight: bold;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* Gallery */
.gallery {
    margin-bottom: 1.5em;
}

.gallery-item {
    display: inline-block;
    text-align: center;
    vertical-align: top;
    width: 100%;
}

.gallery-columns-2 .gallery-item {
    max-width: 50%;
}

.gallery-columns-3 .gallery-item {
    max-width: 33.33%;
}

.gallery-columns-4 .gallery-item {
    max-width: 25%;
}

.gallery-columns-5 .gallery-item {
    max-width: 20%;
}

.gallery-columns-6 .gallery-item {
    max-width: 16.66%;
}

.gallery-columns-7 .gallery-item {
    max-width: 14.28%;
}

.gallery-columns-8 .gallery-item {
    max-width: 12.5%;
}

.gallery-columns-9 .gallery-item {
    max-width: 11.11%;
}

.gallery-caption {
    display: block;
}