/* ===== NOTES SEARCH ===== */
.notes-search-container {
    max-width: 400px;
    margin: -16px auto 20px;
}

.notes-search-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    font-size: 0.9rem;
    outline: none;
    transition: all 0.2s ease;
    background: #f8f8f8;
}

.notes-search-input:focus {
    border-color: #1a1a1a;
    background: #ffffff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

/* ===== FAMILY FILTER - DESKTOP (tombol) ===== */
.desktop-family {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 24px;
    padding: 0 4px;
}

.family-filter-btn {
    padding: 6px 14px;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    background: #ffffff;
    color: #666;
    font-size: 0.7rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.family-filter-btn:hover {
    border-color: #1a1a1a;
    background: #f5f5f5;
}

.family-filter-btn.active {
    border-color: #1a1a1a;
    background: #1a1a1a;
    color: #ffffff;
}

/* ===== FAMILY FILTER - MOBILE (dropdown) ===== */
.mobile-family {
    display: none;
    max-width: 400px;
    margin: -10px auto 20px;
}

.family-dropdown {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    font-size: 0.9rem;
    outline: none;
    background: #ffffff;
    color: #333;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23999' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.family-dropdown:focus {
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

/* ===== NOTES GRID ===== */
.notes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
    margin-top: 8px;
}

.note-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 16px 12px;
    text-align: center;
    border: 1px solid #f0f0f0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.note-card:hover {
    border-color: #d0d0d0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

.note-card .note-image-wrapper {
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: 50%;
    overflow: hidden;
    background: #f5f5f5;
    margin-bottom: 8px;
    border: 2px solid #f0f0f0;
}

.note-card .note-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.note-card .note-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1a1a1a;
}

.note-card .note-family-link {
    font-size: 0.65rem;
    color: #888;
    font-weight: 500;
    margin-top: 4px;
    display: inline-block;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.note-card .note-family-link:hover {
    color: #1a1a1a;
}

/* ===== NOTES DETAIL ===== */
.notes-detail {
    margin-top: 8px;
}

.notes-detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    background: #ffffff;
    border-radius: 16px;
}

.notes-detail-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #f8f8f8;
    border-radius: 16px;
    padding: 40px;
    min-height: 300px;
}

.notes-detail-left .note-image-big {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    overflow: hidden;
    background: #ffffff;
    border: 3px solid #e0e0e0;
}

.notes-detail-left .note-image-big img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.notes-detail-left .note-name-big {
    font-size: 2rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-top: 12px;
}

.notes-detail-left .note-family-big {
    font-size: 0.9rem;
    color: #888;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.notes-detail-left .note-family-big:hover {
    color: #1a1a1a;
}

.notes-detail-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
}

.notes-detail-right .note-desc {
    font-size: 1rem;
    color: #555;
    line-height: 1.8;
}

.notes-detail-right .note-character {
    font-size: 0.9rem;
    color: #666;
}

.notes-detail-right .note-character strong {
    color: #1a1a1a;
}

/* Notes rekomendasi di detail notes */
.notes-recommendations {
    margin-top: 32px;
    padding-top: 32px;
    border-top: 2px solid #f0f0f0;
}

.notes-recommendations h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 16px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .desktop-family {
        display: none;
    }
    .mobile-family {
        display: block;
    }
    
    .notes-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 12px;
    }
    .note-card {
        padding: 12px 10px;
    }
    .note-card .note-name {
        font-size: 0.8rem;
    }
    .notes-detail-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .notes-detail-left {
        padding: 24px;
        min-height: 160px;
    }
    .notes-detail-left .note-image-big {
        width: 120px;
        height: 120px;
    }
    .notes-detail-left .note-name-big {
        font-size: 1.4rem;
    }
    .notes-search-container {
        max-width: 300px;
        margin: -12px auto 16px;
    }
    .notes-search-input {
        padding: 10px 14px;
        font-size: 0.85rem;
    }
}

@media (max-width: 420px) {
    .notes-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 10px;
    }
    .note-card {
        padding: 10px 8px;
    }
    .note-card .note-name {
        font-size: 0.7rem;
    }
    .note-card .note-family-link {
        font-size: 0.55rem;
    }
    .notes-detail-left .note-image-big {
        width: 100px;
        height: 100px;
    }
    .notes-detail-left .note-name-big {
        font-size: 1.2rem;
    }
    .family-dropdown {
        font-size: 0.8rem;
        padding: 10px 14px;
    }
}