/* =============================================
   JOE SAWADA — Main Stylesheet
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Noto+Sans:wght@300;400;500;600&family=Noto+Sans+JP:wght@300;400;500&display=swap');

/* --- Reset & Base ---------------------------------------- */
html {
    scroll-behavior: smooth;
    overflow-y: scroll; /* Force scrollbar to prevent layout shift */
}

body {
    font-family: 'Noto Sans', 'Inter', 'Noto Sans JP', sans-serif;
    background-color: #ffffff;
    color: #1a1a1a;
    -webkit-font-smoothing: antialiased;
}

/* Fix for fixed header overlapping sections */
section,
header,
#workshops {
    scroll-margin-top: 80px;
}

/* --- Carousel -------------------------------------------- */
.carousel-container {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -ms-overflow-style: none;
    scrollbar-width: none;
    gap: 0;
    padding-bottom: 1rem;
}

.carousel-container::-webkit-scrollbar {
    display: none;
}

.carousel-item {
    position: relative;
    flex: 0 0 100%;
    scroll-snap-align: start;
    overflow: hidden;
    background: #f9f9f9;
}

/* Adult content blur */
.adult-content {
    position: relative;
}

.adult-content.blurred img {
    filter: blur(20px);
}

.adult-content .adult-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 1.5rem;
    font-weight: bold;
    pointer-events: none;
    z-index: 10;
}

.adult-content:not(.blurred) .adult-overlay {
    display: none;
}

@media (min-width: 991px) {
    .carousel-item {
        flex: 0 0 50%;
    }

    .special-carousel .carousel-item {
        flex: 0 0 100%;
    }
}

.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Navigation ------------------------------------------ */
.nav-link {
    position: relative;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -2px;
    left: 0;
    background-color: #1a1a1a;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* --- Dropdown -------------------------------------------- */
.dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #ffffff;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.05);
    z-index: 100;
    padding-top: 0.5rem;
    border: 1px solid #f3f4f6;
}

.dropdown-content a {
    color: #1a1a1a;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: background 0.2s;
}

.dropdown-content a:hover {
    background-color: #f9fafb;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* --- Language switcher ----------------------------------- */
.lang-btn {
    font-size: 0.75rem;
    opacity: 0.5;
    transition: opacity 0.3s;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.lang-btn.active {
    opacity: 1;
    font-weight: 600;
}

/* --- Slider controls ------------------------------------- */
.slider-control {
    transition: all 0.3s ease;
    opacity: 0.3;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.slider-control:hover {
    opacity: 1;
}

/* --- Mobile Menu ----------------------------------------- */
#mobile-menu {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

body.menu-open {
    overflow: hidden;
}

.burger-line {
    transition: all 0.3s ease;
    transform-origin: center;
    display: block;
    width: 100%;
    height: 2px;
    background-color: #171717;
}

#menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 1.5rem;
    height: 1.5rem;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

#menu-toggle.active .line-1 {
    transform: translateY(7px) rotate(45deg);
}

#menu-toggle.active .line-2 {
    opacity: 0;
}

#menu-toggle.active .line-3 {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 990px) {
    #menu-toggle {
        display: flex;
    }
}

/* --- Publication views ----------------------------------- */

/* List view */
.pub-list-view {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.pub-list-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 0;
    border-bottom: 1px solid #f0f0ee;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}
.pub-list-item:first-child { border-top: 1px solid #f0f0ee; }

.pub-list-cover {
    width: 36px;
    height: 46px;
    object-fit: cover;
    flex-shrink: 0;
    background: #f0f0ee;
    display: block;
}

.pub-list-cover-placeholder {
    width: 36px;
    height: 46px;
    background: #f5f5f3;
    border: 1px solid #e5e5e3;
    flex-shrink: 0;
}

.pub-list-info { flex: 1; min-width: 0; }

.pub-list-title {
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pub-list-date {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #aaa;
    margin-top: 0.2rem;
}

/* Thumbnail view */
.pub-thumb-view {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .pub-thumb-view {
        grid-template-columns: repeat(4, 1fr);
    }
}

.pub-thumb-item {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: opacity 0.2s;
}

.pub-thumb-cover-wrap {
    aspect-ratio: 2/3;
    overflow: hidden;
    background: #f5f5f3;
    margin-bottom: 0.65rem;
    position: relative;
}

.pub-thumb-cover-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pub-thumb-no-cover {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f3;
}

.pub-thumb-title {
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.pub-thumb-date {
    font-size: 0.6rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #aaa;
    margin-top: 0.2rem;
}
.photo-tag {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background-color: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(4px);
    padding: 4px 8px;
    font-size: 9px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #1a1a1a;
    pointer-events: none;
    z-index: 10;
    font-weight: 500;
}

/* --- Notes/Blog styling --------------------------------- */
.note-card {
    margin-bottom: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid #f0f0ee;
}

.note-card:last-child {
    border-bottom: none;
}

.note-hero-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    margin-bottom: 2rem;
}

.note-header {
    margin-bottom: 2rem;
}

.note-title {
    font-size: 1.75rem;
    font-weight: 300;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

.note-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid #f0f0ee;
}

.note-author-photo {
    width: 70px;
    height: 70px;
    max-width: 70px;
    max-height: 70px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    flex-shrink: 0;
}

.note-author-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
}

.note-author-name {
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: #1a1a1a;
}

.note-date {
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #aaa;
}

.note-content {
    font-family: 'Noto Sans', 'Inter', 'Noto Sans JP', sans-serif;
    color: #3a3a3a;
    line-height: 1.8;
    font-size: 0.95rem;
}

.note-content p {
    margin-bottom: 1.25rem;
}

.note-content h2 {
    font-size: 1.4rem;
    font-weight: 500;
    margin: 2rem 0 1rem;
    letter-spacing: -0.01em;
}

.note-content h3 {
    font-size: 1.1rem;
    font-weight: 500;
    margin: 1.5rem 0 0.75rem;
    letter-spacing: -0.01em;
}

.note-content strong {
    font-weight: 600;
}

.note-content em {
    font-style: italic;
}

.note-content ul, .note-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.note-content li {
    margin-bottom: 0.5rem;
}

.note-content img {
    max-width: 100%;
    height: auto;
    margin: 1.5rem 0;
    display: block;
}

.note-content figure {
    margin: 1.5rem 0;
}

.note-content figcaption {
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.5rem;
    font-style: italic;
    line-height: 1.5;
}

.note-content blockquote {
    border-left: 3px solid #e5e5e3;
    padding-left: 1.25rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #666;
}

.note-content a {
    color: #1a1a1a;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.note-content a:hover {
    opacity: 0.6;
}
