/*!
 * Header Styles for dshop theme
 * 
 * @package dshop
 * @since 1.0.0
 */

/* Header */
.site-header {
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: stretch;
    padding: 1.5rem 2vw 1.5rem 2vw;
}

.header-left {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.header-center {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: space-between;
    margin: 0 2rem;
}

/* Header Phone */
.header-phone {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
}

.phone-text {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 0.8rem;
    font-weight: 400;
    color: #666666;
    line-height: 1;
}

.phone-number {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: #333333;
    text-decoration: none;
    transition: color 0.3s ease;
    line-height: 1;
}

.phone-number:hover {
    color: #007cba;
}

.site-title {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 2rem;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
}

.site-title a {
    color: #333333;
    text-decoration: none;
}

/* Logo Styles */
.custom-logo,
.custom-logo-link {
    display: flex;
    line-height: 0;
    align-items: center;
}

.custom-logo-image {
    max-height: 40px;
    width: auto;
    height: auto;
    transition: opacity 0.3s ease;
    vertical-align: middle;
}

.custom-logo-link:hover .custom-logo-image {
    opacity: 0.8;
}

/* WordPress Custom Logo Support */
.custom-logo-link img {
    max-height: 30px;
    width: auto;
    height: auto;
}

/* Navigation */
.main-navigation {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 1.5rem;
    align-items: center;
}

.main-navigation a {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333333;
    text-decoration: none;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
}

.main-navigation a:hover,
.main-navigation a:focus {
    color: #007cba;
}

/* Header Buttons */
.header-buttons {
    display: flex;
    gap: 0;
    align-items: stretch;
    margin-top: -1.5rem;
    margin-bottom: -1.5rem;
    margin-right: -2vw;
}

.header-btn {
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    color: #ffffff;
    background-color: #F28300;
    text-decoration: none;
    padding: 3rem 1.5rem;
    border-radius: 0;
    transition: background-color 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-btn:hover {
    background-color: #D07200;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    -webkit-tap-highlight-color: transparent;
}

.menu-toggle:focus,
.menu-toggle:active,
.menu-toggle:hover {
    background: transparent;
    outline: none;
}

.menu-toggle:focus-visible {
    outline: none;
}

.menu-icon {
    width: 30px;
    height: 30px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-icon span {
    display: block;
    width: 24px;
    height: 3px;
    background-color: #333333;
    transition: all 0.3s ease;
    position: absolute;
}

.menu-icon span:first-child {
    top: 9px;
}

.menu-icon span:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
}

.menu-icon span:last-child {
    bottom: 9px;
}

.menu-toggle[aria-expanded="true"] .menu-icon span:first-child {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-icon span:nth-child(2) {
    opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-icon span:last-child {
    bottom: 50%;
    transform: translateY(50%) rotate(-45deg);
}

/* Mobile Responsive for Header */
@media (max-width: 767px) {
    .site-header {
        flex-wrap: wrap;
        min-height: auto;
    }
    
    .header-left {
        flex: 0 0 auto;
        margin-right: 1rem;
    }
    
    .custom-logo-image {
        max-height: 24px;
    }
    
    .site-title {
        font-size: 1.2rem;
    }
    
    .header-center {
        flex: 1;
        margin: 0;
        justify-content: flex-end;
    }
    
    .header-phone {
        display: none;
    }
    
    .main-navigation {
        display: flex;
        align-items: center;
        margin-top: 0;
        position: relative;
    }
    
    .menu-toggle {
        display: flex;
        margin-left: auto;
        padding: 0.5rem;
    }
    
    .menu-icon {
        width: 24px;
        height: 24px;
    }
    
    .menu-icon span {
        width: 20px;
        height: 2px;
    }
    
    .main-navigation ul {
        display: none;
        flex-direction: column;
        gap: 1rem;
        position: absolute;
        top: 100%;
        right: 0;
        background: white;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        padding: 1rem;
        z-index: 1000;
        min-width: 200px;
    }
    
    .main-navigation.toggled ul,
    .main-navigation ul.toggled {
        display: flex;
    }
    
    .header-buttons {
        display: none;
    }
    
    /* Show buttons in mobile menu if needed */
    .main-navigation ul {
        padding-bottom: 1rem;
    }
    
    .main-navigation ul::after {
        content: '';
        display: block;
        width: 100%;
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid #eee;
    }
}

/* Small Mobile - さらに小さなサイズ調整 */
@media (max-width: 480px) {
    
    .custom-logo-image {
        max-height: 20px;
    }
    
    .site-title {
        font-size: 1rem;
    }
    
    .menu-toggle {
        padding: 0.25rem;
    }
    
    .menu-icon {
        width: 30px;
        height: 30px;
    }
    
    .menu-icon span {
        width: 16px;
        height: 2px;
    }
} 